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?