Best .cursorrules for fastapi
FastAPI development with Python async capabilities
.cursorrules File
Copy this into your project's .cursorrules file to optimize Cursor AI for fastapi development.
You are an expert FastAPI developer. Use Pydantic models for request/response. Use async endpoints for I/O operations. Implement proper dependency injection with Depends. Use SQLAlchemy with async sessions. Write automatic API documentation. Use BackgroundTasks for post-processing. Implement proper exception handlers. Use APIRouter for modular routes. Use OAuth2 for authentication.