Swagger v3 YAML format support | Community
Skip to main content
Level 2
October 20, 2022
Solved

Swagger v3 YAML format support

  • October 20, 2022
  • 2 replies
  • 1936 views

The latest Swagger v3 has YAML format.   Does AEM support Swagger definition in YAML format or it has to convert to JSON in order for AEM to parse?  Tried with petstore.yaml with that latest SP 14 and the create data source UI hang. 

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Mayank_Gandhi

@lyuan only v2 is supported, I tested pet store on my local it worked fine, send me your YAML(inbox the link)

2 replies

Pulkit_Jain_
Adobe Employee
Adobe Employee
October 20, 2022

@lyuan 

AEM forms currently support swagger 2.0 but recall a discussion around including support for 3.0 in future releases.

I will check and get back to you with a response to your questions on the YAML format as well.

Adobe Employee
October 20, 2022

you can use YAML format, does not have to be in JSON

yes  AEM Forms supports OpenAPI Specification version 2.0 (fka Swagger).

LYUANAuthor
Level 2
October 20, 2022

We've tried with petstore.yaml with SP 14 and it hang and cannot finish during cloud data source creation.  The error log showing AEM is trying to parse it as JSON via Google JSON parser and failed with null pointer errors.   It would be great if the success steps in SP 14 can be shared.   Thanks a lot.

Mayank_Gandhi
Adobe Employee
Mayank_GandhiAdobe EmployeeAccepted solution
Adobe Employee
October 26, 2022

@lyuan only v2 is supported, I tested pet store on my local it worked fine, send me your YAML(inbox the link)

LYUANAuthor
Level 2
October 26, 2022

@mayank_gandhi, thank you for confirming that only v2 supported.   Tested v2 YAML and JSON and both work.  https://petstore3.swagger.io/api/v3/openapi.yaml was the URL tested and failed, which is the V3 version.  This explains why it didn't work.  Looking forward to see AEM supporting v3 API in the future.

Mayank_Gandhi
Adobe Employee
Adobe Employee
October 27, 2022

@lyuan you may raise a feature request for the same. 

 

Happy to help!