Media Observations API icon

Media Observations API

(0 reviews)
The Observations API provides information on observed weather data for weather stations throughout Australia.

home

1 Weather Station Data - Current Conditions

These calls are used to get observation data from a weather station. Currently only observations from official Bureau of Meteorology weather stations are available through the service. Only 3 days’ worth of observation data is kept in the service. To get data going further back use Daily Summaries.

There are two basic ways to access the weather data by state or by station. It is intended that most requests will be by station.

Observation data includes time stamps when the observations were taken. These time stamps are in the local time of the observation station and include a time zone offset.

1.1 By State:

Description: This call gets an array of the observational data for either all weather stations in a single state or territory, or if state is a comma separated list, a group of states or territories.

See Additional Parameters below for additional filtering options.

API Call:

GET /countries/{countryCode}/observations/weatherStations?states=[stateCodes]&product=conditions

Parameters:

ParameterExampleDescription
countryCodeauThis is the short code of the country that the weather information relates to.

Available codes are:

au – Australia.

This parameter is Mandatory.
statesnswThe ISO 3166-2 codes for states or territories.

Supported codes are:

• nsw
• qld
• sa
• tas
• vic
• wa
• act
• nt

States can be a comma separated list of codes. A maximum of four states can be supplied.

This parameter is Mandatory for state filters
productconditionsObservation product to return.

Supported products are:

• conditions
• dailySummary

This parameter is Optional. The default behavior is to display the current conditions or product=conditions

Example:

This example would return all the current observations for all weather stations within New South Wales.

GET /countries/au/observations/weatherStations?states=nsw&product=conditions

API Response:

See By Weather Station below for an example of a station observation.

1.2 By Weather Station:

Description: This call gets the observational data for a single weather station. By default the current observations are returned.

See Additional Parameters below for additional filtering options.

API Call:

GET /countries/{countryCode}/observations/weatherStations/{stationID}/conditions?states=[stateCode]

Parameters:

ParameterExampleDescription
countryCodeauThis is the short code of the country that the weather information relates to.

Available codes are:

au – Australia.

This parameter is Mandatory.
stationID94599This is the unique ID of the weather station.

This parameter is Mandatory.
statesnswThe ISO 3166-2 codes for states or territories covered by the station to filter by.

Supported codes are:

• nsw
• qld
• sa
• tas
• vic
• wa
• act
• nt

States can be a comma separated list of codes.

This parameter is Optional.

Example:

This example shows a request to get the current observations for station Cape Byron.

GET /countries/au/observations/weatherStations/94599/conditions

API Response:

{
    "results":[
        {
            "generationTime":"2017-03-08T19:11:01+10:00",
            "startTime":"2017-03-08T19:10:00+10:00",
            "key":"94599",
            "bom_id":"058216",
            "city":"Cape Byron Aws",
            "country":"Australia",
            "continent":"Australasia",
            "state":"New South Wales",
            "latitude":-28.6399,
            "longitude":153.6358,
            "elevation":95.00,
            "values":{
                "obs_feelsLikeTempC":13.8,
                "obs_delta_t":0.7,
                "obs_tempC":17.1,
                "obs_dewPointC":16.0,
                "obs_pres":1011.8,
                "obs_qnh_pres":1011.8,
                "obs_relativeHumidityPct":93,
                "obs_wind_dir":"SW",
                "obs_wind_dir_deg":233,
                "obs_windSpeedKm":2,
                "obs_wind_spd":15,
                "obs_precipSince9amMM":4.2,
                "obs_rainfall_24hr":0.0,
                "obs_maxTempC":17.2,
                "obs_maxTempLocalTime":"6:10 am",
                "obs_minTempC":17.0,
                "obs_minTempLocalTime":"6:09 am",
                "obs_maximum_gust_spd":27,
                "obs_maximum_gust_kmh":50,
                "obs_maximum_gust_dir":"S"
            },
            "endTime":"2017-03-09T01:10:00+10:00",
            "plainValidity":"Wed"
        }
    ]
}

Data fields:

Field NameData TypeUnitsDescription
generationTimestringYYYY-MM-DDThh:mm:ssThe time at which this weather dataset was generated, in local time.
startTimestringYYYY-MM-DDThh:mm:ssStart time of validity, in local time.
keystringnnnnnThe unique WMO ID of the station.
bom_idstringnnnnnnThe BOM ID of the weather station.
citystringtextThe weather station the observations relate to.
statestringtextThe state the station is located in.
countrystringtextThe country the station is located in.
continentstringtextThe continent the station is located in.
latitudenumberDegrees (decimal)Geolocation details of the station.
longitudenumberDegrees (decimal)Geolocation details of the station.
elevationnumbermetresGeolocation details of the station.
valuesobjectn/aDetails of the daily observations.
obs_feelsLikeTempCnumberCelsiusApparent Temperature (comfort level).
obs_delta_tnumberCelsiusWet Bulb Depression (Air Temperature - Wet Bulb Temperature).
obs_tempCnumberCelsiusAmbient air temperature.
obs_dewPointCnumberCelsiusTemperature to which air must be cooled for dew to form.
obs_presnumberhectopascalsAtmospheric pressure reduced to mean sea level.
obs_qnh_presnumberhectopascalsQNH pressure based on the conditions specified by the International Standard Atmosphere.
obs_relativeHumidityPctnumberPercentRelative humidity.
obs_wind_dirstringCompass points (16)Wind Direction, relative to True North, from which the wind is blowing.
obs_wind_dir_degnumberDegrees TrueWind Direction, relative to True North, from which the wind is blowing.
obs_wind_spdnumberknotsThe wind speed (mean over last 10 min).
obs_windSpeedKmnumberkilometres per hourThe wind speed (mean over last 10 min).
obs_wind_gust_spdnumberknotsThe wind gust (mean over last 10 min).
obs_wind_gust_kmhnumberkilometres per hourThe wind gust (mean over last 10 min).
obs_rain_hournumbermillimetresPrecipitation observed over last 1 hour.
obs_rain_tennumbermillimetresPrecipitation observed over last 10 min.
obs_precipSince9amMMnumbermillimetresPrecipitation since 9 am.
obs_rainfall_24hrnumbermillimetresPrecipitation (rainfall) in the 24 hours to 9am.
obs_cloudstringtextDescription of cloud cover amount.
obs_cloud_oktasnumberoktasCloud cover amount in oktas (number of eighths).
obs_cloud_type_idnumbernnObserved cloud type (manual observations only).
obs_vis_kmnumberkilometresHorizontal visibility.
obs_weatherstringtextCurrent weather type (manual observations only).
obs_maxTempCnumberCelsiusThe Daytime high temperature, from 6 am to 9 pm.
obs_maxTempLocalTimestringh:mm am/pmThe local time the maximum temperature was reported.
obs_minTempCnumberCelsiusThe Overnight low temperature from 6 pm through to 9 am.
obs_minTempLocalTimestringh:mm am/pmThe local time the minimum temperature was reported.
obs_maximum_gust_spdnumberknotsWind gust speed at time of highest wind gust.
obs_maximum_gust_kmhnumberkilometres per hourWind gust speed at time of highest wind gust.
obs_maximum_gust_dirstringCompass points (16)Wind gust direction at time of highest wind gust.
obs_sea_heightnumbermetresHeight of sea (wind) waves (manual coastal observations only).
obs_swell_heightnumbermetresHeight of swell waves (manual coastal observations only).
obs_swell_periodnumbersecondsPeriod of swell waves (manual coastal observations only).
obs_swell_dirnumberCompass points (16)Direction from which swell moves (manual coastal observations only).
endTimestringYYYY-MM-DDThh:mm:ssEnd time of validity, in local time.
plainValiditystringdddLocal day validity of data.

Observed data fields are as provided by the Bureau of Meteorology. Not all data fields are available for all locations, or for all times. From time to time additional data fields may be added or removed.

For additional information on observed data fields, see: http://reg.bom.gov.au/catalogue/Observations-XML.pdf

1.3 By Weather Stations:

Description: This call gets the observational data for a group of weather stations. By default, the current observations are returned.

See Additional Parameters below for additional filtering options.

API Call:

GET /countries/{countryCode}/observations/weatherStations?stations=[stationID]&product=conditions

Parameters:

ParameterExampleDescription
countryCodeauThis is the short code of the country that the weather information relates to.

Available codes are:

au – Australia.

This parameter is Mandatory.
stations066196, 066037This is the unique ID of the weather stations as a comma separated list.

A maximum of five stations can be supplied.

This parameter is Mandatory for station filters.
productconditionsObservation product to return.

Supported products are:

• conditions
• dailySummary

This parameter is Optional. The default behavior is to display the current conditions or product=conditions

Example:

This example shows a request to get the current observations for Sydney Harbor and Sydney Airport.

GET /countries/au/observations/weatherStations?stations=066196,066037&product=conditions

Additional Parameters

Both the state and station calls can optionally have the results filtered by the use of additional parameters. The additional parameters also allow access to previous results.

ParameterExampleDescription
endDate2017-03-01T13:00:00+10:00The endDate parameter is used to specify the end date time for a time period of time. It is used in conjunction with period. Dates are specified in ISO 8601 format; the local time zone of the observation station is represented by a time offset.

For example, endDate=2017-03-01T13:00:00+10:00&period=12H

This would return observation data from 1st March 2017 01:00:00 QLD to 1st March 2017 13:00:00 QLDThe default behavior is to set the endDate to the time of the request being received. End date can be a maximum of 10days before the current date.

Note: Because URLs treat the plus character as if it was a space, you will need to URL encode at least that character for this parameter for it to work correctly on positive offset timezones.

For example, endDate=2017-03-01T13:00:00%2b10:00=12H
period12HThe period parameter represents the length of time going backwards from the endDate or if no endDate is specified from the current time. Period can be specified in days (D) or hours (H). For example, 24H or 1D both specify a 24-hour period of time.

There are two special cases today and current.

When period=today is used the results are limited to the current day i.e. the current 24-hour period in the local time of the observation station. For example, if it is 13:00 then all the results are return for 00:00 to 13:00.

When period=current is used the results are limited to the last set of observations for the station(s).

The maximum period that can be set is 2 days. The default behavior is period=current.

When retrieving observations by multiple states then period is set to current.

2 Daily Summaries

This call is used to get summaries of the previous day’s observations for a station or stations.

2.1 By Weather Stations:

Description: This call gets the daily summaries for a group of weather stations. By default, the previous day’s summaries are returned.

API Call:

GET /countries/{countryCode}/observations/weatherStations?stations=[stationID]&product=dailySummary&period={period}

Parameters:

ParameterExampleDescription
countryCodeauThis is the short code of the country that the weather information relates to.

Available codes are:

au – Australia.

This parameter is Mandatory.
stations066196,066037This is the unique ID of the weather stations as a comma separated list.

This parameter is Mandatory for station filters.
productdailySummaryObservation product to return. Supported products are:

• conditions
• dailySummary

This parameter is Mandatory with a value of dailySummary in order to get daily summary data. product=dailySummary
period10DThe period parameter represents the length of time going backwards from the current date.

In this context period is only specified in days (D).

This parameter is Optional. The default behavior is display the previous day’s summary or period=1D. The maximum period is 10 days (10D).

Example:

This example shows a request to get the daily summaries for Sydney Harbour and Sydney Airport for the past 10 days excluding today.

GET /countries/au/observations/weatherStations?stations=066196,066037&product=dailySummary&period=10D

API Response:

Refer to By Weather Station response.

2.2 By Weather Station:

Description: This call gets the daily summary for a single weather station. By default the previous day’s summary is returned.

API Call:

GET /countries/{countryCode}/observations/weatherStations/{stationID}/dailySummary?period={period}

Parameters:

ParameterExampleRequiredDescription
countryCodeauThis is the short code of the country that the weather information relates to.

Available codes are:

au – Australia.

This parameter is Mandatory.
stationID94599This is the unique ID of the weather station.

This parameter is Mandatory.
period10DThe period parameter represents the length of time going

backwards from the current date. In this context period is only specified in days (D).This parameter is Optional. The default behavior is display the previous day’s summary or period=1D. The maximum period is 10 days (10D).|

Example:

This example shows a request to get the daily summary for station Cape Byron.

GET /countries/au/observations/weatherStations/94599/dailySummary

API Response:

{
    "results":[
        {
            "dateAt":"2017-03-08",
            "key":"94599",
            "name":"Cape Byron Aws",
            "state":"New South Wales",
            "values":{
                "obs_rainfall_24hr":0.0,
                "obs_maxTempC":17.2,
                "obs_maxTempLocalTime":"6:10 am",
                "obs_minTempC":17.0,
                "obs_minTempLocalTime":"13:09 am",
                "obs_maximum_gust_spd":27,
                "obs_maximum_gust_kmh":50,
                "obs_maximum_gust_dir":"S"
            }
        }
    ]
}

Data fields:

Field NameData TypeUnitsDescription
dateAtstringYYYY-MM-DDThe date the summary is valid for.
keystringnnnnnThe unique WMO ID of the station.
namestringtextThe name of the station.
statestringtextThe state the station is located in.
valuesobjectn/aDetails of the daily observations.
obs_rainfall_24hrnumbermillimetresPrecipitation (rainfall) in the 24 hours to 9am.
obs_maxTempCnumber CelsiusThe Daytime high temperature, from 6 am to 9 pm.
obs_maxTempLocalTimestringh:mm am/pmThe local time the maximum temperature was reported.
obs_minTempCnumberCelsiusThe Overnight low temperature from 6 pm through to 9 am.
obs_minTempLocalTimestringh:mm am/pmThe local time the minimum temperature was reported.
obs_maximum_gust_spdnumberknotsWind gust speed at time of highest wind gust.
obs_maximum_gust_kmhnumberkilometres per hourWind gust speed at time of highest wind gust.
obs_maximum_gust_dirstringCompass points (16)Wind gust direction at time of highest wind gust.

Observed data fields are as provided by the Bureau of Meteorology. Not all data fields are available for all locations, or for all times. From time to time additional data fields may be added or removed.

For additional information on observed data fields, see: http://reg.bom.gov.au/catalogue/Observations-XML.pdf

3 Weather Extremes

This call is used to get the currently observed extreme values. For example, the current hottest, coldest, wettest and windiest locations.

3.1 By an Area

Description: This call returns the observed weather extremes seen across the whole country or a state.

API Call:

GET /countries/{countryCode}/observations/weatherExtremes/{areaCode}

Parameters:

ParameterExampleDescription
countryCodeauThis is the short code of the country that the weather information relates to.

Available codes are:

au – Australia.

This parameter is Mandatory.
areaCodenationalThis is the short code of the location to retrieve the weather data for. It can be the entire country or a state. ISO 3166-2 codes are used for states or territories.

Available codes for Australia are:

• national
• nsw
• qld
• sa
• tas
• vic
• wa
• act
• nt

This parameter is Mandatory.

National Example:

This example would return the hottest location, coldest location, windiest location and the highest wind gust location across the country.

GET /countries/au/observations/weatherExtremes/national

API Response:

{
    "result": [
        {
            "validAt": "2018-10-15T13:43:32+11:00",
            "area": "national",
            "temperature": {
                "high": {
                    "key": "94333",
                    "name": "Boulia Airport",
                    "state": "Queensland",
                    "obs_tempC": "39.4"
                },
                "low": {
                    "key": "95925",
                    "name": "Mount Ginini Aws",
                    "state": "New South Wales",
                    "obs_tempC": "6.0"
                }
            },
            "wind": {
                "high": {
                    "key": "94580",
                    "name": "Gold Coast Seaway",
                    "state": "Queensland",
                    "obs_windSpeedKm": "65.0",
                    "obs_wind_spd": 35
                }
            },
            "gust": {
                "high": {
                    "key": "94580",
                    "name": "Gold Coast Seaway",
                    "state": "Queensland",
                    "obs_gust_kmh": "78.0",
                    "obs_wind_gust_spd": 42
                }
            }
        }
    ]
}
Field NameDataTypeDescription
validAtstringThe time in AEST the response was generated.
areastringThe code of the area the weather data relates to.
temperatureobjectThe details of the locations with the current highest and lowest temperatures.
highobjectDetails of the location with the current highest reported temperature.
keystringThe unique ID of the station.
namestringThe name of the station.
statestringThe state the station is located in.
obs_tempCnumberThe temperature, measured in degrees Celsius.
lowobjectDetails of the location with the current lowest reported temperature.
windobjectDetails of the locations with the strongest winds.
highobjectDetails of the location with the current highest reported wind speed.
obs_windSpeedKmnumberWind speed in kilometres per hour.
obs_wind_spdnumberWind speed in knots.
gustobjectDetails of the location with the highest wind gust.
obs_gust_kmhnumberWind gust speed in kilometers per hour.
obs_wind_gust_spdnumberWind gust speed in knots.

State Example:

This example would return the hottest location, coldest location, maximum temperature (6am to 9pm local time), minimum temperature (6am to 9pm local time), wettest location (rainfall since 9am local time), windiest location, highest wind gust location and the maximum wind gust location (since midnight local time) across the state.

GET /countries/au/observations/weatherExtremes/tas

API Response:

{
    "result":[
        {
            "validAt":"2018-10-15T09:40:00+11:00",
            "area":"tas",
            "temperature":{
                "high":{
                    "key":"95961",
                    "name":"Low Rocky Point",
                    "state":"Tasmania",
                    "obs_tempC":"21.4"
                },
                "low":{
                    "key":"94979",
                    "name":"Lake Leake (Elizabeth River)",
                    "state":"Tasmania",
                    "obs_tempC":"9.9"
                },
                "maximum":{
                    "key":"95961",
                    "name":"Low Rocky Point",
                    "state":"Tasmania",
                    "obs_tempC":"21.4"
                },
                "minimum":{
                    "key":"94959",
                    "name":"Butlers Gorge",
                    "state":"Tasmania",
                    "obs_tempC":"4.5"
                }
            },
            "rainfall":{
                "key":"95989",
                "name":"Bicheno (Council Depot)",
                "state":"Tasmania",
                "obs_rainfall_since9AM":"3.0"
            },
            "wind":{
                "high":{
                    "key":"95986",
                    "name":"Tasman Island",
                    "state":"Tasmania",
                    "obs_windSpeedKm":"61.0",
                    "obs_wind_spd":"33.0"
                }
            },
            "gust":{
                "high":{
                    "key":"95986",
                    "name":"Tasman Island",
                    "state":"Tasmania",
                    "obs_gust_kmh":"72.0",
                    "obs_wind_gust_spd":"39.0"
                },
                "maximum":{
                    "key":"95986",
                    "name":"Tasman Island",
                    "state":"Tasmania",
                    "obs_gust_kmh":"83.0",
                    "obs_wind_gust_spd":"45.0"
                }
            }
        }
    ]
}

Data fields:

Field NameData TypeDescription
validAtstringThe time, in the local state time, the observations are valid for.
areastringThe short code of the area the weather data relates to.
temperatureobjectThe details of the locations with the current highest, current lowest, minimum and maximum temperatures.
highobjectDetails of the location with the current highest reported temperature.
keystringThe unique ID of the station.
namestringThe name of the station.
statestringThe state the station is located in.
obs_tempCnumberThe temperature, measured in degrees Celsius.
lowstringDetails of the location with the current lowest reported temperature.
maximumobjectDetails of the location with the maximum reported temperature between 6am and 9pm.
minimumobjectDetails of the location with the minimum reported temperature between 6am and 9pm.
rainfallobjectDetails of the location with the current highest reported rainfall.
obs_rainfall_since9AMnumberPrecipitation (rainfall) since 9AM measured in millimeters.
windobjectDetails of the location with the strongest winds.
highobjectDetails of the location with the current highest reported wind speed.
obs_windSpeedKmnumberWind speed in kilometres per hour.
obs_wind_spdnumberWind speed in knots.
gustobjectDetails of the location with the highest wind gust.
highobjectDetails of the location with the current highest reported wind gust.
obs_gust_kmhnumberWind gust speed in kilometers per hour.
obs_wind_gust_spdnumberWind gust speed in knots.
maximumobjectDetails of the location with the maximum reported gust since midnight local time.

3.2 By multiple Areas:

Description: This call returns the observed weather extremes seen across a series of locations.

API Call:

GET /countries/{countryCode}/observations/weatherExtremes?areas=[areaCodes]

Parameters:

ParameterExampleDescription
countryCodeauThis is the short code of the country that the weather information relates to.

Available codes are:

au – Australia.

This parameter is Mandatory.
areasnsw,qldThis is a comma separated list of locations to retrieve the weather data for. A maximum of seven areas can be supplied.

Available codes for Australia are:

• national
• nsw
• qld
• sa
• tas
• vic
• wa
• act
• nt

This parameter is Mandatory.

Example:

GET /countries/au/observations/weatherExtremes?areas=nsw,qld

This example would return the hottest location, coldest location, wettest location and the windiest location across New South Wales and Queensland.

API Response:

Refer to response By an Area


Reviews