Access our data
Welcome to the UKHSA data dashboard API developer's guide. Here, you'll find concise instructions for interacting with our API and comprehensive Swagger documentation detailing endpoint information, parameters, and example responses.
Data structure
Last updated on Thursday, 21 March 2024 at 02:45pm
The full URL is constructed as follows:
GET /themes/{theme}/sub_themes/{sub_theme}/topics/{topic}/geography_types/{geography_type}/geographies/{geography}/metrics/{metric}
The following path parameters are required:
theme
the largest overall topical subgroup of data for exampleinfectious_disease
sub_theme
a topical subgroup associated with the parent theme. for examplerespiratory
topic
categorical subgroup associated with the selectedtheme
andsub_theme
. For example atopic
ofCOVID-19
would only be available for atheme
ofinfectious_disease
and asub_theme
ofrespiratory
geography_type
the overarching area type for the intended geography for exampleNation
geography
the selected area under thegeography_type
. For exampleEngland
metric
the type of data being selected. For exampleCOVID-19_testing_PCRcountByDay
Each intermediate part of the URL will provide a list of entities which are available for the cumulative selections.
For example, to retrieve a list of metrics which are available under the COVID-19
dataset for the overall geography
of England
:
GET /themes/infectious_disease/sub_themes/respiratory/topics/COVID-19/geography_types/Nation/geographies/England/metrics
If you are looking for data associated with a particular metric for a given geography
, you will have to traverse the API from the beginning and make the selections by following the hierarchy to determine which entities are available for the intended selections. This is because the returned entities are relevant to the previous selections only.
For example, a selected topic
of Parainfluenza
will not have the same geographies
available to it as COVID-19
.
For more detailed information regarding each metric
. Please see the metrics documentation.