OpenAPITools / OpenAPITools/openapi-generator
[REQ] Allow referencing vendor extensions at the path level
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 26.8k
- Forks
- 7.7k
- PR merge metrics
- PR metrics pending
Description
Is your feature request related to a problem? Please describe.
I have the following two vendor extensions in my OpenAPI spec, x-foo-at-path-level and x-foo-at-operation-level:
/pets:
x-foo-at-path-level: true
get:
x-foo-at-operation-level: true
responses:
'200':
description: A list of pets.
content:
...
I'm able to reference x-foo-at-operation-level with the following in mustache:
{{#operations}}
{{#operation}}
{{vendorExtensions.x-foo-at-operation-level}} // able to reference this
{{/operation}}
{{/operations}}
However, I'm not able to reference x-foo-at-path-level (or at least don't know how to).
Describe the solution you'd like
Please allow accessing the vendor extensions at the path level with {{../vendorExtensions.x-foo-at-path-level}} or similar syntax.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names no file or test. Start by tracing how operation-level vendor extensions are exposed to Mustache templates, then compare that context with the path-level data available during generation. Done means a path-level extension is accessible from the template context as described, with coverage for the provided OpenAPI example.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, openapi
- Domain
- api, tooling
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100