Hello,
I will recommend checking our Next.js FastAPI Starter template to understand how to structure your application.