Get Latest Initial Time |
Get Available Time range |
Get Colormap |
Find Station
Get Latest Initial Time
You can find out when the data was computed (which model run the data originated from) using this query:
https://api.meteomatics.com/get_init_date?model=<model>&valid_date=<validdatetime>¶meters=<parameter_list>
https://api.meteomatics.com/get_init_date?model=ecmwf-ifs&valid_date=__replace__0T19:00:00ZP1D:PT6H¶meters=t_2m:C,relative_humidity_2m:p
Reply:
validdate;initdate_t_2m:sql;initdate_relative_humidity_2m:sql
2017-06-22T19:00:00Z;2017-06-21T12:00:00Z;2017-06-21T12:00:00Z
2017-06-23T01:00:00Z;2017-06-21T12:00:00Z;2017-06-21T12:00:00Z
2017-06-23T07:00:00Z;2017-06-21T12:00:00Z;2017-06-21T12:00:00Z
2017-06-23T13:00:00Z;2017-06-21T12:00:00Z;2017-06-21T12:00:00Z
2017-06-23T19:00:00Z;2017-06-21T12:00:00Z;2017-06-21T12:00:00Z
If a value of a certain time step can not be assigned to an init date, the init date is represented as
00-00-00T00:00:00Z
.
Get Available Time Range
The valid dates that are available within the API can be queried with using:
https://api.meteomatics.com/get_time_range?model=<model>¶meters=<parameter_list>
Example:
https://api.meteomatics.com/get_time_range?model=ecmwf-ifs¶meters=global_rad:W,t_2m:C
Response:
parameter;min_date;max_date
global_rad:W;2013-12-30T00:00:00Z;2017-07-01T12:00:00Z
t_2m:C;2013-12-30T00:00:00Z;2017-07-01T12:00:00Z
Get Color Maps
The colormaps described
here can be queried by using:
https://api.meteomatics.com/get_colormap?paramter=<parameter>&style=<style>&format=<format>
The parameters of a get_colormap request a as follows:
Option |
Description |
Example |
<parameter> |
A weather parameter. Please refer to Available Parameters for a sorted list of valid parameters. |
fresh_snow:cm |
<style> |
The colormap you want to get the numerical values for. The list of available colormaps is here. If style= is omitted from a get_colormap request, then a default value for <style> is provided depending on the requested parameter. |
jet_segmented |
<format> |
The output data format. CSV is the only available output format. |
csv |
Example of a get_colormap request with all the three parameters explicitly defined:
https://api.meteomatics.com/get_colormap?parameter=fresh_snow:cm&style=jet_segmented&format=csv
Example of a get_colormap request with only two parameters explicitly defined. In this case,
<style>
is automatically set to
jet
:
https://api.meteomatics.com/get_colormap?parameter=fresh_snow:cm&format=csv
Example of generated csv file:
Value;Hex Color
160;#870000FF
156;#9B0F14FF
152;#AC1E32FF
...
12;#1928B9FF
8;#0519A0FF
4;#000A6EFF
Find Station
You can get a list of available weather stations, such that you can decide which one you are interested in:
https://api.meteomatics.com/find_station?<list of conditions>
You will get a sorted list of stations matching your conditions.
Available conditions:
Identifier |
Description |
Example |
location |
Coordinates: location=<lat>,<lon> , or bounding box location=<lat_max>,<lon_min>_<lat_min>,<lon_max> |
location=47.3,9.3 , location=47.3,9.3_40,10 , location=germany |
elevation |
in meters ASL: elevation=<elevation> |
elevation=2500 |
parameters |
parameters=<comma separated parameter list> |
parameters=t_2m:C,wind_speed_10m:ms |
startdate |
the earliest time you are interested in: startdate=<iso timestamp> |
startdate=2017-10-01T00Z |
enddate |
the latest time you are interested in: enddate=<iso timestamp> |
enddate=2017-11-01T00Z |
Example:
https://api.meteomatics.com/find_station?location=47.3,9.3&elevation=2500
Response:
Station Category;Station Type;ID Hash;WMO ID;Alternative IDs;Name;Location Lat,Lon;Elevation;Start Date;End Date
SYNOP;SYNA;1723840649;066800;;Säntis;47.25,9.35;2500m;2017-01-01T00:00:00Z;2017-11-23T07:00:00Z
SYNOP;SYNO;625541767;066860;;Vorab-Talstation;46.88,9.18;2566m;2017-01-01T00:00:00Z;2017-11-23T07:00:00Z
SYNOP;SYNO;1550441974;067850;;Crap Sogn Gion;46.83,9.22;2226m;2017-01-01T00:00:00Z;2017-11-23T07:00:00Z
SYNOP;SYNO;2311361043;067800;;Weissfluhjoch;46.83,9.82;2667m;2017-01-01T00:00:00Z;2017-11-23T07:00:00Z
...