Back to API parent page

Method: schedule-for-route

Retrieve the full schedule for a route on a particular day

Sample Response

    <data class="entryWithReferences">
       <entry class="routeSchedule">
          <!-- More serviceId entries... -->
              <tripHeadsign>E to Boeing - W to Mukilteo</tripHeadsign>
                 <!-- More stopId entries... -->
                 <!-- More tripId entries... -->
                        <!-- More tripWithStopTimes entries... -->
          <!-- More StopTripGrouping entries... -->

Request Parameters

  • id - the route id to request the schedule for, encoded directly in the URL:
  • date - The date for which you want to request a schedule of the format YYYY-MM-DD (optional, defaults to current date)


The intent of this response is to mimic a traditional schedule-table format for viewing a route. As such the entry includes traditional header information, as well as a section of concentrated schedule information (in the form of stopTripGroupings).

The header information is: * <routeId/> - the route being looked into - this information is presented in the format [agency]_[routeIdentifier] * <scheduleDate/> - the date being looked at - the date of service in milliseconds since the Unix epoch * <serviceIds> - the Service Ids which contain that route and are live on the specified date - for more information see the GTFS spec

The entry also has concentrated schedule information in the form of stopTripGroupings. Each grouping includes: * <directionId\> - the direction the trips are heading - for more information see the GTFS spec * <tripHeadsign\> - the trip headsign - a string indicting the destination of the trip * <stopIds\> - an ordered list of stop Ids - Each id is of the format [agency]_[stopIdentifier] * <tripIds\> - a list of trip Ids that matched by shared direction- Each trip Id is of the format [agency]_[tripIdentifier]

Alternate codes: 404 - returned if the route ID in the request is not found 510 - returned if the route has no schedules for the day requested