apyhub
GEOLOCATION · STANDARD DATA

Retrieve USGS Earthquake Data API

What it does

USGS Earthquake Data returns earthquake records from the USGS feed for a time window you define. Send a starttime and endtime, and optionally filter by minmagnitude and limit.

Use it when you need recent seismic events for dashboards, alerts, research workflows, or map visualisations. The endpoint is built around query parameters, so it fits cleanly into scheduled jobs and lightweight backend services.

The response schema is open-ended, so the service returns a structured JSON object with the earthquake data available from the source response. In practice, that lets you treat the endpoint as a retrieval layer for USGS event data without having to wire up the feed directly.

If you are building monitoring tools, compliance checks, or location-based analysis, USGS Earthquake Data gives you a simple way to fetch events for a specific date range and magnitude threshold.

GET
USGS earthquakes
http://localhost:8080/dosvak/usgs-earthquakes

QUICKSTART

GUIDE

Quickstart

Fetch USGS earthquake data for a date range using the required query parameters.

curl -X GET "http://localhost:8080/dosvak/usgs-earthquakes?starttime=2026-07-01&endtime=2026-07-28" \
  -H "apy-token: $APY_TOKEN"

What you'll get back

Returns a JSON object. The schema does not declare any specific top-level fields, so the response shape may vary.

{
  "count": 2,
  "results": [
    {
      "id": "event_12345",
      "time": 1753690200000,
      "place": "Sample Location",
      "magnitude": 5.2,
      "latitude": 35.1234,
      "longitude": -117.4567,
      "depth_km": 10.5,
      "status": "reviewed"
    }
  ],
  "attribution": [
    {
      "source": "USGS"
    }
  ]
}
TRY ITLIVE · 100 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.

About this endpoint

What it does

Retrieves USGS earthquake data for a specified time range, with optional filtering by result limit and minimum magnitude. The response schema is not yet defined beyond a JSON object, so the exact fields returned are not captured here.

Query Parameter(s)

AttributeTypeMandatoryDescription
limitIntegerNoMaximum number of results to return.<br>Default: 100.<br>Minimum: 1.<br>Maximum: 1000.
endtimeStringYesEnd of the time range to query.
starttimeStringYesStart of the time range to query.
minmagnitudeNumberNoMinimum earthquake magnitude to include.<br>Default: 4.5.<br>Minimum: 0.<br>Maximum: 10.

Response

Returns a JSON object. The schema allows additional properties, but it does not define any concrete top-level fields, so the exact response shape is not specified yet.

Query parameters

Name
Type
Description
limitOPTIONAL
integer
DEFAULT 100
endtimeREQUIRED
string
starttimeREQUIRED
string
minmagnitudeOPTIONAL
number
DEFAULT 4.5
▣ COMMON ERRORS

Errors any endpoint can return

400bad_request

Required parameter missing or malformed body.

401unauthorized

API key missing, revoked, or not authorized for this service.

429rate_limited

Your plan's per-second rate exceeded. Retry with exponential backoff.

503upstream_busy

Backend temporarily unavailable. Try again in a few seconds.