---
title: "Start history collection"
method: POST
path: "/topics/{topicId}/history"
tags: ["History"]
---

# Start history collection

`POST /topics/{topicId}/history`

## Request

- Base URL: `https://api.youscan.io/api/external`
- URL: `https://api.youscan.io/api/external/topics/{topicId}/history`
- Auth: one of:
  - API key in header `X-API-KEY`
  - API key in query parameter `apiKey`
- TypeScript: <https://skmtc.dev/youscan/apis/youscan-api/docs/topics/:topicId/history/post.ts> (a function with typed inputs; its response is checked against the schema)

Start collecting historical mentions for the topic for the given date range.

## Path parameters

- `topicId` integer, required

## Request body

- object
  - `from` string, date, required: ISO formatted date from.
  - `to` string, date, required: ISO formatted date to.

## Response `200`

History collection started.

## Other responses

- `400`: The request is invalid.
- `401`: The API key is missing or invalid.
- `403`: Your permission level for this topic is too low for the action.
- `404`: Topic not found or you don't have access to it.

---

[API](https://skmtc.dev/youscan/apis/youscan-api.md) - [All operations](https://skmtc.dev/youscan/apis/youscan-api/llms.txt) - [OpenAPI document](https://skmtc.dev/youscan/apis/youscan-api/revisions/f5bef260f153?raw)
