# Recipes — Comuline public API Base: `https://api.comuline.com` — no auth, documented. Docs: `https://api.comuline.com/docs`; OpenAPI spec: `https://api.comuline.com/openapi`. **Caveat:** data is a frozen snapshot (last sync ~2025-03-30). Use it for station/route reference and historical schedule structure — not for current timetables. ## Stations ```bash # all stations curl -s https://api.comuline.com/v1/station | jq '.data[] | {id, name, daop: .metadata.origin.daop}' # one station (MRI = Manggarai) curl -s https://api.comuline.com/v1/station/MRI | jq '.data' ``` ## Departures at a station ```bash curl -s https://api.comuline.com/v1/schedule/MRI | jq '.data[0:5]' # rows: { train_id, line, route, station_origin_id, station_destination_id, departs_at, arrives_at, metadata.origin.color } ``` ## One train's full stop sequence ```bash curl -s https://api.comuline.com/v1/route/1448B | jq '.data.routes[] | {station_name, departs_at}' ``` ## Status ```bash curl -s https://api.comuline.com/status ``` ## If you need CURRENT timetables - The upstream partner API (`api-partner.krl.co.id`) is token-gated. Do **not** reuse the token published in a public repo — obtain legitimate partner access if you need it. - Community alternatives (not audited here): `tarif-krl` (fares/schedules), `Fannandya/api-krl` (network-data SaaS), plus the live trackers listed in [[comuline-krl-data/sources|Sources]]. - Always add a freshness check when consuming third-party transit APIs — compare `updated_at`/timestamps against today.