# Saved places

> List, add, edit and remove the places an account is watched for, with each place's text, sunrise and sunset, SPC outlook, tropical, winter impacts and lightning settings.

API reference · Reference · https://wxalerts.org/docs/api/notifications-places/

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

A saved place is a point on an account that alerts are matched against. The
guide is [Saved places](/docs/alerts/saved-places/); the channels that hear
about a place are attached with the
[contact routes](/docs/api/notifications-contacts/). Authentication, the CSRF
header, `402` upgrade bodies and the `422` format are on the
[overview](/docs/api/notifications/).

All four routes accept a session cookie or a Bearer token from the phone app,
and none is cached (`Cache-Control: no-store`).

## Place object

This is `SavedPlaceOut`, returned by every route here.

| Field | Type | Description |
| --- | --- | --- |
| `id` | integer | the place's id, used in every other route |
| `label` | string | the name the account gave it. Unique within the account |
| `lat`, `lon` | number | decimal degrees |
| `display_name` | string or null | the gazetteer's name for the spot, if one was sent |
| `sms_significances` | array of `W`, `A`, `Y`, `S` | which NWS significances this place sends by default (warning, watch, advisory, statement). A contact attached to the place inherits it unless the contact's own rule for the place says otherwise. A new place defaults to `["W"]` |
| `muted_phenomena` | array of string | VTEC phenomenon codes this place never alerts for, on any channel. Always a list, never `null`. The life-safety set cannot be muted on push |
| `sms_enabled` | boolean | whether this place sends text messages |
| `sky` | object | sunrise and sunset settings, below |
| `outlook` | object | SPC outlook settings, below |
| `tropical` | `off`, `alert` or `silent` | tropical systems threatening the place. `silent` delivers without sound |
| `winter_impacts` | `off`, `alert` or `silent` | Moderate or higher winter impacts within about 72 hours, from WPC's Winter Storm Severity Index |
| `lightning_radius_km` | integer or null | radius of the lightning feed for this place on the MQTT V2 topics, in kilometers. `null` is no lightning |
| `created_at` | string | UTC timestamp |

### `sky`

| Field | Type | Default | Description |
| --- | --- | --- | --- |
| `sunrise` | boolean | `false` | notify about sunrises |
| `sunset` | boolean | `false` | notify about sunsets |
| `min_score` | integer, 0 to 100 | `50` | the lowest score worth a notification. 50 is the bottom of Good, 75 the bottom of Great |
| `push` | boolean | `true` | send as a push notification |
| `email` | boolean | `false` | send as an email |
| `product` | `colour`, `clear` or `both` | `colour` on output | which forecast it is judged on: a colourful sky, the sun's disc visible to the horizon, or either |

### `outlook`

Off unless turned on: no `days` and every threshold `null` sends nothing.

| Field | Type | Default | Description |
| --- | --- | --- | --- |
| `days` | array of 1, 2, 3 | `[]` | categorical outlook days to be told about. At most 3 items, returned sorted and deduplicated |
| `min_level` | `TSTM`, `MRGL`, `SLGT`, `ENH`, `MDT` or `HIGH` | `SLGT` | the lowest categorical level that notifies |
| `tornado_min` | integer 1 to 100 or null | `null` | Day 1 tornado probability, in percent, that notifies |
| `hail_min` | integer 1 to 100 or null | `null` | the same for hail |
| `wind_min` | integer 1 to 100 or null | `null` | the same for wind |
| `extended_min` | integer 1 to 100 or null | `null` | Day 4 to 8 severe probability (SPC draws 15 and 30) |
| `fire_min` | `ELEV`, `CRIT`, `EXTM` or null | `null` | Day 1 and 2 fire weather level |
| `dry_thunder_min` | `IDRT`, `SDRT` or null | `null` | Day 1 and 2 dry thunderstorm level |
| `fire_extended_min` | integer 1 to 100 or null | `null` | Day 3 to 8 fire probability |
| `dry_thunder_extended_min` | integer 1 to 100 or null | `null` | Day 3 to 8 dry thunderstorm probability |
| `md` | boolean | `false` | any mesoscale discussion drawn over the place |
| `push` | boolean | `true` | send as a push notification |
| `email` | boolean | `false` | send as an email |

## `GET /notifications/places`

List the account's saved places.

Access: signed in (cookie or Bearer). No parameters.

Response `200`:

| Field | Type | Description |
| --- | --- | --- |
| `places` | array of place | oldest first |
| `max_places` | integer | the plan's cap, so a client can disable Add at the limit |
| `tier` | string | the plan key: `free`, `legacy_supporter`, `pro`, `business` or `business_50` |
| `tier_label` | string | the plan's display name |
| `sky_available` | boolean | whether sunrise and sunset notifications are offered to this account. `false` while a staff beta limits them |
| `outlook_available` | boolean | the same for SPC outlook notifications |
| `life_safety` | object | the locked life-safety set: `phenomena` (VTEC codes), `significance` (`W`), `emergencies` (`true`: any event named Emergency is included), `events` (names) and `reason` (the line a locked toggle shows) |
| `life_safety_events` | array of string | the same set as NWS event names |

```json
{
  "places": [
    {
      "id": 41,
      "label": "Home",
      "lat": 35.2087,
      "lon": -97.4414,
      "display_name": "Norman, OK",
      "sms_significances": ["W"],
      "muted_phenomena": [],
      "sms_enabled": true,
      "sky": { "sunrise": false, "sunset": true, "min_score": 60, "push": true, "email": false, "product": "colour" },
      "outlook": {
        "days": [1], "min_level": "ENH", "tornado_min": 5, "hail_min": null,
        "wind_min": null, "extended_min": null, "fire_min": null,
        "dry_thunder_min": null, "fire_extended_min": null,
        "dry_thunder_extended_min": null, "md": true, "push": true, "email": false
      },
      "tropical": "off",
      "winter_impacts": "alert",
      "lightning_radius_km": 80,
      "created_at": "2026-09-02T14:21:05.118Z"
    }
  ],
  "max_places": 5,
  "tier": "pro",
  "tier_label": "Supporter",
  "sky_available": true,
  "outlook_available": true,
  "life_safety": {
    "phenomena": ["TO", "SV", "FF", "EW", "HU", "SS", "TS", "SQ", "DS"],
    "significance": "W",
    "emergencies": true,
    "events": ["Tornado Warning", "Severe Thunderstorm Warning", "Flash Flood Warning", "Extreme Wind Warning", "Hurricane Warning", "Storm Surge Warning", "Tsunami Warning", "Snow Squall Warning", "Dust Storm Warning", "Tornado Emergency", "Flash Flood Emergency", "Civil Emergency Message", "Local Area Emergency"],
    "reason": "Life-safety warnings are always on"
  },
  "life_safety_events": ["Tornado Warning", "Severe Thunderstorm Warning"]
}
```

(`life_safety_events` is shortened in the example; it carries the whole
`events` list.)

Errors: the [sign-in errors](/docs/api/notifications/#sign-in-errors).

## `POST /notifications/places`

Save a place.

Access: signed in. Needs the CSRF header with a cookie.

Body (`SavedPlaceIn`):

| Field | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `label` | string, 1 to 80 characters | yes | | name for the place. Must not match another label on the account |
| `lat` | number, -90 to 90 | yes | | |
| `lon` | number, -180 to 180 | yes | | |
| `display_name` | string, up to 200 | no | `null` | |
| `sms_significances` | array of `W`, `A`, `Y`, `S`, or null | no | `["W"]` | `null` takes the default. An empty array is allowed and means saved but sends nothing |
| `muted_phenomena` | array of string, up to 200 items, or null | no | `null` (nothing muted) | VTEC codes, such as `TO`. Not an enum, because the NWS owns the list |
| `sms_enabled` | boolean | no | `true` | |
| `sky` | object or null | no | all off | see `sky` above. `min_score` 0 to 100 |
| `outlook` | object or null | no | all off | see `outlook` above |
| `tropical` | `off`, `alert`, `silent` or null | no | `off` | |
| `winter_impacts` | `off`, `alert`, `silent` or null | no | `off` | |
| `lightning_radius_km` | integer 1 to 322, or null | no | `null` | 322 km is 200 miles |

```json
{ "label": "Home", "lat": 35.2087, "lon": -97.4414, "sms_significances": ["W", "A"], "lightning_radius_km": 80 }
```

Response `201`: a place object. The new place has no contacts attached.

| Status | Body | When |
| --- | --- | --- |
| `400` | `{"detail": "You already have a place called 'Home'."}` | duplicate label on the account |
| `402` | place limit body, see the [overview](/docs/api/notifications/#upgrade-bodies-402) | the plan has no room for another place. `error` is `place_limit_reached` |
| `422` | standard validation list | a field out of bounds, an unknown enum value, a `muted_phenomena` list over 200 |

## `PATCH /notifications/places/{place_id}`

Edit a place.

Access: signed in. Needs the CSRF header with a cookie.

| Parameter | In | Type | Description |
| --- | --- | --- | --- |
| `place_id` | path | integer | the place's id |

The body is the same object as `POST`, and `label`, `lat` and `lon` are
**required** again. It is not a partial update: `display_name` omitted is
saved as `null`, and `sms_enabled` omitted is saved as `true`. What follows is
how each optional field behaves when it is left out.

| Field | If omitted or `null` |
| --- | --- |
| `sms_significances` | the stored list is kept |
| `muted_phenomena` | the stored list is kept. Send `[]` to clear it |
| `sky` | the stored sunrise and sunset settings are kept. When sent, the whole object replaces them, except `product`, which is kept if omitted or `null` |
| `outlook` | the stored settings are kept. When sent, `days`, `min_level`, `tornado_min`, `hail_min`, `wind_min`, `push` and `email` replace the stored values. The later fields (`extended_min`, `fire_min`, `dry_thunder_min`, `fire_extended_min`, `dry_thunder_extended_min`, `md`) change only if the request names them |
| `tropical` | the stored choice is kept |
| `winter_impacts` | the stored choice is kept |
| `lightning_radius_km` | kept if the field is left out. **Sending `null` clears it** (no lightning) |

Response `200`: the updated place object.

| Status | Body | When |
| --- | --- | --- |
| `404` | `{"detail": "No such place."}` | no such place on this account. Someone else's place gives the same answer |
| `422` | standard validation list | as for `POST` |

## `DELETE /notifications/places/{place_id}`

Forget a place, and every contact attachment on it.

Access: signed in. Needs the CSRF header with a cookie.

| Parameter | In | Type | Description |
| --- | --- | --- | --- |
| `place_id` | path | integer | the place's id |

Response `204`, no body. It is idempotent: a place that is already gone, or
that belongs to someone else, also answers `204`. The contacts themselves
stay on the account.
