TripPlan Data Type

A TripPlan is a set of ways to get from point A to point B at time T.

Properties
name data type description
date number The time and date of travel
from Place The origin
to Place The destination
itineraries array of Itinerary A list of possible itineraries

Example

{
  "date" : 12345,
  "from" : {
    "name" : "...",
    "stopId" : {
      "id" : "...",
      "agencyId" : "..."
    },
    "stopCode" : "...",
    "platformCode" : "...",
    "lon" : 12345.0,
    "lat" : 12345.0,
    "arrival" : 12345,
    "departure" : 12345,
    "orig" : "...",
    "zoneId" : "...",
    "stopIndex" : 12345,
    "stopSequence" : 12345,
    "vertexType" : "TRANSIT",
    "bikeShareId" : "..."
  },
  "to" : {
    "name" : "...",
    "stopId" : {
      "id" : "...",
      "agencyId" : "..."
    },
    "stopCode" : "...",
    "platformCode" : "...",
    "lon" : 12345.0,
    "lat" : 12345.0,
    "arrival" : 12345,
    "departure" : 12345,
    "orig" : "...",
    "zoneId" : "...",
    "stopIndex" : 12345,
    "stopSequence" : 12345,
    "vertexType" : "TRANSIT",
    "bikeShareId" : "..."
  },
  "itineraries" : [ {
    "duration" : 12345,
    "startTime" : 12345,
    "endTime" : 12345,
    "walkTime" : 12345,
    "transitTime" : 12345,
    "waitingTime" : 12345,
    "walkDistance" : 12345.0,
    "walkLimitExceeded" : true,
    "elevationLost" : 12345.0,
    "elevationGained" : 12345.0,
    "transfers" : 12345,
    "fare" : {
      "fare" : {
        "property1" : "...",
        "property2" : "..."
      }
    },
    "leg" : [ {
      "startTime" : 12345,
      "endTime" : 12345,
      "departureDelay" : 12345,
      "arrivalDelay" : 12345,
      "realTime" : true,
      "isNonExactFrequency" : true,
      "headway" : 12345,
      "distance" : 12345.0,
      "pathway" : true,
      "mode" : "...",
      "route" : "...",
      "agencyName" : "...",
      "agencyUrl" : "...",
      "agencyTimeZoneOffset" : 12345,
      "routeColor" : "...",
      "routeType" : 12345,
      "routeId" : { },
      "routeTextColor" : "...",
      "interlineWithPreviousLeg" : true,
      "tripShortName" : "...",
      "tripBlockId" : "...",
      "headsign" : "...",
      "agencyId" : "...",
      "tripId" : { },
      "serviceDate" : "...",
      "from" : { },
      "to" : { },
      "intermediateStops" : [ { }, { } ],
      "legGeometry" : { },
      "steps" : [ { }, { } ],
      "alerts" : [ { }, { } ],
      "routeShortName" : "...",
      "routeLongName" : "...",
      "boardRule" : "...",
      "alightRule" : "...",
      "rentedBike" : true,
      "transitLeg" : true,
      "duration" : 12345.0
    }, {
      "startTime" : 12345,
      "endTime" : 12345,
      "departureDelay" : 12345,
      "arrivalDelay" : 12345,
      "realTime" : true,
      "isNonExactFrequency" : true,
      "headway" : 12345,
      "distance" : 12345.0,
      "pathway" : true,
      "mode" : "...",
      "route" : "...",
      "agencyName" : "...",
      "agencyUrl" : "...",
      "agencyTimeZoneOffset" : 12345,
      "routeColor" : "...",
      "routeType" : 12345,
      "routeId" : { },
      "routeTextColor" : "...",
      "interlineWithPreviousLeg" : true,
      "tripShortName" : "...",
      "tripBlockId" : "...",
      "headsign" : "...",
      "agencyId" : "...",
      "tripId" : { },
      "serviceDate" : "...",
      "from" : { },
      "to" : { },
      "intermediateStops" : [ { }, { } ],
      "legGeometry" : { },
      "steps" : [ { }, { } ],
      "alerts" : [ { }, { } ],
      "routeShortName" : "...",
      "routeLongName" : "...",
      "boardRule" : "...",
      "alightRule" : "...",
      "rentedBike" : true,
      "transitLeg" : true,
      "duration" : 12345.0
    } ],
    "tooSloped" : true
  }, {
    "duration" : 12345,
    "startTime" : 12345,
    "endTime" : 12345,
    "walkTime" : 12345,
    "transitTime" : 12345,
    "waitingTime" : 12345,
    "walkDistance" : 12345.0,
    "walkLimitExceeded" : true,
    "elevationLost" : 12345.0,
    "elevationGained" : 12345.0,
    "transfers" : 12345,
    "fare" : {
      "fare" : {
        "property1" : "...",
        "property2" : "..."
      }
    },
    "leg" : [ {
      "startTime" : 12345,
      "endTime" : 12345,
      "departureDelay" : 12345,
      "arrivalDelay" : 12345,
      "realTime" : true,
      "isNonExactFrequency" : true,
      "headway" : 12345,
      "distance" : 12345.0,
      "pathway" : true,
      "mode" : "...",
      "route" : "...",
      "agencyName" : "...",
      "agencyUrl" : "...",
      "agencyTimeZoneOffset" : 12345,
      "routeColor" : "...",
      "routeType" : 12345,
      "routeId" : { },
      "routeTextColor" : "...",
      "interlineWithPreviousLeg" : true,
      "tripShortName" : "...",
      "tripBlockId" : "...",
      "headsign" : "...",
      "agencyId" : "...",
      "tripId" : { },
      "serviceDate" : "...",
      "from" : { },
      "to" : { },
      "intermediateStops" : [ { }, { } ],
      "legGeometry" : { },
      "steps" : [ { }, { } ],
      "alerts" : [ { }, { } ],
      "routeShortName" : "...",
      "routeLongName" : "...",
      "boardRule" : "...",
      "alightRule" : "...",
      "rentedBike" : true,
      "transitLeg" : true,
      "duration" : 12345.0
    }, {
      "startTime" : 12345,
      "endTime" : 12345,
      "departureDelay" : 12345,
      "arrivalDelay" : 12345,
      "realTime" : true,
      "isNonExactFrequency" : true,
      "headway" : 12345,
      "distance" : 12345.0,
      "pathway" : true,
      "mode" : "...",
      "route" : "...",
      "agencyName" : "...",
      "agencyUrl" : "...",
      "agencyTimeZoneOffset" : 12345,
      "routeColor" : "...",
      "routeType" : 12345,
      "routeId" : { },
      "routeTextColor" : "...",
      "interlineWithPreviousLeg" : true,
      "tripShortName" : "...",
      "tripBlockId" : "...",
      "headsign" : "...",
      "agencyId" : "...",
      "tripId" : { },
      "serviceDate" : "...",
      "from" : { },
      "to" : { },
      "intermediateStops" : [ { }, { } ],
      "legGeometry" : { },
      "steps" : [ { }, { } ],
      "alerts" : [ { }, { } ],
      "routeShortName" : "...",
      "routeLongName" : "...",
      "boardRule" : "...",
      "alightRule" : "...",
      "rentedBike" : true,
      "transitLeg" : true,
      "duration" : 12345.0
    } ],
    "tooSloped" : true
  } ]
}