> For AI agents: the documentation index is at https://docs.gethandup.dev/llms.txt. Append .md to any page URL (without the trailing slash) for Markdown, for example https://docs.gethandup.dev/cli.md.

# history

`GET /v1/history`

Resolved requests, newest resolution first, with cursor pagination. history.keep_days/max_requests and best-effort history.max_bytes bound retained requests; history.files_keep_days can expire files while keeping history.

## Parameters

### Query Parameters

- **cursor**: `string`

  next_cursor of the previous page

- **limit**: `integer`, >= 0

  Page size, default 50, maximum 500

- **outcome**: `string`

  One or more of approved, denied, expired, cancelled, auto (rule or YOLO decision), dismissed (info notice), comma-separated

- **agent**: `string`

  One or more agent names, comma-separated

- **type**: `string`

  Only requests with a preview of this type

  Allowed values: `text` `markdown` `code` `diff` `files` `command` `json` `html` `image` `video` `audio` `file` `pdf` `email`

- **has**: `string`

  attachments: any file, files, image, pdf, audio, or video preview

  Grouped history preview filter.

  Allowed values: `attachments`

- **kind**: `string`

  One or more request kinds: command, edit, review, question, info, custom, comma-separated

- **q**: `string`

  Case-insensitive search in title, summary, and cwd

## Responses

### 200

Media type: `application/json`

`object`

Retention for resolved requests (decision history). The daemon prunes at
start and hourly; 0 disables a cap. Pending requests are never pruned.

- **keep_days**: `integer` format: int32, default: `90`, >= 0

  Delete resolved requests older than this many days (0 = no age cap).

- **max_requests**: `integer` format: int32, default: `2000`, >= 0

  Keep at most this many resolved requests (0 = no count cap).

- **max_bytes**: `integer` format: int64, default: `0`, >= 0

  Best-effort live database/WAL/blob byte cap, excluding free database pages (0 = unlimited).

- **files_keep_days**: `integer` format: int32, default: `0`, >= 0

  Remove files belonging only to resolutions older than N days (0 = request lifetime).

### 400

Invalid filter or cursor
