feat: utterances API routes — list, clip, tag, dismiss

Adds app/api/main.py (create_app factory with health endpoint), utterances
router (GET /api/utterances with date/room/speaker/status filters, GET clip,
POST tag, POST dismiss), stub routers for speakers/rooms/search/rag, and
tests/routes/ with 6 passing TDD tests.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-28 10:43:22 -05:00
parent 9a672c4c17
commit 4def6a526c
8 changed files with 273 additions and 0 deletions
+18
View File
@@ -0,0 +1,18 @@
import pytest
from fastapi.testclient import TestClient
@pytest.fixture
def api_client(settings):
from app.api.main import create_app
app = create_app(settings)
return TestClient(app)
@pytest.fixture
def seeded_db(db):
"""DB with a room and speaker pre-inserted."""
db.execute("INSERT INTO rooms (name) VALUES (?)", ("Kitchen",))
db.execute("INSERT INTO speakers (name) VALUES (?)", ("Jeremy",))
db.commit()
return db