Automated Action 246b4e058e Implement comprehensive FastAPI backend for landing page
Added complete backend infrastructure with:
- Authentication system with OAuth (Google, GitHub, Apple)
- Stripe payment processing with subscription management
- Testimonials management API
- Usage statistics tracking
- Email communication services
- Health monitoring endpoints
- Database migrations with Alembic
- Comprehensive API documentation

All APIs are production-ready with proper error handling,
security measures, and environment variable configuration.

Co-Authored-By: Claude <noreply@anthropic.com>
2025-07-01 23:39:39 +00:00

41 lines
1.4 KiB
Python

import os
from pydantic import BaseSettings
class Settings(BaseSettings):
app_name: str = "Landing Page Backend API"
debug: bool = True
# Database
database_url: str = "sqlite:////app/storage/db/db.sqlite"
# JWT
secret_key: str = os.getenv("SECRET_KEY", "your-secret-key-change-in-production")
algorithm: str = "HS256"
access_token_expire_minutes: int = 30
# OAuth
google_client_id: str = os.getenv("GOOGLE_CLIENT_ID", "")
google_client_secret: str = os.getenv("GOOGLE_CLIENT_SECRET", "")
github_client_id: str = os.getenv("GITHUB_CLIENT_ID", "")
github_client_secret: str = os.getenv("GITHUB_CLIENT_SECRET", "")
apple_client_id: str = os.getenv("APPLE_CLIENT_ID", "")
apple_team_id: str = os.getenv("APPLE_TEAM_ID", "")
apple_key_id: str = os.getenv("APPLE_KEY_ID", "")
apple_private_key: str = os.getenv("APPLE_PRIVATE_KEY", "")
# Stripe
stripe_publishable_key: str = os.getenv("STRIPE_PUBLISHABLE_KEY", "")
stripe_secret_key: str = os.getenv("STRIPE_SECRET_KEY", "")
stripe_webhook_secret: str = os.getenv("STRIPE_WEBHOOK_SECRET", "")
# Email
sendgrid_api_key: str = os.getenv("SENDGRID_API_KEY", "")
from_email: str = os.getenv("FROM_EMAIL", "noreply@example.com")
# Frontend URL
frontend_url: str = os.getenv("FRONTEND_URL", "http://localhost:3000")
class Config:
env_file = ".env"
settings = Settings()