> ## Documentation Index
> Fetch the complete documentation index at: https://docs.capout.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Status and Waiting

> Use capout_document_status and capout_wait_for_document to follow an export until it reaches a terminal state.

CapOut processing calls return quickly with a `document_id`. After that, use one of the status tools until the export is complete or failed.

## capout\_document\_status

Use this for a one-shot status check.

```json theme={null}
{
  "tool": "capout_document_status",
  "arguments": {
    "document_id": "b9cf4ef8-9fa3-441b-b0d3-990bee7fbcce"
  }
}
```

## capout\_wait\_for\_document

Use this when you want the agent UI to wait and stream progress for a bounded window.

```json theme={null}
{
  "tool": "capout_wait_for_document",
  "arguments": {
    "document_id": "b9cf4ef8-9fa3-441b-b0d3-990bee7fbcce",
    "max_wait_ms": 110000,
    "poll_interval_ms": 3000
  }
}
```

Never send `max_wait_ms` above `110000`.

If one wait window ends and the document is still in progress, call `capout_wait_for_document` again immediately.

## Example output

Both tools return a terminal-friendly export panel instead of raw JSON. A completed export looks like:

```text theme={null}
EXPORTING TO XACTIMATE
STATUS: COMPLETE

Workflow Complete : YES
File Name         : broderick.pdf
Message           : Xactimate export completed successfully.
```

## Terminal state

Treat the workflow as finished when the returned panel indicates a terminal result. For successful runs, expect:

* `STATUS: COMPLETE`
* `Workflow Complete : YES`

If the document is still running, keep calling one of these tools until it reaches a terminal state.
