All projects

Bathing Water Widgets

We previously worked with the Environment Agency (EA) and subsequently National Resources Wales (NRW) to design and build services that help Local Authorities and other users add the bathing water data quickly to their websites and beach pubic display screens using a configurable widget. We also currently run the NRW bathing water data service.

Logos of the Environment Agency and Natural Resources Wales side by side

Client: Natural Resources Wales, Environment Agency

Our Role: Consultancy, data modelling, data publishing, app development

Site: https://environment.data.gov.uk/wales/bathing-waters/widget/design

The Challenge

To develop a simple means for web-developers from any organisation to embed live feeds of bathing water quality data into their own websites or public display screens, without having the need to develop their own code to collect and display the data from EA or NRW systems.

Background

Bathing Water Quality results derived from the EA and NRW bathing water sampling of designated bathing waters is important and widely used data. It is used by Local Authorities and bathing water managers, researchers, conservation and leisure charities, tourist and other kinds of organisation, as well as individual members of the public. See our item on ‘bathing waters’ for general details about the data itself.

In many cases, organisations want to re-publish the EA or NRW data for their own users, e.g. local authorities for users of their bathing waters, tourist sites for tourists, etc.

Web and App developers can do that by getting the data programmatically from the Bathing Water Data APIs (Application Programming Interface), they can then use the data in their own user interfaces. However, for many organisations that adds a significant barrier to reusing the data.

The Bathing Water Widget Designer

The Bathing Water Widget Designer allows people to customise a live feed of water quality data for a given bathing water site, or all of the sites in a given area, and display that feed onto their website with minimal effort or technical expertise with using APIs. There are also links to the NRW’s or EA’s own bathing water profile pages and so to more detailed information about the bathing waters.

Example of NRW Bathing Water Widget designer webpage. With 3 steps. 1) Pick a widget template options are single bathing water or display of multiple bathing waters in a distric. 2) Configure your widget, using the example of a single bathing water widget. Options include, the choice of the bathing water, the size and layout, and content choices, to show a photo, GPS location, compliance history and whether to allow Google Tag manager analytics and also two testing options for showing what the widget would look like in the bathing water season (useful if it is not currenty the season) and if there were a pollution incident. 3) the designer provides copy-and-pastable code to be used by the web developer on their website. Finally there is a preview of what the widget will look like.
Example of NRW Bathing Water Widget designer webpage

Using the widget itself within a website page simply involves pasting a small piece of HTML code (in the screenshot above) into the webpage’s own HTML. That gives all the functionality of the Widget and access to the data. Below is an example of the widget being used by Neath Port Talbot Council for the Aberafan bathing water.

Screenshot of Neath Port Talbot Council's Bathing Water Quality webpage displaying the bathing water quality widget for Aberafan bathing water
Screenshot of Neath Port Talbot Council’s Bathing Water Quality Webpage

As we described in our post on Building Bilingual Water Quality Data Applications, the Welsh Language Act ensures that Welsh citizens have equal access to public information in the Welsh language as well as in English.

Bathing water widgets embedded into a Welsh-language page will correctly display in Welsh, both data and text. The screenshots below illustrate the change when switching between languages.

Screenshots of Bathing Water Quality  Widgets for used by Denbighshire Council for their 4 beaches (Marine Lake, Rhyl, Prestatyn, Rhyl and Rhyl East) in both English and Welsh languages
Screenshots of Bathing Water Quality Widgets for used by Denbighshire Council
in both English and Welsh language versions

Project Summary

Bathing Water Quality results derived from the EA and NRW bathing water sampling of designated bathing waters is important and widely used data. It is used by Local Authorities and bathing water managers, researchers charities and many others. We worked with EA and NRW to develop an easy to use and configurable website widget, that enabled web developers to add a live feed of bathing water data quickly to their websites and beach display screens.