
- Set up FastAPI project structure with best practices - Implemented SQLAlchemy models with SQLite database - Added Alembic for database migrations - Created CRUD API endpoints for items - Added health check endpoint - Updated documentation generated with BackendIM... (backend.im)
9 lines
302 B
Python
9 lines
302 B
Python
from sqlalchemy import Column, String, Text
|
|
from app.models.base import TimestampModel
|
|
|
|
class Item(TimestampModel):
|
|
"""Item model for demonstration purposes."""
|
|
__tablename__ = "items"
|
|
|
|
name = Column(String(255), nullable=False, index=True)
|
|
description = Column(Text, nullable=True) |