# Train Badger > Train Badger is a UK train times app with automatic Delay Repay tracking. AI agents use its Delay Repay API (v1 beta) to pre-register a user's future trains, read which journeys are claimable, and record filed claims — the agent files each claim on the operator's own website and must show it to the human before submitting. - Agent guide (human-readable): [For AI agents](https://trainbadger.app/for-agents) - Full agent guide (this file's long form): [llms-full.txt](https://trainbadger.app/llms-full.txt) - API reference: [api-docs](https://trainbadger.app/api-docs) - OpenAPI spec: [openapi.json](https://trainbadger.app/api-docs/openapi.json) - REST base URL: `https://api.trainbadger.app` - MCP server: `https://api.trainbadger.app/mcp` (streamable HTTP, stateless, 8 delay-repay tools) ## Published API (complete — nothing else is documented or stable) Public lookups (no auth): - `GET /public/journey-check` — how a past train performed: times, delay minutes, cancellation, eligibility - `GET /public/delay-repay/{operator}` — an operator's Delay Repay scheme, bands and claim link - `GET /public/crs/{query}` — station search by name or CRS code fragment Your own account data (Bearer [REDACTED] — agents use a scoped `tb_live_` API key, never a password): - `GET /api/journeys` — journey history with Delay Repay eligibility per journey - `GET /api/journeys/claim-summary` — unclaimed eligible journeys grouped by operator (the work list) - `PUT /api/journeys/{id}/claimed` — mark a filed claim so it drops out of the work list - `GET /api/keys` — list your API keys (login token only) - `POST /api/keys` — mint a scoped API key (login token only) - `DELETE /api/keys/{id}` — revoke a key (login token only) - `POST /api/tracked-journeys` — pre-register a future train before its scheduled departure - `GET /api/tracked-journeys` — list pre-registered journeys and their resolution state - `GET /api/tracked-journeys/{id}` — fetch one pre-registered journey - `PATCH /api/tracked-journeys/{id}` — edit a pre-registered journey - `DELETE /api/tracked-journeys/{id}` — withdraw a pre-registered journey - `GET /api/account/export` — export everything held on the account (login token only) ## Agent workflow 1. Mint a key (app: Settings › API Access, or the account portal) with `delay-repay:read`, plus `delay-repay:write` and `delay-repay:track` as needed. 2. Pre-register travel with `POST /api/tracked-journeys` before each scheduled departure (or `track_journey` over MCP). 3. Poll `GET /api/journeys/claim-summary` (or `get_my_delay_repay_claims`) for claimable journeys — only `verificationStatus` `verified` or `user_confirmed` can be filed. 4. File each claim on the operator's `claimUrl`, showing it to the human first. 5. Mark filed with `PUT /api/journeys/{id}/claimed` (or `mark_delay_repay_claimed`). Beta: shapes may change, no SLA. Terms: https://trainbadger.app/terms. Tip: the iOS app records journeys automatically with live verification — no pre-registration needed.