---
title: "Get metric values for a single content item over a date range."
method: GET
path: "/metrics/{base_path}/time-series"
tags: ["Time series"]
---

# Get metric values for a single content item over a date range.

`GET /metrics/{base_path}/time-series`

## Request

- Base URL: `https://content-data-api.publishing.service.gov.uk/api/v1`
- URL: `https://content-data-api.publishing.service.gov.uk/api/v1/metrics/{base_path}/time-series`
- Auth: HTTP bearer

Returns an array of values for each metric. Each item represents a
metric value at a single point in time.

## Path parameters

- `base_path` string, required
- `metrics` string, required

## Query parameters

- `from` string, required
- `to` string, required

## Response `200`

Success response

- TimeSeriesResponse: An object where each key is a metric ID and each value is a time series.

## Other responses

- `400`: The API request is invalid.

## Changes

- **2018-09-12** `db80c4ca0476`: 1 breaking, 2 info
  - the `additionalProperties/items/date` response's property type changed from `date` to `string` for status `200`
  - for the `query` request parameter `from`, the type was generalized from `date` to `string`
  - for the `query` request parameter `to`, the type was generalized from `date` to `string`
- **2018-09-07** `526b660a1342`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/government-digital-service/apis/gov-uk-content-data-api/changes/metrics/:base_path/time-series/get.md)

---

[API](https://skmtc.dev/government-digital-service/apis/gov-uk-content-data-api.md) - [All operations](https://skmtc.dev/government-digital-service/apis/gov-uk-content-data-api/llms.txt) - [OpenAPI document](https://skmtc.dev/government-digital-service/apis/gov-uk-content-data-api/revisions/856c07d21d1b?raw)
