Skip to content
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

#Question How can I open page with swagger? #196

Closed
Maksim-Burtsev opened this issue May 20, 2023 · 1 comment
Closed

#Question How can I open page with swagger? #196

Maksim-Burtsev opened this issue May 20, 2023 · 1 comment

Comments

@Maksim-Burtsev
Copy link

Hi.
I have simple hello-world sanic application and when I start it i have page with ReDoc only which works.
изображение

And I have message about it in the console:

[2023-05-20 22:38:24 +0300] [92186] [INFO]   > injection [0 dependencies; 0 constants]
[2023-05-20 22:38:24 +0300] [92186] [INFO]   > openapi [http://0.0.0.0:8000/docs]
[2023-05-20 22:38:24 +0300] [92186] [INFO]   > http 

But if i open /swagger page i have 404:

изображение
from sanic import Sanic

app = Sanic("HelloWorld")

Why swagger doesnt works and how can i run it?

@ahopkins
Copy link
Member

https://sanic.dev/en/plugins/sanic-ext/openapi/ui.html#ui
image

That is of course just the default. You can configure it however you want.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants