Azure / Azure/azure-functions-openapi-extension

feature request: influence/customize yaml generation

Open
#410 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C#
Stars
388
Forks
202
PR merge metrics
No merged PRs in 30d

Description

My AzureFunction ( i.e. its attributes/annotations ) looks something like this:
```
[FunctionName("GetQuotes")]
[OpenApiOperation(operationId: "GetQuotes", tags: new[] { "quotes" })]
[OpenApiResponseWithBody(statusCode: HttpStatusCode.OK, contentType: "application/json", bodyType: typeof(QuotesDto), Description = "The OK response")]
```
In the generated yaml **QuotesDto** is converted to **quotesDto** .
```
responses:
'200':
description: The OK response
content:
application/json:
schema:
$ref: '#/components/schemas/quotesDto'
```
How can I enforce the casing of the C# classnames? I.e.
```
responses:
'200':
description: The OK response
content:
application/json:
schema:
$ref: '#/components/schemas/QuotesDto'
```

Contributor guide

Open the contributing guide

Research direction

Start by tracing how the Azure Functions OpenAPI extension derives schema names from C# types during YAML generation. Compare the generated reference for QuotesDto with the requested casing and identify the existing customization or configuration entry point. Done means users can enforce the original class-name casing in generated schema references.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, csharp, openapi
Domain
backend-api-design
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.