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

# Verify

> Page-level verification status and actions.

## Overview

`okra verify` gives you page-level verification status for any document. Every page is either `verified`, `needs_review`, `failed`, or `clean` (no extractable content).

Modeled after `gh pr review` — verb-first, inline action flags, pipe-friendly JSON output.

## Summary

```bash theme={null}
okra verify doc-abc123
```

```json theme={null}
{
  "document_id": "doc-abc123",
  "phase": "complete",
  "total_pages": 13,
  "verified": 10,
  "needs_review": 2,
  "failed": 1,
  "clean": 0,
  "verification_pct": 77,
  "vendor": "llamaparse",
  "pages": [...]
}
```

## Filter Pages

```bash theme={null}
# Pages needing attention
okra verify doc-abc123 --needs-review

# Pages with failed nodes
okra verify doc-abc123 --failed

# Pages with low confidence
okra verify doc-abc123 --below 0.7
```

## Page Detail

```bash theme={null}
okra verify doc-abc123 --page 7
```

Returns node-level issues for that page, including node IDs, types, confidence scores, and failure reasons. Each page includes an `image_url` for visual reference.

## Approve Pages

```bash theme={null}
# Approve a single page
okra verify doc-abc123 --approve 7

# Bulk approve all high-confidence pages
okra verify doc-abc123 --approve-all --above 0.9
```

Approving a page marks all child nodes on that page as `verified` with confidence `1.0`.

## Flag Pages

```bash theme={null}
okra verify doc-abc123 --flag 7 --reason "table misaligned with source"
```

Flagging a page marks child nodes as `failed` with the given reason recorded in the audit trail.

## Pipe-Friendly Workflows

```bash theme={null}
# Agent workflow: approve obvious pages, review the rest
okra verify doc-abc123 --needs-review -q | \
  jq -r '.pages[] | select(.confidence > 0.9) | .page' | \
  xargs -I{} okra verify doc-abc123 --approve {} -q

# Export verification report
okra verify doc-abc123 -q > verification-report.json
```

## Options

| Flag              | Description                                     |
| ----------------- | ----------------------------------------------- |
| `--needs-review`  | Filter to pages needing review                  |
| `--failed`        | Filter to pages with failed nodes               |
| `--below <n>`     | Filter to pages with confidence below threshold |
| `--page <n>`      | Show detail for a single page                   |
| `--approve <n>`   | Approve page n                                  |
| `--approve-all`   | Bulk approve (requires `--above`)               |
| `--above <n>`     | Confidence threshold for `--approve-all`        |
| `--flag <n>`      | Flag page for review                            |
| `--reason <text>` | Reason for flagging (required with `--flag`)    |
| `-q, --quiet`     | Suppress progress messages                      |
