oslew docs
Console
Menu

EventsplatformoperationId events

GET/v1/events

Events near a point or in a box overlapping a time range: ticketed events, earthquakes, and hours when air readings reached a city's alert level.

Feeds: Ticketmaster's Discovery API (concerts, games, theatre; every country it sells in, the next thirty days), the USGS real-time earthquake feed (M2.5 and up, the last week, worldwide), and air episodes derived from the station series against Mexico City's contingency programme (PCAA 2019) and the US AQI. An air episode is a run of hours with readings at that level, not a declaration: details.declared_by names who declares. Every feed searched is listed in sources with its release and licence, whether it matched or not.

Send Authorization: Bearer sk_live_…. The key's plan must include theplatform product; which plans do.

Explained in Events and earthquakes.

Example

Earthquakes near Salinas, California, newest first, in a week of November 2026.

curl
curl -G "https://api.oslew.com/v1/events" \
  -H "Authorization: Bearer $GEO_API_KEY" \
  --data-urlencode 'at=36.6777,-121.6555' \
  --data-urlencode 'radius_m=50000' \
  --data-urlencode 'category=quake' \
  --data-urlencode 'order=newest' \
  --data-urlencode 'from=1795046400' \
  --data-urlencode 'to=1795478400' \
  --data-urlencode 'limit=3'
Python
from oslew import Client

# The key is read from GEO_API_KEY.
client = Client(base_url="https://api.oslew.com")

answer = client.events(
    at="36.6777,-121.6555",
    radius_m=50000,
    from_=1795046400,
    to=1795478400,
    category="quake",
    order="newest",
    limit=3,
)
TypeScript
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.events({
  at: "36.6777,-121.6555",
  radius_m: 50000,
  from: 1795046400,
  to: 1795478400,
  category: "quake",
  order: "newest",
  limit: 3,
});
Response
HTTP/1.1 200 OK
content-type: application/json
ratelimit-limit: 100
ratelimit-remaining: 299
ratelimit-reset: 1

{
  "at": [
    36.6777,
    -121.6555
  ],
  "radius_m": 50000,
  "bbox": null,
  "from": 1795046400,
  "to": 1795478400,
  "order": "newest",
  "total": 23,
  "results": [
    {
      "id": "usgs:nc75471082",
      "title": "M 2.9 - 9 km NW of Pinnacles, CA",
      "category": "quake",
      "start": 1795428066,
      "lat": 36.587833404541,
      "lon": -121.219497680664,
      "venue": "9 km NW of Pinnacles, CA",
      "url": "https://earthquake.usgs.gov/earthquakes/eventpage/nc75471082",
      "details": {
        "depth_km": 7.30000019073486,
        "felt": 2,
        "intensity": 2.2,
        "magnitude": 2.91,
        "magnitude_type": "md",
        "status": "automatic",
        "tsunami": 0,
        "type": "earthquake",
        "updated_ms": 1795448804348
      },
      "distance_m": 40168,
      "feed": "usgs-quakes"
    },
    {
      "id": "usgs:nc75470917",
      "title": "M 2.5 - 15 km NW of Pinnacles, CA",
      "category": "quake",
      "start": 1795400744,
      "lat": 36.6218338012695,
      "lon": -121.266830444336,
      "venue": "15 km NW of Pinnacles, CA",
      "url": "https://earthquake.usgs.gov/earthquakes/eventpage/nc75470917",
      "details": {
        "depth_km": 11.3500003814697,
        "magnitude": 2.51,
        "magnitude_type": "md",
        "status": "automatic",
        "tsunami": 0,
        "type": "earthquake",
        "updated_ms": 1795402344059
      },
      "distance_m": 35226,
      "feed": "usgs-quakes"
    },
    {
      "id": "usgs:nc75470822",
      "title": "M 2.8 - 9 km NW of Pinnacles, CA",
      "category": "quake",
      "start": 1795390256,
      "lat": 36.59033203125,
      "lon": -121.210334777832,
      "venue": "9 km NW of Pinnacles, CA",
      "url": "https://earthquake.usgs.gov/earthquakes/eventpage/nc75470822",
      "details": {
        "depth_km": 5.98000001907349,
        "felt": 3,
        "intensity": 2.2,
        "magnitude": 2.8,
        "magnitude_type": "md",
        "status": "automatic",
        "tsunami": 0,
        "type": "earthquake",
        "updated_ms": 1795419831201
      },
      "distance_m": 40893,
      "feed": "usgs-quakes"
    }
  ],
  "sources": [
    {
      "name": "usgs-quakes",
      "release": "2026-11-23T21:38Z",
      "license": "USGS Earthquake Hazards Program, public domain"
    },
    {
      "name": "air-cdmx",
      "release": "2026-11-23T21:38Z",
      "license": "Derived from SEDEMA Ciudad de México (SIMAT), CC BY 4.0"
    },
    {
      "name": "air-us",
      "release": "2026-11-23T21:38Z",
      "license": "Derived from AirNow (US EPA and partners), public domain"
    }
  ],
  "took_us": 58
}

A real response, captured from the service at commit b8f4bde-dirty. Timing fields such as took_us differ on every call.

Query

NameTypeDescription
at
query
string
lat,lon; or bbox.
bbox
query
string
lng_lo,lat_lo,lng_hi,lat_hi.
radius_m
query
number
≤ 500000
default 25000
from
query
integer
Unix seconds; default a day ago.
to
query
integer
Unix seconds; default thirty days ahead.
category
query
string
Comma-separated: music, sports, arts, film, family, other, quake, air.
q
query
string
Text the title contains, any case.
order
query
string
soonest | newest | nearest
default soonest
limit
query
integer
≤ 100
default 20

Responses

200 — In the order asked for.

  • atnumber[] | nullrequired
  • bboxnumber[] | nullrequired
  • fromintegerrequired
  • orderstringrequired
  • radius_mnumber | nullrequired
  • resultsEventHit[]required
    • categorystringrequired
      music | sports | arts | film | family | other | quake | air
    • feedstringrequired
      The sources entry it came from.
    • idstringrequired
      <feed>:<provider id>, stable across refreshes.
    • latnumberrequired
    • lonnumberrequired
    • startintegerrequired
      Unix seconds. With time_tba, local midnight of the announced date.
    • titlestringrequired
    • citystring
    • countrystring
      ISO 3166-1 alpha-2.
    • detailsobject
      Per feed. Quakes: magnitude, magnitude_type, depth_km, felt, intensity, mmi, alert, tsunami, type, status, updated_ms. Ticketed: segment, genre, status, price_min, price_max, currency, onsale. Air: parameter, unit, programme, level, threshold, peak, peak_at, station, stations, declared_by.
    • distance_mnumber
      From at; absent for a box.
    • endinteger
      Unix seconds, when known.
    • time_tbaboolean
      Present and true when only the date was announced.
    • timezonestring
      IANA zone of the venue.
    • urlstring
      The provider's page: tickets, the quake's summary.
    • venuestring
      The venue, or for a quake the feed's description of where.
  • sourcesSource[]required
    Every feed searched.
    • licensestringrequired
    • namestringrequired
    • releasestringrequired
  • tointegerrequired
  • took_usintegerrequired
  • totalintegerrequired
    Matches before limit.

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.

400Bad request, or no events layer loaded.
401No key, or one that is unknown, revoked or suspended.
403The 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.
429This 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.
503The 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

Air episodes: PM2.5 at the US AQI's unhealthy level, near New Delhi
curl
curl -G "https://api.oslew.com/v1/events" \
  -H "Authorization: Bearer $GEO_API_KEY" \
  --data-urlencode 'at=28.6139,77.209' \
  --data-urlencode 'radius_m=25000' \
  --data-urlencode 'category=air' \
  --data-urlencode 'from=1794960000' \
  --data-urlencode 'to=1795132800'
Python
from oslew import Client

# The key is read from GEO_API_KEY.
client = Client(base_url="https://api.oslew.com")

answer = client.events(
    at="28.6139,77.209",
    radius_m=25000,
    from_=1794960000,
    to=1795132800,
    category="air",
)
TypeScript
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.events({
  at: "28.6139,77.209",
  radius_m: 25000,
  from: 1794960000,
  to: 1795132800,
  category: "air",
});
Response
HTTP/1.1 200 OK
content-type: application/json
ratelimit-limit: 100
ratelimit-remaining: 298
ratelimit-reset: 1

{
  "at": [
    28.6139,
    77.209
  ],
  "radius_m": 25000,
  "bbox": null,
  "from": 1794960000,
  "to": 1795132800,
  "order": "soonest",
  "total": 1,
  "results": [
    {
      "id": "air:airnow:pm25:very_unhealthy:DS1010001:1794992400",
      "title": "PM2.5 at very unhealthy level",
      "category": "air",
      "start": 1794992400,
      "end": 1795053600,
      "lat": 28.63576,
      "lon": 77.22445,
      "venue": "New Delhi",
      "details": {
        "declared_by": "Readings at this level; a contingency or action day is declared by the local air agency (AirNow action day).",
        "level": "very_unhealthy",
        "parameter": "pm25",
        "peak": 279.1,
        "peak_at": 1795028400,
        "programme": "us_aqi",
        "station": "DS1010001",
        "stations": 1,
        "threshold": 125.4,
        "unit": "µg/m³"
      },
      "distance_m": 2860,
      "feed": "air-us"
    }
  ],
  "sources": [
    {
      "name": "usgs-quakes",
      "release": "2026-11-23T21:38Z",
      "license": "USGS Earthquake Hazards Program, public domain"
    },
    {
      "name": "air-cdmx",
      "release": "2026-11-23T21:38Z",
      "license": "Derived from SEDEMA Ciudad de México (SIMAT), CC BY 4.0"
    },
    {
      "name": "air-us",
      "release": "2026-11-23T21:38Z",
      "license": "Derived from AirNow (US EPA and partners), public domain"
    }
  ],
  "took_us": 19
}

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.