Data & API

The catalogue, readable by people and software

Far by Rail publishes its train journey catalogue as plain JSON so people and software can read the same facts. Everything below is read-only and needs no key.

There is no key, no sign-up and no rate-limit agreement. Everything is read-only.

Endpoints

  • Search journeys

    /data/search.json

    Filter the whole published catalogue by text, country, journey type, month, maximum journey length and reviewed overnight status. Returns the full match count, not just a page.

    /data/search.json?country=switzerland&max_duration_minutes=300&limit=5

  • Compact catalogue

    /data/experiences.json

    Every published journey as a compact record, paged with working next links.

    /data/experiences.json?limit=5

  • One journey, shared contract

    /data/journeys/{slug}.json

    The same semantic record the website renders: routes and variants, journey length and what it is measured from, reviewed day or overnight status with its source, pricing components with their scope, the labelled operator link, seat-side guidance, sources and photo rights.

    /data/journeys/bernina-express.json

  • One journey, canonical machine record

    /data/experiences/{slug}.json

    The canonical publication record for one journey, unchanged.

    /data/experiences/bernina-express.json

  • Compare journeys

    /data/compare.json

    Up to four journeys side by side in the order you supply. No winner is declared and nothing is ranked across different currencies, classes or journey lengths.

    /data/compare.json?slugs=bernina-express,glacier-express

  • Filter values

    /data/facets.json

    Countries, journey types and intents with counts, for use as filter values.

    /data/facets.json

  • Route geometry

    /data/map.json

    Representative polylines through published stops. Not exact track alignment; separate parts of a route stay separate.

    /data/map.json?country=japan

  • Collections

    /data/collections.json

    Index of published editorial collections, each with a machine link to members.

    /data/collections.json

  • One collection

    /data/collections/{slug}.json

    A collection and its member journeys.

    /data/collections/high-speed-train-journeys.json

  • OpenAPI description

    /openapi.json

    Machine-readable description of every endpoint, parameter, enum and error.

    /openapi.json

  • Capability manifest

    /data/manifest.json

    Canonical capability manifest with the live invocation URL for each capability.

    /data/manifest.json

  • Capability layer

    /data/capabilities.json

    Vendor-neutral capability declaration, including which transports are live.

    /data/capabilities.json

How to read the data

Source-backed, with the sources attached
Facts come from operator and official material. Each journey carries the sources consulted and, where recorded, the date they were checked.
Unknown stays unknown
If something has not been verified, it is returned as unknown. Unknown never turns into a no, and a journey type is never treated as proof of a fact.
Prices have a scope, not a promise
Recorded amounts state what they cover and when they were observed. Supplements are kept as separate components and are never added together automatically. Nothing here is a current bookable fare.
No live availability
There is no timetable, seat inventory or ticketing here. Month information describes editorial and service suitability, not whether a train runs on a chosen date.
Links are labelled for what they are
An outbound link is marked as a verified reservation entry point, the operator's own journey information page, or the operator homepage. An information page is never presented as a booking channel.
Rights stay with their owners
Public read access does not grant commercial reuse. Every photograph carries its own licence, credit and, where applicable, a note that it is an illustration rather than documentary photography.

Caching and methods

Every endpoint answers GET, HEAD and OPTIONS, and returns an ETag calculated from the content itself. Send the ETag back as If-None-Match and you get a 304 when nothing has changed, so repeated checks stay cheap. Cross-origin reads are allowed for these methods.

Unsupported or malformed parameters return a 400 with the list of supported parameters, so a filter is never silently ignored.

Sources, rights and limits

Cite the operator source attached to a fact where one is recorded, and send people to the operator to check dates, fares and availability. Photographs carry their own licence and credit, which must travel with the image. This page does not grant any new licence and makes no promise about commercial reuse.

Photography is licensed and credited to its source wherever provenance is recorded.