-
-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[REQ] name endpoint fns/methods using spec case operationId #32
Comments
This issue came up when writing v3.0.3 unit test spec. When one endpoint has multiple tags it was generated multiple times. A better way to do it is to generate each endpoint once then import or inherit it in tag code. |
@rm3l and @kevariste225 Your feature request was to get an endpoint by operationId though.
Then one could do this:
One could see my above PR as a similar-to and I am available if you want a meeting to talk about how to do it. |
Closing because this repo has been relocated |
Is your feature request related to a problem? Please describe.
Some engineers prefer that endpoint methods/fns be named using the original operationId spec case
Can this feature be added to python-experimental?
@rm3l
Describe the solution you'd like
Using the original case is possible but awkward because operationIds can be any string, even invalid python variable names like:
So to implement this, the api classes would:
__dict__
Whichever one best works with type hints would be chosen.
To do this, api_client may have to be passed in to each endpoint call.
Pseudocode would look like:
Describe alternatives you've considered
Or we can keep the code as-is where operationId is converted to python snake case
Additional context
This was requested in: OpenAPITools/openapi-generator#5214 (comment)
Similar issue: OpenAPITools/openapi-generator#3813
Please vote for what you want!
The text was updated successfully, but these errors were encountered: