seifhassan89/StudentWebApi — reverse-engineered prompt

Reverse engineered prompt

GitHub

Build me a simple ASP.NET Core Web API for managing a small school system.

I want endpoints for students, courses, and departments. For each one, I should be able to create, view all, view one by id, update, and delete. Students should be able to have courses, so I need an endpoint to get the courses for a student. Courses should also show their students, and I need endpoints to add a student to a course and remove a student from a course.

Use Entity Framework Core with MySQL for the database, and set up Swagger so I can test everything in the browser. Keep the project clean and easy to understand, with separate models, services, repositories, and mapping where it makes sense. Include basic validation and sensible responses for missing records or bad requests.

Please make it runnable locally, include the database setup or migrations, and add a Postman collection or clear examples for testing the API.

Want more depth? Deep Reverse