zuhrulumam/go-parking-lot — reverse-engineered prompt

Reverse engineered prompt

GitHub

Build me a Go backend for a parking lot system with multiple entry and exit gates. It should let someone park a vehicle, unpark it, search for a vehicle by plate number, and check how many spots are still available.

The important part is handling lots of requests at the same time safely. If two gates try to park cars at once, they should never get the same spot, and a car should only have one active parking record. Use PostgreSQL for storage and make the database updates reliable with transactions.

Please include clean, simple API endpoints with Swagger or OpenAPI docs so I can test them in the browser. Set it up so I can run everything locally with Docker, use an env file for config, seed the database with parking spots, and run tests. If possible, include a basic load test so I can see how it behaves under traffic.

Want more depth? Deep Reverse