Implements complete FastAPI backend infrastructure for MoreThanADiagnosis with:
Core Infrastructure:
- FastAPI application with CORS, error handling, health checks
- SQLAlchemy ORM with PostgreSQL support
- Pydantic configuration management
- Docker & Docker Compose for production deployment
Database Models (7 MVPs + Auth):
- User, Profile, Role, Consent (identity)
- RefreshToken, AuthAuditLog (authentication)
- ForumCategory, ForumThread, ForumPost, ForumReaction, ForumReport (forum)
- BlogPost (blog)
- PodcastEpisode (podcast)
- Resource (resources)
- TributeEntry (tribute)
- MerchProduct, Order, OrderItem (merch)
API Endpoints (Alphabetical MVPs):
- /api/v1/blog - Blog posts (list, get)
- /api/v1/forum - Categories, threads, posts, reactions, reports
- /api/v1/merch - Products, orders
- /api/v1/podcast - Episodes
- /api/v1/profiles - User profiles
- /api/v1/resources - Knowledge base
- /api/v1/tribute - Memorials
- /api/v1/health - Health checks
Configuration & Deployment:
- .env.example for configuration
- Dockerfile with multi-stage build
- docker-compose.yml for PostgreSQL + Redis + API
- Production-ready on nexus-vector with port 8000
- Non-root user, health checks, security best practices
Dependencies:
- FastAPI, SQLAlchemy, Pydantic
- PostgreSQL, Redis
- Testing (pytest), Security (passlib, python-jose)
- Full requirements.txt with 30+ packages
Status: Foundation complete, MVP endpoint stubs ready
Next: Database migrations, authentication implementation
Job ID: MTAD-IMPL-2025-11-18-CL
🤖 Generated with Claude Code
Co-Authored-By: Claude <noreply@anthropic.com>
22 lines
873 B
Python
22 lines
873 B
Python
"""
|
|
API v1 router aggregation.
|
|
|
|
Job ID: MTAD-IMPL-2025-11-18-CL
|
|
"""
|
|
|
|
from fastapi import APIRouter
|
|
from app.api.v1 import blog, forum, merch, podcast, profiles, resources, tribute, health
|
|
|
|
api_router = APIRouter()
|
|
|
|
# Include routers for all 7 MVPs
|
|
api_router.include_router(blog.router, prefix="/blog", tags=["Blog"])
|
|
api_router.include_router(forum.router, prefix="/forum", tags=["Forum"])
|
|
api_router.include_router(merch.router, prefix="/merch", tags=["Merch"])
|
|
api_router.include_router(podcast.router, prefix="/podcast", tags=["Podcast"])
|
|
api_router.include_router(profiles.router, prefix="/profiles", tags=["Profiles"])
|
|
api_router.include_router(resources.router, prefix="/resources", tags=["Resources"])
|
|
api_router.include_router(tribute.router, prefix="/tribute", tags=["Tribute"])
|
|
api_router.include_router(health.router, tags=["Health"])
|
|
|
|
__all__ = ["api_router"]
|