Skip to content

Latest commit

 

History

History
50 lines (35 loc) · 1.68 KB

README.md

File metadata and controls

50 lines (35 loc) · 1.68 KB

FastAPI official repository

https://github.com/fastapi/fastapi

Installation

Create and activate a virtual environment and then install FastAPI:

$ pip install "fastapi[standard]"

---> 100%

Note: Make sure you put "fastapi[standard]" in quotes to ensure it works in all terminals.

Run it

Run the server with:

$ fastapi dev main.py

 ╭────────── FastAPI CLI - Development mode ───────────╮
 │                                                     │
 │  Serving at: http://127.0.0.1:8000                  │
 │                                                     │
 │  API docs: http://127.0.0.1:8000/docs               │
 │                                                     │
 │  Running in development mode, for production use:   │
 │                                                     │
 │  fastapi run                                        │
 │                                                     │
 ╰─────────────────────────────────────────────────────╯

INFO:     Will watch for changes in these directories: ['/home/user/code/awesomeapp']
INFO:     Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit)
INFO:     Started reloader process [2248755] using WatchFiles
INFO:     Started server process [2248757]
INFO:     Waiting for application startup.
INFO:     Application startup complete.