Skip to main content

List a data set’s versions

List a data set’s versions. Only provides summary information of each version.

The URL for this endpoint is:

GET https://dev.statistics.api.education.gov.uk/api/v{version}/data-sets/{dataSetId}/versions

Parameters

Path parameters

The following parameters will need to be substituted into the URL path.

Parameter Type Required Description
dataSetId string true

The ID of the data set.

version string true

The requested API version

Defaults to: 1.0

Query parameters

Parameter Type Required Description
page integer false

The page of results to fetch.

Defaults to: 1

Validation constraints:

  • Format: int32

  • Minimum: 1

pageSize integer false

The maximum number of results per page.

Defaults to: 10

Validation constraints:

  • Format: int32

  • Minimum: 1

  • Maximum: 20

Example request

To illustrate how to use this API endpoint, we have provided some samples below in various languages.

cURL

curl -X GET https://dev.statistics.api.education.gov.uk/api/v{version}/data-sets/{dataSetId}/versions

JavaScript

const url = 'https://dev.statistics.api.education.gov.uk/api/v{version}/data-sets/{dataSetId}/versions';

const response = await fetch(url, {
  method: 'GET',
});

console.log(response.json());

Python

import requests

url = 'https://dev.statistics.api.education.gov.uk/api/v{version}/data-sets/{dataSetId}/versions'

response = requests.get(url)

print(response.text)

R

library(httr)

url <- "https://dev.statistics.api.education.gov.uk/api/v{version}/data-sets/{dataSetId}/versions"

response <- GET(url)

output <- content(response)

Responses

Status Description Media Type Schema
200

The paginated list of data set versions.

application/json DataSetVersionPaginatedListViewModel
400

Bad Request

application/json ValidationProblemViewModel
403

Forbidden

application/json ProblemDetailsViewModel

Example successful response

{
  "paging": {
    "page": 1,
    "pageSize": 20,
    "totalResults": 60,
    "totalPages": 3
  },
  "results": [
    {
      "version": "1.0",
      "type": "Major",
      "status": "Published",
      "published": "2024-03-01T09:30:00+00:00",
      "withdrawn": "2024-06-01T12:00:00+00:00",
      "notes": "Some notes about the version.",
      "totalResults": 1000000,
      "file": {
        "id": "e0754872-3206-4918-aad4-029eaaae191f"
      },
      "release": {
        "title": "Spring term 2023/24",
        "slug": "2023-24-spring-term"
      },
      "timePeriods": {
        "start": "2024 January",
        "end": "2024 December"
      },
      "geographicLevels": [
        "National",
        "Regional",
        "Local authority"
      ],
      "filters": [
        "Characteristic",
        "School type"
      ],
      "indicators": [
        "Authorised absence rate",
        "Overall absence rate"
      ]
    }
  ]
}