# Audit trail and export

Source: https://pushary.com/docs/agents/audit-log
Last updated: 2026-11-23

> Review recorded agent questions, approvals and notifications in the append-only audit trail. Filter it by agent, session or decision and export CSV or JSON.

The audit trail is Pushary's record of what your AI agents asked and what you let them do. Recorded questions, approvals, denials and notifications appear as individual rows. Use it to answer "who approved that `git push`, and when?", to review a run, or to hand an export to a compliance reviewer.

Open it at **Dashboard > Agent > Activity**, on [pushary.com/dashboard/agent/activity](https://pushary.com/dashboard/agent/activity). The **Questions** tab shows the rows. The **What changed** tab lists file edits, commands and commits your agents reported.

Codex can approve a waiting tool call locally under a rule and then report it to Pushary. That report is best effort. If the hook reaches its deadline or the connection fails, the call can run without an approval row in Activity or its export. The original question can still appear as withdrawn.

## What each row records [#what-each-row-records]

Each row holds the agent type and name, the session, the tool involved, the question or notification text, your decision, who decided, and timestamps.

| Decision       | Meaning                                                                                                                                                                     |
| -------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `approved`     | A person or policy approved the call                                                                                                                                        |
| `denied`       | A person or policy denied the call                                                                                                                                          |
| `answered`     | You answered a choice or text question                                                                                                                                      |
| `defer`        | Left to the terminal: the decision went back to your agent's own prompt. You chose to handle it on your machine, it was withdrawn, or Pushary did not send it to your phone |
| `pending`      | Asked, not answered yet                                                                                                                                                     |
| `notification` | A one-way notification with no decision                                                                                                                                     |

### How a risky step was approved [#how-a-risky-step-was-approved]

A risky step, such as `rm -rf`, `git push --force` or a step that does not match what you asked, needs more than one tap to approve. Its row also records how it was approved, and opening the row in Activity says so, with what made the step risky:

| `riskConfirmation`      | Shown as                                                                   |
| ----------------------- | -------------------------------------------------------------------------- |
| `device_auth`           | Approved from the Pushary app with Face ID or passcode.                    |
| `sheet_and_device_auth` | Approved from the Pushary app after the warning, with Face ID or passcode. |
| `web_confirm`           | Approved on the web after a second confirm.                                |
| `notch_confirm`         | Approved in Pushary for Mac after a second confirm.                        |
| `call_confirm`          | Approved on a phone call after the warning and a spoken double-check.      |
| `agent_computer`        | Approved at the computer the agent runs on, in Pushary for Mac.            |

For example: "Approved from the Pushary app with Face ID or passcode. Risky: Deletes files." The column is empty for every other answer, for a deny, and for rows written before November 20, 2026. A workspace owner or admin can turn on **Risky steps need the keyboard** in **Agent settings**. Then a risky step from an agent connected through the CLI's hooks, MCP or the Server API is approved only in Pushary for Mac on the agent's computer, recorded as `agent_computer`, or at the agent's own prompt, recorded as `defer`. A step Pushary for Mac or an editor plugin forwards is held the same way, but its approve in Pushary for Mac on the agent's computer leaves this column empty. [Permission policies](/docs/agents/policies#risky-steps-need-the-keyboard) has the details.

The confirmation is what the app or page that answered reported. The server checks that it matches the step and that the place it came from can give it, but it cannot see your Face ID. `agent_computer` is a claim too: Pushary for Mac says which computer it runs on, and the server compares that with the computer the agent asked from. That stops Slack, one-tap links, the web and the phone, but a workspace member who scripts the API could still claim to be the agent's Mac, and the row would record `agent_computer`. The [hash chain](#check-it-yourself) does not cover this column yet, so the verifiable export does not include it.

## Filter the audit trail [#filter-the-audit-trail]

<Callout type="warn" title="Agent Pro and above">
  The server filters, the What changed tab and export need the Agent Pro, Team, Partner or Enterprise plan. On other plans the Activity page shows your 100 most recent entries, which you can filter, with an upgrade prompt.
</Callout>

You can filter by:

* **Agent type**: any agent Pushary supports, such as `claude_code`, `codex`, `cursor`, `gemini_cli` or `hermes`
* **Session**: one agent run
* **Decision**: `approved`, `denied`, `pending` or `notification`
* **Origin**: who decided. `human`, or a machine origin: `autopilot`, `safe_readonly`, `policy_timeout` or `kill_switch`
* **End user**: `externalId`, for Partner sites that ask their own users
* **Search**: text inside the question or notification
* **Date range**: `from` and `to`

The Activity page opens on the last 7 days. A link that names a decision, such as `?decision=pending`, opens all time until you pick a period. Results come 50 to a page by default, up to 200, with a cursor for the next page.

## Export the audit trail to CSV or JSON [#export-the-audit-trail-to-csv-or-json]

Open the &#x2A;*⋯** menu above the table and choose **Export CSV** or **Export JSON**. The export uses the filters you set and follows the open tab: Questions exports decisions, What changed exports tool actions, and Agent runs exports one row per run. On the Team plan it covers every site in the workspace; on other plans, the current site. To see what each person's agents asked and who answered, use the **Agent runs** tab on the same Activity page, described in [Pushary Team](/docs/agents/team#see-what-happened). Team owners and admins also have **Export for your security review** there, a CSV of who answered what and which rule routed it.

The CSV columns are:

```text
createdAt, site, agentType, agentName, sessionId, type, content, decision,
decisionSource, answeredAt, decidedByUserId, decidedByActor, externalId,
correlationId, decisionLatencyMs, toolName, toolTarget, executionState,
permitId, autoResolved, decisionOrigin, requestedBy, riskConfirmation,
riskReasons
```

`decidedByUserId` is a Pushary user id. `decidedByActor` can be an external actor such as `slack:U0123ABC`. Both are empty when the answer came over a credential that carries no identity.

`riskConfirmation` is one of the codes in [How a risky step was approved](#how-a-risky-step-was-approved). `riskReasons` lists the reason codes the step was approved with, such as `deletes_files`, separated by `;` in the CSV and as an array in the JSON. It is empty when the decision's record has passed its retention.

New columns are only ever added at the end, never inserted or reordered, so a parser written against an earlier export keeps working.

The What changed tab exports the same way, with these columns:

```text
createdAt, site, agentType, sessionId, machineId, toolName, kind, target, ok
```

<Callout type="info">
  One export holds up to 10,000 rows, and it cannot reach further back than your plan's [retention](#retention) window.
</Callout>

## Append-only by construction [#append-only-by-construction]

The audit table is protected in the database, not only in the app. A `BEFORE UPDATE OR DELETE` trigger on `agent_interactions` refuses changes, so the guarantee holds even against Pushary's own server code.

* **Edits.** The trigger allows writing the first answer to a question that has none yet. That write cannot change any of 16 pinned columns, including the site, the agent, the session, the tool, the text and the creation time. The only other change it allows is clearing the link to a policy rule after that rule is removed. Any other edit fails with an error.
* **Deletions.** The trigger refuses a delete unless the scheduled [retention](#retention) sweep declared itself for that transaction, or the site the row belongs to is being deleted along with it.

Once an interaction is written, the audit trail preserves its contents. The plan window determines how far back you can view it.

This is a database rule, not a cryptographic proof. Whoever administers the database, and that includes Pushary, could remove the trigger. The verifiable export below is the part you do not have to take on trust.

## Check it yourself [#check-it-yourself]

Each site has a hash chain for recorded questions and decisions. Each entry holds a SHA-256 hash of what the row said and of the entry before it, so changing or removing an old entry breaks every hash after it. Pushary signs the newest hash with an Ed25519 key within about an hour of any new entry.

1. Open **Dashboard > Agent > Activity*&#x2A;, open the &#x2A;*⋯** (More) menu and click **Verifiable export**. It is on Agent Pro and above. You get a JSON file with the chain, the rows it covers and the signed checkpoints. It holds each question's text and each answer, including any note the person added when answering; structured context an agent attached is in it only as a hash. The item appears once your site's first entry has been recorded.
2. Run the check. It needs no account, no key and no network.

```bash
npx -y pushary@latest audit verify pushary-audit-chain-main-2026-11-05.json
```

```text
Main (site_8f1c...): entries 1 to 523, 4 signed checkpoints, exported 2026-11-05 14:00 UTC
  480 checked against their row, 30 superseded by a later decision, 13 past retention, 0 changed since recorded
  This file says rows created before 2026-08-07 are past your plan's retention.
  Result: no changes found.
```

The command remembers what it verified in `~/.local/share/pushary/audit-checkpoints.json` (or under `$XDG_DATA_HOME`), which `pushary clean` leaves alone. That covers the signed checkpoints, the newest entry it saw for each site, and every site it saw. Run it again on a later export and it fails if an entry it already saw was rewritten, or if a newer export ends before it, even when the new file is signed again. Kept files can be checked in any order: an older file after a newer one is a note, not a change. Export on a schedule, keep the files, and run the check on each one.

What the check tells you:

* **Changed.** A row that no longer matches its hash, a missing or reordered entry, an answered decision that changed afterwards or is marked superseded, an entry the file labels wrongly, a bad signature, or history that differs from or ends before a checkpoint you verified before. The command prints `CHANGED` and exits with code 5.
* **Superseded.** A question that timed out or was withdrawn can still be answered from the phone. The chain records both decisions, and the export shows the older one as superseded. An answered decision is never superseded; if one is, that is reported as changed.
* **Changed since recorded.** A question nobody had answered yet whose outcome changed in the last few minutes, before the chain recorded it, as a late answer does. Export again later and it verifies. An answered decision never shows here.
* **Past retention.** An entry whose row passed your plan's retention window keeps its hashes, so the chain stays whole, but no longer shows its text.
* **Removed early.** A row that is gone although it is inside your retention window. A per-request retention setting on a Partner decision can do this; otherwise treat it as a deletion.

Exit codes:

* `0`: everything in the file was checked and nothing changed.
* `5`: something changed.
* `9`: nothing changed in what could be checked, but something could not be confirmed. That covers:
  * the notes above;
  * an older page;
  * a file with no signed checkpoint, or whose newest signature was made more than 80 minutes before the file was exported while newer entries follow it;
  * a file exported no later than a longer one an earlier run already verified;
  * an empty file for a site an earlier run found changed, so it kept nothing to compare against. Once an earlier run verified entries for that site and found no change, an empty file exported later is a change, code `5`;
  * a signing key this version of `pushary` does not pin;
  * a damaged checkpoint store, or one this run could not save;
  * a site id your earlier runs never saw while they did see others.
* `3`: the file has no entries yet, and nothing else is open.
* `2`: the file could not be read, or is not a verifiable export.

A scheduled check should treat anything but `0` as worth a look.

An older page, one exported with `&beforeSeq=`, cannot show whether a newer entry was removed or changed, so it always ends in code `9`. Verify the newest export for that.

What it cannot tell you:

* It covers what reached Pushary. It cannot show a question an agent never asked.
* A question nobody has answered can legitimately change its outcome, for example from timed out to answered, so a change to an unanswered question is not proof of tampering.
* It trusts the retention window the file states. It prints that date so you can check it against your plan.
* A row removed inside the retention window is a note, not proof of a change, because a Partner request's own retention setting can remove it early.
* The first time it sees a site id, it trusts that site from then on. Its checkpoints are what later runs compare against. A new machine, or a deleted checkpoint store, starts again from trust.
* Entries recorded within an hour of the last signature are covered only by the next one, up to about 71 minutes later.
* One file holds the newest 10,000 entries of one site. For older entries, add `&beforeSeq=<first entry number>` to the export link.

## Retention [#retention]

Your plan sets how far back the dashboard shows your agent audit records. A record can stay in storage after it disappears from the dashboard. Deleting a site or account deletes its agent audit records. See [Data retention in the privacy policy](/privacy) for the policy that applies to these records. The hash chain keeps an entry's hashes after its row ages out, so the chain stays continuous. Those entries hold hashes and ids, not question or answer text. The hashes are not salted, so someone holding a file could match a short record, such as a yes or no answer from one of your members, by guessing.

A longer dashboard window can show older records that are still stored. It cannot restore deleted records.

<Accordions>
  <Accordion title="Can I delete an audit entry?">
    Not one entry, and not from the app. The database trigger refuses the delete, with two exceptions: the scheduled retention sweep, and deleting the whole site. No UI, API or support action removes one row and leaves the rest. If you need data removed for a legal reason, contact support. It is a deliberate operation on the whole trail, not a per-row edit.
  </Accordion>

  <Accordion title="What is the difference between the audit trail and list_sessions?">
    [`list_sessions`](/docs/agents/control-panel) is a live view of running agents and open questions. The audit trail is the history of events Pushary received, for as long as your plan keeps it.
  </Accordion>

  <Accordion title="Where does my answer get written?">
    When you answer, the pending row is updated once with your response and the time you answered. That first answer is the one write the append-only trigger allows.
  </Accordion>
</Accordions>

## Next steps [#next-steps]

<Cards>
  <Card title="Decide what gets asked" description="Permission policies set which tool calls run on their own and which wait for you." href="/docs/agents/policies" />

  <Card title="Watch your agents live" description="The control panel shows every running session and which one is waiting on you." href="/docs/agents/control-panel" />
</Cards>