springwolf-core icon indicating copy to clipboard operation
springwolf-core copied to clipboard

Is there any library to validate the ascynapi documents and show the errors in documents ?

Open ajit2k21 opened this issue 1 year ago • 2 comments

Created asyncapi document and tested it with springwolf-ui sample application. But it gives errors with springwolf-ui but giving no error with official AscynAPI UI (https://studio.asyncapi.com/). Can you please check the ascynapi file asyncapi-sample.json whether I missed anything in this file or not.

ajit2k21 avatar Oct 19 '24 02:10 ajit2k21

Welcome to Springwolf. Thanks a lot for reporting your first issue. Please check out our contributors guide and feel free to join us on discord.

github-actions[bot] avatar Oct 19 '24 02:10 github-actions[bot]

Hi @ajit2k21, there is no library for it and I considered it also as a non-goal.

Note: springwolf-ui doesn't support the full AsyncAPI spec. Source: https://www.springwolf.dev/docs/faq

You can use springwolf-examples/springwolf-kafka-example/src/test/resources/asyncapi.json as a reference for the structure. Additionally, you can edit that file while running the npm start dev server in springwolf-ui and verify that no typescript errors are outputted.


As a general question, what are you trying to achieve? Have you considered using the async api renderer, since you use a non Springwolf-generated asyncapi file?

The AsyncApi renderer supports the full spec. Example: https://github.com/timonback/springwolf-asyncapi-ui/blob/main/template/index.ejs using the AsyncAPI library https://github.com/asyncapi/asyncapi-react

timonback avatar Oct 19 '24 14:10 timonback

Closing due to inactivity

timonback avatar Jan 31 '25 12:01 timonback