Get next departures from transit stops
Retrieve scheduled and real-time departure information from public transport stops. Two modes: search by coordinates (location) or query a specific stop (stopId + regionName from /stopsInRadius response)
Parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
location | string | ✓* | Coordinates for nearby stops search (Mode 1: by coordinates). Required if stopId is not provided. Cannot be combined with stopId | 53.535402,-2.523009 |
stopId | string | ✓* | Internal stop identifier (Mode 2: by stop ID). This is an API-specific ID, not an external code (e.g. not NaPTAN/ATCO). Obtain it from the stopId field in /stopsInRadius response. Required if location is not provided. Must be used together with regionName and countryIso. Cannot be combined with location | 8150831397776266088 |
regionName | string | ✓* | Region name, required when using stopId mode. Obtain from the regionName field in /stopsInRadius response | uk_ireland |
countryIso | string | ISO 3166-1 alpha-3 country code from /stopsInRadius response. Required for busmaps.com host, not needed for wikiroutes.info | GBR | |
requestTime | string | ISO 8601 time to list departures from. Z for UTC, an offset like +01:00 (encode + as %2B), or no zone for local time at the stop or location. See Time format below.Default: current time (UTC) | 2025-09-18T09:00:00Z | |
radius | integer | Stop search radius in meters (for location mode only) Default: 500 | 500 | |
results | integer | Maximum number of departures to return Default: 40 | 30 | |
lang | string | Language code for translated stop/route names (IETF BCP 47 format, e.g. en, ru, es, zh-CN). If no translation is available, the original name is returned | en |
* Conditional: provide either location (Mode 1) or stopId + regionName (Mode 2). One mode is required.
Time format
Time parameters use ISO 8601. The zone designator at the end of the value determines its interpretation.
| Form | Example | Meaning |
|---|---|---|
| No zone | 2025-09-18T10:00:00 | Local time at the queried location: the origin for /routes, the stop or location for /nextDepartures. The caller does not need the location's UTC offset. |
| UTC | 2025-09-18T14:00:00Z | A fixed instant. The Z suffix marks UTC. |
| Explicit offset | 2025-09-18T10:00:00-04:00 | A fixed instant. Encode + as %2B in the query string. |
- The UTC and offset forms denote the same instant regardless of caller location; only the no-zone form is location-relative.
09:00:00Zand10:00:00+01:00are equivalent. - If omitted, the current time is used.
- Seconds are rounded up to the next minute.
- Departure and arrival times in the response use the region's local time. The
localDateandlocalTimefields report the request time in that zone.
Real-time vs scheduled times
Times come in two flavours: the schedule (always present) and the real-time/live value (present only when the operator feeds live data). When a real-time value is present it is the actual expected time - use it instead of the scheduled one. The field names differ per endpoint:
| Endpoint | Scheduled field | Real-time field (live only) |
|---|---|---|
/nextDepartures | departureTime (HH:MM:SS) + date | rtDepartureTime (HH:MM:SS) + rtDate |
/routes | section departure.time / arrival.time (full ISO 8601) | section departure.rtDeparture / arrival.rtArrival (full ISO 8601); same on intermediateStops[] |
- Real-time fields are absent when no live data exists - then only the schedule is known. Always check for the
rt*field and fall back to the scheduled one. - Delay = real-time minus scheduled (positive = running late). A live/delay badge is the typical UI.
- Service disruptions come as a top-level
alerts[]array (header, description, cause, effect, validFrom/validUntil, and the affected route/stop viainformedEntity/sectionIds).
Try It Out
https://capi.busmaps.com:8443Mode 1: Search by coordinates
curl -H "capi-key: Bearer YOUR_API_KEY" -H "capi-host: busmaps.com" "https://capi.busmaps.com:8443/nextDepartures?location=53.535402,-2.523009&radius=500&results=30"Mode 2: Query specific stop by ID
curl -H "capi-key: Bearer YOUR_API_KEY" -H "capi-host: busmaps.com" "https://capi.busmaps.com:8443/nextDepartures?stopId=8150831397776266088®ionName=uk_ireland&countryIso=GBR&results=30"Response Example
HTTP 200 - Success
{
"requestTime": 1780654980,
"stopDepartures": [
{
"stopId": "2096119542657293652",
"countryIso": "GBR",
"countryUrl": "uk",
"stopName": "Charing Cross Underground Station",
"urlStopName": "Charing-Cross-Underground-Station",
"stopLat": 51.507449,
"stopLon": -0.128097,
"stopDesc": "",
"departureList": [
{
"tripId": "1-0faf6fa091bed4e27aa2",
"routeId": "2521614975-583762869",
"countryIso": "GBR",
"countryUrl": "uk",
"routeShortName": "Bakerloo",
"routeLongName": "Elephant & Castle - Queen's Park - Harrow & Wealdstone",
"urlRouteShortName": "Bakerloo",
"routeDesc": null,
"routeColor": "A45A2A",
"routeTextColor": "FFFFFF",
"routeType": "subway",
"tripHeadsign": "Queen's Park Underground Station",
"departureTime": "11:24:00",
"date": "2026-06-05",
"agencyId": "2264224218-1585141307"
},
{
"tripId": "1-a18f03bf6d624524e004",
"routeId": "2521614975-583762869",
"countryIso": "GBR",
"countryUrl": "uk",
"routeShortName": "Bakerloo",
"routeLongName": "Elephant & Castle - Queen's Park - Harrow & Wealdstone",
"urlRouteShortName": "Bakerloo",
"routeDesc": null,
"routeColor": "A45A2A",
"routeTextColor": "FFFFFF",
"routeType": "subway",
"tripHeadsign": "Harrow & Wealdstone Underground Station",
"departureTime": "11:28:00",
"rtDepartureTime": "11:28:00",
"date": "2026-06-05",
"rtDate": "2026-06-05",
"agencyId": "2264224218-1585141307"
}
],
"agencies": [
{
"agencyId": "2264224218-1585141307",
"countryIso": "GBR",
"countryUrl": "uk",
"agencyName": "London Underground (TfL)",
"urlAgencyName": "London-Underground-TfL",
"agencyUrl": "https://www.traveline.info",
"agencyPhone": "03432221234"
}
]
},
{
"stopId": "15755802674393014223",
"countryIso": "GBR",
"countryUrl": "uk",
"stopName": "Charing Cross Underground Station",
"urlStopName": "Charing-Cross-Underground-Station",
"stopLat": 51.508178,
"stopLon": -0.125891,
"stopDesc": "",
"departureList": [
{
"tripId": "1-7ce2b300be7f3fb92d66",
"routeId": "2521614975-583762869",
"countryIso": "GBR",
"countryUrl": "uk",
"routeShortName": "Bakerloo",
"routeLongName": "Elephant & Castle - Queen's Park - Harrow & Wealdstone",
"urlRouteShortName": "Bakerloo",
"routeDesc": null,
"routeColor": "A45A2A",
"routeTextColor": "FFFFFF",
"routeType": "subway",
"tripHeadsign": "Elephant & Castle Underground Station",
"departureTime": "11:23:00",
"rtDepartureTime": "11:23:00",
"date": "2026-06-05",
"rtDate": "2026-06-05",
"agencyId": "2264224218-1585141307"
},
{
"tripId": "1-7db5f4b64ff556939f53",
"routeId": "2521614975-583762869",
"countryIso": "GBR",
"countryUrl": "uk",
"routeShortName": "Bakerloo",
"routeLongName": "Elephant & Castle - Queen's Park - Harrow & Wealdstone",
"urlRouteShortName": "Bakerloo",
"routeDesc": null,
"routeColor": "A45A2A",
"routeTextColor": "FFFFFF",
"routeType": "subway",
"tripHeadsign": "Elephant & Castle Underground Station",
"departureTime": "11:26:00",
"rtDepartureTime": "11:27:00",
"date": "2026-06-05",
"rtDate": "2026-06-05",
"agencyId": "2264224218-1585141307"
}
],
"agencies": [
{
"agencyId": "2264224218-1585141307",
"countryIso": "GBR",
"countryUrl": "uk",
"agencyName": "London Underground (TfL)",
"urlAgencyName": "London-Underground-TfL",
"agencyUrl": "https://www.traveline.info",
"agencyPhone": "03432221234"
}
]
}
],
"alerts": [
{
"id": "dd1e4d9bb7ef",
"origin": "API",
"cause": "TECHNICAL_PROBLEM",
"effect": "NO_SERVICE",
"header": "Bakerloo Line",
"description": "No service between Queen's Park and Harrow & Wealdstone while we fix a signal failure at Willesden Junction. Tickets are being accepted on London Buses, the Lioness line and London Northwestern Railway. GOOD SERVICE on the rest of the line.",
"url": "https://tfl.gov.uk/tube-dlr-overground/status/",
"validFrom": "",
"validUntil": "",
"operator": "2264224218-1585141307",
"countryIso": "GBR",
"countryUrl": "uk",
"informedEntity": [
{
"routeId": "2521614975-583762869",
"countryIso": "GBR",
"countryUrl": "uk"
}
]
}
],
"localDate": "2026-06-05",
"localTime": "11:23:00",
"regionName": "uk_ireland",
"imperial": true,
"processingTimeMs": 285.42
}Response Schema
Title: Next Departures Response View Full JSON Schema
{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "Next Departures Response",
"type": "object",
"properties": {
"stopDepartures": {
"type": "array",
"items": {
"type": "object",
"properties": {
"departureList": {
"type": "array",
"items": {
"type": "object",
"properties": {
"countryIso": {
"type": "string",
"description": "ISO 3166-1 alpha-3 country code (e.g. 'GBR')"
},
"rtDate": {
"type": "string",
"description": "Real-time service date (YYYY-MM-DD)"
},
"date": {
"type": "string",
"description": "Service date in YYYY-MM-DD"
},
"tripId": {
"type": "string",
"description": "Internal trip identifier"
},
"routeShortName": {
"type": [
"null",
"string"
],
"description": "Short route name shown to passengers (e.g. '18', 'Bakerloo')"
},
"routeColor": {
"type": [
"null",
"string"
],
"description": "Route color as a hex string"
},
"rtDepartureTime": {
"type": "string",
"description": "Real-time (live) departure time (HH:MM:SS)"
},
"departureTime": {
"type": "string",
"description": "Scheduled departure time (HH:MM:SS, region-local)"
},
"tripHeadsign": {
"type": "string",
"description": "Trip destination shown on the vehicle"
},
"agencyId": {
"type": "string",
"description": "Internal agency identifier"
},
"routeTextColor": {
"type": [
"null",
"string"
],
"description": "Route text color as a hex string"
},
"routeDesc": {
"type": [
"null",
"string"
],
"description": "Additional route description"
},
"urlRouteShortName": {
"type": [
"null",
"string"
],
"description": "URL-safe slug of the route short name"
},
"countryUrl": {
"type": "string",
"description": "Country URL slug (e.g. 'uk')"
},
"routeId": {
"type": "string",
"description": "Internal route identifier"
},
"routeType": {
"type": "string",
"description": "Transport type (bus, subway, train, tram, ...)"
},
"platformCode": {
"type": "string",
"description": "Platform or stand code"
},
"routeLongName": {
"type": [
"null",
"string"
],
"description": "Full route name/description"
},
"urlRouteLongName": {
"type": [
"null",
"string"
],
"description": "URL-safe slug of the route long name"
}
},
"required": [
"tripHeadsign",
"countryIso",
"departureTime",
"agencyId",
"urlRouteShortName",
"date",
"countryUrl",
"routeId",
"routeShortName",
"routeType"
]
},
"description": "Upcoming departures from this stop"
},
"countryIso": {
"type": "string",
"description": "ISO 3166-1 alpha-3 country code (e.g. 'GBR')"
},
"stopId": {
"type": "string",
"description": "Internal stop identifier (use with /nextDepartures stopId mode)"
},
"stopLon": {
"type": "number",
"description": "Stop longitude"
},
"stopName": {
"type": "string",
"description": "Human-readable stop name"
},
"stopLat": {
"type": "number",
"description": "Stop latitude"
},
"countryUrl": {
"type": "string",
"description": "Country URL slug (e.g. 'uk')"
},
"wheelchairBoarding": {
"type": "integer",
"description": "Wheelchair accessibility flag (GTFS: 0 unknown, 1 yes, 2 no)"
},
"stopCode": {
"type": "string",
"description": "Public stop code shown to passengers"
},
"stopDesc": {
"type": "string",
"description": "Additional stop description (direction, platform hint)"
},
"urlStopName": {
"type": [
"null",
"string"
],
"description": "URL-safe slug of the stop name"
},
"agencies": {
"type": "array",
"items": {
"type": "object",
"properties": {
"agencyUrl": {
"type": "string",
"description": "Agency website URL"
},
"countryIso": {
"type": "string",
"description": "ISO 3166-1 alpha-3 country code (e.g. 'GBR')"
},
"agencyId": {
"type": "string",
"description": "Internal agency identifier"
},
"urlAgencyName": {
"type": [
"null",
"string"
],
"description": "URL-safe slug of the agency name"
},
"countryUrl": {
"type": "string",
"description": "Country URL slug (e.g. 'uk')"
},
"agencyPhone": {
"type": [
"null",
"string"
],
"description": "Agency contact phone"
},
"agencyName": {
"type": "string",
"description": "Agency name"
}
},
"required": [
"agencyUrl",
"countryIso",
"agencyId",
"urlAgencyName",
"countryUrl",
"agencyName"
]
},
"description": "Agencies operating departures from this stop"
}
},
"required": [
"departureList",
"countryIso",
"stopId",
"countryUrl",
"stopLon",
"stopName",
"stopLat",
"urlStopName",
"agencies"
]
},
"description": "Array of stop departures"
},
"imperial": {
"type": "boolean",
"description": "True when distances are meant to be shown in imperial units (US/UK)"
},
"localDate": {
"type": "string",
"description": "Local date in YYYY-MM-DD format"
},
"regionName": {
"type": "string",
"description": "Transit data region that served the request"
},
"alerts": {
"type": "array",
"items": {
"type": "object",
"properties": {
"countryIso": {
"type": [
"null",
"string"
],
"description": "ISO 3166-1 alpha-3 country code (e.g. 'GBR')"
},
"operator": {
"type": "string",
"description": "Operator name"
},
"informedEntity": {
"type": "array",
"items": {
"type": "object",
"properties": {
"routeId": {
"type": "string",
"description": "Internal route identifier"
},
"countryIso": {
"type": "string",
"description": "ISO 3166-1 alpha-3 country code (e.g. 'GBR')"
},
"countryUrl": {
"type": "string",
"description": "Country URL slug (e.g. 'uk')"
},
"stopId": {
"type": "string",
"description": "Internal stop identifier (use with /nextDepartures stopId mode)"
}
},
"required": [
"routeId",
"countryIso",
"countryUrl"
]
},
"description": "Entities (route/stop) the alert applies to"
},
"id": {
"type": "string",
"description": "Identifier"
},
"header": {
"type": "string",
"description": "Short alert headline"
},
"effect": {
"type": "string",
"description": "GTFS-RT alert effect"
},
"validFrom": {
"type": "string",
"description": "Alert start time (ISO 8601)"
},
"countryUrl": {
"type": [
"null",
"string"
],
"description": "Country URL slug (e.g. 'uk')"
},
"cause": {
"type": "string",
"description": "GTFS-RT alert cause"
},
"description": {
"type": "string",
"description": "Full alert text"
},
"validUntil": {
"type": "string",
"description": "Alert end time (ISO 8601)"
},
"origin": {
"type": "string",
"description": "Source/origin of the alert"
},
"url": {
"type": "string",
"description": "Link with more information"
}
},
"required": [
"countryIso",
"id",
"operator",
"header",
"effect",
"countryUrl",
"cause",
"description",
"informedEntity",
"origin"
]
},
"description": "Service alerts/disruptions affecting the result"
},
"requestTime": {
"type": "integer",
"description": "Unix timestamp of request"
},
"processingTimeMs": {
"type": "number",
"description": "Server processing time in milliseconds"
},
"localTime": {
"type": "string",
"description": "Local time in HH:MM:SS format"
}
},
"required": [
"stopDepartures",
"localDate",
"regionName",
"requestTime",
"processingTimeMs",
"localTime"
]
}
Response Codes
Departures retrieved successfully (or noCoverage notice if region not supported)
Invalid parameters or missing required fields
Internal server error