Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

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

Does FastAPI support Swagger (OpenAPI) version 2.0 or just 3.0 of the spec? #70

Closed
EricG-Personal opened this issue Mar 6, 2019 · 4 comments

Comments

@EricG-Personal
Copy link

Does FastAPI support Swagger (OpenAPI) version 2.0 or just 3.0 of the spec?

For example, https://bravado.readthedocs.io/en/stable/, supports only version 2.0.

@EricG-Personal EricG-Personal added the question Question or problem label Mar 6, 2019
@madstacks
Copy link

From what I can see in the code, it only supports 3.0.2

self.openapi_version = "3.0.2"

@tiangolo
Copy link
Owner

@EricG-Personal yes, it only supports the latest, OpenAPI 3.x.

If you don't want to use plain requests you can generate a client with: https://github.com/OpenAPITools/openapi-generator#openapi-generator-online-docker-image

I see that Bravado generates a client with methods live, without code generation. That probably means that it can't have any "static" type checking (in your editor, before running the code), auto-completion or documentation.

Thanks @madstacks for your help here!

@tiangolo
Copy link
Owner

I'll close this issue now, but feel free to add more comments or new issues.

@tiangolo tiangolo changed the title [QUESTION] Does FastAPI support Swagger (OpenAPI) version 2.0 or just 3.0 of the spec? Does FastAPI support Swagger (OpenAPI) version 2.0 or just 3.0 of the spec? Feb 24, 2023
@tiangolo tiangolo reopened this Feb 28, 2023
@github-actions
Copy link
Contributor

Assuming the original need was handled, this will be automatically closed now. But feel free to add more comments or create new issues or PRs.

@tiangolo tiangolo reopened this Feb 28, 2023
Repository owner locked and limited conversation to collaborators Feb 28, 2023
@tiangolo tiangolo converted this issue into discussion #8235 Feb 28, 2023

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Projects
None yet
Development

No branches or pull requests

3 participants