Timetables data is available in the TransXChange format. This is an XML standard used for exchanging bus schedules and related data. More information including schema guidance can be found on the TransXChange website https://www.gov.uk/government/collections/transxchange.
Where multiple TransXChange datasets exist for an operator, you can use the RevisionNumber to understand the sequence of datasets that have been supplied. This can be used alongside StartDate and EndDate values to allow you to identify which data is valid at any one time, and how datasets continue on from each other.
A processed output of the timetables data is also made available in GTFS format for those consumers who would find it useful. The General Transit Feed Specification (GTFS) is a data specification that allows public transit agencies to publish their transit data in a format that can be consumed by a wide variety of software applications. Today, the GTFS data format is used by thousands of public transport providers. More information on this can be found found here.
Fares data is available in the NeTEx format. This is an XML standard developed during 2019 by industry standard leads to provide an interoperable format for the publication of fares data within the UK bus industry. NeTEx is a CEN standard that can be used to represent many aspects of a multi-modal transport network. The UK profile includes the elements related to fares for buses, for more information on the schema and profile use the following links:
Bus location data
Bus location data is available using the SIRI-VM profile shown in the table below. This is an XML standard for exchanging real time bus location information. More information including technical guidance on the SIRI-VM profile can be found on here.
|SIRI-VM profile||Type||Mandatory in Profile||Description|
|Produce ref||xsd: NMTOKEN ref||Yes||Codespace for dataset producer.|
|Vehicle Ref||String||Yes||Reference to the Vehicle.|
|VehicleJourneyRef||Yes||Reference to the Vehicle journey.|
|Operator ref||xsd:NMTOKEN||Yes||Reference to Operator in question (ID to the corresponding company in the timetable data).|
|Published line name||Int||Yes||Published line name for the line the vehicle is running on.|
|Line Ref||xsd:NMTOKEN||Yes||Reference to the Line in question (ID to the corresponding object in the timetable data).|
|Direction Ref||String||Yes||Direction of the trip.|
|Origin ref||Yes||Reference to the first stop on the vehicle’s trip.|
|Origin name||xsd:string||Yes||Reference to origin Quay in question (ID to the corresponding Quay in the timetable data and national stop place registry).|
|Aimed departure time||xsd:dateTime||Yes||The schedule time of departure from the origin stop.|
|Destination ref||xsd:NMTOKEN||Yes||Reference to destination Quay in question (ID to the corresponding Quay in the timetable data and national stop place registry) NAPTAN stop.|
|Destination name||xsd:string||Yes||Name describing the destination of the departure.|
|Aimed arrival time||xsd:dateTime||Yes||The scheduled time of arrival at the destination stop.|
|Vehicle Location-Longitude||xsd:decimal||Yes||Longitude (-180 to 180).|
|Vehicle Location-Latitude||xsd:decimal||Yes||Latitude (-90 to 90).|
|Recorded at (/GPS timestamp)||xsd:dateTime||Yes||Timestamp for when the dataset was created/published i.e. 2004-12-17T09:30:47-05:00.|
|Speed||Yes||Speed of the vehicle in question.|
|Bearing||xsd:float||Current compass bearing (direction of VehicleJourney).|
|Block ref||String||Yes||Reference to the block of the vehicle running as defined by the running boards.|
A processed output of bus location data is also made available in GTFS-RT format for those who wish to consume it. GTFS Realtime is a feed specification that allows public transportation agencies to provide realtime updates about their fleet to application developers. It is an extension to GTFS (General Transit Feed Specification), an open data format for public transportation schedules and associated geographic information. GTFS Realtime was designed around ease of implementation, good GTFS interoperability and a focus on passenger information. More information on this can be found here.