# Observations

> Measured surface conditions at a point with every field credited to its own station, plus the stations themselves, their latest readings and their recent history.

API reference · Reference · https://wxalerts.org/docs/api/observations/

Base URL: `https://api.wxalerts.org`

What real instruments are reporting right now: airfield observations, buoys
and coastal stations, and the backyard stations of CWOP and amateur radio.
Nothing here is a model. Every number says which station it came from, how far
away that station is, and how old the reading was.

No key needed. Browsers block calls from other websites (CORS allows only
wxalerts.org), so call it from a server, script or app. The answers are
cached for 60 seconds; see [rate limits](/docs/developers/rate-limits/).

For a screen that wants six flat numbers and a forecast beside them, use
[`GET /weather`](/docs/api/weather/). Its `current` block is `/conditions`
reduced to one value per field and one station name.

## Where the readings come from

Every station has an id with its network in front of it, and a `source`
naming the feed it arrives on.

| `source` | id looks like | what it is | `trust_tier` |
| --- | --- | --- | --- |
| `metar` | `metar:KDTO` | ASOS and AWOS at airfields, via the Aviation Weather Center. Reports hourly, more often when the weather changes | 1 |
| `ndbc` | `ndbc:42095`, `ndbc:LONF1` | NDBC buoys, C-MAN and coastal stations, NOS tide gauges and partner platforms. The only source of sea state | 1 |
| `fawn` | `fawn:405` | The Florida Automated Weather Network, about 50 University of Florida research stations. Every 15 minutes, with a 10 m wind and its 15-minute maximum as the gust | 2 |
| `aprs` | `cwop:GW4373`, `aprs:KC5CAM-13` | CWOP and amateur radio weather stations off APRS-IS, mostly every five minutes. `cwop:` ids are CWOP registrations, `aprs:` ids are callsigns | 4 |

`trust_tier` runs from 1 (a maintained instrument) to 4 (somebody's console).
Tier 2 is for mesonets (FAWN is the first) and tier 3 for stations hosted here
directly (`source` `pws`), which is not ingesting yet. The
[station owner's guide](/docs/weather-stations/on-wxalerts/) covers how a
CWOP station is positioned and weighted from the other side.

Two more labels describe the platform rather than the feed:

- `station_type`: `land`, `coastal`, `buoy`, `platform`, `usv`, `dart`,
  `tao` or `other`. A METAR can come from an oil rig.
- `domain`: `land` or `marine`. Whether the station may speak for conditions
  ashore. A buoy is `marine`; a C-MAN tower on a pier is `land`, because the
  air it measures is the air on the beach.

`position_source`, on a single station, is where its coordinates came from: a
roster (`awc`, `madis`, `ndbc`, `fawn`) or the station's own APRS beacon (`aprs`),
which is self-reported.

## How a point's conditions are ranked

The nearest stations are ranked once, and each field takes the best-ranked
station that reports it. A station missing a sensor costs that one field, not
the whole answer. Stations are never averaged. Two stations disagreeing is a
fact about the weather; their mean is a number nobody observed.

The ranking is one line:

> score = distance × tier penalty × (1 + age in seconds / 7200)

Lowest wins. The tier penalty is 1.0 for tier 1, 1.3 for tier 2, 1.6 for
tier 3 and 2.0 for tier 4, so a CWOP station has to be more than twice as
close as an airfield to win a field, and a reading two hours old counts as
twice as far away as a fresh one. In the Florida Keys that puts a C-MAN tower
32 km away ahead of a CWOP station 10 km away for temperature and wind.

Each entry in `fields` carries:

| key | |
| --- | --- |
| `value` | in the response's unit system |
| `unit`, `label` | machine code (`F`, `hPa`) and display form (`°F`) |
| `station_id`, `source` | who measured it |
| `distance_m` | from the requested point to that station |
| `age_seconds` | how old the reading was when served |
| `derived` | computed rather than measured. A METAR carries no humidity and a CWOP packet carries no dew point, so the missing half of each pair is derived from the other (`relative_humidity` on `metar`, `dewpoint` on `aprs`) |

## Readings that are held back

A broken backyard thermometer is caught by its neighbors. For `temperature`
and `dewpoint`, a reading more than 16.7 °C (about 30 °F) from the median of
at least three land stations within 50 miles is refused, and the field falls
through to the next station. The bound is loose on purpose: sea breezes,
outflow and valley inversions are real and stay. When a derived value fails,
the measurement it came from goes with it (a CWOP dew point fails, so its
humidity is withheld too). Wind and rain are never checked this way, because
one storm really can put them at one station and not the next.

Buoys and offshore platforms (`domain: marine`) never answer air temperature,
moisture, wind, cloud or present weather for a point, because air over open
water is not the air ashore. Their pressure counts, and they are the main
source of `marine`.

## The fields

Field names in `fields`, `marine`, a station's `latest` and a history's
`samples` are the ones below and under [Sea state](#sea-state).

| field | |
| --- | --- |
| `temperature`, `dewpoint`, `relative_humidity` | |
| `wind_direction` | degrees true, the direction it blows **from**. A calm METAR reports `0` with a speed of `0` |
| `wind_speed`, `wind_gust` | sustained wind and peak gust |
| `pressure_sea_level` | reduced to sea level. On a CWOP station the owner's console did the reduction, with an elevation they typed in |
| `pressure_altimeter` | the altimeter setting in a METAR |
| `pressure_station` | at the station, not reduced |
| `pressure_tendency` | change over the last three hours; negative is falling |
| `visibility` | prevailing |
| `precip_1h`, `precip_24h`, `precip_since_local_midnight` | accumulations over each window |
| `snow_depth` | |
| `solar_irradiance` | downwelling, W/m² in every system |
| `cloud` | METAR sky layers, lowest first: `[{ "cover": "BKN", "base_ft_agl": 3900.0 }]`. Bases are always feet above ground, whatever `units` says |
| `wx_string` | present weather in METAR code: `"-RA BR"`, `"VCSH"` |
| `flight_category` | `VFR`, `MVFR`, `IFR` or `LIFR` |

Three pressures, never one: they are different measurements, and a station
can report all three. `/weather` picks one for you.

`cloud`, `wx_string` and `flight_category` carry `null` for `unit` and
`label`; they are text, not quantities.

## Sea state

```json
"marine": {
  "water_temperature": { "value": 83.7, "unit": "F", "label": "°F", "station_id": "ndbc:TBYF1",
                         "source": "ndbc", "station_type": "coastal", "distance_m": 21126,
                         "age_seconds": 4035, "derived": false },
  "water_level": { "value": 0.3, "unit": "ft", "label": "ft", "station_id": "ndbc:TBYF1",
                   "source": "ndbc", "station_type": "coastal", "distance_m": 21126,
                   "age_seconds": 4035, "derived": false }
}
```

`marine` is its own block, chosen the same way, because the station that
answers it is often much further away and the distance is the point. It is
`{}` inland. Each entry adds `station_type`, so you can tell a buoy 30 km out
from a gauge on the pier.

| field | |
| --- | --- |
| `water_temperature` | near the waterline, about 0.6 m down on a buoy hull. Not a skin or satellite temperature |
| `wave_height` | significant wave height: the mean of the highest third, about half the largest wave present |
| `wave_period_dominant`, `wave_period_average` | seconds. In a mixed sea the two differ |
| `wave_direction` | degrees true, the direction the dominant waves come **from** |
| `water_level` | above the station's datum |

## Map clients

- For a marine layer, filter on **`reports_sea=true`, not `domain=marine`**.
  In the Keys box `-83,24,-79,27`, `domain=marine` finds 2 stations and
  `reports_sea=true` finds 18.
- A platform that reaches us through two feeds is drawn once.
- A station that has not reported for 24 hours is dropped from the map and
  from every conditions answer, whatever `max_age_minutes` asks for. It comes
  back on its next report. Its history stays until it ages out (below).
- The check behind `withheld` is the one above, run against the station's
  neighbors in the viewport. A viewport with fewer than three peers around a
  station gets no check.

### `detail=minimal`

`minimal` keeps what a client needs to place and color a point:

```json
{ "station_id": "metar:KLUD", "source": "metar", "temperature": 66.2,
  "lat": 33.2568, "lon": -97.5826, "age_seconds": 927 }
```

With `reports_sea=true` or `domain=marine`, the minimal row swaps the air
temperature for the water:

```json
{ "station_id": "ndbc:41122", "source": "ndbc", "station_type": "buoy",
  "water_temperature": 82.9, "wave_height": 1.3,
  "lat": 26.001, "lon": -80.096, "age_seconds": 2427 }
```

## How much history

Readings are kept for 90 days, then deleted.

A CWOP station reports every five minutes, so a week of it is around 2,000
rows and the default `limit` of 500 covers about the last two days. If `count`
equals `limit`, the start of the window was cut; ask for a higher `limit` to
reach it.

## Units

```
GET /conditions?lat=33.2&lon=-97.1&units=metric
```

| value | temperature | speed | pressure | precipitation | visibility | wave height, water level |
| --- | --- | --- | --- | --- | --- | --- |
| `si` | K | m/s | Pa | kg/m² | m | m |
| `metric` | °C | km/h | hPa | mm | km | m |
| `us` | °F | mph | inHg | in | mi | ft |
| `uk` | °C | mph | hPa | mm | mi | m |
| `auto` | chosen from the caller's country | | | | | |

Humidity is `%`, directions `deg`, wave periods `s` and solar irradiance
W/m² in every system. With `auto`, a country that reads Fahrenheit gets
`us`, Britain gets `uk` and everywhere else `metric`; a caller who cannot be
placed gets `us`.

Every response's `units` block names the system, how it was chosen
(`source`: `explicit`, `geo` or `default`), the country when it was chosen
from one, and the unit, label and a one-line description for every field the
endpoint can return. The vocabulary is the forecast's own, so a `temperature`
here and a `temperature` on [`/forecast`](/docs/api/forecast/) render through
the same code.

A response whose units were picked from your country comes back
`Cache-Control: private`. **Pass `units` explicitly** for a response a CDN
can share.

## `GET /conditions`

**Observed conditions at a point, assembled from nearby stations.**

**Access.** Anonymous, or an [API key](/docs/developers/api-keys/) holding `weather:read`. Also served at `/v1/conditions`, where a key (or the app or website sign-in) is required. Anonymous requests share the per-address limit, and a request with a key is charged to the key. See [Rate limits](/docs/api/conventions/#rate-limits).

Measured surface conditions at a point, with every field credited to its own station.

This is not a forecast and does not blend with one. Give `lat` and `lon`, or
`location_id`, or `q`. The nearest stations are ranked once (distance,
weighted by how much the network is trusted and by the age of the reading)
and each field takes the best ranked station that reports it, so the
temperature can come from a backyard station and the visibility from an
airfield. Stations are never averaged. Every field names the station it came
from, how far away that station is and how old the reading was.

There is no distance cap: a point in the open ocean is answered from the
nearest airfield, however far, so check `distance_m` before showing a number
as "here". `candidates_considered` of 0 means nothing has reported nearby
within `max_age_minutes`. Sea state is returned separately in `marine`. A
field absent from `fields` had no station reporting it.

### Parameters

| Name | In | Type | Required | Default | Bounds | Description |
| --- | --- | --- | --- | --- | --- | --- |
| `lat` | query | number or null | no | none | -90 to 90 | Latitude of the point, in degrees north |
| `lon` | query | number or null | no | none | -180 to 180 | Longitude of the point, in degrees east |
| `q` | query | string or null | no | none | at least 1 character, at most 120 characters | A place name, used instead of `lat` and `lon`. The best match from `/locations/search` is used. No match is a 404 |
| `location_id` | query | integer or null | no | none | none | A place id from a `/locations/search` result, used instead of `lat` and `lon`. An unknown id is a 404 |
| `units` | query | "si" \| "metric" \| "us" \| "uk" \| "auto" | no | `"auto"` | none | Unit system for every measurement in the response. `si` is exactly what the model published (K, m/s, Pa, kg/m2, m). `metric` is degrees C, km/h, hPa, mm, km. `us` is degrees F, mph, inHg, in, mi. `uk` is degrees C, mm and hPa, but mph and miles. `auto` (the default) picks one from the caller's country, and a caller who cannot be placed gets `us`. The response's `units` block names the unit of every field. An `auto` response varies by caller and is sent `Cache-Control: private`; pass a system explicitly for a response a shared cache can hold |
| `max_age_minutes` | query | integer | no | `120` | 5 to 1440 | Ignore stations whose last report is older than this many minutes, from 5 to 1440 |
| `limit` | query | integer | no | `12` | 1 to 50 | How many of the nearest stations to rank, from 1 to 50. More fills more fields, from further away |

### Response

Returns object.

| Field | Type | Description |
| --- | --- | --- |
| `server_time` | string (date-time) | When the response was built, in UTC. |
| `location` | object | The point the conditions are for. |
| `location.lat` | number | Latitude of the point the conditions are for, degrees north. |
| `location.lon` | number | Longitude of the point, degrees east. |
| `location.name` | string or null | Place name when the point was given as `q` or `location_id`. |
| `location.display_name` | string or null | Place name with its state, e.g. 'Denton, TX'. Same rule as `name`. |
| `location.state` | string or null | State or region of the named place. |
| `units` | object | The unit system and the unit of every field. |
| `units.system` | string | The unit system used: si \| metric \| us \| uk |
| `units.source` | string | How the system was chosen. 'explicit': you asked for it. 'geo': derived from the caller's country, so the response varies by caller. 'default'. |
| `units.country` | string or null | The country the system was derived from, when it was. |
| `units.fields` | object | The unit, display label and a one line description of every field this endpoint can return, keyed by field name. |
| `fields` | object | Keyed by field name. Absent keys had no station reporting them. |
| `marine` | object | Sea state from the nearest marine platform: water temperature, wave height and period. Separate from `fields` because it is answered by a different population of station and is often much further away, so the distance is part of the answer. Empty inland. |
| `stations` | array of object | Only the stations that supplied at least one field, with their position, raw report, distance and age. |
| `stations[].station_id` | string | Station id with its network in front, e.g. 'metar:KDTO' or 'aprs:KC5CAM-13'. |
| `stations[].source` | string | The feed the station reports through: metar \| aprs \| ndbc \| fawn \| pws |
| `stations[].station_type` | string or null | The physical platform: land, coastal, buoy, platform, usv, dart, tao or other. A METAR can come from an oil rig. |
| `stations[].domain` | string or null | `land` or `marine`: whether the station may speak for conditions ashore. A buoy is marine; a C-MAN tower on a pier is land. |
| `stations[].trust_tier` | integer or null | 1 METAR/ASOS · 2 mesonet · 3 hosted PWS · 4 CWOP/APRS |
| `stations[].name` | string or null | From the station roster. Airfields are named; CWOP stations usually are not. |
| `stations[].lat` | number or null | Station latitude, degrees north. |
| `stations[].lon` | number or null | Station longitude, degrees east. |
| `stations[].distance_m` | integer | Meters from the requested point to the station. |
| `stations[].age_seconds` | integer | How old the station's reading was when served. |
| `stations[].observed_at` | string (date-time) or null | When the station reported, in UTC. |
| `stations[].raw` | string or null | The station's own report: a raw METAR or APRS packet |
| `candidates_considered` | integer | Stations ranked for this point. Zero means nothing has reported nearby recently, a different answer from every field being absent. |

```json
{
  "candidates_considered": 12,
  "fields": {
    "cloud": {
      "age_seconds": 854,
      "derived": false,
      "distance_m": 6210,
      "source": "metar",
      "station_id": "metar:KDTO",
      "value": [
        {
          "base_ft_agl": 3900,
          "cover": "BKN"
        }
      ]
    },
    "pressure_altimeter": {
      "age_seconds": 854,
      "derived": false,
      "distance_m": 6210,
      "label": "inHg",
      "source": "metar",
      "station_id": "metar:KDTO",
      "unit": "inHg",
      "value": 30.2
    },
    "temperature": {
      "age_seconds": 74,
      "derived": false,
      "distance_m": 2485,
      "label": "°F",
      "source": "aprs",
      "station_id": "aprs:KC5CAM-13",
      "unit": "F",
      "value": 69
    }
  },
  "location": {
    "lat": 33.215,
    "lon": -97.133
  },
  "marine": {},
  "server_time": "2026-11-09T19:07:14Z",
  "stations": [
    {
      "age_seconds": 854,
      "distance_m": 6210,
      "domain": "land",
      "lat": 33.2088,
      "lon": -97.1992,
      "name": "Denton Muni, TX",
      "observed_at": "2026-11-09T18:53:00Z",
      "raw": "METAR KDTO 091853Z AUTO 17003KT 10SM BKN039 19/13 A3020 RMK AO2 SLP221 T01940128",
      "source": "metar",
      "station_id": "metar:KDTO",
      "station_type": "land",
      "trust_tier": 1
    }
  ],
  "units": {
    "fields": {
      "pressure_altimeter": {
        "description": "Altimeter setting, as reported in a METAR.",
        "label": "inHg",
        "unit": "inHg"
      },
      "temperature": {
        "description": "Air temperature.",
        "label": "°F",
        "unit": "F"
      }
    },
    "source": "explicit",
    "system": "us"
  }
}
```

### Errors

| Status | Meaning |
| --- | --- |
| 404 | `{"detail": "No place matched 'xyz'"}` for a `q` with no match, or `{"detail": "Unknown location id"}` for a `location_id` that matches nothing. |
| 422 | `{"detail": "Give lat and lon, or location_id, or q."}` when none of the three ways to name the point is given. A bad value in any parameter returns the [list form](/docs/api/conventions/#the-422-format). |

Plus the [common errors](/docs/api/conventions/#errors) every route can return (`400 key_in_query`, `401`, `403`, `429`, `500`).

### Caching and limits

`Cache-Control: public, max-age=60`. When `units` is `auto` and your country is known from the request, the answer depends on the caller, so it is sent `private, max-age=60` with `Vary: CF-IPCountry`; pass `units` explicitly for a response a shared cache can hold. Under `/v1` the header is always `private`. There is no `ETag`, so no `304`; cache for the `max-age` and ask again after it.

## `GET /stations`

**Reporting stations inside a viewport.**

**Access.** Anonymous, or an [API key](/docs/developers/api-keys/) holding `weather:read`. Also served at `/v1/stations`, where a key (or the app or website sign-in) is required. Anonymous requests share the per-address limit, and a request with a key is charged to the key. See [Rate limits](/docs/api/conventions/#rate-limits).

Every station in a map viewport that has reported recently, with its latest reading.

For drawing a map. Stations that reported within `max_age_minutes` are
returned, airfields and buoys first, then the most recent. Filter with
`sources`, `domain` or `reports_sea`. For a marine layer use
`reports_sea=true` rather than `domain=marine`: nearly half the stations
that report sea state (piers, C-MAN towers, tide gauges) are in the land
domain. `truncated` is true when the box held more stations than `limit`.
A field that disagrees badly with the station's neighbors is set to null and
named in `withheld`, so the station stays on the map.

### Parameters

| Name | In | Type | Required | Default | Bounds | Description |
| --- | --- | --- | --- | --- | --- | --- |
| `bbox` | query | string | yes | none | none | The viewport as `west,south,east,north` in degrees: the map's current extent. At most 30 degrees a side, or up to 180 when `sources=metar` is the only source. Does not cross the antimeridian. A malformed, inverted or oversized box is a 422 saying which |
| `units` | query | "si" \| "metric" \| "us" \| "uk" \| "auto" | no | `"auto"` | none | Unit system for every measurement in the response. `si` is exactly what the model published (K, m/s, Pa, kg/m2, m). `metric` is degrees C, km/h, hPa, mm, km. `us` is degrees F, mph, inHg, in, mi. `uk` is degrees C, mm and hPa, but mph and miles. `auto` (the default) picks one from the caller's country, and a caller who cannot be placed gets `us`. The response's `units` block names the unit of every field. An `auto` response varies by caller and is sent `Cache-Control: private`; pass a system explicitly for a response a shared cache can hold |
| `limit` | query | integer | no | `400` | 1 to 2000 | Most stations to return, from 1 to 2000. `truncated` says when the viewport held more |
| `sources` | query | string or null | no | none | none | Comma separated feeds to include: `metar`, `aprs`, `ndbc`, `fawn`, `pws`. Default is all. An unknown name matches nothing rather than failing |
| `domain` | query | "land" \| "marine" or null | no | none | none | Whether the station may speak for conditions ashore. Marine platforms (buoys, offshore rigs) are excluded from land composition because air measured over open water is not the air on the beach |
| `reports_sea` | query | boolean | no | `false` | none | Only stations measuring the water: sea surface temperature or wave height. This is NOT the same as domain=marine, and a marine map layer wants this one: a C-MAN tower on a pier is in the land domain, because its air temperature is the air ashore, and it still reports the water beside it. Nearly half of all sea-state observations come from stations in the land domain |
| `max_age_minutes` | query | integer | no | `120` | 5 to 1440 | Leave out stations whose last report is older than this many minutes, from 5 to 1440 |
| `detail` | query | "full" \| "minimal" | no | `"full"` | none | `full` (the default) returns the whole row for each station. `minimal` returns only what is needed to place and color a point: position, one reading and the age. That reading is the air temperature, or, with `reports_sea=true` or `domain=marine`, the water temperature and wave height. For a client drawing a field rather than a list: over a continent the full rows are most of a megabyte, nearly all of it raw reports nobody will click |

### Response

Returns object.

| Field | Type | Description |
| --- | --- | --- |
| `server_time` | string (date-time) | When the response was built, in UTC. |
| `count` | integer | Number of stations in `stations`. |
| `truncated` | boolean | The viewport holds more reporting stations than the limit returned. Zoom in rather than assuming this is all of them. |
| `units` | object | The unit system and the unit of every field. |
| `units.system` | string | The unit system used: si \| metric \| us \| uk |
| `units.source` | string | How the system was chosen. 'explicit': you asked for it. 'geo': derived from the caller's country, so the response varies by caller. 'default'. |
| `units.country` | string or null | The country the system was derived from, when it was. |
| `units.fields` | object | The unit, display label and a one line description of every field this endpoint can return, keyed by field name. |
| `stations` | array of object | Stations in the box, airfields and buoys first, then the most recent. With `detail=minimal` each row carries only a few keys. |
| `stations[].station_id` | string | Station id with its network in front, e.g. 'metar:KLUD' or 'cwop:GW4373'. |
| `stations[].source` | string | The feed the station reports through: metar \| aprs \| ndbc \| fawn \| pws |
| `stations[].network` | string or null | The roster's name for the program, finer than `source`: ASOS/AWOS, CWOP, APRSWXNET, NOS/CO-OPS, IOOS Partners and so on. |
| `stations[].name` | string or null | From the station roster. Often null for CWOP. |
| `stations[].lat` | number | Station latitude, degrees north. |
| `stations[].lon` | number | Station longitude, degrees east. |
| `stations[].elevation_m` | number or null | Station elevation above sea level, meters. |
| `stations[].trust_tier` | integer or null | 1 METAR/ASOS · 2 mesonet · 3 hosted PWS · 4 CWOP/APRS |
| `stations[].station_type` | string or null | The physical platform, which `source` does not tell you: land, coastal, buoy, platform, usv, dart, tao or other. |
| `stations[].domain` | string or null | `land` or `marine`: whether the station may speak for conditions ashore. The one thing a map layer needs to decide whether to draw it. |
| `stations[].observed_at` | string (date-time) or null | When the station reported, in UTC. |
| `stations[].age_seconds` | integer or null | How old the reading was when served. Null if it has never reported. |
| `stations[].temperature` | number or null | Air temperature, in the response's units. |
| `stations[].dewpoint` | number or null | Dew point, in the response's units. |
| `stations[].relative_humidity` | number or null | Relative humidity, percent. |
| `stations[].wind_direction` | number or null | Direction the wind blows from, degrees true. |
| `stations[].wind_speed` | number or null | Sustained wind speed, in the response's units. |
| `stations[].wind_gust` | number or null | Peak gust, in the response's units. |
| `stations[].pressure_sea_level` | number or null | Pressure reduced to sea level, in the response's units. |
| `stations[].precip_1h` | number or null | Precipitation over the last hour, in the response's units. |
| `stations[].water_temperature` | number or null | Water temperature near the surface. Null ashore. |
| `stations[].wave_height` | number or null | Significant wave height, in the response's units. Null ashore. |
| `stations[].wave_period_dominant` | number or null | Dominant wave period, seconds. Null ashore. |
| `stations[].wave_direction` | number or null | Direction the dominant waves come from, degrees true. Null ashore. |
| `stations[].raw` | string or null | The station's own report: a raw METAR or APRS packet. |
| `stations[].withheld` | array of string | Fields this station reported that disagreed with its neighbors badly enough to be withheld. Each is set to null above. Empty when nothing was refused. |

```json
{
  "count": 1,
  "server_time": "2026-11-09T19:10:02Z",
  "stations": [
    {
      "age_seconds": 927,
      "dewpoint": 53.6,
      "domain": "land",
      "elevation_m": 319,
      "lat": 33.2568,
      "lon": -97.5826,
      "name": "Decatur Muni, TX",
      "network": "ASOS/AWOS",
      "observed_at": "2026-11-09T18:55:00Z",
      "raw": "METAR KLUD 091855Z AUTO 19004KT 10SM FEW029 FEW036 FEW100 19/12 A3020 RMK AO2",
      "relative_humidity": 63.8,
      "source": "metar",
      "station_id": "metar:KLUD",
      "station_type": "land",
      "temperature": 66.2,
      "trust_tier": 1,
      "wind_direction": 190,
      "wind_speed": 4.6,
      "withheld": []
    }
  ],
  "truncated": true,
  "units": {
    "fields": {
      "pressure_altimeter": {
        "description": "Altimeter setting, as reported in a METAR.",
        "label": "inHg",
        "unit": "inHg"
      },
      "temperature": {
        "description": "Air temperature.",
        "label": "°F",
        "unit": "F"
      }
    },
    "source": "explicit",
    "system": "us"
  }
}
```

### Errors

| Status | Meaning |
| --- | --- |
| 422 | `bbox` is not four numbers: `{"detail": "bbox must be four numbers: west,south,east,north"}`; not west < east, south < north and inside the world: `{"detail": "bbox must be west<east, south<north, and within the world"}`; wider or taller than 30 degrees (180 when `sources=metar` is the only source): `{"detail": "bbox is larger than 30° a side; zoom in, or ask for sources=metar"}`. Other bad values return the [list form](/docs/api/conventions/#the-422-format). |

Plus the [common errors](/docs/api/conventions/#errors) every route can return (`400 key_in_query`, `401`, `403`, `429`, `500`).

### Caching and limits

`Cache-Control: public, max-age=60`. When `units` is `auto` and your country is known from the request, the answer depends on the caller, so it is sent `private, max-age=60` with `Vary: CF-IPCountry`; pass `units` explicitly for a response a shared cache can hold. Under `/v1` the header is always `private`. There is no `ETag`, so no `304`; cache for the `max-age` and ask again after it. With `detail=minimal` the body is built differently and its `server_time` uses the `+00:00` form instead of `Z`; see [Units and timestamps](/docs/api/conventions/#units-and-timestamps).

## `GET /stations/{station_id}`

**One station and its latest reading.**

**Access.** Anonymous, or an [API key](/docs/developers/api-keys/) holding `weather:read`. Also served at `/v1/stations/{station_id}`, where a key (or the app or website sign-in) is required. Anonymous requests share the per-address limit, and a request with a key is charged to the key. See [Rate limits](/docs/api/conventions/#rate-limits).

One station: who it is, where it is and its latest reading.

`latest` holds only the fields this station reports; an absent key means
the station has no such sensor. `position_source` says where the
coordinates came from. A station on the roster that has not sent anything
yet has `observed_at`, `age_seconds` and `raw` null and `latest` empty.

### Parameters

| Name | In | Type | Required | Default | Bounds | Description |
| --- | --- | --- | --- | --- | --- | --- |
| `station_id` | path | string | yes | none | at most 64 characters | Source-prefixed id, e.g. metar:KMOB, cwop:EW1958, aprs:KN4OQW-9 |
| `units` | query | "si" \| "metric" \| "us" \| "uk" \| "auto" | no | `"auto"` | none | Unit system for every measurement in the response. `si` is exactly what the model published (K, m/s, Pa, kg/m2, m). `metric` is degrees C, km/h, hPa, mm, km. `us` is degrees F, mph, inHg, in, mi. `uk` is degrees C, mm and hPa, but mph and miles. `auto` (the default) picks one from the caller's country, and a caller who cannot be placed gets `us`. The response's `units` block names the unit of every field. An `auto` response varies by caller and is sent `Cache-Control: private`; pass a system explicitly for a response a shared cache can hold |

### Response

Returns object.

| Field | Type | Description |
| --- | --- | --- |
| `server_time` | string (date-time) | When the response was built, in UTC. |
| `units` | object | The unit system and the unit of every field. |
| `units.system` | string | The unit system used: si \| metric \| us \| uk |
| `units.source` | string | How the system was chosen. 'explicit': you asked for it. 'geo': derived from the caller's country, so the response varies by caller. 'default'. |
| `units.country` | string or null | The country the system was derived from, when it was. |
| `units.fields` | object | The unit, display label and a one line description of every field this endpoint can return, keyed by field name. |
| `station` | object | The station and its latest reading. |
| `station.station_id` | string | Station id with its network in front, e.g. 'metar:KDTO'. |
| `station.source` | string | The feed the station reports through: metar \| aprs \| ndbc \| fawn \| pws |
| `station.station_type` | string or null | The physical platform: land, coastal, buoy, platform, usv, dart, tao or other. |
| `station.domain` | string or null | `land` or `marine`: whether the station may speak for conditions ashore. |
| `station.network` | string or null | The roster's name for the program, e.g. ASOS/AWOS, CWOP, NOS/CO-OPS. |
| `station.name` | string or null | From the station roster. Often null for CWOP. |
| `station.lat` | number or null | Station latitude, degrees north. |
| `station.lon` | number or null | Station longitude, degrees east. |
| `station.elevation_m` | number or null | Station elevation above sea level, meters. |
| `station.trust_tier` | integer or null | 1 METAR/ASOS · 2 mesonet · 3 hosted PWS · 4 CWOP/APRS |
| `station.position_source` | string or null | Where the coordinates came from. A roster position ('madis', 'awc') outranks one parsed from a beacon ('aprs'), which is self-reported. |
| `station.first_seen_at` | string (date-time) or null | When this station first reported to the service, in UTC. |
| `station.last_seen_at` | string (date-time) or null | When this station last reported to the service, in UTC. |
| `station.observed_at` | string (date-time) or null | When the latest reading was taken, in UTC. Null if it has none. |
| `station.age_seconds` | integer or null | How old the latest reading was when served. Null if it has none. |
| `station.raw` | string or null | The latest raw METAR or APRS packet. |
| `station.latest` | object | Latest reading, converted. Only fields this station reports are present; an absent key means it has no such sensor. |

```json
{
  "server_time": "2026-11-09T19:09:12Z",
  "station": {
    "age_seconds": 992,
    "elevation_m": 199,
    "first_seen_at": "2026-08-31T13:55:55Z",
    "last_seen_at": "2026-11-09T19:09:11Z",
    "lat": 33.2088,
    "latest": {
      "cloud": [
        {
          "base_ft_agl": 3900,
          "cover": "BKN"
        }
      ],
      "dewpoint": 55,
      "flight_category": "VFR",
      "pressure_altimeter": 30.2,
      "pressure_sea_level": 30.18,
      "relative_humidity": 65.6,
      "temperature": 66.9,
      "visibility": 10,
      "wind_direction": 170,
      "wind_speed": 3.5
    },
    "lon": -97.1992,
    "name": "Denton Muni, TX",
    "network": "ASOS/AWOS",
    "observed_at": "2026-11-09T18:53:00Z",
    "position_source": "awc",
    "raw": "METAR KDTO 091853Z AUTO 17003KT 10SM BKN039 19/13 A3020 RMK AO2 SLP221 T01940128",
    "source": "metar",
    "station_id": "metar:KDTO",
    "trust_tier": 1
  },
  "units": {
    "fields": {
      "pressure_altimeter": {
        "description": "Altimeter setting, as reported in a METAR.",
        "label": "inHg",
        "unit": "inHg"
      },
      "temperature": {
        "description": "Air temperature.",
        "label": "°F",
        "unit": "F"
      }
    },
    "source": "explicit",
    "system": "us"
  }
}
```

### Errors

| Status | Meaning |
| --- | --- |
| 422 | A parameter is missing, malformed or out of range. `detail` lists which. |
| 404 | `{"detail": "Unknown station 'metar:XXXX'"}`. |

Plus the [common errors](/docs/api/conventions/#errors) every route can return (`400 key_in_query`, `401`, `403`, `429`, `500`).

### Caching and limits

`Cache-Control: public, max-age=60`. When `units` is `auto` and your country is known from the request, the answer depends on the caller, so it is sent `private, max-age=60` with `Vary: CF-IPCountry`; pass `units` explicitly for a response a shared cache can hold. Under `/v1` the header is always `private`. There is no `ETag`, so no `304`; cache for the `max-age` and ask again after it.

## `GET /stations/{station_id}/history`

**One station's recent readings.**

**Access.** Anonymous, or an [API key](/docs/developers/api-keys/) holding `weather:read`. Also served at `/v1/stations/{station_id}/history`, where a key (or the app or website sign-in) is required. Anonymous requests share the per-address limit, and a request with a key is charged to the key. See [Rate limits](/docs/api/conventions/#rate-limits).

One station's readings over the last `hours`, oldest first.

Each sample carries `observed_at` and only the fields that reading had. A
known station with nothing in the window returns an empty list, not an
error; an id no station has is a 404.

### Parameters

| Name | In | Type | Required | Default | Bounds | Description |
| --- | --- | --- | --- | --- | --- | --- |
| `station_id` | path | string | yes | none | at most 64 characters | Source-prefixed id, e.g. metar:KMOB, cwop:EW1958, aprs:KN4OQW-9 |
| `hours` | query | integer | no | `24` | 1 to 168 | How far back to look, in hours, from 1 to 168 |
| `units` | query | "si" \| "metric" \| "us" \| "uk" \| "auto" | no | `"auto"` | none | Unit system for every measurement in the response. `si` is exactly what the model published (K, m/s, Pa, kg/m2, m). `metric` is degrees C, km/h, hPa, mm, km. `us` is degrees F, mph, inHg, in, mi. `uk` is degrees C, mm and hPa, but mph and miles. `auto` (the default) picks one from the caller's country, and a caller who cannot be placed gets `us`. The response's `units` block names the unit of every field. An `auto` response varies by caller and is sent `Cache-Control: private`; pass a system explicitly for a response a shared cache can hold |
| `limit` | query | integer | no | `500` | 1 to 2000 | Most samples to return, from 1 to 2000. When the window holds more, the newest `limit` are kept, so a `count` equal to `limit` means the start of the window was cut |

### Response

Returns object.

| Field | Type | Description |
| --- | --- | --- |
| `server_time` | string (date-time) | When the response was built, in UTC. |
| `station_id` | string | The station these readings are from. |
| `hours` | integer | The window that was asked for, in hours back from now. |
| `count` | integer | Number of samples returned. |
| `units` | object | The unit system and the unit of every field. |
| `units.system` | string | The unit system used: si \| metric \| us \| uk |
| `units.source` | string | How the system was chosen. 'explicit': you asked for it. 'geo': derived from the caller's country, so the response varies by caller. 'default'. |
| `units.country` | string or null | The country the system was derived from, when it was. |
| `units.fields` | object | The unit, display label and a one line description of every field this endpoint can return, keyed by field name. |
| `samples` | array of object | Oldest first. Each carries `observed_at` and only the fields that reading had. When the window holds more than `limit` readings, the newest are kept. |

```json
{
  "count": 2,
  "hours": 3,
  "samples": [
    {
      "cloud": [
        {
          "base_ft_agl": 4500,
          "cover": "OVC"
        }
      ],
      "dewpoint": 55.9,
      "flight_category": "VFR",
      "observed_at": "2026-11-09T16:53:00Z",
      "pressure_altimeter": 30.25,
      "pressure_sea_level": 30.24,
      "relative_humidity": 83.5,
      "temperature": 61,
      "visibility": 10,
      "wind_direction": 0,
      "wind_speed": 0
    },
    {
      "dewpoint": 57,
      "observed_at": "2026-11-09T17:53:00Z",
      "temperature": 64.4,
      "wind_direction": 170,
      "wind_speed": 2.3
    }
  ],
  "server_time": "2026-11-09T19:09:41Z",
  "station_id": "metar:KDTO",
  "units": {
    "fields": {
      "pressure_altimeter": {
        "description": "Altimeter setting, as reported in a METAR.",
        "label": "inHg",
        "unit": "inHg"
      },
      "temperature": {
        "description": "Air temperature.",
        "label": "°F",
        "unit": "F"
      }
    },
    "source": "explicit",
    "system": "us"
  }
}
```

### Errors

| Status | Meaning |
| --- | --- |
| 422 | A parameter is missing, malformed or out of range. `detail` lists which. |
| 404 | `{"detail": "Unknown station 'metar:XXXX'"}`. A known station with nothing in the window is `200` with `count: 0`. |

Plus the [common errors](/docs/api/conventions/#errors) every route can return (`400 key_in_query`, `401`, `403`, `429`, `500`).

### Caching and limits

`Cache-Control: public, max-age=60`. When `units` is `auto` and your country is known from the request, the answer depends on the caller, so it is sent `private, max-age=60` with `Vary: CF-IPCountry`; pass `units` explicitly for a response a shared cache can hold. Under `/v1` the header is always `private`. There is no `ETag`, so no `304`; cache for the `max-age` and ask again after it.
