TransitroutingoperationId stops
GET/v1/stops
The transit stops nearest a point, with the routes calling at each, from a GTFS feed.
Send Authorization: Bearer sk_live_…. The key's plan must include therouting product; which plans do.
Explained in Stops and departures.
Example
Stops near Embarcadero.
curl -G "https://api.oslew.com/v1/stops" \
-H "Authorization: Bearer $GEO_API_KEY" \
--data-urlencode 'at=37.7929,-122.3971' \
--data-urlencode 'radius_m=300' \
--data-urlencode 'limit=3'from oslew import Client
# The key is read from GEO_API_KEY.
client = Client(base_url="https://api.oslew.com")
answer = client.stops("37.7929,-122.3971", radius_m=300, limit=3)import { Client } from "@oslew/client";
// The key is read from GEO_API_KEY.
const client = new Client({ baseUrl: "https://api.oslew.com" });
const answer = await client.stops("37.7929,-122.3971", { radius_m: 300, limit: 3 });HTTP/1.1 200 OK
content-type: application/json
ratelimit-limit: 100
ratelimit-remaining: 293
ratelimit-reset: 1
{
"at": [
37.7929,
-122.3971
],
"results": [
{
"stop": {
"id": "M16-1",
"name": "Embarcadero",
"lat": 37.792789,
"lon": -122.39708,
"parent": 109,
"platform": "1",
"boarding": true
},
"distance_m": 12.467138822531075,
"routes": [
{
"id": "1",
"short_name": "Yellow-S",
"long_name": "Antioch to SF Int'l Airport SFO/Millbrae",
"kind": 1
},
{
"id": "5",
"short_name": "Green-S",
"long_name": "Berryessa/North San Jose to Daly City",
"kind": 1
},
{
"id": "7",
"short_name": "Red-S",
"long_name": "Richmond to SF Int'l Airport SFO/Millbrae",
"kind": 1
},
{
"id": "11",
"short_name": "Blue-S",
"long_name": "Dublin/Pleasanton to Daly City",
"kind": 1
}
],
"provenance": {
"name": "bart",
"release": "2026-08-19.0",
"license": "BART developer terms"
}
},
{
"stop": {
"id": "M16-2",
"name": "Embarcadero",
"lat": 37.792741,
"lon": -122.397019,
"parent": 109,
"platform": "2",
"boarding": true
},
"distance_m": 19.05888977190873,
"routes": [
{
"id": "2",
"short_name": "Yellow-N",
"long_name": "Millbrae/SF Int'l SFO to Antioch",
"kind": 1
},
{
"id": "6",
"short_name": "Green-N",
"long_name": "Daly City to Berryessa/North San Jose",
"kind": 1
},
{
"id": "8",
"short_name": "Red-N",
"long_name": "Millbrae/SF Int'l Airport SFO to Richmond",
"kind": 1
},
{
"id": "12",
"short_name": "Blue-N",
"long_name": "Daly City to Dublin/Pleasanton",
"kind": 1
}
],
"provenance": {
"name": "bart",
"release": "2026-08-19.0",
"license": "BART developer terms"
}
}
],
"took_us": 9
}A real response, captured from the service at commit b8f4bde-dirty. Timing fields such as took_us differ on every call.
Query
| Name | Type | Description |
|---|---|---|
atqueryrequired | string | lat,lon. |
radius_mquery | number ≤ 5000 default 1000 | |
limitquery | integer ≥ 1, ≤ 50 default 5 |
Responses
200 — Nearest first.
atnumber[]requiredresultsobject[]requireddistance_mnumberrequiredprovenanceSourcerequiredlicensestringrequirednamestringrequiredreleasestringrequired
routesTransitRoute[]requiredidstringrequiredkindintegerrequiredGTFS route_type: 0 tram, 1 metro, 2 rail, 3 bus, 4 ferry.long_namestringrequiredshort_namestringrequired
stopStoprequiredboardingbooleanrequiredA platform or stop rather than a station.idstringrequiredlatnumberrequiredlonnumberrequirednamestringrequiredparentinteger | nullrequiredIndex of the parent station in the feed's stops.platformstring | nullrequired
took_usintegerrequired
With RateLimit-Limit, RateLimit-Remaining and RateLimit-Reset(and their X-RateLimit-* aliases); see rate limits.
Refusals
Every refusal is a JSON object with an error string, except where noted.
| 400 | Bad request. |
| 401 | No key, or one that is unknown, revoked or suspended. |
| 403 | The key's plan does not include this route's product, or the request is larger than the plan allows. The body names the plan that does. |
| 429 | This product's bucket is empty: the key is going faster than its plan's sustained rate. Wait Retry-After seconds; nothing is used up. Carries Retry-After. |
| 503 | The pod cannot reach the control plane and its entitlements are too old to trust. Retry. |
A malformed query string or JSON body is refused by the framework before this route runs, in plain text rather than JSON; see errors.
More examples
Stops near Guadalajara cathedral
curl -G "https://api.oslew.com/v1/stops" \
-H "Authorization: Bearer $GEO_API_KEY" \
--data-urlencode 'at=20.6767,-103.3475' \
--data-urlencode 'radius_m=400' \
--data-urlencode 'limit=3'from oslew import Client
# The key is read from GEO_API_KEY.
client = Client(base_url="https://api.oslew.com")
answer = client.stops("20.6767,-103.3475", radius_m=400, limit=3)import { Client } from "@oslew/client";
// The key is read from GEO_API_KEY.
const client = new Client({ baseUrl: "https://api.oslew.com" });
const answer = await client.stops("20.6767,-103.3475", { radius_m: 400, limit: 3 });HTTP/1.1 200 OK
content-type: application/json
ratelimit-limit: 100
ratelimit-remaining: 291
ratelimit-reset: 1
{
"at": [
20.6767,
-103.3475
],
"results": [
{
"stop": {
"id": "S00000724",
"name": "Guadalajara Centro",
"lat": 20.67571,
"lon": -103.347372,
"parent": null,
"platform": null,
"boarding": true
},
"distance_m": 110.88560550525033,
"routes": [
{
"id": "MT_L3",
"short_name": "TL-3",
"long_name": "",
"kind": 1
}
],
"provenance": {
"name": "Secretaría de Transporte del Estado de Jalisco (SETRAN)",
"release": "2026-11-23",
"license": "see feed terms"
}
},
{
"stop": {
"id": "LM-V02_r1_77",
"name": "Plaza Guadalajara",
"lat": 20.677277,
"lon": -103.348437,
"parent": null,
"platform": null,
"boarding": true
},
"distance_m": 116.6983607796165,
"routes": [
{
"id": "LM-V02",
"short_name": "LM-V02",
"long_name": "",
"kind": 3
},
{
"id": "R-03",
"short_name": "R-03",
"long_name": "",
"kind": 3
}
],
"provenance": {
"name": "Secretaría de Transporte del Estado de Jalisco (SETRAN)",
"release": "2026-11-23",
"license": "see feed terms"
}
},
{
"stop": {
"id": "moovit_81208255",
"name": "Independencia",
"lat": 20.677937,
"lon": -103.346583,
"parent": null,
"platform": null,
"boarding": true
},
"distance_m": 167.39249957203404,
"routes": [
{
"id": "T14B-C02 Benito Juarez",
"short_name": "T14B-C02",
"long_name": "Benito Juarez",
"kind": 3
}
],
"provenance": {
"name": "Secretaría de Transporte del Estado de Jalisco (SETRAN)",
"release": "2026-11-23",
"license": "see feed terms"
}
}
],
"took_us": 1392
}A real response, captured from the service at commit b8f4bde-dirty. Timing fields such as took_us differ on every call.
Rendered from the OpenAPI document at commit b8f4bde-dirty; the same document is served at/v1/openapi.json and generates both clients.