-
Notifications
You must be signed in to change notification settings - Fork 4
IBX-10396: Added support for x-ibexa-example-file in request files #212
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
base: main
Are you sure you want to change the base?
Conversation
eb301b3 to
1be92b0
Compare
1be92b0 to
a3b0005
Compare
Co-authored-by: Konrad Oboza <konrad.oboza@ibexa.co>
|
@konradoboza I've applied your suggestions in 12a1118 In 0de53ef I'm adding improved error handling, because trying to run the OpenAPI generator failed. The result was: Hence a new PR was created: https://github.com/ibexa/collaboration/pull/105 The API file generated with the current version of the code is here:
|
|


JIRA: https://ibexa.atlassian.net/browse/IBX-10396
Current issue: request examples are not part of the REST reference, only the schema is there.
See https://doc.ibexa.co/en/5.0/api/rest_api/rest_api_reference/rest_api_reference.html#tag/Discounts/operation/api_discounts_post for an example - the schema is not that helpful when preparing a request that's more complex.
Disclaimer: I've used Copilot when writing this, especially the tests, but I've reviewed the code manually, and verified locally that it works. The tests are probably too verbose, but I'll leave the decision what to do with them up to you.
Results:
openapi_after.yaml
openapi_before.yaml
In built-in Swagger:

It also works with the buit-in Swagger doc, for both XML and JSON requests.