Full-Stack REST API Builder with Authentication & Database
AAdminยทMar 7, 2026
No rating
Generate a production-ready REST API with JWT authentication, database models, CRUD operations, and error handling in your preferred framework.
Act as a senior full-stack developer with 10+ years of experience building scalable backend systems. Generate a complete REST API for [Application Type] using [Framework / Language] (e.g., Node.js/Express, Python/FastAPI, Go/Gin).
Requirements:
Project Structure: Provide the full directory layout following industry best practices (MVC or Clean Architecture).
Database Models: Design and implement schemas/models for [Core Entities] using [ORM / Database] (e.g., Prisma/PostgreSQL, SQLAlchemy/MySQL, GORM/SQLite).
Authentication:
Implement JWT-based authentication (register, login, refresh token).
Add middleware for protected routes.
Include password hashing with bcrypt or equivalent.
CRUD Endpoints: For each entity, implement:
GET (list with pagination and filtering)
GET by ID
POST (with validation)
PUT / PATCH
DELETE (soft delete preferred)
Error Handling: Implement a centralized error handler with consistent JSON error responses.
Validation: Add input validation on all POST/PUT endpoints.
Environment Config: Use environment variables for secrets, database URL, and port.
Constraints:
Write clean, commented code.
Include a sample .env file.
Provide setup instructions in a README section.
Tone: Technical but clear. No unnecessary comments.