NAME

Tafmetar - Receive Taf/Metar from airports

DESCRIPTION

Fetch TAFs and/or METARs for airports around the world, based on ICAO ids. Forecasts are for 9 or 24 hour periods. Historical data are available for the last 20 years.

To interpret the data, you can find more information on https://www.vatsim.net/pilot-resource-centre/general-lessons/interpreting-metars-and-tafs.

To find the ICAO code for a specific airport, we suggest using one of the following resources:

USAGE

Actions

/

Default action, can deliver all data (but not fully Swagger compliant)

/info.txt

Get airport info (name, latlon etc)

/taf.FORMAT
/metar.FORMAT
/tafmetar.FORMAT

Get TAF/METAR for airport at given date. FORMAT can be either xml or txt

Parameters

icao

required parameter, ICAO id, like ENGM. Multiple values can be separated by comma

date

YYYY-MM-DD format as per ISO 8601.

Note that this is the 24 period from YYYY-MM-DDT00:00:00 to YYYY-MM-DDT23:59:59 UTC. To get the calendar date in localtime you must add the offset parameter to indicate timezone and daylight savings.

If date is not set you will get data for the last 24 hours, which is most cases is what you really want...

offset

The offset parameter is the difference from UTC, on the format "+HH:MM" or "-HH:MM" as defined in ISO 8601. This is used to calculate the period start as follows:

  <date> + "T00:00:00" + <offset>

This is then converted to UTC to get the start of the 24-hour period.

If not given, the timezone defaults to +00:00, but you should not use this for locations outside the GMT timezone, since for e.g. Hawaii you would get TAF/METARs for the period 2018-05-10T14:00 to 2018-05-11T14:00 local time, instead of 2018-05-11T00:00 to 2018-05-12T00:00.

Presently timezones for the offset parameter range from -12:00 to +14:00, although this may change in the future. For GMT, only +00:00 is allowed. You can see a list of all current timezones on https://en.wikipedia.org/wiki/List_of_UTC_time_offsets.

content_type

text/xml or text/plain. Mandatory for /

content

info, taf, metar or tafmetar. Mandatory for /

Example requests

Schema

The XML Schema is available from https://api.met.no/weatherapi/tafmetar/1.0/schema

Change log

Better date handling features: 2019-08-13

Since the previous version could only deliver data for UTC calender dates, we have added an offset parameter to enable you to get data for midnight to midnight local time. E.g. date=2019-08-13&offset=+02:00 will new get you data from 2019-08-12T22:00:00 to 2019-08-13T22:00:00 UTC.

Also, you can now drop the date parameter completely, in which case you will get data for the last 24 hours (which is usually exactly what you want).

New version 1.1: 2013-02-16

New product available, delivering Taf and metar