-
Notifications
You must be signed in to change notification settings - Fork 96
Labels
bugSomething isn't workingSomething isn't workingneeds investigationWork is needed to figure out the root cause of the problem.Work is needed to figure out the root cause of the problem.
Milestone
Description
I am having an issue with parameters being compiled as an object instead of an array. This is invalid OpenAPI.
I am using references heavily.
I have many different yaml files that are referenced by the primary spec so it is easy to maintain.
Each endpoint has parameters, which usually point to another file since they are used everywhere.
When a parameter reference points to something within the same file, the compiled parameter
Example Code (one of the referenced files) that does not work. It compiles to an object that has numbered keys.
'/v1/user':
get:
parameters:
- $ref: 'parameters.yaml#/components/parameters/ApiVersion'
- $ref: 'parameters.yaml#/components/parameters/Page'
Example Code (one of the referenced files) that does work. It compiles to an array.
'/v1/user':
get:
parameters:
- $ref: 'parameters.yaml#/components/parameters/ApiVersion'
- $ref: 'parameters.yaml#/components/parameters/Page'
- $ref: '#/components/parameters/User'
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingneeds investigationWork is needed to figure out the root cause of the problem.Work is needed to figure out the root cause of the problem.