Destination Weather
POST /v1/destination/weather — a daily forecast for a destination, honestly degraded.
POST /v1/destination/weather returns a multi-day forecast for a destination, resolved
server-side from an airport code, a city name, or explicit coordinates.
Airline-scoped, model-free:
X-Session-Id is optional and enables flight-aware dates. A missing or malformed
optional header is treated as sessionless, never a 400, and starts at the
provider’s first local forecast day. Only a valid bound session can change the
start date: it uses the scheduled arrival date in the destination’s time when
the flight destination matches the requested airport, never before local today.
A different airport or a city/coordinate-only request uses the date without
flight alignment. A shorter forecast is never padded, so a later arrival can
return fewer rows.
A failed flight read is logged and uses local today. If the forecast supplies no offset, the first forecast date is used. If no forecast is available, UTC today is used. The provider’s current offset is used, so a daylight-saving transition can affect an arrival within an hour of midnight. No JSON field is added, removed or retyped.
Body (max 16 KiB):
* At least one of airport, city, or the lat+lon pair is required — see the error note
below.
weatherAvailableis a required field — always present,trueorfalse, never omitted (it’s a boolean, not a nullable one, so the null-omission rule doesn’t apply here).- On honest degradation,
forecastis an empty array, not omitted. precipProbis the only optional field on a forecast day; it’s omitted when unknown.
Honest degradation
Two distinct failure modes both return 200 with weatherAvailable: false and forecast: [] —
never an error:
- The locator doesn’t resolve to a known place (an unrecognized city with no airport/coordinates to fall back on).
- The weather provider call itself fails.
Errors
This is the one endpoint on the platform where request.validation is a 400, not a 422.
Every other validation failure across this API returns 422 request.validation — see Errors &
Limits. Here specifically, sending a request with none of airport, city, or
a lat+lon pair returns 400 request.validation. Branch on the code field as always;
just don’t assume this one is a 422 by pattern-matching on the code name.
Standard envelope otherwise: 401 / 403, 500. There is no 429 — this
endpoint is model-free, so the per-client request-rate limit on AI-backed
endpoints does not apply to it, and no dedicated 500 case
exists beyond the platform-wide generic one (a provider failure degrades honestly, per above,
rather than erroring).