---
title: "List saved knowledge document versions"
method: GET
path: "/api/knowledge/{id}/history"
tags: ["Knowledge"]
---

# List saved knowledge document versions

`GET /api/knowledge/{id}/history`

## Request

- Base URL: `https://core-api.getaptly.com`
- URL: `https://core-api.getaptly.com/api/knowledge/{id}/history`
- Auth: one of:
  - API key in header `x-token`
  - API key in header `Authorization`
  - HTTP bearer
- TypeScript: <https://skmtc.dev/getaptly/apis/aptly-api/docs/api/knowledge/:id/history/get.ts> (a function with typed inputs; its response is checked against the schema)

Reads retained saved snapshots of a non-archived knowledge document. Partner tokens require knowledge-docs; API keys or delegate tokens use knowledge read access. Delegate callers must remain active company members and currently be able to view the document; membership, document and team authorization use primary reads. API keys and partner tokens are company-scoped. Archived, deleted, or inaccessible documents return 404. There is no archived override. Snapshots older than the current document creation time are excluded so a reused document ID cannot expose a deleted document history. These are saved versions, not unsaved drafts or a complete edit audit: rapid saves may merge and older history may be pruned (normally 50 versions retained). savedBy records the saver, not necessarily the author of every passage; Hiro before/after snapshots both name the approver. No restore or mutation is performed. Versions sort by savedAt descending, then version ID descending. Date bounds are inclusive instants; date-only values mean midnight UTC without end-of-day expansion. A filtered list may omit a predecessor needed for a comparison: omit the date filter to retrieve earlier versions. Metadata only; use the version detail endpoint for text.

## Path parameters

- `id` string, required

## Query parameters

- `companyId` string
- `savedFrom` string
- `savedTo` string
- `savedBy` string
- `limit` integer
- `offset` integer

## Response `200`

Saved history. Nullable fields and nextOffset: null are preserved.

- KnowledgeHistoryList
  - `documentId` string
  - `name` string
  - `note` string
  - `nextOffset` integer, nullable: Pass as offset to continue; null means this result is complete.
  - `current` object
    - `updatedAt` string, date-time, nullable
    - `updatedBy` string, nullable
  - `versions` KnowledgeHistoryVersion[]
    - `versionId` string
    - `name` string, nullable
    - `savedAt` string, date-time, nullable
    - `savedBy` string, nullable
    - `savedByName` string, nullable
    - `conduit` string, nullable: hiro identifies a save through Hiro. Saver attribution is not proof of passage authorship.
    - `emoji` string, nullable
    - `iconUrl` string, nullable
    - `iconFileId` string, nullable
    - `coverId` string, nullable
    - `coverUrl` string, nullable

## Other responses

- `400`: Invalid filters/pagination, or (detail only) an unsupported historical content format.
- `401`: Missing or invalid authentication.
- `403`: Credential lacks knowledge read access.
- `404`: Document inaccessible, archived, or absent; or the requested version does not belong to this document and company.

---

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