Repository navigation
Support OpenAPI 3.2 #499
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
Merged
Merged
Support OpenAPI 3.2 #499
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
56d6958
Support OpenAPI 3.2
modosc 5bb684f
Match additionalOperations by exact method case and ignore trace requ…
modosc ef6aabd
Require openapi_parser 2.7 for exact-case additionalOperations matching
modosc 21d1eed
Keep additionalOperations apart from standard methods that differ onl…
modosc f96462c
Require openapi_parser 2.8 so a Get request routes to additionalOpera…
modosc File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,199 @@ | ||
| openapi: 3.2.0 | ||
| info: | ||
| version: 1.0.0 | ||
| title: OpenAPI 3.2 Test | ||
| description: A Sample file | ||
| paths: | ||
| /items: | ||
| query: | ||
| description: search items with a request body | ||
| requestBody: | ||
| required: true | ||
| content: | ||
| application/json: | ||
| schema: | ||
| $ref: '#/components/schemas/ItemQuery' | ||
| responses: | ||
| '200': | ||
| summary: matching items | ||
| description: success | ||
| content: | ||
| application/json: | ||
| schema: | ||
| type: array | ||
| items: | ||
| $ref: '#/components/schemas/Item' | ||
| additionalOperations: | ||
| PURGE: | ||
| description: purge cached items | ||
| parameters: | ||
| - name: older_than | ||
| in: query | ||
| required: false | ||
| schema: | ||
| type: integer | ||
| responses: | ||
| '204': | ||
| description: purged | ||
| purge: | ||
| description: a distinct operation, since method names are case-sensitive | ||
| parameters: | ||
| - name: scope | ||
| in: query | ||
| required: true | ||
| schema: | ||
| type: string | ||
| responses: | ||
| '204': | ||
| description: purged | ||
| SEARCH: | ||
| description: search items with a custom method | ||
| requestBody: | ||
| required: true | ||
| content: | ||
| application/json: | ||
| schema: | ||
| $ref: '#/components/schemas/ItemQuery' | ||
| responses: | ||
| '200': | ||
| description: success | ||
| trace: | ||
| description: a requestBody that must be ignored, since TRACE carries no content | ||
| requestBody: | ||
| required: true | ||
| content: | ||
| application/json: | ||
| schema: | ||
| $ref: '#/components/schemas/ItemQuery' | ||
| responses: | ||
| '200': | ||
| description: success | ||
| /pets: | ||
| post: | ||
| description: create a pet | ||
| requestBody: | ||
| content: | ||
| application/json: | ||
| schema: | ||
| $ref: '#/components/schemas/Pet' | ||
| responses: | ||
| '200': | ||
| description: success | ||
| /shared: | ||
| post: | ||
| description: request and response bodies from components.mediaTypes | ||
| requestBody: | ||
| content: | ||
| application/json: | ||
| $ref: '#/components/mediaTypes/ItemJson' | ||
| responses: | ||
| '200': | ||
| description: success | ||
| content: | ||
| application/json: | ||
| $ref: '#/components/mediaTypes/ItemJson' | ||
| /versions: | ||
| get: | ||
| description: the standard GET | ||
| parameters: | ||
| - name: standard | ||
| in: query | ||
| required: true | ||
| schema: | ||
| type: string | ||
| responses: | ||
| '200': | ||
| description: success | ||
| additionalOperations: | ||
| Get: | ||
| description: a distinct method from GET, since method names are case-sensitive | ||
| parameters: | ||
| - name: custom | ||
| in: query | ||
| required: true | ||
| schema: | ||
| type: string | ||
| responses: | ||
| '200': | ||
| description: success | ||
| SYNC~V2: | ||
| description: a method name with a character escaped in JSON Pointers | ||
| responses: | ||
| '200': | ||
| description: success | ||
| /filter: | ||
| get: | ||
| description: whole query string as one parameter | ||
| parameters: | ||
| - name: filter | ||
| in: querystring | ||
| required: true | ||
| content: | ||
| application/x-www-form-urlencoded: | ||
| schema: | ||
| type: object | ||
| required: | ||
| - q | ||
| responses: | ||
| '200': | ||
| description: success | ||
| /events: | ||
| get: | ||
| description: server-sent events | ||
| responses: | ||
| '200': | ||
| description: event stream | ||
| content: | ||
| text/event-stream: | ||
| itemSchema: | ||
| type: object | ||
| required: | ||
| - data | ||
| components: | ||
| mediaTypes: | ||
| ItemJson: | ||
| schema: | ||
| $ref: '#/components/schemas/Item' | ||
| schemas: | ||
| Item: | ||
| type: object | ||
| required: | ||
| - name | ||
| properties: | ||
| name: | ||
| type: string | ||
| ItemQuery: | ||
| type: object | ||
| required: | ||
| - name | ||
| properties: | ||
| name: | ||
| type: string | ||
| limit: | ||
| type: integer | ||
| minimum: 1 | ||
| Pet: | ||
| oneOf: | ||
| - $ref: '#/components/schemas/Cat' | ||
| - $ref: '#/components/schemas/Dog' | ||
| discriminator: | ||
| propertyName: pet_type | ||
| defaultMapping: Cat | ||
| Cat: | ||
| type: object | ||
| required: | ||
| - name | ||
| properties: | ||
| pet_type: | ||
| type: string | ||
| name: | ||
| type: string | ||
| Dog: | ||
| type: object | ||
| required: | ||
| - bark | ||
| properties: | ||
| pet_type: | ||
| type: string | ||
| bark: | ||
| type: boolean |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.