-
Notifications
You must be signed in to change notification settings - Fork 154
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
Changes in 'example', "examples" are not handled #666
Comments
This is not correct. For OAS 3.1:
examples:
- examp1
- examp2
Mise le meas,
--
Micheál Higgins
Senior Solutions Architect
SmartBear Software
…Sent from my iPad
On 1 Jun 2024, at 15:56, Aliaksandr Pinchuk ***@***.***> wrote:
'example' and "examples" fields in OpenAPI objects (eg Parameter, Schema, MediaType, Header) are not compared.
Old schema:
schema:
type: string,
example: old example
New schema:
schema:
type: string,
example: new example
Such fields are not valuable for API functionality, but they are important from an API documentation perspective. Descriptions are already handled, so my suggestion is to handle examples as well.
—
Reply to this email directly, view it on GitHub<#666>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ANMNL5TOC55HDFNWKYE6EBTZFHOJZAVCNFSM6AAAAABIUG6IW2VHI2DSMVQWIX3LMV43ASLTON2WKOZSGMZDSMJYGU3TEOA>.
You are receiving this because you are subscribed to this thread.Message ID: ***@***.***>
We hope you found this email of interest; however, click here if you wish to unsubscribe<http://www2.smartbear.com/SubscriptionCenter.html?utm_source=outlook&utm_medium=email&utm_content=emailsig> or manage your email preferences. Privacy Policy.<https://smartbear.com/privacy/>
Disclaimer
The information contained in this communication from the sender is confidential. It is intended solely for use by the recipient and others authorized to receive it. If you are not the recipient, you are hereby notified that any disclosure, copying, distribution or taking action in relation of the contents of this information is strictly prohibited and may be unlawful.
|
@mhiggins-SA Sorry, it's my bad, the provided schemas did not explain all the cases. For sure OAS 3.1 introduces "examples" in favor of deprecated "example". But openapi-diff works with all versions of specifications (Swagger 2.0, OAS 3.0, OAS 3.1). Basically, I would say that openapi-diff does not handle "examples" and "example" in all versions of the specification. Currently, I am working on PR to solve this, so will cover all versions. |
'example' and "examples" fields in OpenAPI objects (eg Parameter, Schema, MediaType, Header) are not compared.
Old schema:
New schema:
Such fields are not valuable for API functionality, but they are important from an API documentation perspective. Descriptions are already handled, so my suggestion is to handle examples as well.
The text was updated successfully, but these errors were encountered: