Skip to content
abmagil edited this page Nov 29, 2012 · 13 revisions

Table of Contents

Vehicle Pull In/Pull Out Data

This API gives vehicle pull in pull out information for use. Every vehicle pullout API call takes includeAll optional parameter. If set to true the web service will include all pullouts for the vehicles. If not set or set to false, the web service will return only most recent pullout per vehicle. This is the default behaviour.

Call

(tdm component)/api/pullouts/list

Options

Option Output
/api/pullouts/list will return results with most recent pullout per vehicle
/api/pullouts/list?includeAll=true will return results with all pullouts per vehicle
/api/pullouts/(bus number)/list will return results with active pull outs by bus
/api/pullouts/depot/(depot)/list will return results with active pull outs by depot
/api/pullouts/agency/(agency id)/list will return results with active pull outs by agency

Response

This API returns JSON. The JSON will consist of vehicles, approximating the following

 {
  pullouts: [
    {
      "vehicle-id": "1269",
      "agency-id-tcip": "2008",
      "agency-id": "MTA NYCT",
      "depot": "OS",
      "service-date": "2012-06-20",
      "pullout-time": "2012-06-20T08:05:00-04:00",
      "run": "SBS15-106",
      "operator-id": "1663",
      "pullin-time": "2012-06-20T23:27:00-04:00"
    },
    [...]
  ],
  status: "OK"
 }

Data

The data underlying this API is documented here

Clone this wiki locally