Timeseries¶
By Latest Forecast¶
Provides timeseries data for all variables of a model’s latest forecast.
GET /models/{model-name}/latest-forecast/timeseries/{latitude}/{longitude}
Request Example¶
See Headers for request header details.
$ curl -X GET http://model.api.wdtinc.com/models/weatherops-global/latest-forecast/timeseries/35.0/-97.0
Response Example¶
See Status Codes for response code details.
HTTP/1.1 200 OK
{
"forecast": "/forecasts/233a3aac-45fc-427e-ab93-9fb67d528a77",
"variables": {
"1hr-wind-speed": {
"series": [
{
"validTime": "2017-12-19T00:00:00Z",
"value": 16.2
},
{
"validTime": "2017-12-19T01:00:00Z",
"value": 17.4
},
{
"validTime": "2017-12-19T02:00:00Z",
"value": 18.0
},
...
],
"mean": 17.2,
"median": 17.4,
"mode": 16.2,
"unit": {
"description": "nautical miles per hour",
"label": "kts"
}
},
...
}
}
By Variable¶
Provides a timeseries for a forecast by variable name for a specific location. The location is expressed as a latitude/longitude pair. The response includes basic statistics (mean, median, and mode) over the series.
GET /forecasts/{forecast-id}/variables/{variable-name}/timeseries/{latitude}/{longitude}
Optional Parameters¶
The default response contains all available valid times for the forecast variable.
Name | Type | Description | Accepted Values / Range | Example |
---|---|---|---|---|
start | string | UTC start time (ISO8601) | any valid timestamp | 2017-12-19T00:00:00Z |
end | string | UTC end time (ISO8601) | any valid timestamp | 2017-12-19T06:00:00Z |
limit | number | max number of results | any positive integer | 10 |
Request Example¶
See Headers for request header details.
$ curl -X GET http://model.api.wdtinc.com/forecasts/6b62039c-b4ee-45d4-b56a-ff1c211b5cec/variables/1hr-wind-speed/timeseries/35.482/-97.535
Response Example¶
See Status Codes for response code details.
HTTP/1.1 200 OK
{
"series": [
{
"validTime": "2017-12-19T00:00:00Z",
"value": 16.2
},
{
"validTime": "2017-12-19T03:00:00Z",
"value": 17.4
},
{
"validTime": "2017-12-19T06:00:00Z",
"value": 18.0
}
],
"mean": 17.2,
"median": 17.4,
"mode": 16.2,
"unit": {
"description": "nautical miles per hour",
"label": "kts"
}
}