Skip to content

query the API via individual observations (and filters) #45

@fiona-grimm

Description

@fiona-grimm

Consider adding option to also query the API via individual observations (and filters)?

To take weekly deaths as an example, take the latest version URL and add /dimensions
https://api.beta.ons.gov.uk/v1/datasets/weekly-deaths-local-authority/editions/time-series/versions/15/dimensions

This shows you the available dimensions. You’ll need to put an option in for each dimension. You can call /dimensions/[dimension]/options to get a list of available options for a dimension.

Here is a valid call to the observations API:
https://api.beta.ons.gov.uk/v1/datasets/weekly-deaths-local-authority/editions/time-series/versions/15/observations?time=2020&geography=E08000003&placeofdeath=hospital&causeofdeath=all-causes&registrationoroccurrence=registrations&week=week-15

You can also put a wildcard * operator in one dimension e.g.
https://api.beta.ons.gov.uk/v1/datasets/weekly-deaths-local-authority/editions/time-series/versions/15/observations?time=2020&geography=E08000003&placeofdeath=hospital&causeofdeath=all-causes&registrationoroccurrence=registrations&week=*

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions