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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add FastAPI to web frameworks #1209

wants to merge 1 commit into
base: master


None yet
1 participant
Copy link

tiangolo commented Dec 22, 2018

What is this project?

FastAPI is a modern, fast (high-performance), web framework for building APIs with Python 3.6+.


Source Code:

The key features are:

  • Fast: Very high performance, on par with NodeJS and Go (thanks to Starlette and Pydantic).

  • Fast to code: Increase the speed to develop features by about 200% to 300% *.

  • Less bugs: Reduce about 40% of human (developer) induced errors. *

  • Intuitive: Great editor support. Completion everywhere. Less time debugging.

  • Easy: Designed to be easy to use and learn. Less time reading docs.

  • Short: Minimize code duplication. Multiple features from each parameter declaration. Less bugs.

  • Robust: Get production-ready code. With automatic interactive documentation.

  • Standards-based: Based on (and fully compatible with) the open standards for APIs: OpenAPI and JSON Schema.

* estimation based on tests on an internal development team, building production applications.

Why is it awesome?

Apart from the features above, the fact that with simple, standard Python 3.6+ type declarations, you get:

  • Great editor support (completion everywhere and type checks).
  • Data conversion (serialization, parsing).
  • Data validation.
  • Automatic annotations and documentation using OpenAPI and JSON Schema.
  • 2 automatic interactive API documentation user interfaces.

A block of code is worth a thousand words:

from fastapi import FastAPI

app = FastAPI()

def read_root():
    return {"Hello": "World"}

def read_item(item_id: int, q: str = None):
    return {"item_id": item_id, "q": q}

And you get this, "for free":

Swagger UI

And the coding experience is great, with completion and type checks everywhere:

editor support


Anyone who agrees with this pull request could vote for it by adding a 馃憤 to it, and usually, the maintainer will merge it when votes reach 20.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can鈥檛 perform that action at this time.