import gradio as gr from fastapi import FastAPI app = FastAPI() @app.get("/") def read_main(): return {"message": "This is your FastAPI app"} import main gr.mount_gradio_app(app, main.demo, path="/")