Weather.gov · Schema

UnitOfMeasure

A string denoting a unit of measure, expressed in the format "{unit}" or "{namespace}:{unit}". Units with the namespace "wmo" or "wmoUnit" are defined in the World Meteorological Organization Codes Registry at http://codes.wmo.int/common/unit and should be canonically resolvable to http://codes.wmo.int/common/unit/{unit}. Units with the namespace "nwsUnit" are currently custom and do not align to any standard. Units with no namespace or the namespace "uc" are compliant with the Unified Code for Units of Measure syntax defined at https://unitsofmeasure.org/. This also aligns with recent versions of the Geographic Markup Language (GML) standard, the IWXXM standard, and OGC Observations and Measurements v2.0 (ISO/DIS 19156). Namespaced units are considered deprecated. We will be aligning API to use the same standards as GML/IWXXM in the future.

WeatherGovernmentUnited StatesForecastingAlertsOpen Data
View JSON Schema on GitHub

JSON Schema

weather-gov-unit-of-measure-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/weather-gov/refs/heads/main/json-schema/weather-gov-unit-of-measure-schema.json",
  "title": "UnitOfMeasure",
  "description": "A string denoting a unit of measure, expressed in the format \"{unit}\" or \"{namespace}:{unit}\".\nUnits with the namespace \"wmo\" or \"wmoUnit\" are defined in the World Meteorological Organization Codes Registry at http://codes.wmo.int/common/unit and should be canonically resolvable to http://codes.wmo.int/common/unit/{unit}.\nUnits with the namespace \"nwsUnit\" are currently custom and do not align to any standard.\nUnits with no namespace or the namespace \"uc\" are compliant with the Unified Code for Units of Measure syntax defined at https://unitsofmeasure.org/. This also aligns with recent versions of the Geographic Markup Language (GML) standard, the IWXXM standard, and OGC Observations and Measurements v2.0 (ISO/DIS 19156).\nNamespaced units are considered deprecated. We will be aligning API to use the same standards as GML/IWXXM in the future.\n",
  "type": "string",
  "pattern": "^((wmo|uc|wmoUnit|nwsUnit):)?.*$"
}