Files
fastapi/docs_src/path_params/tutorial004.py
2020-03-27 17:15:26 +01:00

9 lines
156 B
Python

from fastapi import FastAPI
app = FastAPI()
@app.get("/files/{file_path:path}")
async def read_file(file_path: str):
return {"file_path": file_path}