---
title: "Get history"
method: GET
path: "/topics/{topicId}/history"
tags: ["Topics"]
---

# Get history

`GET /topics/{topicId}/history`

## Request

- Base URL: `https://api.modem.dev/v1`
- URL: `https://api.modem.dev/v1/topics/{topicId}/history`
- Auth: HTTP bearer

Get change history for a topic. Returns audit trail of modifications with user attribution, and the topics merged into it or that it was merged into. actions is always empty. A topic archived in the v1 to v2 migration returns 404 with data.reason archived_in_v1_to_v2_migration.

## Path parameters

- `topicId` union, required
  - string, uuid
  - string, uuid

## Query parameters

- `changedByFilter` string[]: Filter by actor type. Defaults to user and agent changes (excludes system).
- `limit` integer: Maximum number of history records to return (default 20, max 50).

## Response `200`

OK

- object
  - `actions` object[], required
    - `actionAt` string, date-time
    - `actionType` 'dismissed' | 'merged' | 'resolved' | 'started', required: Semantic category of the action taken: started (a discrete unit of work was initiated, e.g. a PR was opened — per-artifact, not a topic-level state), merged (a code change was integrated into a canonical branch — NOT the same as deployed/shipped/released), resolved (a tracked task was completed positively, e.g. issue closed as completed), dismissed (a task was closed as wontfix / not pursued). User-initiated rows (created via dashboard, agent MCP tool, or direct API call) use the same enum values as auto rows — origin is encoded in metadata.source.
    - `createdByUser` object, nullable, required
      - `id` union, required
        - string
        - string
      - `image` string, nullable, required: Optional URL to the user avatar image.
      - `name` string, required: Human-readable name of the user.
    - `externalLink` union, required
      - object
        - `authorLogin` string, required
        - `createdAt` string, date-time
        - `draft` boolean, required
        - `linkType` 'github_pull_request', required
        - `merged` boolean, required
        - `number` integer, required
        - `state` 'closed' | 'open', required
        - `title` string, required
        - `url` string, uri, required
      - object
        - `linkType` 'github_issue', required
        - `number` integer, required
        - `title` string, required
        - `url` string, uri, required
      - object
        - `linkType` 'none', required
    - `id` string, uuid, required: Unique identifier for the action record.
    - `metadata` unknown
    - `note` string, nullable, required
  - `history` object[], required
    - `changedAt` string, date-time
    - `changedBy` 'agent' | 'system' | 'user', required: Actor type that initiated the change: system (internal/cascading), agent (AI), or user (manual).
    - `changes` object, required
    - `id` union, required
      - string, uuid
      - string, uuid
    - `operation` 'DELETE' | 'INSERT' | 'UPDATE', required: Type of database operation that triggered the history record.
    - `previousValues` object, nullable, required
    - `user` object, nullable, required
      - `id` union, required
        - string
        - string
      - `image` string, nullable, required: Optional URL to the user avatar image.
      - `name` string, required: Human-readable name of the user.
  - `mergedInto` object, nullable, required
    - `id` string, required
    - `mergedAt` string, date-time
    - `targetTopic` object, nullable, required
      - `id` string, required
      - `title` string, required
    - `user` object, nullable, required
      - `id` union, required
        - string
        - string
      - `image` string, nullable, required: Optional URL to the user avatar image.
      - `name` string, required: Human-readable name of the user.
  - `merges` object[], required
    - `id` string, required
    - `mergedAt` string, date-time
    - `sourceTopics` object[], required
      - `id` string, required
      - `title` string, required
    - `user` object, nullable, required
      - `id` union, required
        - string
        - string
      - `image` string, nullable, required: Optional URL to the user avatar image.
      - `name` string, required: Human-readable name of the user.
  - `totalCount` number, required

## Other responses

- `400`: Invalid request (validation failed).
- `401`: Missing or invalid API key.
- `403`: The API key does not have access to this resource.
- `404`: The requested resource was not found.
- `429`: Rate limit exceeded.
- `500`: Internal server error.

---

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