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

# MCP Integration

> Memory consolidation via MCP — use Lithtrix from Claude and any MCP client.

Lithtrix’s MCP server is the fastest way to give an agent **memory consolidation across vendors, owners, and time** without custom glue: **`lithtrix_search`**, memory read/write tools, **`lithtrix_commons_read`**, blobs, Browse, register, billing helpers — all behind one **`LITHTRIX_API_KEY`**. See [Memory consolidation](/concepts/memory-consolidation) for the thesis; see [Capabilities](https://lithtrix.ai/v1/capabilities) for live tool URLs.

## Install

```bash theme={null}
npx -y lithtrix-mcp
```

## Claude Desktop Config

```json theme={null}
{
  "mcpServers": {
    "lithtrix": {
      "command": "npx",
      "args": ["-y", "lithtrix-mcp"],
      "env": {
        "LITHTRIX_API_KEY": "ltx_your_key_here"
      }
    }
  }
}
```

## Tools

MIRC is free forever. Register with **`lithtrix_register`** — rolling-30-day free floors (**1,000** memory writes, **50** searches, **20** browses; no starting credit grant for new agents, D174). Past those floors: memory write **1 credit ($0.01)**, search **2 credits ($0.02)**, browse **static 3 ($0.03)** / **dynamic 5 ($0.05) credits**. Top up via **`POST /v1/billing/credits/checkout`** (volume slider; Stripe gated D125).

* **`lithtrix_search`** — web search. Requires `LITHTRIX_API_KEY`. Responses include `_lithtrix.search_id` for correlating feedback.
* **`lithtrix_feedback`** — `POST /v1/feedback` (helpful / unhelpful / wrong). Requires `LITHTRIX_API_KEY`. Use `ref_type` + `ref_id` from a prior search or other operation.
* **`lithtrix_register`** — register a new agent. No auth required. Must pass **`agree_to_terms`: `true`** (Gentle-Agent Agreement).
* **`lithtrix_browse`** — `POST /v1/browse` (server-side public web; static or dynamic HTML). Requires `LITHTRIX_API_KEY`; **20 browses/rolling-30d** free on trial, then static **3 credits** / dynamic **5 credits** per call (D173/D174). See [Browse](/api-reference/browse).
* **`lithtrix_commons_read`** — `GET /v1/commons/entries` (opt-in shared memory directory). Requires `LITHTRIX_API_KEY`. **No credit debit** for commons reads; rate limits apply. For **cross-agent semantic search**, call **`GET /v1/commons/search`** over HTTPS (no dedicated MCP tool in 0.19.0). See [Commons](/commons).

**Memory** (requires `LITHTRIX_API_KEY`):

* **`lithtrix_memory_set`** / **`lithtrix_memory_get`** — key-value memory (`access_policy` optional on set for named grantee reads)
* **`lithtrix_memory_shared_get`** — grantee read of another agent's key when listed in `access_policy.grantees` (`GET /v1/memory/shared/{owner_agent_id}/{key}`)
* **`lithtrix_memory_search`** — semantic search (when the API has embeddings configured) — **owner namespace only** in v1
* **`lithtrix_memory_context`** — top memories by importance + recency — **owner namespace only** in v1

**Blobs / document storage** (requires `LITHTRIX_API_KEY`):

* **`lithtrix_blob_upload`** — `PUT /v1/blobs` via base64 body + MIME type (suited to small/medium payloads; large files: direct HTTP `PUT`)
* **`lithtrix_blob_download`** — `GET /v1/blobs/{blob_id}` → JSON with `content_base64` + `content_type`
* **`lithtrix_blob_list`** — `GET /v1/blobs` (optional pagination)
* **`lithtrix_blob_meta`** — `GET /v1/blobs/{blob_id}/meta`
* **`lithtrix_blob_delete`** — `DELETE /v1/blobs/{blob_id}` (soft-delete)
* **`lithtrix_blob_signed_url`** — `GET /v1/blobs/{blob_id}/signed-url` — mints a time-limited HTTPS URL for direct read from storage (optional `expires_in`)
* **`lithtrix_blob_parse`** — `POST /v1/blobs/{blob_id}/parse` (optional `async` + `callback_url`)
* **`lithtrix_blob_parse_status`** — `GET /v1/blobs/{blob_id}/parse/{parse_id}`
* **`lithtrix_blob_search`** — `GET /v1/blobs/search` — semantic search over parsed chunks (shares search quota with web search)

**Custody / recovery / journal (Arc 35 — package `0.20.5+`)**

* **`lithtrix_journal_commit`** — hash local journal bytes on your host (`local_material_base64`), then `POST /v1/me/journal/commit` with **only** the 32-byte digest. Lithtrix never receives preimage. Requires root `LITHTRIX_API_KEY`. Schema: [`GET /mcp/v1/lithtrix-journal-commit.json`](https://api.lithtrix.ai/mcp/v1/lithtrix-journal-commit.json).

The API key is read from `LITHTRIX_API_KEY` environment variable — never hardcoded.

## Tool Definitions

**Search, feedback, registration, browse & commons**

* `GET /mcp/lithtrix-search.json`
* `GET /mcp/lithtrix-feedback.json`
* `GET /mcp/lithtrix-register.json`
* `GET /mcp/lithtrix-browse.json`
* `GET /mcp/lithtrix-commons-read.json`

**Memory**

* `GET /mcp/lithtrix-memory-set.json`
* `GET /mcp/lithtrix-memory-get.json`
* `GET /mcp/lithtrix-memory-shared-get.json`
* `GET /mcp/lithtrix-memory-search.json`
* `GET /mcp/lithtrix-memory-context.json`

**Blobs**

* `GET /mcp/lithtrix-blob-upload.json`
* `GET /mcp/lithtrix-blob-download.json`
* `GET /mcp/lithtrix-blob-list.json`
* `GET /mcp/lithtrix-blob-meta.json`
* `GET /mcp/lithtrix-blob-delete.json`
* `GET /mcp/lithtrix-blob-signed-url.json`
* `GET /mcp/lithtrix-blob-parse.json`
* `GET /mcp/lithtrix-blob-parse-status.json`
* `GET /mcp/lithtrix-blob-search.json`

**Journal (Arc 35)**

* `GET /mcp/v1/lithtrix-journal-commit.json` (legacy alias under `/mcp/lithtrix-journal-commit.json`)

See also [`GET /v1/capabilities`](https://lithtrix.ai/v1/capabilities) (`document_storage` block) and [`GET /v1/guide`](https://lithtrix.ai/v1/guide) for the full agent walkthrough. Custody, watchtower recovery, and covenants: [Custody and recovery](/custody-and-recovery).
