# Risk Events API – Earthquakes

> Risk Events API – Earthquakes is a paid API for AI agents from risk-events-api.onrender.com, paid per call via x402, $0.0405/call, status unknown (last checked 2026-11-28).

Returns worldwide USGS earthquake events above a specified magnitude within a given time window, optionally filtered by proximity to a geographic point, with distance, depth, tsunami flag, and PAGER alert level.

## Facts

- Endpoint: GET https://risk-events-api.onrender.com/v1/earthquakes?utm_source=zero.xyz
- Price: $0.0405/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-28
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/risk-events-api-earthquakes-1c62a687
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_kfX2WjyhxYdJeYqfVFguo

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability risk-events-api-earthquakes-1c62a687
```

Example prompt: Show me all USGS earthquakes above magnitude 5.0 within 500 km of the Port of Kobe (latitude 34.69, longitude 135.19) in the last 48 hours, including depth and any tsunami warnings.

## When to prefer this

Choose this endpoint when you need real-time or near-real-time USGS earthquake data filtered by magnitude, time window, and optionally geographic proximity to a specific point such as a port, plant, city, or offshore asset. It is the right choice when you need structured seismic event data including depth, tsunami flag, and PAGER alert level for risk assessment workflows. Prefer it over generic USGS feeds when you need proximity-filtered results with distance calculations already computed.

## Known failure modes

- Missing required query context — if no parameters are provided, defaults (min_magnitude 4.5, last 24 h, global) apply but may return a very large set
- Invalid latitude/longitude values outside [-90,90] / [-180,180] range may return errors or empty results
- hours value outside 1–720 range may be rejected
- limit value outside 1–200 range may be rejected
- USGS feed latency may mean very recent events (last few minutes) are not yet reflected
- Render cold-start delays may add several seconds to first response
- Payment failure (x402) if USDC balance is insufficient

## How this service works

Returns earthquakes worldwide (USGS) above a magnitude within the last hours, optionally within a radius of a point (port, plant, city) with distance, depth, tsunami flag and PAGER alert level.

## Output

A list of earthquake events from the USGS feed matching the filters, each including magnitude, event time, location name, depth (km), distance from the query point (if lat/lon provided), a tsunami flag, and a PAGER alert level indicating estimated impact severity.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [],
     "properties": {
      "lat": {
       "type": "string",
       "description": "Center latitude (optional)"
      },
      "lon": {
       "type": "string",
       "description": "Center longitude (optional)"
      },
      "hours": {
       "type": "string",
       "description": "Look-back window in hours (1-720)"
      },
      "limit": {
       "type": "string",
       "description": "Max events (1-200)"
      },
      "radius_km": {
       "type": "string",
       "description": "Radius around the center in km (default 500)"
      },
      "min_magnitude": {
       "type": "string",
       "description": "Minimum magnitude, default 4.5"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/risk-events-api-earthquakes-1c62a687/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from risk-events-api.onrender.com](https://www.zero.xyz/host/risk-events-api.onrender.com/llms.txt)
