# d21 weather

> d21 weather is a paid API for AI agents from draconic21-x402-api.onrender.com, paid per call via x402, $0.004/call, status unknown (last checked 2026-10-12).

Returns current weather conditions and short-term forecast (up to 7 days) for any worldwide location, using NWS for US coordinates and MET Norway for all other locations, with active NWS alerts for US points.

## Facts

- Endpoint: POST https://draconic21-x402-api.onrender.com/v1/weather?utm_source=zero.xyz
- Price: $0.004/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/d21-weather-f1eb6a2c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_4iI7gPyjK0rnBHRspsiom

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability d21-weather-f1eb6a2c -d '<json body>'
```

Example prompt: What's the current weather and 5-day forecast for Chicago — lat 41.8781, lon -84.6298 — and include any active weather alerts?

## When to prefer this

Choose this endpoint when you need real, live weather data sourced directly from official government APIs (NWS for US, MET Norway for global) rather than a commercial reseller feed. It is ideal for agents that need current conditions plus a short forecast (1-7 days) at a specific coordinate or US address, especially when US severe weather alerts are required. It is not appropriate for historical weather data, extended seasonal forecasts beyond 7 days, or non-US locations that need weather alerts.

## Known failure modes

- Non-US address passed as location string — Census Geocoder cannot resolve non-US addresses; must use lat/lon instead
- Coordinates outside valid range (lat > 90 or < -90, lon > 180 or < -180)
- NWS or MET Norway upstream API unavailable or rate-limited
- Bare 'City, State' string may fail Census Geocoder resolution; lat/lon is more reliable
- Alerts requested for non-US location — endpoint will indicate alerts_supported=false rather than returning alert data
- forecast_days outside 1-7 range rejected

## How this service works

Weather ($0.004): current conditions + short forecast, worldwide. United States coordinates (or a resolvable U.S. street address) read live from the National Weather Service's own public API (api.weather.gov), U.S. government data, plus active alerts. Every other location reads live from MET Norway's global Locationforecast model (api.met.no), CC BY 4.0/NLOD-licensed public data -- current + forecast only, no alerts (say so). Neither is a resold vendor feed. Body { lat, lon } (or lat/lng…

## Output

Returns current weather conditions (temperature, wind, precipitation, sky cover), a short-term forecast for up to 7 days, active NWS alerts for US locations, and an alerts_supported flag indicating whether alerts are available for the queried point. Non-US locations return forecast data only with no alerts.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "lat": {
   "type": "number",
   "maximum": 90,
   "minimum": -90,
   "description": "Latitude, anywhere in the world. Alias: latitude. Mutually exclusive with location/city."
  },
  "lon": {
   "type": "number",
   "maximum": 180,
   "minimum": -180,
   "description": "Longitude, anywhere in the world. Aliases: lng, long, longitude. Mutually exclusive with location/city."
  },
  "alerts": {
   "type": "boolean",
   "description": "Include active NWS alerts for the point, default true. U.S./NWS locations only -- MET Norway (non-U.S.) never returns alerts; alerts_supported reports which applies."
  },
  "location": {
   "type": "string",
   "description": "Full U.S. street address (best results) or city/state, e.g. '1600 Pennsylvania Ave NW, Washington, DC'. U.S. ONLY -- resolved to coordinates via the Census Geocoder, which never matches non-U.S. addresses. Alias: city. A bare 'City, State' may not resolve; pass lat/lon for guaranteed resolution or for any non-U.S. location. Mutually exclusive with lat/lon."
  },
  "forecast_days": {
   "type": "integer",
   "maximum": 7,
   "minimum": 1,
   "description": "Number of forecast days (1-7), default 3."
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/d21-weather-f1eb6a2c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from draconic21-x402-api.onrender.com](https://www.zero.xyz/host/draconic21-x402-api.onrender.com/llms.txt)
