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

# Lexera Protocol: Human-in-the-Loop Legal Verification API

> Lexera routes contracts to human attorneys via MCP and returns law firm-certified artifacts. Asynchronous SSE architecture with priced verification.

The Lexera Protocol API is built on the Model Context Protocol (MCP). It gives AI agents and enterprise systems programmatic access to human-in-the-loop legal verification. The API is fully asynchronous and stateful, using a Server-Sent Events (SSE) architecture: you open a secure connection, dispatch a document, and retrieve certified artifacts once the human verification loop completes.

Pricing is per-jurisdiction and denominated in AED. Lexera automatically resolves regional aliases (for example, UAE Federal and DIFC both map to UAE) and places a temporary hold on your corporate wallet when you route a document to a specialist.

<CardGroup cols={2}>
  <Card title="Quickstart" icon="rocket" href="/quickstart">
    Run your first statutory audit in minutes.
  </Card>

  <Card title="Authentication" icon="key" href="/authentication">
    Bearer tokens, key management, and HTTPS requirements.
  </Card>

  <Card title="Execution Lifecycle" icon="arrows-rotate" href="/concepts/execution-lifecycle">
    SSE streams, session IDs, and JSON-RPC dispatch.
  </Card>

  <Card title="Tools Overview" icon="wrench" href="/tools/introduction">
    All MCP tools, invocation patterns, and auth requirements.
  </Card>
</CardGroup>

## How it works

<Steps>
  <Step title="Open an SSE stream">
    Connect to `https://lexera.dev/mcp-server/sse` with your Bearer token. The server returns a persistent stream and an `endpoint` event containing your session ID.
  </Step>

  <Step title="Dispatch a document">
    POST a JSON-RPC 2.0 payload to your session URL calling `lexera_route_to_specialist`. The server returns `HTTP 202 Accepted` and places a temporary AED hold.
  </Step>

  <Step title="Retrieve certified artifacts">
    Poll `lexera_get_order_status` over the same SSE stream. When `current_status` becomes `verified_executed`, download the law firm-certified `.docx` redline and report.
  </Step>
</Steps>

## Explore

<CardGroup cols={2}>
  <Card title="MCP Architecture" href="/concepts/mcp-architecture">
    Why Lexera uses MCP, JSON-RPC 2.0 over SSE, and async stateful design.
  </Card>

  <Card title="Wallet & Pricing" href="/concepts/wallet-and-pricing">
    AED wallet holds, per-jurisdiction tiers, and alias resolution.
  </Card>

  <Card title="Tools Overview" href="/tools/introduction">
    Reference for every MCP tool and its JSON-RPC invocation pattern.
  </Card>

  <Card title="Errors" href="/reference/errors">
    Error signatures, streamed payloads, and how to resolve them.
  </Card>
</CardGroup>
