# Trace assessments

Each time your Trace rules ran on an agent's action, with the facts they read and what was unavailable, and the Trace pause.

Related guide: [Trace rules](https://provenanceauth.com/docs/trace/guides/trace-rules.md)

## Endpoints

- `GET /v1/trace/settings/pause`: [Retrieve the Trace pause](#get-v1-trace-settings-pause)
- `GET /v1/trace/assessments/{id}`: [Retrieve an assessment](#get-v1-trace-assessments-id)
- `GET /v1/trace/assessments`: [List assessments](#get-v1-trace-assessments)
- `POST /v1/trace/assessments`: [Assess an action](#post-v1-trace-assessments)
- `POST /v1/trace/pause`: [Pause Trace](#post-v1-trace-pause)
- `POST /v1/trace/resume`: [Resume Trace](#post-v1-trace-resume)

## The trace pause object

### Attributes

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `object` | enum | yes | The type of object. One of `trace_pause`. |
| `paused` | boolean | yes | Whether Trace is paused now. |
| `paused_at` | timestamp \| null | yes | When the pause started (null when not paused). |
| `paused_by` | string \| null | yes | Who paused: a member's user ID, or `owner` (null when not paused). |
| `paused_by_email` | string \| null | yes | The email of the person who paused. |
| `reason` | string \| null | yes | The note given with the pause. |
| `still_paused_by` | enum | yes | `pause_all` while Pause all holds: it stops Trace too, so Trace stays stopped after a resume. One of `pause_all`. |
| `already` | boolean | no | On the pause and resume actions only: true when Trace was already in that state, so nothing changed. |

### Example

```json
{
  "object": "trace_pause",
  "paused": true,
  "paused_at": "2026-11-25T16:04:22.381Z",
  "paused_by": "usr_01M5R0C0555A43E2PW7SB25YVG",
  "paused_by_email": "maya@pellowmarsh.example",
  "reason": "Injection campaign on the support model",
  "still_paused_by": null,
  "already": false
}
```

## Events

Sent to your [webhook endpoints](https://provenanceauth.com/docs/integrate/webhooks.md) when they subscribe:

- `trace.assessment.denied`
- `trace.assessment.updated`
- `trace.pause.started`
- `trace.pause.ended`

## Retrieve the Trace pause

`GET /v1/trace/settings/pause`

Whether Trace is paused, by whom and why. Any member, or a key with the `trace` scope.

Auth: an API key, as `Authorization: Bearer <key>`.

### Parameters

No parameters.

### Returns

The pause. See [the trace pause object](#object).

### Errors

- [`authentication_required`](https://provenanceauth.com/docs/platform/errors.md#authentication_required)
- [`rate_limit_exceeded`](https://provenanceauth.com/docs/platform/errors.md#rate_limit_exceeded)

### Request

**curl**

```bash
export PROVENANCE_KEY=prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5
curl "$PROVENANCE_API/v1/trace/settings/pause" \
  -H "Authorization: Bearer $PROVENANCE_KEY"
```

**Node**

```ts
const data = await (await fetch(`${process.env.PROVENANCE_API}/v1/trace/settings/pause`, {
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5" },
})).json();
```

**Python**

```python
import os
import httpx

api = os.environ["PROVENANCE_API"]
data = httpx.get(f"{api}/v1/trace/settings/pause", headers={"Authorization": "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5"}).json()
```

### Response 200

```json
{
  "object": "trace_pause",
  "paused": false,
  "paused_at": null,
  "paused_by": null,
  "paused_by_email": null,
  "reason": null,
  "still_paused_by": null
}
```

## Retrieve an assessment

`GET /v1/trace/assessments/{id}`

One trace assessment.

Auth: an API key, as `Authorization: Bearer <key>`.

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `id` | path | string | yes | The assessment's ID (`tsa_`). |
| `wait` | query | integer | no | Long-poll a challenge: wait up to this many seconds for the person to decide. |

### Returns

The assessment.

### Errors

- [`authentication_required`](https://provenanceauth.com/docs/platform/errors.md#authentication_required)
- [`rate_limit_exceeded`](https://provenanceauth.com/docs/platform/errors.md#rate_limit_exceeded)
- [`resource_missing`](https://provenanceauth.com/docs/platform/errors.md#resource_missing)

### Request

**curl**

```bash
export PROVENANCE_KEY=prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5
curl -s -X POST "$PROVENANCE_API/v1/trace/assessments" \
  -H "Authorization: Bearer $PROVENANCE_KEY" \
  -H "Idempotency-Key: tsa-reference-2" \
  -H "Content-Type: application/json" \
  -d '{ "action": { "tool": "crm.search" } }' > step.json
export TRACE_ASSESSMENT_ID=$(jq -r '.id' step.json)
curl "$PROVENANCE_API/v1/trace/assessments/$TRACE_ASSESSMENT_ID" \
  -H "Authorization: Bearer $PROVENANCE_KEY"
```

**Node**

```ts
const step1 = await (await fetch(`${process.env.PROVENANCE_API}/v1/trace/assessments`, {
  method: "POST",
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Content-Type": "application/json", "Idempotency-Key": "tsa-reference-2" },
  body: JSON.stringify({ "action": { "tool": "crm.search" } }),
})).json();
const traceAssessmentId = step1.id;
const data = await (await fetch(`${process.env.PROVENANCE_API}/v1/trace/assessments/${traceAssessmentId}`, {
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5" },
})).json();
```

**Python**

```python
import os
import httpx

api = os.environ["PROVENANCE_API"]
step1 = httpx.post(f"{api}/v1/trace/assessments", headers={"Authorization": "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Idempotency-Key": "tsa-reference-2"}, json={
    "action": {
        "tool": "crm.search"
    }
}).json()
trace_assessment_id = step1["id"]
data = httpx.get(f"{api}/v1/trace/assessments/{trace_assessment_id}", headers={"Authorization": "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5"}).json()
```

### Response 200

```json
{
  "object": "trace_assessment",
  "id": "tsa_01M8AD188NC2S3HHN1VJ2JYW3F",
  "created_at": "2026-11-25T22:25:46.773Z",
  "outcome": "allow",
  "reason": null,
  "stage": "action",
  "action": {
    "tool": "crm.search",
    "risk": "read",
    "risk_source": "derived",
    "args_hash": null
  },
  "signature": null,
  "authority": null,
  "agent_id": null,
  "agent_session_id": null,
  "run_id": null,
  "policy": null,
  "approval": null,
  "approval_context": null,
  "findings": [],
  "trace": null,
  "facts": {
    "trace.reading_source": "none",
    "action.tool": "crm.search",
    "action.risk": "read"
  },
  "facts_version": 1,
  "lock": null,
  "trip_id": null,
  "unavailable": [],
  "unassessed": false,
  "decided_at": "2026-11-25T22:25:46.773Z"
}
```

## List assessments

`GET /v1/trace/assessments`

Your trace assessments, newest first.

Auth: an API key, as `Authorization: Bearer <key>`.

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `limit` | query | integer | no | Page size, 1–100 (default 20). Outside the range → 400 parameter_invalid. |
| `cursor` | query | string | no | Opaque; pass a response's `next_cursor` back to get the next page. |
| `outcome` | query | enum | no | Only this outcome. One of `allow`, `challenge`, `deny`. |
| `stage` | query | enum | no | Only this stage. One of `action`, `completion`. |
| `agent_id` | query | string | no | Only this agent. |
| `risk` | query | enum | no | Only this risk class. One of `read`, `write`, `send`, `delete`, `pay`. |
| `rule_id` | query | string | no | Only those this rule decided. |
| `unassessed` | query | boolean | no | Only SDK records (`true`) or only assessments (`false`). |
| `created_gte` | query | timestamp | no | Created at or after. |
| `created_lte` | query | timestamp | no | Created at or before. |

### Returns

A page of assessments.

### Errors

- [`authentication_required`](https://provenanceauth.com/docs/platform/errors.md#authentication_required)
- [`parameter_invalid`](https://provenanceauth.com/docs/platform/errors.md#parameter_invalid)
- [`rate_limit_exceeded`](https://provenanceauth.com/docs/platform/errors.md#rate_limit_exceeded)

### Request

**curl**

```bash
export PROVENANCE_KEY=prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5
curl -s -X POST "$PROVENANCE_API/v1/trace/assessments" \
  -H "Authorization: Bearer $PROVENANCE_KEY" \
  -H "Idempotency-Key: tsa-reference-list-1" \
  -H "Content-Type: application/json" \
  -d '{ "action": { "tool": "crm.search" } }' > /dev/null
curl -s -X POST "$PROVENANCE_API/v1/trace/assessments" \
  -H "Authorization: Bearer $PROVENANCE_KEY" \
  -H "Idempotency-Key: tsa-reference-list-2" \
  -H "Content-Type: application/json" \
  -d '{ "action": { "tool": "crm.search" } }' > /dev/null
curl "$PROVENANCE_API/v1/trace/assessments?limit=1&stage=action" \
  -H "Authorization: Bearer $PROVENANCE_KEY"
```

**Node**

```ts
const step1 = await (await fetch(`${process.env.PROVENANCE_API}/v1/trace/assessments`, {
  method: "POST",
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Content-Type": "application/json", "Idempotency-Key": "tsa-reference-list-1" },
  body: JSON.stringify({ "action": { "tool": "crm.search" } }),
})).json();
const step2 = await (await fetch(`${process.env.PROVENANCE_API}/v1/trace/assessments`, {
  method: "POST",
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Content-Type": "application/json", "Idempotency-Key": "tsa-reference-list-2" },
  body: JSON.stringify({ "action": { "tool": "crm.search" } }),
})).json();
const data = await (await fetch(`${process.env.PROVENANCE_API}/v1/trace/assessments?limit=1&stage=action`, {
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5" },
})).json();
```

**Python**

```python
import os
import httpx

api = os.environ["PROVENANCE_API"]
step1 = httpx.post(f"{api}/v1/trace/assessments", headers={"Authorization": "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Idempotency-Key": "tsa-reference-list-1"}, json={
    "action": {
        "tool": "crm.search"
    }
}).json()
step2 = httpx.post(f"{api}/v1/trace/assessments", headers={"Authorization": "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Idempotency-Key": "tsa-reference-list-2"}, json={
    "action": {
        "tool": "crm.search"
    }
}).json()
data = httpx.get(f"{api}/v1/trace/assessments?limit=1&stage=action", headers={"Authorization": "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5"}).json()
```

### Response 200

```json
{
  "object": "list",
  "data": [
    {
      "object": "trace_assessment",
      "id": "tsa_01M8ARHPNVRNTCPRVMTGF23HFR",
      "created_at": "2026-11-26T01:47:00.155Z",
      "outcome": "allow",
      "reason": null,
      "stage": "action",
      "action": {
        "tool": "crm.search",
        "risk": "read",
        "risk_source": "derived",
        "args_hash": null
      },
      "signature": null,
      "authority": null,
      "agent_id": null,
      "agent_session_id": null,
      "run_id": null,
      "policy": null,
      "approval": null,
      "approval_context": null,
      "findings": [],
      "trace": null,
      "facts": {
        "trace.reading_source": "none",
        "action.tool": "crm.search",
        "action.risk": "read"
      },
      "facts_version": 1,
      "lock": null,
      "trip_id": null,
      "unavailable": [],
      "unassessed": false,
      "decided_at": "2026-11-26T01:47:00.155Z"
    }
  ],
  "has_more": true,
  "next_cursor": "eyJpZCI6InRzYV8wMU04QVJIUE5WUk5UQ1BSVk1UR0YyM0hGUiIsImRpcmVjdGlvbiI6Im5leHQifQ"
}
```

## Assess an action

`POST /v1/trace/assessments`

Runs your Trace rules on an agent's action before the tool runs. `Idempotency-Key` is required: a retry with the same key returns the same assessment. Send the action's structured fields; `args` is kept only as its SHA-256. With `unassessed: true`, records a tool your SDK ran while Provenance couldn't be reached (never evaluated, never billed). One decision per action assessment.

Auth: an API key, as `Authorization: Bearer <key>`.

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `Idempotency-Key` | header | string | no | Retry a create safely: the same key + request returns the stored response (24 h, per caller). |
| `stage` | body | enum | no | `action`: before a tool call. One of `action`. |
| `trace_id` | body | string | no | The trace of the model call that produced the tool call. |
| `agent_id` | body | string | no | The registered agent. |
| `agent_session_id` | body | string | no | The agent's session (a rule's lock names it). |
| `run_id` | body | string | no | The run the action belongs to. |
| `action` | body | object | yes | The action the agent is about to take. |
| `action.tool` | body | string | yes | The tool's name, such as `payments.send`. |
| `action.risk` | body | enum | no | The risk class; read from the tool's name when left out. One of `read`, `write`, `send`, `delete`, `pay`. |
| `action.amount` | body | integer | no | The amount in minor units. |
| `action.currency` | body | string | no | ISO 4217. |
| `action.payee` | body | string | no | A payee ID or domain. |
| `action.description` | body | string | no | What the action does, in words. |
| `action.args` | body | any | no | The tool's arguments: hashed (`args_hash`), never kept. |
| `context` | body | object | no | What was in the model's context. |
| `context.untrusted_sources` | body | array of enums | no | Kinds of untrusted content in the model's context. |
| `findings` | body | array of objects | no | What your own guards reported. An unknown category is refused (`finding_category_unknown`). |
| `findings.reporter` | body | enum | yes | Who reported it. One of `lakera`, `bedrock_guardrails`, `prompt_shields`, `nemo_guardrails`, `own`. |
| `findings.category` | body | enum | no | The finding's category. One of `prompt_injection`, `indirect_injection`, `jailbreak`, `unsafe_output`, `pii_leak`, `malicious_link`, `credential_exfiltration`, `off_task`. |
| `findings.confidence` | body | number | no | The reporter's confidence. |
| `findings.unanswered` | body | boolean | no | The guard ran and didn't answer (its `finding.*` facts are unavailable). |
| `unassessed` | body | boolean | no | An SDK's record of a tool that ran while Provenance couldn't be reached. |
| `unassessed_at` | body | timestamp | no | When the tool ran. |
| `unassessed_reason` | body | enum | no | Why it ran unchecked. One of `unreachable`, `timeout`, `server_error`. |
| `dropped` | body | integer | no | Records the SDK dropped before this one could be posted. |
| `wait` | body | object | no | Wait for a person to decide a challenge before answering. |
| `wait.approval_s` | body | integer | no | Seconds to wait (at most 25); the answer is still `challenge` if nobody decided. |

### Returns

The assessment.

### Errors

- [`authentication_required`](https://provenanceauth.com/docs/platform/errors.md#authentication_required)
- [`finding_category_unknown`](https://provenanceauth.com/docs/platform/errors.md#finding_category_unknown)
- [`idempotency_key_reused`](https://provenanceauth.com/docs/platform/errors.md#idempotency_key_reused)
- [`invalid_json`](https://provenanceauth.com/docs/platform/errors.md#invalid_json)
- [`parameter_invalid`](https://provenanceauth.com/docs/platform/errors.md#parameter_invalid)
- [`parameter_missing`](https://provenanceauth.com/docs/platform/errors.md#parameter_missing)
- [`policy_account_required`](https://provenanceauth.com/docs/platform/errors.md#policy_account_required)
- [`rate_limit_exceeded`](https://provenanceauth.com/docs/platform/errors.md#rate_limit_exceeded)
- [`resource_missing`](https://provenanceauth.com/docs/platform/errors.md#resource_missing)
- [`trace_rules_unavailable`](https://provenanceauth.com/docs/platform/errors.md#trace_rules_unavailable)
- [`trial_ended`](https://provenanceauth.com/docs/platform/errors.md#trial_ended)

### Request

**curl**

```bash
export PROVENANCE_KEY=prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5
curl -s -X PUT "$PROVENANCE_API/v1/trace/policies" \
  -H "Authorization: Bearer $PROVENANCE_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "note": "ask before paying after an injected email; never delete",
    "document": {
      "rules": [
        {
          "id": "injected-email-payments",
          "label": "Payments after an injected email",
          "when": [
            {
              "fact": "action.risk",
              "op": "eq",
              "value": "pay"
            },
            {
              "fact": "context.untrusted_sources",
              "op": "contains",
              "value": "email"
            },
            {
              "fact": "finding.categories",
              "op": "contains",
              "value": "indirect_injection"
            }
          ],
          "require": {
            "approval": true
          }
        },
        {
          "id": "no-deletes",
          "label": "Deletes",
          "when": [
            {
              "fact": "action.risk",
              "op": "eq",
              "value": "delete"
            }
          ],
          "require": {
            "deny": true,
            "lock": true
          }
        }
      ]
    }
  }' > step.json
export TRACE_POLICY_VERSION=$(jq -r '.version' step.json)
curl -X POST "$PROVENANCE_API/v1/trace/assessments" \
  -H "Authorization: Bearer $PROVENANCE_KEY" \
  -H "Idempotency-Key: tsa-reference-1" \
  -H "Content-Type: application/json" \
  -d '{
    "agent_session_id": "ses_reference_trace",
    "action": {
      "tool": "payments.send",
      "amount": 185000,
      "currency": "USD",
      "payee": "acct_brindlecote_supplies",
      "description": "Pay invoice INV-2041"
    },
    "context": {
      "untrusted_sources": [
        "email"
      ]
    },
    "findings": [
      {
        "reporter": "own",
        "category": "indirect_injection",
        "confidence": 0.91
      }
    ]
  }'
curl -s -X DELETE "$PROVENANCE_API/v1/trace/policies" \
  -H "Authorization: Bearer $PROVENANCE_KEY" > /dev/null
```

**Node**

```ts
const step1 = await (await fetch(`${process.env.PROVENANCE_API}/v1/trace/policies`, {
  method: "PUT",
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Content-Type": "application/json" },
  body: JSON.stringify({
    "note": "ask before paying after an injected email; never delete",
    "document": {
      "rules": [
        {
          "id": "injected-email-payments",
          "label": "Payments after an injected email",
          "when": [
            {
              "fact": "action.risk",
              "op": "eq",
              "value": "pay"
            },
            {
              "fact": "context.untrusted_sources",
              "op": "contains",
              "value": "email"
            },
            {
              "fact": "finding.categories",
              "op": "contains",
              "value": "indirect_injection"
            }
          ],
          "require": {
            "approval": true
          }
        },
        {
          "id": "no-deletes",
          "label": "Deletes",
          "when": [
            {
              "fact": "action.risk",
              "op": "eq",
              "value": "delete"
            }
          ],
          "require": {
            "deny": true,
            "lock": true
          }
        }
      ]
    }
  }),
})).json();
const tracePolicyVersion = step1.version;
const data = await (await fetch(`${process.env.PROVENANCE_API}/v1/trace/assessments`, {
  method: "POST",
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Content-Type": "application/json", "Idempotency-Key": "tsa-reference-1" },
  body: JSON.stringify({
    "agent_session_id": "ses_reference_trace",
    "action": {
      "tool": "payments.send",
      "amount": 185000,
      "currency": "USD",
      "payee": "acct_brindlecote_supplies",
      "description": "Pay invoice INV-2041"
    },
    "context": {
      "untrusted_sources": [
        "email"
      ]
    },
    "findings": [
      {
        "reporter": "own",
        "category": "indirect_injection",
        "confidence": 0.91
      }
    ]
  }),
})).json();
```

**Python**

```python
import os
import httpx

api = os.environ["PROVENANCE_API"]
step1 = httpx.put(f"{api}/v1/trace/policies", headers={"Authorization": "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5"}, json={
    "note": "ask before paying after an injected email; never delete",
    "document": {
        "rules": [
            {
                "id": "injected-email-payments",
                "label": "Payments after an injected email",
                "when": [
                    {
                        "fact": "action.risk",
                        "op": "eq",
                        "value": "pay"
                    },
                    {
                        "fact": "context.untrusted_sources",
                        "op": "contains",
                        "value": "email"
                    },
                    {
                        "fact": "finding.categories",
                        "op": "contains",
                        "value": "indirect_injection"
                    }
                ],
                "require": {
                    "approval": True
                }
            },
            {
                "id": "no-deletes",
                "label": "Deletes",
                "when": [
                    {
                        "fact": "action.risk",
                        "op": "eq",
                        "value": "delete"
                    }
                ],
                "require": {
                    "deny": True,
                    "lock": True
                }
            }
        ]
    }
}).json()
trace_policy_version = step1["version"]
data = httpx.post(f"{api}/v1/trace/assessments", headers={"Authorization": "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Idempotency-Key": "tsa-reference-1"}, json={
    "agent_session_id": "ses_reference_trace",
    "action": {
        "tool": "payments.send",
        "amount": 185000,
        "currency": "USD",
        "payee": "acct_brindlecote_supplies",
        "description": "Pay invoice INV-2041"
    },
    "context": {
        "untrusted_sources": [
            "email"
        ]
    },
    "findings": [
        {
            "reporter": "own",
            "category": "indirect_injection",
            "confidence": 0.91
        }
    ]
}).json()
```

### Response 201

```json
{
  "object": "trace_assessment",
  "id": "tsa_01M8AD188JGCSZHVSRKMWZGMRY",
  "created_at": "2026-11-25T22:25:46.770Z",
  "outcome": "challenge",
  "reason": "approval_required",
  "stage": "action",
  "action": {
    "tool": "payments.send",
    "risk": "pay",
    "risk_source": "derived",
    "amount": 185000,
    "currency": "USD",
    "payee": "acct_brindlecote_supplies",
    "description": "Pay invoice INV-2041",
    "args_hash": null
  },
  "signature": null,
  "authority": null,
  "agent_id": null,
  "agent_session_id": "ses_reference_trace",
  "run_id": null,
  "policy": {
    "id": "pol_956287817DE7DEF7A3C4E0C732",
    "version": 7,
    "rule": {
      "id": "rul_01M8AD18814Z7YZAN1KM1D5677",
      "name": "Payments after an injected email",
      "phase": "action",
      "action": "challenge",
      "conditions": [
        {
          "fact": "action.risk",
          "op": "eq",
          "value": "pay",
          "actual": "pay"
        },
        {
          "fact": "context.untrusted_sources",
          "op": "contains",
          "value": "email",
          "actual": [
            "email"
          ]
        },
        {
          "fact": "finding.categories",
          "op": "contains",
          "value": "indirect_injection",
          "actual": [
            "indirect_injection"
          ]
        }
      ]
    },
    "logged": []
  },
  "approval": {
    "id": "appr_01M8AD188J8JX6FET9CM1P6TW2",
    "status": "pending",
    "expires_at": "2026-11-25T22:35:46.770Z",
    "delivery": "sent"
  },
  "approval_context": null,
  "findings": [
    {
      "reporter": "own",
      "category": "indirect_injection",
      "confidence": 0.91
    }
  ],
  "trace": null,
  "facts": {
    "trace.reading_source": "none",
    "finding.categories": [
      "indirect_injection"
    ],
    "finding.reporters": [
      "own"
    ],
    "finding.max_confidence": 0.91,
    "action.tool": "payments.send",
    "action.risk": "pay",
    "action.amount": 185000,
    "action.currency": "USD",
    "action.payee": "acct_brindlecote_supplies",
    "context.untrusted_sources": [
      "email"
    ],
    "agent_session_id": "ses_reference_trace"
  },
  "facts_version": 1,
  "lock": null,
  "trip_id": null,
  "unavailable": [],
  "unassessed": false,
  "decided_at": null
}
```

## Pause Trace

`POST /v1/trace/pause`

Pauses Trace for an incident: model calls, trace assessments, checks, signed readings, new trace jobs and eval runs stop with `trace_paused`; payments and the other products keep running. Owner or admin, from a console session, with a recent second-factor check; no API key can. Sends `trace.pause.started`.

Auth: an API key, as `Authorization: Bearer <key>`.

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `reason` | body | string | no | A note for the banner, the security event and the webhook. |

### Returns

The pause. See [the trace pause object](#object).

### Errors

- [`authentication_required`](https://provenanceauth.com/docs/platform/errors.md#authentication_required)
- [`csrf_invalid`](https://provenanceauth.com/docs/platform/errors.md#csrf_invalid)
- [`insufficient_role`](https://provenanceauth.com/docs/platform/errors.md#insufficient_role)
- [`parameter_invalid`](https://provenanceauth.com/docs/platform/errors.md#parameter_invalid)
- [`rate_limit_exceeded`](https://provenanceauth.com/docs/platform/errors.md#rate_limit_exceeded)
- [`recent_two_factor_required`](https://provenanceauth.com/docs/platform/errors.md#recent_two_factor_required)
- [`trace_pause_needs_session`](https://provenanceauth.com/docs/platform/errors.md#trace_pause_needs_session)

### Request

**curl**

```bash
export PROVENANCE_KEY=prv_test_full_K7mN3xQp9RbT2vWm8sYd4cFjLhXn6gAe
curl -X POST "$PROVENANCE_API/v1/trace/pause" \
  -H "Authorization: Bearer $PROVENANCE_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "reason": "Injection campaign on the support model" }'
```

**Node**

```ts
const data = await (await fetch(`${process.env.PROVENANCE_API}/v1/trace/pause`, {
  method: "POST",
  headers: { Authorization: `Bearer ${process.env.PROVENANCE_KEY}`, "Content-Type": "application/json" },
  body: JSON.stringify({ "reason": "Injection campaign on the support model" }),
})).json();
```

**Python**

```python
import os
import httpx

api = os.environ["PROVENANCE_API"]
data = httpx.post(f"{api}/v1/trace/pause", headers={"Authorization": f"Bearer {os.environ['PROVENANCE_KEY']}"}, json={
    "reason": "Injection campaign on the support model"
}).json()
```

### Response 200

```json
{
  "object": "trace_pause",
  "paused": true,
  "paused_at": "2026-11-25T16:04:22.381Z",
  "paused_by": "usr_01M5R0C0555A43E2PW7SB25YVG",
  "paused_by_email": "maya@pellowmarsh.example",
  "reason": "Injection campaign on the support model",
  "still_paused_by": null,
  "already": false
}
```

## Resume Trace

`POST /v1/trace/resume`

Lifts the Trace pause. While Pause all holds, Trace stays stopped and `still_paused_by` is `pause_all`. Owner or admin, from a console session, with a recent second-factor check; no API key can. Sends `trace.pause.ended`.

Auth: an API key, as `Authorization: Bearer <key>`.

### Parameters

No parameters.

### Returns

The pause. See [the trace pause object](#object).

### Errors

- [`authentication_required`](https://provenanceauth.com/docs/platform/errors.md#authentication_required)
- [`csrf_invalid`](https://provenanceauth.com/docs/platform/errors.md#csrf_invalid)
- [`insufficient_role`](https://provenanceauth.com/docs/platform/errors.md#insufficient_role)
- [`parameter_invalid`](https://provenanceauth.com/docs/platform/errors.md#parameter_invalid)
- [`rate_limit_exceeded`](https://provenanceauth.com/docs/platform/errors.md#rate_limit_exceeded)
- [`recent_two_factor_required`](https://provenanceauth.com/docs/platform/errors.md#recent_two_factor_required)
- [`trace_pause_needs_session`](https://provenanceauth.com/docs/platform/errors.md#trace_pause_needs_session)

### Request

**curl**

```bash
export PROVENANCE_KEY=prv_test_full_K7mN3xQp9RbT2vWm8sYd4cFjLhXn6gAe
curl -X POST "$PROVENANCE_API/v1/trace/resume" \
  -H "Authorization: Bearer $PROVENANCE_KEY"
```

**Node**

```ts
const data = await (await fetch(`${process.env.PROVENANCE_API}/v1/trace/resume`, {
  method: "POST",
  headers: { Authorization: `Bearer ${process.env.PROVENANCE_KEY}` },
})).json();
```

**Python**

```python
import os
import httpx

api = os.environ["PROVENANCE_API"]
data = httpx.post(f"{api}/v1/trace/resume", headers={"Authorization": f"Bearer {os.environ['PROVENANCE_KEY']}"}).json()
```

### Response 200

```json
{
  "object": "trace_pause",
  "paused": false,
  "paused_at": null,
  "paused_by": null,
  "paused_by_email": null,
  "reason": null,
  "still_paused_by": null,
  "already": false
}
```
