Hindcast Data

This endpoint can be used to retrieve hindcast output for specific times and locations. Hindcast in this context refers to the best values of previous forecast outputs.

get
Get Point Hindcast

https://api.sofarocean.com/marine-weather/v1/models/:model_id/hindcast/point
Returns hindcast data from the specified model at a single latitude and longitude point within a given timeframe. Variables and model IDs used as parameters in the endpoint can be queried from the metadata endpoints described in the Weather Object Metadata Section. The endpoint will return the output of the specified operational forecast model and variables for the given time frame (as determined by start and end parameters).
Request
Response
Request
Path Parameters
model_id
required
string
The ID of the model from which you want to retrieve hindcast data
Query Parameters
token
required
string
A valid API token
variableIDs
required
array
An array of comma separated strings containing variable IDs which you want to retrieve as part of the hindcast data. A list of valid variable IDs for any given model can be retrieved from the /weather/v1/models/:model_id endpoint.
longitude
required
number
The longitude of the requested hindcast point. Can be positive or negative.
latitude
required
number
The latitude of the requested hindcast point. Must be between -90 and 90 degrees.
start
required
string
The beginning of the requested time frame. Must be a valid ISO 8601 timestamp.
end
required
string
The end of the requested time frame. Must be a valid ISO 8601 timestamp and greater or equal to the requested start.
Response
200: OK
Hindcast successfully retrieved for the following query: https://api.sofarocean.com/marine-weather/v1/models/SofarOperationalWaveModel/hindcast/point?longitude=-152&latitude=37&variableIDs=SofarOperationalWaveModel-significantWaveHeight&start=2020-03-12T22:00:00Z&end=2020-03-12T24:00:00Z
{
"modelID": "SofarOperationalWaveModel",
"requestTime": "2020-04-29T22:40:00.000Z",
"requestStart": "2020-03-12T22:00:00.000Z",
"requestEnd": "2020-03-13T00:00:00.000Z",
"requestLocation": {
"latitude": 37,
"longitude": -152
},
"hindcastVariables": [
{
"variableID": "SofarOperationalWaveModel-significantWaveHeight",
"variableName": "significantWaveHeight",
"dataCategory": "surfaceWaves",
"physicalUnit": "m",
"values": [
{
"timestamp": "2020-03-12T22:00:00.000Z",
"value": 3.37999987602234
},
{
"timestamp": "2020-03-12T23:00:00.000Z",
"value": 3.3199999332428
}
]
}
]
}
400: Bad Request
The request parameters were invalid.
{ "message": "\"longitude\" is required" }
403: Forbidden
A valid API token was not provided or you do not have access to the weather API.
{ "message": "Invalid API token" }
404: Not Found
The model with the specified ID does not exist or the specified variables do not exist in the model.
{ "message": "Model 'not-a-real-model' does not exist" }
{ "message": "Variable 'not-a-real-variable' does not exist on model 'SofarOperationalWaveModel'" }
422: Unprocessable Entity
Used when an invalid value was provided for latitude.
{ "message": "Latitude 180 is invalid. Latitude must be between -90 and 90 degrees" }

‚Äč