Azure / Azure/azure-functions-openapi-extension

Add funtionality to allow providing open API parameters without using attributes

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

Description

Currently the only way to define openapi parameters is using the openapi attributes on the function method. I'd like to be able to customise the way the open api parameters are discovered since the code i have doesn't need to use the attributes and can pull the parameter details directly from the method parameters. This is done using custom bindings similar to the ones available in AspNet (ie. FromBody, FromQuery, etc).

Possible implementation would be to add additional properties to the `IOpenApiConfigurationOptions` to allow for this customisation.

Note, conversation moved here from other issue to allow for clearer discussion.

Contributor guide

Open the contributing guide

Research direction

Start with IOpenApiConfigurationOptions and trace the existing attribute-based OpenAPI parameter discovery path. Define how configurable discovery should obtain parameter details from method parameters and custom bindings such as FromBody or FromQuery, then verify that parameters can be generated without attributes.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, csharp, openapi
Domain
api, backend-api-design
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.