📝 Move tutorial src files to top level docs

This commit is contained in:
Sebastián Ramírez committed 2018-12-21 16:22:33 +04:00
1 parent d5e782074f
commit 0a65c41909
132 files changed
+134 -422

No files matched your search

+15
View File
@@ -0,0 +1,15 @@
from fastapi import FastAPI
app = FastAPI()
@app.get("/items/{item_id}")
async def read_item(item_id: str, q: str = None, short: bool = False):
item = {"item_id": item_id}
if q:
item.update({"q": q})
if not short:
item.update(
{"description": "This is an amazing item that has a long description"}
)
return item