Nov 17, 2020
Yes, you just need to modify from @app.post to @app.get. In this tutorial, I am using POST because posting data to FastAPI server. If you just wanted to retrieve it, you can simply do it with GET and return FileResponse
For streaming, you should use streaming response instead. Have a look at the following code from official documentation
https://fastapi.tiangolo.com/advanced/custom-response/#streamingresponse