Routes


The routes call returns a list an agency's routes. Each route record includes the route id, type and real-time flag, and, where provided in the originating data feed, the route color. Routes flagged as "patterned" are skip stop routes with potentially varying stop sequence patterns between trips.

Call format


PartDescriptionOptionalExample
URLTransiCast web server instance URLhttp://transicast.appspot.com/ws/V3
Servlet descriptorroutesroutes
Parameter:
agency=<agency ID>
Agency ID, as provided by the agencies callagency=SFMTA

http://transicast.appspot.com/ws/V3/routes?agency=SFMTA&appid=<api_key>

Response format


Individual routes are returned through the <stop> tag. It contains the following attributes:

AttributeDescriptionKeyUsed inExample
idRoute ID
+
Stops responses
Route detail calls
Next bus and train time calls
Service Messages
id="1AX"
colorRoute colorcolor="339999"
typeRoute type. Values are following the definition of route_type in GTFStype="3"
patternedPatterned (skip stop) flagpatterned="false"
rtFlag. true for stops that offer service messages and next bus and train times based on real-time estimatesrt="true"
longTag: Route long name, see below

Where route longnames are defined in the originating data feed, the <route> tag contains a <long> tag with the following attributes:

AttributeDescriptionKeyUsed inExample
nameRoute longnamename="ROLLING ROAD - DOWNTOWN EXPRESS"

<?xml version="1.0" encoding="UTF-8"?>
<resultSet queryTime="1319343181700" ct="4">
<route id="1" color="cc6600" type="3" rt="true" patterned="false"> <long name="1-California"/></route>
<route id="1AX" color="990000" type="3" rt="true" patterned="false"> <long name="1AX-California A Express"/></route>
<route id="1BX" color="cc3333" type="3" rt="true" patterned="false"> <long name="1BX-California B Express"/></route>
<route id="2" color="000000" type="3" rt="true" patterned="false"> <long name="2-Clement"/></route>
</resultSet>

Notes

Contact

By email  

© 2011 - 2023 TransiCast