API reference

Every route the API serves. Generated, not written.

This reference renders from the OpenAPI document the server emits about itself, checked in and gated in CI, so it cannot describe a route the deployed API does not serve. Even the curl commands are generated, example values included. Base URL: https://api.orr.sh. Version 0.1.0. Every data endpoint works without a key (60 requests/minute per IP); create an account for an API key and plan-rate limits.

meta

Service liveness

get/health

curl 'https://api.orr.sh/health'
  • 200The service is up

atmosphere

International Standard Atmosphere state

get/v1/atmosphere

ISA state for a geometric altitude, computed with the standard-atmosphere crate.

curl 'https://api.orr.sh/v1/atmosphere?altitude_m=1000'
ParameterTypeRequiredDescription
altitude_mnumber (double)yesGeometric altitude, metres, -500 to 86000
  • 200ISA temperature, pressure, and density at the altitude
  • 400Missing or out-of-range altitude_m
  • 429Rate limit exceeded

weather

Weather intelligence (the V1 beachhead)

get/v1/weather/forecast

Point forecast, one time series per requested variable.

curl 'https://api.orr.sh/v1/weather/forecast?lat=35&lon=-100&vars=temperature_2m,wind_speed_10m'
ParameterTypeRequiredDescription
latnumber (double)yesLatitude, WGS84 degrees, -90 to 90
lonnumber (double)yesLongitude, WGS84 degrees, -180 to 180
varsstringyesComma-separated canonical variable ids, e.g. temperature_2m,wind_speed_10m
modelstringnoModel override: auto (default), nbm, hrrr, gfs, or ecmwf
horizon_hoursinteger (int32)noHours ahead of issue time to cover
  • 200One series per variable (stub: series are empty until the store lands)
  • 400Missing or invalid parameters
  • 429Rate limit exceeded

get/v1/weather/observations

Recent observed/analyzed values near a point.

curl 'https://api.orr.sh/v1/weather/observations?lat=35&lon=-100&var=temperature_2m&since=2026-07-01T00:00:00Z'
ParameterTypeRequiredDescription
latnumber (double)yesLatitude, WGS84 degrees, -90 to 90
lonnumber (double)yesLongitude, WGS84 degrees, -180 to 180
varstringyesCanonical variable id, e.g. temperature_2m
sincestringyesReturn values at or after this RFC 3339 instant
  • 200Observations near the point (stub: empty until the store lands)
  • 400Missing or invalid parameters
  • 429Rate limit exceeded

get/v1/weather/wind

Wind at a height above ground, for wind-energy work.

curl 'https://api.orr.sh/v1/weather/wind?lat=35&lon=-100&height_m=120'
ParameterTypeRequiredDescription
latnumber (double)yesLatitude, WGS84 degrees, -90 to 90
lonnumber (double)yesLongitude, WGS84 degrees, -180 to 180
height_mnumber (double)yesHeight above ground to report wind at, metres, 10 to 300 (modern turbine hubs sit at 80-160 m)
  • 200Wind at the requested height from the freshest published GFS cycle, with the shear derivation and model lineage
  • 400Missing or invalid parameters
  • 429Rate limit exceeded
  • 503No recent GFS cycle is reachable

energy

Power-system data, keyed by ISO zone

get/v1/energy/load

System load (demand) for a zone.

curl 'https://api.orr.sh/v1/energy/load?zone=ERCOT'
ParameterTypeRequiredDescription
zonestringyesBalancing authority / ISO zone, e.g. CAISO, ERCOT, MISO, PJM
sincestringnoReturn values at or after this RFC 3339 instant (default: now)
  • 200Load series for the zone (stub: null until the store lands)
  • 400Missing or invalid parameters
  • 429Rate limit exceeded

get/v1/energy/prices

Locational marginal prices for a zone (optionally one node/hub).

curl 'https://api.orr.sh/v1/energy/prices?zone=ERCOT'
ParameterTypeRequiredDescription
zonestringyesBalancing authority / ISO zone, e.g. CAISO, ERCOT, MISO, PJM
nodestringnoNode or hub within the zone
sincestringnoReturn values at or after this RFC 3339 instant (default: now)
  • 200LMP series for the zone (stub: null until the store lands)
  • 400Missing or invalid parameters
  • 429Rate limit exceeded

account

Self-serve accounts and API keys. Data endpoints work without a key at 60 requests/minute per IP; a free key raises that to 300.

post/v1/accounts

Create an account and its first API key.

curl -X POST 'https://api.orr.sh/v1/accounts' \
  -H 'content-type: application/json' \
  -d '{"email":"trader@example.com","password":"correct-horse-battery"}'
  • 201Account created; the key secret is shown only here
  • 400Invalid email or password shape
  • 409An account with this email already exists
  • 429Rate limit exceeded

post/v1/auth/login

Verify credentials and see the account and its keys.

curl -X POST 'https://api.orr.sh/v1/auth/login' \
  -H 'content-type: application/json' \
  -d '{"email":"trader@example.com","password":"correct-horse-battery"}'
  • 200Credentials verified; the account and its key metadata
  • 401Email or password is incorrect
  • 429Rate limit exceeded

post/v1/keys

Mint an additional API key.

curl -X POST 'https://api.orr.sh/v1/keys' \
  -H 'content-type: application/json' \
  -d '{"email":"trader@example.com","password":"correct-horse-battery"}'
  • 201Key minted; the secret is shown only here
  • 401Email or password is incorrect
  • 429Rate limit exceeded

post/v1/keys/revoke

Revoke an API key by id.

curl -X POST 'https://api.orr.sh/v1/keys/revoke' \
  -H 'content-type: application/json' \
  -d '{"email":"trader@example.com","key_id":"ok_1a2b3c4d5e6f","password":"correct-horse-battery"}'
  • 200Key revoked
  • 401Email or password is incorrect
  • 404No such key on this account
  • 429Rate limit exceeded

get/v1/me

The identity behind the presented API key.

curl 'https://api.orr.sh/v1/me' \
  -H "Authorization: Bearer $ORRERY_API_KEY"
  • 200The account, plan, and limits behind the key
  • 401Missing, unknown, or revoked API key
  • 429Rate limit exceeded

signup

Early-access list (double opt-in)

get/v1/confirm

Finish a double opt-in: match the token, flip to confirmed, render the page.

curl 'https://api.orr.sh/v1/confirm?e=you@example.com&t=one-time-token-from-the-email'
ParameterTypeRequiredDescription
estringyesSubscriber email address
tstringyesOne-time confirmation token from the email
  • 200Confirmed onto the list; a branded HTML page
  • 400Missing, malformed, or stale link; a branded HTML page
  • 500Backend failure; a branded HTML page

post/v1/subscribe

Capture a signup: validate, store the row, best-effort send the confirm email.

curl -X POST 'https://api.orr.sh/v1/subscribe' \
  -H 'content-type: application/json' \
  -d '{"email":"you@example.com"}'
  • 200Already confirmed; nothing re-sent
  • 202Captured; the double-opt-in email was sent or deferred
  • 400Not a valid email address
  • 500The subscription store is unavailable