sync

Get Sync Weather

Request weather data for a specific Model using the given settings (location, period, weather factors, e.g.).

This data is then formatted as the requested output format (output unit system and file format) before returning the requested data.

(Please note that as some models are predictive or otherwise restricted in the periods available for requests, that sometimes the 'begin' and 'end' values will be altered to match these restrictions.) An API function that retrieves specific weather data for a specific Weather Model and returns it as the requested output format and units.

Args: request: The original request object containing query parameters. source_id: The Source ID of the Source to request the weather data from. model_id: The Model ID for the Model to request the weather data from. cleanup_tasks: A BackgroundTasks object to hold any pending cleanup tasks for when the data request is finished. ret_args: A WeatherContentRequestQuery object holding the parameters for the weather data request to use. fmt_args: A WeatherFormattingRequestQuery object holding the parameters for the output format and units to use. accept: Header type to use for the output file. Rounded to the most likely value using header_accept_type().

Returns: The weather data in the requested format for the requested parameters.

get/weather/sources/{source_id}/models/{model_id}

Path parameters

source_idstring required
model_idstring required

Query parameters

beginstring

From date and time

From date and time

endstring

To date and time

To date and time

latnumber required

GPS Latitude or RD x-coordinate

GPS Latitude or RD x-coordinate

lonnumber required

GPS Longitude or RD y-coordinate

GPS Longitude or RD y-coordinate

factorsstring[]

Only return these weather factors (default: all factors)

Only return these weather factors (default: all factors)

units'si' | 'human' | 'original'

Enumeration of valid output unit sets for weather data.

Unit of weather factors

response_format'netcdf4' | 'netcdf3' | 'json' | 'json_dataset' | 'csv'

Enumeration of valid output file-formats for weather data responses.

Response format (overrides mime-types from Accept HTTP header)

Headers

acceptstring

Response

Successful response with the requested weather data.

string required

Changes