# CodeTutor Backend

FastAPI backend for the CodeTutor coding interview preparation application.

## Setup

```bash
# Install dependencies
pip install -e ".[dev]"

# Run migrations
alembic upgrade head

# Load content data
python scripts/load_data.py

# Start development server
uvicorn src.main:app --reload
```

## API Endpoints

- `GET /api/questions` - List questions with filters
- `GET /api/questions/{slug}` - Question detail
- `GET /api/categories` - List categories
- `GET /api/patterns` - List patterns
- `GET /api/patterns/{slug}` - Pattern detail
- `GET /api/stats` - Aggregate statistics
- `GET /api/health` - Health check

## Testing

```bash
pytest
```

## Code Quality

```bash
ruff check .
ruff format --check .
mypy src/
```
