# Sightscreen ## Docs - [Authentication](https://285e39fd5e337e58f16290.sightscreen.app/backend/authentication.md): How auth works in the backend -- Cognito JWT, API keys, middleware chain, and Sentry integration. - [Background jobs](https://285e39fd5e337e58f16290.sightscreen.app/backend/background-jobs.md): The background jobs that power the real-time scoring and Live Activity system. - [Configuration reference](https://285e39fd5e337e58f16290.sightscreen.app/backend/configuration.md): All environment variables and their purposes. - [Devices](https://285e39fd5e337e58f16290.sightscreen.app/backend/endpoints-devices.md): Multi-device registration, push tokens, and notification endpoints. - [Fixtures](https://285e39fd5e337e58f16290.sightscreen.app/backend/endpoints-fixtures.md): Fixture import, sync, and management endpoints. - [Health & config](https://285e39fd5e337e58f16290.sightscreen.app/backend/endpoints-health.md): Health checks, readiness probes, and app configuration endpoints. - [Leagues](https://285e39fd5e337e58f16290.sightscreen.app/backend/endpoints-leagues.md): League management and configuration endpoints. - [Matches](https://285e39fd5e337e58f16290.sightscreen.app/backend/endpoints-matches.md): Match listing, live scores, match following, and Live Activity endpoints. - [Replay & testing](https://285e39fd5e337e58f16290.sightscreen.app/backend/endpoints-replay.md): Replay match simulation and tape management endpoints. - [Teams](https://285e39fd5e337e58f16290.sightscreen.app/backend/endpoints-teams.md): Team registry, SportMonks import, and display overrides. - [Users](https://285e39fd5e337e58f16290.sightscreen.app/backend/endpoints-users.md): User profile, account, and follow sync endpoints. - [Observability](https://285e39fd5e337e58f16290.sightscreen.app/backend/observability.md): Structured logging with pino, error tracking with Sentry, and distributed tracing for the LA pipeline. - [Authentication flow](https://285e39fd5e337e58f16290.sightscreen.app/business-flows/auth-flow.md): How authentication works across the system. - [Device registration & push tokens](https://285e39fd5e337e58f16290.sightscreen.app/business-flows/device-registration.md): How iOS devices register for push notifications — now with multi-device support. - [Live Activity lifecycle](https://285e39fd5e337e58f16290.sightscreen.app/business-flows/live-activity-lifecycle.md): How Live Activities are created, updated, and ended — from user follow to lock screen dismissal. - [Live score → lock screen](https://285e39fd5e337e58f16290.sightscreen.app/business-flows/live-scores.md): How a live cricket score travels from SportMonks to the user's lock screen via the event-driven pipeline. - [Match following](https://285e39fd5e337e58f16290.sightscreen.app/business-flows/match-following.md): What happens when a user follows a match — from tap to Live Activity. - [Replay system](https://285e39fd5e337e58f16290.sightscreen.app/business-flows/replay-system.md): Test the full live scoring pipeline on demand using pre-recorded match tapes. - [Architecture](https://285e39fd5e337e58f16290.sightscreen.app/ios/architecture.md): iOS app architecture — server-driven UI, MVVM with @Observable, facade pattern, DataSource + ViewSubscriber, cache-first reads, and Swift 6 actor isolation. - [Build & deploy](https://285e39fd5e337e58f16290.sightscreen.app/ios/build-deploy.md): Build configuration, scripts, and deployment. - [Data models & code generation](https://285e39fd5e337e58f16290.sightscreen.app/ios/data-models.md): Generated Swift models from backend Zod schemas, the two-stage codegen pipeline, and the API contract. - [Live Activities](https://285e39fd5e337e58f16290.sightscreen.app/ios/live-activities.md): Live Activity lifecycle, the three-manager architecture, push-to-start, token management, Dynamic Island presentations, and the APNs contract. - [Live Activity platform reference](https://285e39fd5e337e58f16290.sightscreen.app/ios/live-activity-platform.md): How iOS Live Activities work at the platform level — architecture, token lifecycle, APNs payloads, and production gotchas. Read this before touching LA code. - [Services](https://285e39fd5e337e58f16290.sightscreen.app/ios/services.md): The service layer — protocols, real/fake implementations, DI via @Environment, and the DataSource + ViewSubscriber pattern. - [Architecture decision records](https://285e39fd5e337e58f16290.sightscreen.app/system-map/adrs.md): Key architectural decisions made in the project, with context and rationale. - [Code conventions](https://285e39fd5e337e58f16290.sightscreen.app/system-map/conventions.md): Coding standards, architectural rules, and review guidelines enforced across the codebase. - [Data model](https://285e39fd5e337e58f16290.sightscreen.app/system-map/data-model.md): All DynamoDB tables, their keys, GSIs, and which services access them. - [Layer architecture](https://285e39fd5e337e58f16290.sightscreen.app/system-map/layers.md): How the backend is structured internally — layers, dependency flow, the event-driven pipeline, and the factory-based injection pattern. - [Learnings](https://285e39fd5e337e58f16290.sightscreen.app/system-map/learnings.md): Hard-won lessons from production development — patterns to follow and traps to avoid. - [Overview](https://285e39fd5e337e58f16290.sightscreen.app/system-map/overview.md): What is Sightscreen — an event-driven cricket live-scoring platform with backend API, iOS app, and Pavilion admin app. - [System context](https://285e39fd5e337e58f16290.sightscreen.app/system-map/system-context.md): High-level diagram of all systems and how they connect in the Sightscreen platform. ## OpenAPI Specs - [openapi](https://285e39fd5e337e58f16290.sightscreen.app/api-reference/openapi.json)