Repository navigation
Releases
Releases · Ourea-Technologies/ensemble-weather-swift
v0.1.0
The first release: SwiftPM by URL, from the v0.1.0 tag. Targets the v1
contract at ensemble-weather-spec 7954268 (the server's public spec at
256cd770, byte for byte); all 58 shared vectors pass.
The client
Clientfor every v1 operation exceptgetMapsToken: location and
point forecasts, current conditions, alerts, nearby locations, search,
explore, composition, the season, the snow trend, the snowpack (beta),
location lists, the location and station catalog (pages and lazy
PageSequences), model runs, the GeoJSON alert outlines and avalanche
zones, and attribution.- The coordinate methods are
getPointForecast,getPointCurrent,
getPointAlertsandgetPointNearby; the named-location methods are
forecast(for:),currentConditions(for:),alerts(for:)and
nearbyLocations(to:). ProbabilityQuery(prob=) andWindowTotalQuery(totals=), with
exact threshold unit conversion and the server's rounding; answers are
matched to the caller's terms by the canonicaltermthe server echoes,
never by position.- Canonical URLs (comma lists sorted, de-duplicated and sent with literal
commas), keyless open routes, same-host redirects (the key is dropped
across hosts), retries withRetry-Afteror full jitter, an in-memory
ETagcache, deprecation notices and typedOureaErrors withcode,
docURL,parameter,nearestLocationandrequestID. - Hand-written
Sendable,Codable,Hashablemodels for every schema the
operations reach; unknown enum values keep their raw string.
Added since the v1 contract of 2026-10-27
explorePage(_:...)andexplore(_:...): places ranked by an
ExploreMetric(.snow5Days,.baseDepth,.seasonPrecip, ...), with
order(RankOrder),type,state,near(Coordinate),
radiusKilometers, elevation bounds,points(ExplorePoints) and
cursor paging.season(for:),snowTrend(for:)(Plus or Pro),snowpack(for:)and
snowpackPlume(for:)(beta),composition()(an open route, sent without
the key), and the GeoJSON routesalertOutlines(classes:boundingBox:)
andavalancheZones().searchLocationstakessort,order,near,radiusKilometersand
units; a hit carriesexplorewith a metric sort.ForecastOptions.members(MemberSelection:.excluded,.rowsor
.plume) replacesincludesMembers; the plume view is in
ForecastData.plume(MemberPlume), andMembersView.poolis new.nearandbboxare typed (Coordinate,BoundingBox), sent with the
shortest decimals and literal commas; an out-of-range value, or a box with
west > east or south > north, is a usage error.ErrorCode.plusRequired(PLUS_REQUIRED), a permission error.- New fields:
ForecastResponse.locationis aForecastLocation(adds
elevationandelevations),.snowOnGroundand.avalanche;
snowLevelWetBulbonEnsembleStats,ModelMean,MemberForecastand
DailyForecast;TimeSeriesPoint.isMeasured,.snowCharacter,
.membersSpread,.members6Hours,.precipitationByType;
DailyForecast.coveredFrom,.measuredPrecipitation,.snowCharacter,
.snowToLiquidRatio,.snowLevelRange,.snowLevelWetBulbRange,
.normal,.departure,.percentile;ForecastDataand
ElevationForecast.precipitationOutlookand.plume;
ElevationForecast.displayName,.snowOnGround,.nearestSensors;
SnowOutlook.next72Hours;WindowTotal.method;
CurrentConditions.isMeasuredand.cloudCover;
ConditionsStation.isCalm;CurrentConditionsResponse.summary
(PlaceSummary) and.pass(PassForecast);
SensorObservation.distanceKilometersand.elevationDifference; ten
NWS fields onActiveAlert(sent,messageType,description,
instruction, ...);PrecipDisplay.snowAmount;
ModelEntry.displayMembers;SearchHit.explore;
CatalogElevation.displayName;CatalogStationDetail.isIndexable.
LocationSummary.elevationsandNearbyLocation.elevationsare
ElevationSummary(addsdisplayName);MembersCumulativeholds
MemberQuantiles. - Enum values:
light_snowandheavy_snowconditions and icons (and their
night icons),AttributionSourceKind.avalancheForecast; new enums
SnowCharacter,AlertClass,PassStatusLevelandExploreMetric. - The
SnowReportandMapsexamples; a field-level spec-drift test (every field of
every schema has a coding key).
Changed
-
JSON fields that repeat a word of their own type have SDK names
(BEHAVIOR.md 3.0, one table for every Ourea SDK), mapped by each model's
CodingKeys:ForecastResponse.forecastisseriesand.elevationForecastsis
elevations.CurrentConditionsResponse.currentisnow.ProbabilityResult.probabilityisvalue.- The list responses' rows are
itemsand their countscount
(alerts,alertCount,locations,runs; nearby'slocationis
origin, and both nearby routes useitems). WindowTotal.windowStartHours/windowEndHoursare
startHours/endHours.CurrentConditions.condition,.conditionTextand.conditionIcon
arecode,textandicon.- An elevation's
elevationisheight. - The rest of the table is in the README's "Names that differ from the
API's JSON".
GeoJSON bodies are not renamed: a feature's
propertiesis a
[String: JSONValue]with the API's own keys. -
No name stutters (BEHAVIOR.md 3.0):
EnsembleWeatherClientisClient,
EnsembleWeatherErrorisOureaError,EnsembleWeatherVersionis
SDKVersion(itssdkiscurrent) andWeatherConditionis
Condition.
Removed
stormReports(limit:),stormReport(id:)and their models, the catalog's
ads, and the fields, diagnostics and error codes the server withdrew
before the v1 contract.