Subway API endpoint
Returns Subway stores nearest first to a coordinate or a free-text address/city/ZIP, with live open/closed status, payment methods, catering link, and feature flags. This is the proximity search GET /subway/sitemap cannot do directly -- the sitemap enumerates the whole world for bulk scraping, this answers "what is near this point" with distance and live attributes the sitemap/store locator does not carry. Each store's store_id is the same value GET /subway/menu takes, and can be passed back here as store_id to re-read one store's live attributes directly.
/subway/nearbyQuery parameters:
latitude (optional) — search center latitude, e.g. 34.0549076. Set together with longitude, or set query or store_id instead — exactly one search mode.longitude (optional) — search center longitude, e.g. -118.242643.query (optional) — free-text address, city, or ZIP to search near, e.g. Los Angeles, CA. Alternative to latitude/longitude and store_id.store_id (optional) — look up one store directly by its store_id, e.g. 75376-0, from /api/v1/subway/store or a prior /api/v1/subway/nearby result. Alternative to latitude/longitude and query. distance_miles is 0 in this mode — there is no search center to measure from.limit (optional, default 10, max 20) — maximum stores to return.offset (optional) — opaque pagination cursor from a previous response's next_offset, not a numeric page index.features (optional, comma-separated) — restricts results to stores with ALL listed features (AND). Allowed values: HAS_BREAKFAST, IS_REMOTEORDER_ACCEPTED, HAS_HALAL, HAS_DRIVETHROUGH, HAS_CATERING, HAS_CURBSIDE, IS_OPERATING.Exactly one search mode is required: latitude+longitude, query, or store_id.
Response includes stores[], count, total_results, next_offset, source_url, and fetched_at.
Each stores[] entry has store_id (the same value /api/v1/subway/menu takes), address, phone_number, latitude, longitude, distance_miles, timezone, is_open_now, can_take_online_orders, features[] (the subset of the seven allowed values this store actually has), payment_methods[], catering_url, and hours[] (Monday-first, same shape as /api/v1/subway/store).
Each hours[] entry carries day_of_week, closed, opens, closes, and segments[]. Most days have exactly one segment, matching opens/closes. Stores with split or overnight hours have more than one — opens/closes then describe only the first segment, so read segments[] when a day may have a lunch/dinner gap or a close time past midnight recorded as a separate early-morning window.
A coordinate or query with no Subway nearby returns an empty stores list with total_results: 0, not an error.
| Field | Filled in, of 10 checked | Values in the sample |
|---|---|---|
| store_id | 10 | |
| address | 10 | |
| phone_number | 10 | |
| latitude | 10 | |
| longitude | 10 | |
| timezone | 10 | America/New_York in all 10 |
| is_open_now | 10 | true in 10 of 10 |
| can_take_online_orders | 10 | true in 10 of 10 |
| features | 10 | median 4 entries |
| payment_methods | 10 | median 9 entries |
| hours | 10 | median 7 entries |
| distance_miles | 9 | 0.2 to 0.7, median 0.4 |
| catering_url | 8 | ezcater.com |
| Parameter | Type | Required | Default | Description | Example |
|---|---|---|---|---|---|
| latitude | number | No | Search center latitude. Set together with longitude, or set query or store_id instead -- exactly one search mode. | 34.0549076 | |
| longitude | number | No | Search center longitude. | -118.242643 | |
| query | string | No | Free-text address, city or ZIP to search near. Alternative to latitude/longitude and store_id. | Los Angeles, CA | |
| store_id | string | No | Look up one store directly by its store_id, from GET /subway/store or a prior /subway/nearby result. Alternative to latitude/longitude and query. | 75376-0 | |
| limit | integer | No | Maximum stores to return, 1-20 (default 10) | 10 | |
| offset | string | No | Opaque pagination cursor from a previous response's next_offset | ||
| features | string | No | Comma-separated. Restricts results to stores with ALL listed features. Allowed values: HAS_BREAKFAST, IS_REMOTEORDER_ACCEPTED, HAS_HALAL, HAS_DRIVETHROUGH, HAS_CATERING, HAS_CURBSIDE, IS_OPERATING. | HAS_BREAKFAST,IS_REMOTEORDER_ACCEPTED | |
| x-api-key (header) | string | Yes | API key required |
curl -X GET "https://api.crawlora.net/api/v1/subway/nearby?query=coffee&limit=10" \ -H "x-api-key: $CRAWLORA_API_KEY"
{
"code": 200,
"msg": "OK",
"data": {
"stores": [
{
"store_id": "28062-0",
"address": {
"street": "701 Cesar Chavez Avenue",
"city": "Los Angeles",
"region": "CA",
"postal_code": "90012",
"country": "US"
},
"phone_number": "213-626-4411",
"latitude": 34.0610673,
"longitude": -118.2441504,
"distance_miles": 0.4,
"timezone": "America/Los_Angeles",
"is_open_now": false,
"can_take_online_orders": true,
"features": [
"HAS_BREAKFAST",
"IS_REMOTEORDER_ACCEPTED",
"HAS_CATERING",
"HAS_CURBSIDE",
"IS_OPERATING"
],
"payment_methods": [
"APPLEPAY",
"VISA",
"MASTERCARD"
],
"catering_url": "https://www.ezcater.com/catering/pvt/subway-los-angeles",
"hours": [
{
"day_of_week": "Monday",
"closed": false,
"opens": "09:00",
"closes": "22:00",
"segments": [
{
"opens": "09:00",
"closes": "22:00"
}
]
}
]
}
],
"count": 1,
"total_results": 42,
"next_offset": "opaque-cursor-abc123",
"source_url": "https://www.subway.com/api/location-search",
"fetched_at": "2026-09-05T12:00:00Z"
}
}Request schema
No body schema
Response schema
#/definitions/subway.nearbyResponseDoc
| Field | Type | Required | Enum | Bounds | Example | Description |
|---|---|---|---|---|---|---|
| code | integer | No | Code is the HTTP status code or a custom code used to indicate the result of the request @example 200 | |||
| data | subway.NearbyResponse | No | ||||
| data.count | integer | No | ||||
| data.fetched_at | string | No | ||||
| data.next_offset | string | No | NextOffset pages through TotalResults -- pass it back as offset on the next call. Upstream does not signal "last page" explicitly; compare count/total_results, or stop once a page returns fewer stores than requested. | |||
| data.source_url | string | No | ||||
| data.stores | array | No | ||||
| data.stores[].address | subway.StoreAddress | No | StoreAddress record, 5 fields: city, country, postal_code, region, street. Described under Subway Store API. | |||
| data.stores[].can_take_online_orders | boolean | No | ||||
| data.stores[].catering_url | string | No | ||||
| data.stores[].distance_miles | number | No | DistanceMiles is measured from the requested coordinate/query. | |||
| data.stores[].features | array | No | Features lists which of the seven documented filter values this store actually has -- the same tokens the features query param accepts as input. | |||
| data.stores[].hours | array | No | StoreHours record, 7 fields: closed, closes, day_of_week, opens, segments. Described under Subway Store API. | |||
| data.stores[].is_open_now | boolean | No | ||||
| data.stores[].latitude | number | No | ||||
| data.stores[].longitude | number | No | ||||
| data.stores[].payment_methods | array | No | ||||
| data.stores[].phone_number | string | No | ||||
| data.stores[].store_id | string | No | ||||
| data.stores[].timezone | string | No | ||||
| data.total_results | integer | No | ||||
| msg | unknown | No | Msg is the message that describes the result of the request @example "Request successful" |
| Status | Description | Schema |
|---|---|---|
| 400 | Bad Request | #/definitions/app.Response |
| 429 | Too Many Requests | #/definitions/app.Response |
| 503 | Service Unavailable | #/definitions/app.Response |
Use environment variables for secrets and keep Crawlora API keys server-side.
curl -X GET "https://api.crawlora.net/api/v1/subway/nearby?query=coffee&limit=10" \
-H "x-api-key: $CRAWLORA_API_KEY"