---
title: "The audit trail, newest first"
method: GET
path: "/api/v1/activity"
tags: ["Activity"]
---

# The audit trail, newest first

`GET /api/v1/activity`

## Request

- Base URL: `http://localhost:5180`
- URL: `http://localhost:5180/api/v1/activity`
- Auth: API key in cookie `better-auth.session_token`

One page of the trail, or of a few records’ part of it with `entity`. `limit` caps a page at 1000 and `offset` moves the window, so a client that wants the whole history reads it a page at a time until `offset + events.length` reaches `total`. The portfolio snapshot carries only the newest events, so this is where the rest is read.

## Query parameters

- `limit` integer
- `offset` integer
- `entity` string

## Response `200`

Audit events.

- object
  - `ok` unknown, required
  - `data` object, required
    - `events` object[], required
      - `id` string, required: Stable record id, e.g. `lse_012`.
      - `at` string, required: ISO 8601 timestamp.
      - `action` string, required: `lease.indexed`, `message.sent`, `approval.rejected`…
      - `summary` string, required: Human-readable. Every action the AI takes leaves one.
      - `entity` object, required
        - `kind` string, required: Which kind of record this points at, for example `lease`, `unit` or `invoice`.
        - `id` string, required: Stable record id, e.g. `lse_012`.
        - `label` string, required: How the record reads to a person, so a trail can be followed without a second lookup.
      - `workflowRunId` string: Stable record id, e.g. `lse_012`.
      - `severity` string, required
    - `total` number, required: Every event on file, not just the ones returned. Every one of them is reachable through `offset`.
    - `offset` number, required: The offset this page was read at.
  - `meta` object, required
    - `requestId` string, required: Echoed in the x-request-id header. Quote it in a bug report.

## Other responses

- `400`: `limit` or `offset` is out of range.

---

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