Introduction โ
Fastpy is a production-ready FastAPI starter kit that helps you build APIs faster with less boilerplate. It combines the power of FastAPI with battle-tested patterns and a powerful CLI code generator.
What You'll Build
By the end of this guide, you'll have a complete REST API with authentication, database models, and CRUD operations.
What is Fastpy? โ
FastCLI
30+ code generators for models, controllers, routes, and more
Authentication
JWT with refresh tokens, password reset, email verification
Database Support
PostgreSQL or MySQL with SQLModel ORM
Clean Architecture
MVC with service/repository patterns
Testing Setup
pytest with async support and factories
Built-in Facades
Http, Mail, Cache, Storage, Queue, and more
Who is it for? โ
Fastpy is perfect for developers who:
| Profile | Need |
|---|---|
| Backend Developers | Skip boilerplate and focus on business logic |
| Startup Teams | Need a production-ready foundation fast |
| Solo Developers | Want convention over configuration |
| API Architects | Value clean, maintainable code architecture |
Core Principles โ
Convention Over Configuration
Sensible defaults that work out of the box. Override only what you need.
Developer Experience First
Type hints everywhere, excellent IDE support, comprehensive docs, and helpful error messages.
Production Ready
Not just a demo project. Includes everything you need for real-world APIs: auth, rate limiting, logging, testing, and deployment configs.
Quick Example โ
Create a complete API resource in seconds:
fastpy make:resource Post \
-f title:string:required,max:200 \
-f body:text:required \
-f author_id:integer:foreign:users.id \
-m -pThis single command generates:
| Generated | Description |
|---|---|
| Model | SQLModel with fields and validation |
| Controller | Full CRUD operations |
| Routes | Protected API endpoints |
| Migration | Database schema changes |