action ptv_departures_get_for_stop { label: "View departures for all routes from a stop" provider: ptv method: GET path: "/v3/departures/route_type/{route_type}/stop/{stop_id}" encoding: json input: { type: "object" properties: { date_utc: { type: "string" format: "date-time" } devid: { type: "string" } direction_id: { type: "integer" format: "int32" } expand: { type: "array" items: { type: "string" enum: ["All", "Stop", "Route", "Run", "Direction", "Disruption", "VehicleDescriptor", "VehiclePosition", "None"] } } gtfs: { type: "boolean" } include_cancelled: { type: "boolean" } include_geopath: { type: "boolean" } look_backwards: { type: "boolean" } max_results: { type: "integer" format: "int32" } platform_numbers: { type: "array" items: { type: "integer" format: "int32" } } route_type: { type: "integer" format: "int32" enum: [0, 1, 2, 3, 4] } signature: { type: "string" } stop_id: { type: "integer" format: "int32" } token: { type: "string" } } required: ["route_type", "stop_id"] additionalProperties: false } output: { type: "object" properties: { departures: { type: "array" description: "Timetabled and real-time service departures" items: { type: "object" properties: { at_platform: { type: "boolean" description: "Indicates if the metropolitan train service is at the platform at the time of query; returns false for other modes" } departure_sequence: { type: "integer" format: "int32" description: "Chronological sequence for the departures in a run. Order ascendingly by this field to get chronological order (earliest first) of departures with the same run_ref. NOTE, this field is not always N+1 or N-1 of the previous or following departure. e.g 100, 200, 250, 300 instead of 1, 2, 3, 4" } direction_id: { type: "integer" format: "int32" description: "Direction of travel identifier" } disruption_ids: { type: "array" description: "Disruption information identifier(s)" items: { type: "integer" format: "int64" } } estimated_departure_utc: { type: "string" format: "date-time" description: "Real-time estimate of departure time and date in ISO 8601 UTC format" } flags: { type: "string" description: "Flag indicating special condition for run (e.g. RR Reservations Required, GC Guaranteed Connection, DOO Drop Off Only, PUO Pick Up Only, MO Mondays only, TU Tuesdays only, WE Wednesdays only, TH Thursdays only, FR Fridays only, SS School days only; ignore E flag)" } platform_number: { type: "string" description: "Platform number at stop (metropolitan train only; returns null for other modes)" } route_id: { type: "integer" format: "int32" description: "Route identifier" } run_id: { type: "integer" format: "int32" description: "Numeric trip/service run identifier. Defaults to -1 when run identifier is Alphanumeric" } run_ref: { type: "string" description: "Alphanumeric trip/service run identifier" } scheduled_departure_utc: { type: "string" format: "date-time" description: "Scheduled (i.e. timetabled) departure time and date in ISO 8601 UTC format" } stop_id: { type: "integer" format: "int32" description: "Stop identifier" } } } } directions: { type: "object" description: "Directions of travel of route" } disruptions: { type: "object" description: "Disruption information applicable to relevant routes or stops" } routes: { type: "object" description: "Train lines, tram routes, bus routes, regional coach routes, Night Bus routes" } runs: { type: "object" description: "Individual trips/services of a route" } status: { type: "object" properties: { health: { type: "integer" format: "int32" description: "API system health status (0=offline, 1=online)" enum: [0, 1] } version: { type: "string" description: "API Version number" } } } stops: { type: "object" description: "A train station, tram stop, bus stop, regional coach stop or Night Bus stop" } } } }