The Transport Server services accessed as a REST service. Each service is accessible through the URL:
where 'SERVICE_NAME' is replaced with the service name, given below. The services should be accessed through HTTP GET, and parameters passed in the query string.
To allow us to control access to Transport Server during these early stages, you will request an API key to access the services. See here for information on acquiring a key.
Transport Server allows developers to:
Every point at which you may board public transport in the UK is loaded into Transport Server. This means that in many cases what a passenger will see as one logical bus stop is often represented by many entities in our database (two points across the road from each other, or one point for each bay in a bus station).
To combat this problem all bus stops, where data was available, have been grouped into stop gGroups. This is the entity a passenger knows as a 'bus stop', with the individual boarding stop points within a stop group being a distinction only your application should make internally.
Returns all stop groups matching the given criteria.
Two modes of query: either search for stops near a certain point or return stops within a bounding box.
Find stop groups near a given point:
Find stop groups within a bounding box: Note: a maximum of 10,000 stops groups will be returned by this method. If you require wider coverage, please break up your query
Example (all bus stops in the village of Coton):
<response> <groups> <group> <ref>050GLN005008</ref> <name>The Ridgeway</name> <lat>52.0947230781</lat> <long>0.2944719285</long> <dist>907.97751117876408</dist> </group> ... </groups> </response>
The response is fairly self-explanatory with each group listed with it's group reference, name, positional information and distance in metres from the point that was passed (if method was set to 'near').
Takes a group reference and lists all stops that belong within this group. For example, a group may contain just one stop, two stops if the group represents a pair of stops either side of a road, or many stops if the group represents an feature such as a bus station.
<response> <stops> <stop haslivedata="true"> <atco>0500CCITY419</atco> <naptan>cmbdgdma</naptan> <location> <lat>52.2014817002</lat> <long>0.1185535098</long> <street>Trumpington Street</street> <landmark>Pembroke Street</landmark> <indicator>near</indicator> </location> <naming> <common>Pembroke Street</common> <short>Pembroke Street</short> </naming> <direction>SE</direction> </stop> ... </stops> </response>
Takes the ATCO code for a stop and returns a list of bus services due to arrive at that stop.
<response> <arrivals count="5"> <arrival> <service>99</service> <destination>City & The Grafton</destination> <time> <millis>1250260560580</millis> <textual>8 mins</textual> <isdue>false</isdue> <islive>false</islive> </time> </arrival> ... </arrivals> </response>
Takes the ATCO / NaPTAN code for a stop and returns extended stop info.
LookupStop?key=KEY&naptan=cmbdajdm or LookupStop?key=KEY&atco=0500CCITY111
<response> <stop haslivedata="true"> <atco>0500CCITY419</atco> <naptan>cmbdgdma</naptan> <location> <lat>52.2014817002</lat> <long>0.1185535098</long> <street>Trumpington Street</street> <landmark>Pembroke Street</landmark> <indicator>near</indicator> </location> <naming> <common>Pembroke Street</common> <short>Pembroke Street</short> </naming> <direction>SE</direction> </stop> </response>