GetFeature-Request fetches data. A basic
GetFeature-Request according to the WFS 1.0.0 standard is constructed as follows:
The two optional standard WFS arguments
MAXFEATURES limit the amount of features that will appear in the XML file. If a bounding box (
BBOX) is specified, the XML response will contain only features located within the specified area. The
MAXFEATURES parameter caps the amount of delivered features to the specified number. Their use (especially of the bounding box) is recommended as some feature lists are rather expansive, and therefore the GetFeature response will be a large XML file.
|A bounding box specified by maximal and minimal latitude and longitude formatted according to
BBOX=<min_lon,min_lat,max_lon,max_lat> (please note the order). The response will only contain features that are located within this area. If left unspecified, all available features will be returned.
|An unsigned integer specifying the maximal amount of features contained in the XML response, where it is not specified which features are to be omitted. Unbounded if left unspecified.
|A single point in time (UTC) as specified in the section Date/Time Description.
TIME always refers to validdatetime. The response depends on the feature type, see the examples below.
The main WFS feature types, lightnings, several weather station types and tropical cyclone tracks are described in more detail below.
With the feature type
lightnings you can query the lightning strikes during the 5 minute period ending with the specified
TIME, for which we use the current time if not specified. The XML response contains additional information in the form of the currents and strike time.
The following example request will return the locations as well as strike times and currents of the lightning strikes during the last 5 minutes over Switzerland:
Larger intervals can be queried through the API, see here.
Currently there are two available station feature types:
stations_mix-obs, which contains most of our combined observational data, and
stations_mm-mos for our MOS forecast.
In order to fetch data from these weather stations, you'll need to use our custom parameter
|The parameters that you wish to query formatted as a comma-separated list as specified here. The DescribeFeatureType contains all the relevant parameters provided by the station type. For technical reasons the name of the XML node will have the colons (
:) replaced with an underscore (
t_2m:C will end up as
t_2m_C. For WFS purposes only you may also use this format in the queries.
Together with the parameters already mentioned above, this allows to query station data for the purposes listed in the following table:
TIME on the response
stations_mix-obs for observational data,
stations_mm-mos for MOS forecast.
|Returns the entire list of stations if unspecified, otherwise only stations that have data available at that time.
TYPENAME as above,
PARAMETERS from the list of possible parameters provided by the stations (c.f. the DescribeFeatureType response).
|Time stamp of the queried data. If not supplied, we use the current time minus one hour and floor that to the last full hour, meaning that the data is 1-2 hours old.
Please be aware that not all weather stations can provide all the parameters that are advertised by the DescribeFeatureType XML. Unavailable parameters will have no node in the XML response and GIS software usually leaves the corresponding space in the attribute table empty or indicates the absence by something like
It is also possible filtering observation data by importance of the location using the optional parameter
|To all WFS queries, you can append a
level_of_detail filter that will get either all station data in cities or capitals in a bounding box.
The following example gives you all the stations that provided a value for the given bounding box:
Tropical Cyclone Track
With the feature type
tropical_cyclone__<name> you can display the ensemble members of the forecasted track for tropical cyclones. The names of the currently active tropical cyclones can be found via
GetCapabilities request. The XML response contains currently available tropcial cyclone names.
Tropical cyclone names XML response:
Insert the name from the XML response into the (
The link above leads to the output of tropical cyclone track data sorted after each member.
Tropical cyclone track information:
The following example image originated from the forecasted ensemble tracks of Typhoon Maysak at the end of August 2020.
Typhoon Maysak displayed in QGIS: