action ptv_search_search { label: "View stops, routes and myki ticket outlets that match the search term" provider: ptv method: GET path: "/v3/search/{search_term}" encoding: json input: { type: "object" properties: { devid: { type: "string" } include_addresses: { type: "boolean" } include_outlets: { type: "boolean" } latitude: { type: "number" format: "float" } longitude: { type: "number" format: "float" } match_route_by_suburb: { type: "boolean" } match_stop_by_gtfs_stop_id: { type: "boolean" } match_stop_by_suburb: { type: "boolean" } max_distance: { type: "number" format: "float" } route_types: { type: "array" items: { type: "integer" format: "int32" enum: [0, 1, 2, 3, 4] } } search_term: { type: "string" } signature: { type: "string" } token: { type: "string" } } required: ["search_term"] additionalProperties: false } output: { type: "object" properties: { outlets: { type: "array" description: "myki ticket outlets" items: { type: "object" properties: { outlet_business: { type: "string" description: "The business name of the outlet" } outlet_business_hour_fri: { type: "string" description: "The business hours on Friday" } outlet_business_hour_mon: { type: "string" description: "The business hours on Monday" } outlet_business_hour_sat: { type: "string" description: "The business hours on Saturday" } outlet_business_hour_sun: { type: "string" description: "The business hours on Sunday" } outlet_business_hour_thur: { type: "string" description: "The business hours on Thursday" } outlet_business_hour_tue: { type: "string" description: "The business hours on Tuesday" } outlet_business_hour_wed: { type: "string" description: "The business hours on Wednesday" } outlet_distance: { type: "number" format: "float" description: "Distance of outlet from input location (in metres); returns 0 if no location is input" } outlet_latitude: { type: "number" format: "float" description: "Geographic coordinate of latitude at outlet" } outlet_longitude: { type: "number" format: "float" description: "Geographic coordinate of longitude at outlet" } outlet_name: { type: "string" description: "The location name of the outlet" } outlet_notes: { type: "string" description: "Any additional notes for the outlet such as 'Buy pre-loaded myki cards only'. May be null/empty." } outlet_postcode: { type: "integer" format: "int32" description: "The postcode for the outlet" } outlet_slid_spid: { type: "string" description: "The SLID / SPID" } outlet_suburb: { type: "string" description: "The city/municipality the outlet is in" } } } } routes: { type: "array" description: "Train lines, tram routes, bus routes, regional coach routes, Night Bus routes" items: { type: "object" properties: { route_gtfs_id: { type: "string" description: "GTFS Identifer of the route" } route_id: { type: "integer" format: "int32" description: "Route identifier" } route_name: { type: "string" description: "Name of route" } route_number: { type: "string" description: "Route number presented to public (nb. not route_id)" } route_service_status: { type: "object" properties: { description: { type: "string" } timestamp: { type: "string" format: "date-time" } } } route_type: { type: "integer" format: "int32" description: "Transport mode identifier" } } } } 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: "array" description: "Train stations, tram stops, bus stops, regional coach stops or Night Bus stops" items: { type: "object" properties: { route_type: { type: "integer" format: "int32" description: "Transport mode identifier" } routes: { type: "array" description: "List of routes travelling through the stop" items: { type: "object" additionalProperties: true } } stop_distance: { type: "number" format: "float" description: "Distance of stop from input location (in metres); returns 0 if no location is input" } stop_id: { type: "integer" format: "int32" description: "Stop identifier" } stop_landmark: { type: "string" description: "Landmark in proximity of stop" } stop_latitude: { type: "number" format: "float" description: "Geographic coordinate of latitude at stop" } stop_longitude: { type: "number" format: "float" description: "Geographic coordinate of longitude at stop" } stop_name: { type: "string" description: "Name of stop" } stop_sequence: { type: "integer" format: "int32" description: "Sequence of the stop on the route/run; return 0 when route_id or run_id not specified. Order ascendingly by this field (when non zero) to get physical order (earliest first) of stops on the route_id/run_id." } stop_suburb: { type: "string" description: "suburb of stop" } } } } } } }