alperencubuk/fastapi-celery-redis-postgres-docker-rest-api ? reverse-engineered prompt

Reverse engineered prompt

Build me a simple backend API that runs with Docker Compose and uses FastAPI, Celery, Redis, PostgreSQL, and SQLAlchemy.

I want endpoints that let me create users from randomuser.me and weather records from a weather API in the background, then save them in the database and return a task id right away. I also want to be able to check a task by id and see whether it is still running or finished. After the data is saved, there should be endpoints to fetch a user by id and fetch weather data for a city from the database.

Please make it easy to run with one command, and set it up so the API, worker, Redis, and Postgres all work together in containers. If anything needs current docs or best practices, look them up online and use the latest approach.

Are you gonna build this?

make sure you review the code using coderabbit

Try freeSponsored — opens CodeRabbit in a new tab