How to handle HTTP requests with Streamlit?

I have a streamlit app currently deployed on Google’s App Engine. For this application, we want to introduce App Engine Cloud Tasks, to help us with timing and managing our resources. To create a task, our streamlit app on Google App Engine must be able to accept HTTP requests. Are there any good ways to do this?

Ideally we would like to use Flask in our streamlit app, but would like to avoid running two servers if possible.

Thanks in advance!

Hello @vdana, welcome to the forum!

There’s no way to use the Tornado backend used by Streamlit to process our own requests for now. I believe I saw a post on having Streamlit run a Flask/FastAPI process instead of managing 2 different servers, wait I got it here:

I’m actually not sure it answers your use case directly, especially if you expect to return Flask data into Streamlit. Maybe we’d need more info on your use case?

Fanilo :balloon: