SDK Reference
mta.alerts.current() — active MTA service alerts
Reference for mta.alerts in mta-js. Retrieve current MTA service alerts—delays, planned work, and route suspensions—for subway or bus.
GET
Get current service alerts
TheDocumentation Index
Fetch the complete documentation index at: https://mtaapi.dev/docs/llms.txt
Use this file to discover all available pages before exploring further.
mta.alerts namespace surfaces active MTA service alerts pulled from the agency’s GTFS-Realtime alerts feed. Use mta.alerts.current to retrieve delays, planned service changes, and route suspensions for either the subway or bus network, filtered to only what’s happening right now.
mta.alerts.current(params)
Returns all active service alerts for the specified transit mode. Alerts include human-readable header and description text, affected routes, a severity classification, and the time window during which the alert applies.
Parameters
The transit mode to fetch alerts for. Accepted values are
'subway' or 'bus'. Pass 'subway' to get alerts affecting subway routes, or 'bus' to get alerts affecting bus routes.TypeScript signature
Response fields
An array of active service alerts for the requested mode, ordered by
startTime descending. Returns an empty array if there are no active alerts.Severity values
Theseverity field uses the following string values, from least to most severe:
| Value | Meaning |
|---|---|
'INFO' | General informational notice with no service impact. |
'WARNING' | Minor disruption; service is affected but operating. |
'SEVERE' | Significant disruption such as major delays or reroutes. |
'NO_SERVICE' | The affected route or portion of it is suspended. |
'NO_SERVICE' alerts often accompany planned weekend work or emergency shutdowns. Filter on this severity value to surface outages that require riders to seek alternative routes.Code example
Example response
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Query Parameters
Available options:
subway, bus, lirr, metro-north Minimum string length:
1Minimum string length:
1Previous
StopsReference for mta.stops methods in mta-js. Find nearby MTA subway and bus stops sorted by distance from any latitude and longitude.
Next
Get current service alerts