Road Risk API

Road Risk API concept

Road Risk API provides weather data and national alerts at the point of destination and along a route

Road Risk API responds weather data with national alerts along a route that is set up as a massive of points where each point is a pair of latitude, longitude and time. For each point, the API returns air temperature, wind, precipitation, visibility, pressure, humidity, dew point. Active national alerts include alert description, national agency name, and the event hazardous level.

Weather forecast is available for 5 days with minute granularity for the 2 hours from the current moment and hourly granularity for the rest. Historical data is accessible for 5 recent days.

How to request Road Risk API

Method: POST

Header: Content-Type: application/json

API call

https://api.openweathermap.org/data/2.5/roadrisk?appid={API key}
Parameters
lat required Geographical coordinates (latitude) of the point from the specified track
lon required Geographical coordinates (longitude) of the point from the specified track
dt required Date and time for each point of the specified track

Unix time

appid required Your unique API key (you can always find it on your account page under the "API key" tab)
Please note that you can set up the date not earlier than 5 days from the current time and not later than 5 days from the current time.
Example of the request body
                   
{ 
  "roadrisk": [
    {
      "lat": 30.680439786468128,
      "lon": -88.81896972656251,
      "dt": 1602702000
    },
    {
      "lat": 30.56699087315334,
      "lon": -89.44519042968751,
      "dt": 1602702000
    }
  ]
}
                   
                

Road Risk API response

Example of the API response
                   
[
  {
    "dt": 1602702000,
    "coord": [
      7.27,
      44.04
    ],
    "weather": {
      "temp": 278.44,
      "wind_speed": 2.27,
      "wind_deg": 7,
      "precipitation_intensity": 0.38,
      "dew_point": 276.13
    },
    "alerts": [
      {
        "sender_name": "METEO-FRANCE",
        "event": "Moderate thunderstorm warning",
        "event_level": 2
      }
    ]
  },
  {
    "dt": 1602702400,
    "coord": [
      7.37,
      45.04
    ],
    "weather": {
      "temp": 282.44,
      "wind_speed": 1.84,
      "wind_deg": 316,
      "dew_point": 275.99
    },
    "alerts": [
      
    ]
  }
]
                   
                

Fields in API response

  • dt Date and time from the specified track
  • coord Coordinates from the specified track
  • weather
    • weather.temp Temperature
    • weather.wind_speed Wind speed. Units - metre/sec
    • weather.wind_deg Wind direction, degrees (meteorological)
    • weather.precipitation_intensity Intensity of precipitation, mm/hour
    • weather.visibility Average visibility, metres
    • weather.dew_point Atmospheric temperature (varying according to pressure and humidity) below which water droplets begin to condense and dew can form
  • alerts
    • alerts.sender_name Name of the alert source
    • alerts.event Alert event name
    • alerts.event_level Level of the alert severity. Available values:
        0 - Unknown
        1 - Green (no awareness required)
        2 - Yellow (potential danger)
        3 - Orange (dangerous weather)
        4 - Red (very dangerous weather)

List of national weather warning sources

Agency Country
Afghanistan: National Disaster Management Authority Afghanistan
Anguilla: Disaster Management Anguilla Anguilla
Antigua and Barbuda: Meteorological Services Antigua and Barbuda
Aruba: Meteorological Department of Aruba Aruba
Austria: Central Institute for Meteorology and Geodynamics Austria
Barbados: Department of Emergency Management Barbados
Belgium: Royal Meteorological Institute Belgium
Botswana: Department of Meteorological Services Botswan
Canada: Alberta Emergency Management Agency (Government of Alberta, Ministry of Municipal Affairs) Canada
Canada: Meteorological Service of Canada Canada
Canada: Quebec Ministry of Public Safety Canada
China: China Meteorological Administration China
Croatia: State Hydrometeorological Institute (DHMZ) Croatia
Cyprus: Meteorological Service Cyprus
Czech Republic: Czech Hydrometeorological Institute Czech Republic
Denmark: Danmarks Meteorologiske Instituts Denmark
Federated States of Micronesia: Weather Service Office Chuuk Federated States of Micronesia
Federated States of Micronesia: Weather Service Office Pohnpei Federated States of Micronesia
Federated States of Micronesia: Weather Service Office Yap Federated States of Micronesia
Finland: Finnish Meteorological Institute Finland
France: Meteo-France France
Germany: German Meteorological Office Germany
Greece: Hellenic National Meteorological Service Greece
Guyana: Hydrometeorological Service Guyana
Hong Kong: Hong Kong Observatory China/Hong Kong
Hungary: Hungarian Meteorological Service Hungary
India: Meteorological Department India
Indonesia: InaTEWS BMKG, Earthquake with magnitude 5.0 above Indonesia
Ireland: Met Eireann - Irish Meteorological Service Ireland
Israel: Meteorological Service Israel
Italy: National Center of Meteorology and Aeronautical Climatology (CNMCA) Italy
Jamaica: Meteorological Service Jamaica
Kenya: Meteorological Department Kenya
Kuwait: Meteorological Department Kuwait
Lithuania: Lithuanian Hydrometeorological Service Lithuani
Macedonia, the Former Yugoslav Republic of: Republic Hydrometeorological Organization Macedonia
Madagascar: Operational Meteorology Madagascar
Malta: Meteorological Office Malta
Marshall Islands: Majuro Weather Service Office Marshall Islands
Moldova: State Hydrometeorological Service Moldova
Montenegro: Institute of Hydrometeorology and Seismology Montenegro
Myanmar: Department of Meteorology and Hydrology Myanmar
Netherlands: Royal Netherlands Meteorological Institute Netherlands
New Zealand: GNS Science New Zealand
New Zealand: MetService New Zealand
Norway: Norwegian Meteorological Institute Norway
Norway: Norwegian Water Resources and Energy Directorate Norway
Palau: Weather Service Office Palau
Papua New Guinea: Papua New Guinea Meteorological Service Papua New Guinea
Paraguay: Directorate of Meteorology and Hydrology Paraguay
Philippines: Philippine Atmospheric Geophysical and Astronomical Services Administration Philippines
Poland: Institute of Meteorology and Water Management Poland
Romania: National Meteorological Administration Romania
Russian Federal Service for Hydrometeorology and Environmental Monitoring Russia
Saint Lucia: Meteorological Services Saint Lucia
Saint Vincent and the Grenadines: Meteorological Services Saint Vincent and the Grenadines
Samoa: Meteorology Division Samoa
Senegal: National Agency of Civil Aviation and Meteorology Senegal
Slovakia: Slovak Hydrometeorological Institute Slovakia
Slovenia: National Meteorological Service Slovenia
Solomon Islands: Meteorological Service Solomon Islands
South Africa: South Africa Weather Service South Africa
Sweden: Swedish Meteorological and Hydrological Institute Sweden
Tanzania: Meteorological Authority Tanzania
Tonga: Tonga Meteorological Service Tonga
United Kingdom of Great Britain and Northern Ireland: Met Office UK
United States: Environmental Protection Agency (EPA), Air Quality Alerts USA
United States: Integrated Public Alerrt and Warning System (IPAWS) USA
United States: National Oceanic and Atmospheric Administration (NOAA), National Tsunami Warning Center USA
United States: National Oceanic and Atmospheric Administration (NOAA), National Weather Service USA
United States: National Oceanic and Atmospheric Administration (NOAA), National Weather Service - Marine Zones USA
United States: U.S. Geological Survey (USGS), Volcano Hazard Program USA
Vanuatu: Meteorological Services Vanuatu