Allow custom schema examples in OpenAPI format - #616
Merged
Conversation
Contributor
Author
|
Started to check the validity of the scheme through swagger editor and realized that it needs some fine-tuning. I'll reopen the PR later. UPD: |
Contributor
Author
|
I found a error in example. |
mxck
commented
Jun 11, 2022
Eomm
reviewed
Jun 12, 2022
Co-authored-by: Manuel Spigolon <behemoth89@gmail.com>
Eomm
approved these changes
Jun 12, 2022
Contributor
Author
|
Please look again. I added support of examples to params, response and body. |
mcollina
reviewed
Jun 14, 2022
| minItems: 1, | ||
| } | ||
| }, | ||
| "x-examples": { |
Member
There was a problem hiding this comment.
Could you make this example complete? I think we need a custom Ajv config, i.e. ajv.addKeyword() to make this work.
Member
|
@climba03003 @Eomm could you take a look? |
2 tasks
4 tasks
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Hi!
I added the ability to pass examples directly through the "x-examples" field (check this #535 (comment)) and added documentation about examples in general.
Checklist
npm run testandnpm run benchmarkand the Code of conduct