Met Office NSWWS Public API

Introduction

Met Office Logo

The National Severe Weather Warnings Service (NSWWS) is a UK public service to help emergency responders and the public prepare for possible disruption caused by storms or other severe weather. For more information, see the guide to the National Severe Weather Warnings Service.

This API supplies the latest information about weather warnings in a machine-readable format. It uses the Atom Syndication Format, an IETF standard. The Atom Feed is updated whenever there is a change to the list of latest warnings, that is whenever a warning is issued, updated, cancelled, or expires. If you need regular updates for NSWWS warnings that have been issued by forecasters, then this API should make it simple to access the correct information.

To make the best use of this API, the atom feed needs to be regularly polled for changes. When a change is detected, your application can use the feed content to get the latest information as it needs.

Getting started - authentication key and atom feed URL

You will need an API key to authenticate all of your requests to the API. This API key should be added to the request headers under the header x-api-key. To obtain an API key, you need to get signed up by filling in this contact form and requesting access to the NSWWS Public API. With your API key you will also be given information about how frequently you can call the API.

You will also be given the URL for the atom feed when you get the API key. This is the entry point to the API, so you will need this endpoint to poll. All further links you might need are supplied in the atom-feed content at this URL.

Steps

  1. Make a request to the atom feed endpoint.
  2. Get details about warnings from the atom feed response XML.
  3. Depending on what you want to do, you can either get all currently valid warnings or information about a specific change event, using the atom feed id from step 2. The atom feed will contain endpoints for steps i and ii.
    1. Make a request to get a snapshot of all currently valid warnings.
    2. Make a request to the warnings endpoint for that specific warning update.