-
-
Notifications
You must be signed in to change notification settings - Fork 382
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
Example: Implementing Crow with Swagger UI #603
Comments
@julianxhokaxhiu : Here's the answer to the question you posed on #585 . |
Will check this and let you know if I have more questions on top. But looking through the demo repo looks pretty much self-explanatory. Thanks a lot in the meantime! |
@xia-stan I have one question on top of your project. I've seen the whole structure and that's super clear to me. The only part I'm missing is how the Swagger template will pick my endpoints, will I have to declare them manually somewhere or are they going to be auto discovered? Also how is documentation of this API endpoints ( and parameters ) are supposed to work? Do I have to type that manually? Thank you in advance. //EDIT: I see also this in your documentation |
That's correct. Crow (v1.0+5) doesn't automatically generate the OpenAPI specification file. You have to generate that yourself. |
Thank you @xia-stan I'll see what I can make out of this. Appreciated :) |
To keep #585 's message thread clean, I wanted to make this comment to address the question posed about implementing Crow and Swagger UI. The implementation is pretty straight forward. For a long answer, I've made an example repository for reference.
For the quick and dirty answer, define and register a blueprint
Then point
swagger-initializer.js
to your OpenAPI yaml file and update Swagger UI's index.html to use the blueprinted paths. Finally, execute your program from the same directory as your blueprint base path definition.The text was updated successfully, but these errors were encountered: