Reference · built on requestCommons signalTransit, roads & mobility

Metrolinx Open Data API

GO Transit and UP Express stop predictions, Union Station departures, alerts, exceptions, fares, and GTFS-realtime feeds from Metrolinx.

About

Metrolinx publishes the GO API on api.openmetrolinx.com as a set of GET calls over GO Transit and UP Express data, answering in XML, JSON, or protobuf according to the suffix you request. Topics are Stop, ServiceUpdate, ServiceataGlance, Schedule, GTFS Feeds, Fleet, and Fares, and the Access Key decides which topics you may call. Access is free after registration; the key does not expire but can be disabled if extensive calls are detected. The data are licensed under the Open Government Licence – Ontario – Metrolinx.

Through Fibric, an operator watches the stops and trips your guests or staff rely on and proposes a shuttle, roster, or notice change with the GO record attached.

This is a reference listing. It documents what Fibric would read from Metrolinx Open Data API and what it could propose, based on the publisher's published interfaces. Fibric builds it under a managed deployment when you request it; selecting it here installs nothing.

Inputs

  • Next-service predictions for a stop through api/V1/Stop/NextService/{StopCode}: ScheduledDepartureTime, ComputedDepartureTime, DepartureStatus, ScheduledPlatform, ActualPlatform
  • Union Station departures for buses and trains through ServiceUpdate/UnionDepartures/All
  • Service, information, and marketing alerts by date, and schedule exceptions for cancelled trips or stops by Train, Bus, or All
  • Service Guarantee status for a trip number and operational day
  • In-service trips through ServiceataGlance/Buses, Trains, and UPX; line and trip schedules and journeys through Schedule
  • GTFS-realtime Alerts, TripUpdates, and VehiclePosition feeds, with UP Express and occupancy variants under Fleet
  • Fares between two stop codes, optionally for an operational day, and consist data by engine number

Proposed actions

Read-only. This feed informs operators; it changes nothing.

Proposed actions are target capabilities. Every action runs propose-first and needs a validated deployment and the appropriate permissions.

What you can build

  • Time the hotel shuttle to the train that is actually coming

    NextService for the GO stop gives ComputedDepartureTime and ActualPlatform for each line. Shuttle Timing proposes when the driver leaves and which platform to meet, and keeps the prediction it used.

    With Shuttle Timing

  • Cover a shift when a GO trip is cancelled

    ServiceUpdate/Exceptions/Train lists cancelled trips and stops for the day. When one carries your staff, Shift Coverage proposes who covers the opening and attaches the exception.

    With Shift Coverage

  • Explain a late arrival with the Service Guarantee record

    ServiceGuarantee for the trip number and operational day returns that trip's Service Guarantee record. The operator matches a missed start to it and proposes an excused mark with the record attached.

    With No-Show Response

Requirements

  • A registered GO API account and an Access Key with the topics you need enabled
  • The GO stop codes, line codes, and trip numbers your sites depend on
  • The statement 'Contains information licensed under the Open Government Licence - Ontario - Metrolinx' wherever you publish the data
  • A protobuf decoder if you take the .proto form of the GTFS feeds
Authentication
A free Access Key issued after registration at api.openmetrolinx.com, sent with every method call; the capabilities assigned to the key decide which topics answer.

Limits

  • A key hit by extensive calls is disabled by removing its capabilities and must be re-enabled by hand; a 429 signals the use limit
  • Metrolinx publishes no numeric quota and no refresh interval; the help page says the data are public and real time
  • Some endpoints, among them Stop/Details and Stop/All, carry no documentation on the help page
  • The Open API Data Catalogue PDF is dated 2018-07-11

Access and pricing

Reference listing. Public feed access is separate from Fibric integration. If you request this feed, your quote covers the build, usage, and support.

Request Metrolinx Open Data API ↗

Questions and answers

How do I get a Metrolinx GO API key?
Register at api.openmetrolinx.com/OpenDataAPI. Access is free. You receive an Access Key that goes with every call; it does not change or expire. Capabilities attached to the key decide which topics answer, and a compromised key is replaced with the same capabilities.
Which formats can I request?
Append .xml, .json, or .proto to the topic path, for example api/V1/Gtfs.proto for the GTFS-realtime feeds. Stop, ServiceUpdate, Schedule, ServiceataGlance, and Fares return XML or JSON; GTFS Feeds, UP GTFS, and Fleet also return protobuf. Fleet defaults to JSON.
What licence covers the data?
The Open Government Licence – Ontario – Metrolinx, version 1: a worldwide, royalty-free, perpetual, non-exclusive licence to copy, modify, publish, and distribute the information, including commercially, with the stated attribution. It excludes personal information and logos, grants no endorsement, and comes as is.
Ask about Metrolinx Open Data API

Ask about the capabilities and requirements in this listing.

For project-specific requirements, contact Fibric.