Guidance

List recent NWS text products of one type.

Changed on

Returns the newest NWS text products of one type (for example AFD area forecast discussions or HWO hazardous weather outlooks), newest issued_at first, with the bulletin text in body. For distilled fields from the same products, use GET /v1/weather?include=guidance.

Scope

At most one of:

  • lat + lon — products from the office that serves the point, or whose area contains it.
  • wfo — products from one NWS Weather Forecast Office.

With neither, the query is national (for example SPC or WPC products, narrowed with awips_id).

Filters

  • filter — <property> <op> <value>, repeatable (all must pass): the text kind's generic filter, over the catalog text product's (nws_text_product) properties_schema properties marked filterable, with one of their filter_ops (==, !=, >, >=, <, <=, in with a comma list): product_type, wfo, awips_id, outlook_day and issued_at (RFC 3339). A filter on product_type stands in for the parameter, as does an awips_id filter (== or in): an AWIPS id's first three characters are its product type (QPFERD is a QPF), so its ids name the types read. A filter on wfo wins over a point. A read that names no type is a 400 with reason unknown_property, unknown_property product_type, the declared types as valid_values and a hint; its suggested_call is the read pinned to the catalog product's default member (members.default, with the caller's own place, office, filters and window), and alternatives names up to three further members, each with its own suggested_call (GET /v1/catalog/nws_text_product lists every member and the filter that pins it). A property or operator the catalog does not declare is a 400 with reason (unknown_property, invalid_operator), valid_values, did_you_mean and suggested_call, as on GET /v1/features.
  • awips_id — exact AWIPS identifier (e.g. AFDLOT).
  • start — RFC 3339 instant; only products issued after it.
  • limit — 1 to 10, default 1. There is no pagination.
  • omit_body — true returns metadata and properties with an empty body.

Caching

Successful responses carry Cache-Control: max-age=60, stale-while-revalidate=60, public for first-party keys and private for partner keys.

Coverage

With lat/lon, a point outside the 50 US states and DC returns 404 outside-coverage with next_steps; wfo and national queries are not filtered by point.

Auth

Standard sw-api Bearer auth applies.

get/v1/text-products

Request

  • Base URL
    https://api.smarterweather.com
  • Auth
    HTTP bearer

Query parameters

product_type, string

3-character NWS product code (e.g. AFD, HWO, NOW). Upper-cased by the server. Required unless a filter names product_type or awips_id.

filter, string[]

<property> <op> <value> over the text product's filterable properties, repeatable (all must pass), e.g. product_type == SWO and outlook_day == 2.

lat, number double

Latitude. Requires lon; mutually exclusive with wfo.

lon, number double

Longitude. Requires lat; mutually exclusive with wfo.

wfo, string

3-letter NWS Weather Forecast Office identifier. Upper-cased by the server.

awips_id, string

Exact AWIPS product identifier (4-9 letters or digits). Upper-cased by the server.

start, union
string date-time
OR
string date

RFC 3339 instant, or a date (from that local calendar day's midnight at the point; a UTC day for a national or office read). Only products issued after it are returned.

end, union
string date-time
OR
string date

RFC 3339 instant, or a date (through that local calendar day's last second at the point; a UTC day for a national or office read). Only products issued at or before it are returned.

limit, integer

Maximum products to return (1-10, default 1).

omit_body, boolean

When true, body is empty and only metadata and properties are returned.

Response

Matching products. products is an empty array when nothing matches.

TextProductsResponse required

GET /v1/text-products response. products is always an array, newest issued_at first.

products, TextProduct[] required

Example response

{
  "products": [
    {
      "product_type": "AFD",
      "wfo": "LOT",
      "awips_id": "AFDLOT",
      "wmo_header": "FXUS63 KLOT"
    }
  ]
}

Changes

    • info

      added the optional property allOf[#/components/schemas/Problem]/alternatives to the response with the status

    • info

      added the optional property alternatives to the response with the status

    • info

      added the optional property alternatives to the response with the status

    7 more changes in this revision