@talonic/mcp 0.1.69 → 0.1.71
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/content.js +261 -7
- package/dist/content.js.map +1 -1
- package/dist/http-server.js +25 -1
- package/dist/http-server.js.map +1 -1
- package/dist/index.js +25 -1
- package/dist/index.js.map +1 -1
- package/dist/server.js +25 -1
- package/dist/server.js.map +1 -1
- package/package.json +1 -1
package/dist/content.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/content/seo.ts","../src/content/helpers.ts","../src/content/sections/overview.ts","../src/content/sections/install.ts","../src/content/sections/tools.ts","../src/content/sections/features.ts","../src/content/sections/configuration.ts","../src/content/sections/troubleshooting.ts","../src/content/index.ts"],"names":["sections"],"mappings":";AAGO,IAAM,gBAAA,GAAiC;AAAA,EAC5C;AAAA,IACE,EAAA,EAAI,UAAA;AAAA,IACJ,KAAA,EAAO,UAAA;AAAA,IACP,QAAA,EAAU;AAAA,MACR,EAAE,EAAA,EAAI,kBAAA,EAAoB,KAAA,EAAO,cAAA,EAAe;AAAA,MAChD,EAAE,EAAA,EAAI,SAAA,EAAW,KAAA,EAAO,cAAA,EAAe;AAAA,MACvC,EAAE,EAAA,EAAI,aAAA,EAAe,KAAA,EAAO,gBAAA;AAAiB;AAC/C,GACF;AAAA,EACA;AAAA,IACE,EAAA,EAAI,SAAA;AAAA,IACJ,KAAA,EAAO,SAAA;AAAA,IACP,QAAA,EAAU;AAAA,MACR,EAAE,EAAA,EAAI,kBAAA,EAAoB,KAAA,EAAO,UAAA,EAAW;AAAA,MAC5C,EAAE,EAAA,EAAI,gBAAA,EAAkB,KAAA,EAAO,gBAAA,EAAiB;AAAA,MAChD,EAAE,EAAA,EAAI,QAAA,EAAU,KAAA,EAAO,QAAA,EAAS;AAAA,MAChC,EAAE,EAAA,EAAI,OAAA,EAAS,KAAA,EAAO,OAAA,EAAQ;AAAA,MAC9B,EAAE,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AAAA,EACH,GAAGA,SAAAA;AAAA,EACH,GAAGA,SAAAA;AAAA,EACH,GAAGA;AACL,CAAA;AAMA,SAAS,OAAO,GAAA,EAAiC;AAC/C,EAAA,OAAO,GAAA,CAAI,GAAA,CAAI,CAAC,CAAA,KAAM;AACpB,IAAA,MAAM,EAAE,IAAA,EAAM,IAAA,KAAS,cAAA,CAAe,gBAAA,EAAkB,EAAE,IAAI,CAAA;AAC9D,IAAA,OAAO;AAAA,MACL,GAAG,CAAA;AAAA,MACH,WAAA,EAAa,iBAAA,CAAkB,gBAAA,EAAkB,CAAA,CAAE,IAAI,CAAA;AAAA,MACvD,IAAA;AAAA,MACA;AAAA,KACF;AAAA,EACF,CAAC,CAAA;AACH;AAEA,IAAI,SAAA,GAAiC,IAAA;AAErC,SAAS,cAAA,GAA+B;AACtC,EAAA,IAAI,CAAC,SAAA,EAAW;AACd,IAAA,SAAA,GAAY,OAAO,OAAO,CAAA;AAAA,EAC5B;AACA,EAAA,OAAO,SAAA;AACT;AAOO,SAAS,cAAc,IAAA,EAAiC;AAC7D,EAAA,OAAO,cAAA,GAAiB,IAAA,CAAK,CAAC,MAAM,CAAA,CAAE,IAAA,KAAS,IAAI,CAAA,IAAK,IAAA;AAC1D;AAGO,SAAS,iBAAA,GAAkC;AAChD,EAAA,OAAO,cAAA,EAAe;AACxB","file":"content.js","sourcesContent":["import type { NavSection } from \"./types\"\n\n/** MCP documentation navigation — synced to website */\nexport const MCP_NAV_SECTIONS: NavSection[] = [\n {\n id: \"overview\",\n label: \"Overview\",\n children: [\n { id: \"mcp-introduction\", label: \"Introduction\" },\n { id: \"why-mcp\", label: \"Why Use This\" },\n { id: \"get-api-key\", label: \"Get an API Key\" },\n ],\n },\n {\n id: \"install\",\n label: \"Install\",\n children: [\n { id: \"install-overview\", label: \"Overview\" },\n { id: \"claude-desktop\", label: \"Claude Desktop\" },\n { id: \"cursor\", label: \"Cursor\" },\n { id: \"cline\", label: \"Cline\" },\n { id: \"continue\", label: \"Continue\" },\n { id: \"cowork\", label: \"Cowork\" },\n ],\n },\n {\n id: \"tools\",\n label: \"Tool Reference\",\n children: [\n { id: \"talonic-extract\", label: \"talonic_extract\" },\n { id: \"talonic-search\", label: \"talonic_search\" },\n { id: \"talonic-filter\", label: \"talonic_filter\" },\n { id: \"talonic-get-document\", label: \"talonic_get_document\" },\n { id: \"talonic-to-markdown\", label: \"talonic_to_markdown\" },\n { id: \"talonic-list-schemas\", label: \"talonic_list_schemas\" },\n { id: \"talonic-save-schema\", label: \"talonic_save_schema\" },\n { id: \"talonic-get-balance\", label: \"talonic_get_balance\" },\n { id: \"talonic-request-upload\", label: \"talonic_request_upload\" },\n ],\n },\n {\n id: \"features\",\n label: \"Features\",\n children: [\n { id: \"drag-and-drop\", label: \"Drag & Drop Files\" },\n { id: \"how-it-works\", label: \"How It Works\" },\n ],\n },\n {\n id: \"configuration\",\n label: \"Configuration\",\n children: [{ id: \"env-variables\", label: \"Environment Variables\" }],\n },\n {\n id: \"troubleshooting\",\n label: \"Troubleshooting\",\n children: [\n { id: \"common-issues\", label: \"Common Issues\" },\n { id: \"known-limitations\", label: \"Known Limitations\" },\n { id: \"upgrading\", label: \"Upgrading\" },\n ],\n },\n]\n","// ---------------------------------------------------------------------------\n// Pure functions that derive breadcrumbs and prev/next from nav structure.\n// ---------------------------------------------------------------------------\n\ninterface NavChild {\n id: string\n label: string\n}\n\ninterface NavGroup {\n id: string\n label: string\n children?: NavChild[]\n}\n\nexport function deriveBreadcrumbs(\n sections: NavGroup[],\n leafId: string,\n): { label: string; slug: string }[] {\n const root = { label: \"MCP Server\", slug: \"mcp\" }\n\n for (const group of sections) {\n const child = group.children?.find((c) => c.id === leafId)\n if (child) {\n return [root, { label: group.label, slug: group.id }, { label: child.label, slug: child.id }]\n }\n }\n\n const topLevel = sections.find((s) => s.id === leafId)\n if (topLevel) {\n return [root, { label: topLevel.label, slug: topLevel.id }]\n }\n\n return [root]\n}\n\nexport function derivePrevNext(\n sections: NavGroup[],\n leafId: string,\n): { prev: { slug: string; label: string } | null; next: { slug: string; label: string } | null } {\n const flat: NavChild[] = sections.flatMap((s) => s.children ?? [{ id: s.id, label: s.label }])\n\n const idx = flat.findIndex((c) => c.id === leafId)\n if (idx === -1) return { prev: null, next: null }\n\n const prevItem = idx > 0 ? flat[idx - 1] : undefined\n const nextItem = idx < flat.length - 1 ? flat[idx + 1] : undefined\n\n return {\n prev: prevItem ? { slug: prevItem.id, label: prevItem.label } : null,\n next: nextItem ? { slug: nextItem.id, label: nextItem.label } : null,\n }\n}\n","import type { RawSection } from \"../types\"\n\nexport const sections: RawSection[] = [\n {\n slug: \"mcp-introduction\",\n parentSlug: \"overview\",\n title: \"Introduction\",\n seoTitle: \"MCP Server Introduction — Talonic Docs\",\n description:\n \"Official Talonic MCP server. Lets AI agents extract structured, schema-validated data from any document via the Model Context Protocol.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Official Talonic MCP server. Lets AI agents extract structured, schema-validated data from any document via the [Model Context Protocol](https://modelcontextprotocol.io).\",\n },\n {\n type: \"paragraph\",\n text: \"Eight tools and two resources: `talonic_extract`, `talonic_search`, `talonic_filter`, `talonic_get_document`, `talonic_to_markdown`, `talonic_list_schemas`, `talonic_save_schema`, `talonic_get_balance`, plus the `talonic://schemas` and `talonic://webhooks/reference` resources.\",\n },\n {\n type: \"paragraph\",\n text: \"Listed on the [official MCP Registry](https://registry.modelcontextprotocol.io/) as `io.github.talonicdev/talonic-mcp`. Verified end-to-end against production.\",\n },\n {\n type: \"paragraph\",\n text: \"The MCP server acts as a bridge between your AI agent and the Talonic document extraction API. Instead of writing custom HTTP integration code, agent developers get a standards-compliant MCP interface that any compatible client can discover and invoke automatically. The server handles authentication, file upload serialisation, retry logic, and structured error formatting so the agent can focus on the user's task.\",\n },\n {\n type: \"paragraph\",\n text: \"Installation takes under a minute. The recommended path is the hosted endpoint at `mcp.talonic.com` connected via Claude.ai's custom-connector flow, which uses OAuth 2.1 with PKCE and Dynamic Client Registration so no API key is pasted into config. For IDE-style clients, the local `npx` option uses a `TALONIC_API_KEY` environment variable and runs on any machine with Node.js 18 or later. A third path keeps the hosted endpoint but supplies a `Bearer tlnc_…` header for clients that do not yet handle the OAuth handshake.\",\n },\n {\n type: \"paragraph\",\n text: \"A typical agent conversation with Talonic starts when the user drops a document into the chat or asks the agent to process a file from a URL. The agent calls `talonic_extract` with a schema describing the fields to pull out, and receives structured JSON within seconds. From there, the agent can present the data, answer follow-up questions, or feed the extracted values into downstream workflows — all without the user leaving the conversation.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Quick-start: extract an invoice in one tool call\",\n code: `{\n \"file_url\": \"https://example.com/invoice.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"vendor\": { \"type\": \"string\" },\n \"total\": { \"type\": \"number\" },\n \"due_date\": { \"type\": \"string\", \"format\": \"date\" }\n },\n \"required\": [\"vendor\", \"total\"]\n }\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Response: structured data with confidence\",\n code: `{\n \"status\": \"complete\",\n \"data\": {\n \"vendor\": \"Acme Corp\",\n \"total\": 2450.00,\n \"due_date\": \"2026-07-01\"\n },\n \"confidence\": {\n \"overall\": 0.96,\n \"fields\": { \"vendor\": 0.98, \"total\": 0.99, \"due_date\": 0.94 }\n }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"The MCP server supports every major AI coding and chat client: Claude Desktop, Cursor, Cline, Continue, and Cowork. Each client has its own config format, but the setup pattern is the same — add a JSON entry pointing to the Talonic server (hosted URL or local npx command), supply your API key, and restart the client. The server then registers its tools and resources, which the agent can discover and invoke automatically during conversations.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"The MCP server is open-source and published to npm as `@talonic/mcp`. You can inspect the source, report issues, and contribute on GitHub.\",\n },\n ],\n related: [\n { label: \"Why Use This\", slug: \"why-mcp\" },\n { label: \"Claude Desktop\", slug: \"claude-desktop\" },\n { label: \"Node SDK\", slug: \"introduction\" },\n ],\n faq: [\n {\n question: \"What is the Talonic MCP server?\",\n answer:\n \"An official MCP server that gives AI agents (Claude Desktop, Cursor, Cline, etc.) the ability to extract structured data from documents using the Model Context Protocol.\",\n },\n {\n question: \"Is the Talonic MCP server on the official MCP Registry?\",\n answer:\n \"Yes. It is listed as io.github.talonicdev/talonic-mcp on registry.modelcontextprotocol.io, maintained by Anthropic and the MCP steering group.\",\n },\n {\n question: \"Do I need to install anything to use the Talonic MCP server?\",\n answer:\n \"Not necessarily. The hosted server at mcp.talonic.com requires zero local installation — just a URL and API key in your MCP client config. Alternatively, the local npx option requires Node.js 18+.\",\n },\n {\n question: \"What document types does the Talonic MCP server support?\",\n answer:\n \"The server supports PDF, PNG, JPG, TIFF, DOCX, XLSX, and other common document formats. Documents can be invoices, contracts, receipts, forms, certificates, or any structured or semi-structured document. The extraction pipeline handles OCR, layout analysis, and field extraction server-side.\",\n },\n {\n question: \"How many tools does the Talonic MCP server expose?\",\n answer:\n \"Eight tools and two resources. The tools are talonic_extract, talonic_search, talonic_filter, talonic_get_document, talonic_to_markdown, talonic_list_schemas, talonic_save_schema, and talonic_get_balance. The resources are talonic://schemas and talonic://webhooks/reference.\",\n },\n ],\n mentions: [\"MCP\", \"Model Context Protocol\", \"AI agents\", \"document extraction\"],\n },\n {\n slug: \"why-mcp\",\n parentSlug: \"overview\",\n title: \"Why Use This\",\n seoTitle: \"Why Talonic MCP — Talonic Docs\",\n description:\n \"Why AI agents should use the Talonic MCP server instead of raw OCR plus LLM calls for document extraction.\",\n content: [\n {\n type: \"paragraph\",\n text: \"When an agent needs to pull structured data out of a PDF, scan, image, or messy document, the usual approach is raw OCR plus an LLM call. Results are unreliable; tables get mangled, dates get misread, totals drift.\",\n },\n {\n type: \"paragraph\",\n text: \"With this MCP server installed, the agent has a `talonic_extract` tool that returns schema-validated JSON with per-field confidence scores, a detected document type, and stable IDs for follow-up calls. Seven other tools cover the rest of the workflow: searching the workspace, filtering by extracted field values, fetching a document's metadata, getting OCR markdown, listing saved schemas, saving new ones, and reading the workspace credit balance for budget-aware behaviour.\",\n },\n {\n type: \"paragraph\",\n text: \"The extraction pipeline runs server-side on Talonic's infrastructure, which means the agent does not need to manage OCR libraries, prompt engineering for data extraction, or post-processing heuristics. A single tool call replaces what would otherwise be a multi-step chain of OCR, schema validation, and confidence estimation inside the agent's own context window.\",\n },\n {\n type: \"paragraph\",\n text: \"Because each extraction returns **per-field confidence scores**, agents can make informed decisions about when to trust extracted values and when to escalate to the user for review. This is especially valuable for high-stakes fields like financial amounts, legal terms, and dates where silent errors are costly.\",\n },\n {\n type: \"paragraph\",\n text: \"Integration effort is minimal compared to building a custom extraction pipeline. A raw OCR + LLM approach requires choosing an OCR library, writing prompts for each document type, parsing unstructured LLM output into typed fields, implementing confidence estimation, and handling edge cases like rotated pages, multi-column layouts, and mixed languages. The Talonic MCP server replaces all of that with a single tool call that returns clean, validated JSON.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent conversation: comparing raw OCR vs Talonic\",\n code: `// Without Talonic — agent must chain multiple steps:\n// 1. OCR the PDF → raw text with layout errors\n// 2. Prompt LLM to extract fields → unstructured output\n// 3. Parse LLM output → fragile regex/JSON parsing\n// 4. Validate types → manual type coercion\n// 5. Estimate confidence → no signal available\n\n// With Talonic — single tool call:\n{\n \"file_url\": \"https://example.com/contract.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"parties\": { \"type\": \"array\", \"items\": { \"type\": \"string\" } },\n \"effective_date\": { \"type\": \"string\", \"format\": \"date\" },\n \"term_months\": { \"type\": \"integer\" },\n \"governing_law\": { \"type\": \"string\" }\n }\n }\n}\n// → Returns validated JSON + confidence scores in ~3 seconds`,\n },\n {\n type: \"paragraph\",\n text: \"The workspace model is another key advantage. Every document processed through the MCP server is stored in your Talonic workspace with a stable `document_id`. This means an agent can extract an invoice today, and a week later the user can ask 'what was the total on that Meridian invoice?' — the agent searches the workspace, finds the document, and retrieves the previously extracted data without re-uploading or re-processing. This persistent workspace turns the MCP server from a one-shot tool into a long-term document intelligence layer.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Every document processed through the MCP server is stored in your Talonic workspace with a stable `document_id`. Subsequent operations — re-extraction with a different schema, markdown retrieval, metadata lookup — reuse that ID without re-uploading the file, saving both time and credits.\",\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"Get an API Key\", slug: \"get-api-key\" },\n ],\n faq: [\n {\n question: \"Why use Talonic MCP instead of OCR + LLM?\",\n answer:\n \"Raw OCR + LLM calls produce unreliable results — mangled tables, misread dates, drifting totals. Talonic returns schema-validated JSON with per-field confidence scores and stable IDs for follow-up calls.\",\n },\n {\n question: \"Does the MCP server handle retries and errors automatically?\",\n answer:\n \"Yes. The server retries on transient failures (429 rate limits, 5xx server errors) and returns structured error messages the agent can reason about, rather than raw HTTP status codes.\",\n },\n {\n question: \"Can I re-extract a document with a different schema without re-uploading?\",\n answer:\n \"Yes. Pass the document_id from a previous extraction to talonic_extract with a new schema. The server reuses the already-ingested document, which is faster and costs fewer credits.\",\n },\n {\n question: \"What confidence scores does Talonic provide?\",\n answer:\n \"Every extraction includes confidence.overall (0 to 1) and confidence.fields with a per-field score. Agents can use these to decide when to trust values automatically and when to escalate to the user for review. Scores above 0.9 are highly reliable; below 0.7 warrants human verification.\",\n },\n {\n question: \"How does Talonic handle multi-language documents?\",\n answer:\n \"The extraction pipeline auto-detects the document language and returns it in the language_detected field. OCR and field extraction work across Latin, Cyrillic, CJK, and Arabic scripts. No language configuration is needed — the server handles detection and adaptation automatically.\",\n },\n ],\n mentions: [\"OCR\", \"schema-validated\", \"confidence scores\", \"structured data\"],\n },\n {\n slug: \"agent-decision-guide\",\n parentSlug: \"overview\",\n title: \"Agent Decision Guide\",\n seoTitle: \"Agent Decision Guide — Talonic MCP\",\n description:\n \"How an AI agent should pick between Talonic's tools, handle low-confidence results, and avoid unnecessary calls.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Use this guide to pick the right Talonic tool for the user's request. Match the user's intent to one of the scenarios below before calling a tool. The wrong tool returns the wrong data, costs unnecessary credits, and slows the conversation.\",\n },\n {\n type: \"paragraph\",\n text: \"The nine tools are designed for distinct use cases with minimal overlap. **`talonic_extract`** is for structured field extraction with a schema, **`talonic_request_upload`** hands the user a browser link for files too large to pass through a hosted connector (Claude.ai), **`talonic_to_markdown`** is for full-text conversion, **`talonic_search`** handles fuzzy discovery, **`talonic_filter`** handles precise field-value queries, **`talonic_get_document`** returns metadata, the schema tools (**`talonic_list_schemas`**, **`talonic_save_schema`**) manage reusable extraction templates, and **`talonic_get_balance`** lets the agent check the workspace credit balance before kicking off large batches.\",\n },\n {\n type: \"paragraph\",\n text: \"A well-built agent should check conversation history before making any tool call. If the user already extracted data from a document in an earlier turn, re-use that result rather than calling `talonic_extract` again. Repeat calls cost credits and add latency without providing new information.\",\n },\n {\n type: \"paragraph\",\n text: \"When in doubt about which tool to use, consider the user's underlying intent: do they want specific field values (extract), the full document text (to_markdown), to find documents (search/filter), or to manage extraction templates (schema tools)? This mental model covers every scenario.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"decide-extract-vs-markdown\",\n text: \"User has a file (or just dropped one in)\",\n },\n {\n type: \"list\",\n items: [\n \"**They want specific fields**: vendor, total, dates, parties, line items. Use `talonic_extract` with a `schema` (full JSON Schema is most reliable) or a `schema_id` from `talonic_list_schemas`. Don't know the fields yet? Set `auto_schema: true` for open capture — Talonic discovers them and returns a suggested schema to refine.\",\n \"**They want the full text content**, e.g. for summarisation, translation, or general analysis. Use `talonic_to_markdown`. It returns OCR-converted markdown without forcing a schema.\",\n \"**They want both**: extract once with a schema (which also yields markdown when `include_markdown: true` is set), avoiding two uploads.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"decide-find-existing\",\n text: \"User is asking about existing documents in the workspace\",\n },\n {\n type: \"list\",\n items: [\n \"**Conceptual or fuzzy** (e.g. 'do I have any docs about indemnification?', 'find Acme contracts'): use `talonic_search`.\",\n \"**Value-based on extracted fields** (e.g. 'invoices over 1000 EUR', 'contracts expiring before 2026-12-31'): use `talonic_filter`. Use `is_not_empty` for presence checks and `is_empty` for absence checks.\",\n \"**They reference a specific document_id**: use `talonic_get_document` for metadata, `talonic_to_markdown` (with `document_id`) for text, or `talonic_extract` (with `document_id`) to re-extract with a new schema. Re-using a document_id is cheaper than re-uploading.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"decide-schema-mgmt\",\n text: \"User is working with schemas\",\n },\n {\n type: \"list\",\n items: [\n \"**One-off extraction**: pass the schema inline on `talonic_extract`. Do not save it.\",\n \"**The same schema across many documents**: call `talonic_save_schema` once, then pass the returned id (UUID or `SCH-XXXXXXXX`) as `schema_id` on every future `talonic_extract` call. Either id form is accepted.\",\n \"**Discovering existing schemas** before designing a new one: call `talonic_list_schemas`. The `talonic://schemas` resource is the same list rendered as a browseable resource for clients that support it.\",\n \"**Avoid clutter**: do not save a schema until the user has reviewed and confirmed the design. Iterate inline first.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"decide-confidence\",\n text: \"Handling confidence and human review\",\n },\n {\n type: \"paragraph\",\n text: \"Every `talonic_extract` response includes `confidence.overall` (0..1) and `confidence.fields` (per-field 0..1). Use these to decide when to escalate.\",\n },\n {\n type: \"list\",\n items: [\n \"**`confidence.overall` below ~0.7**: tell the user the extraction may be unreliable, show the top low-confidence fields, and ask them to confirm before taking any downstream action (payment, contract execution, data import).\",\n \"**Per-field confidence below ~0.7**: surface those fields with a 'needs review' marker. Do not silently use them in calculations or external API calls.\",\n \"**Critical fields at any confidence**: financial amounts, legal terms, names, dates. Always confirm with the user before acting on them, even at high confidence.\",\n \"**Provenance is not surfaced in v0.1.** Per-field source page or bounding box is not in the response. If the user needs to verify a specific field against the source, send them to the document via `links.dashboard` from the response.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"decide-not-call\",\n text: \"When not to call Talonic\",\n },\n {\n type: \"list\",\n items: [\n \"**The user's question is general knowledge or conversation.** Do not pre-emptively extract or search.\",\n \"**The needed data is already in conversation history** from a previous tool call. Re-use it. Repeat calls cost credits and slow the response.\",\n \"**The user wants to discuss or revise** an extraction you already produced. Reason over the previous result instead of re-extracting.\",\n \"**Schema design iteration**. Iterate the schema with the user via `talonic_extract` with an inline schema; only call `talonic_save_schema` once they confirm.\",\n \"**Cost, EUR price, and remaining credit balance are not surfaced in v0.1 tool responses.** If the user asks 'how much will this cost' or 'how many credits do I have left', point them to the Talonic dashboard at https://app.talonic.com.\",\n ],\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"talonic_filter\", slug: \"talonic-filter\" },\n { label: \"talonic_search\", slug: \"talonic-search\" },\n { label: \"Known Limitations\", slug: \"known-limitations\" },\n ],\n faq: [\n {\n question: \"When should an agent use talonic_extract vs talonic_to_markdown?\",\n answer:\n \"Use talonic_extract when the user wants specific structured fields (with a schema). Use talonic_to_markdown when the user wants the full text content for summarisation or analysis without a schema.\",\n },\n {\n question: \"When should an agent use talonic_search vs talonic_filter?\",\n answer:\n \"Use talonic_search for conceptual or fuzzy queries across the workspace. Use talonic_filter when the user wants documents matching specific structured field values like 'invoices over 1000 EUR'.\",\n },\n {\n question: \"How should an agent handle low-confidence extractions?\",\n answer:\n \"Treat confidence below ~0.7 as needing human review. Surface low-confidence fields explicitly and confirm critical fields (amounts, dates, names) with the user before any downstream action.\",\n },\n ],\n mentions: [\"decision guide\", \"agent\", \"tool selection\", \"confidence\", \"human review\", \"cost\"],\n },\n {\n slug: \"get-api-key\",\n parentSlug: \"overview\",\n title: \"Get an API Key\",\n seoTitle: \"Get an API Key — Talonic MCP\",\n description:\n \"Get a Talonic API key in 30 seconds. Each user runs against their own isolated workspace with private documents and schemas.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Each user runs against their own isolated Talonic workspace. Your documents and schemas are private to you.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"If you are connecting from Claude.ai's custom-connector flow, you can skip the API-key steps below. The connector launches an OAuth 2.1 sign-in to `app.talonic.com` and the MCP server then uses a short-lived bearer token on your behalf. Get an API key when you want to install locally via `npx`, drive the hosted endpoint from a custom-header client, or use the Node SDK.\",\n },\n {\n type: \"list\",\n ordered: true,\n items: [\n \"Sign up at [app.talonic.com](https://app.talonic.com). Free tier: 50 extractions per day, no credit card.\",\n \"Settings → API Keys → Create New Key.\",\n \"Copy the `tlnc_` value into your MCP client config (snippets below).\",\n ],\n },\n {\n type: \"paragraph\",\n text: \"The API key authenticates every tool call the MCP server makes on your behalf. It is passed as a `TALONIC_API_KEY` environment variable in the local `npx` setup, or as a `Bearer` token in the `Authorization` header for the hosted server. The key is never sent to the AI agent itself — it stays within the MCP server process.\",\n },\n {\n type: \"paragraph\",\n text: \"Keep your API key private. Do not commit it to version control or share it in public MCP config examples. If a key is compromised, revoke it immediately in the Talonic dashboard under Settings → API Keys and generate a new one.\",\n },\n {\n type: \"paragraph\",\n text: \"The free tier includes 50 extractions per day, which is enough for development and testing. For production workloads or higher volume, upgrade your plan in the Talonic dashboard. All plans share the same API — the key determines your rate limits and quota.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Local npx config with API key\",\n code: `{\n \"mcpServers\": {\n \"talonic\": {\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": {\n \"TALONIC_API_KEY\": \"tlnc_your_key_here\"\n }\n }\n }\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Hosted config with API key as Bearer token\",\n code: `{\n \"mcpServers\": {\n \"talonic\": {\n \"url\": \"https://mcp.talonic.com/mcp\",\n \"headers\": {\n \"Authorization\": \"Bearer tlnc_your_key_here\"\n }\n }\n }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"After adding your API key to the config, verify the connection by asking your agent to call `talonic_list_schemas`. If the key is valid, the tool returns your saved schemas (or an empty list if you have not saved any yet). If the key is invalid or missing, the server returns a clear authentication error that tells the agent the key needs to be checked. This is the fastest way to confirm your setup is working end-to-end.\",\n },\n {\n type: \"paragraph\",\n text: \"Each API key is scoped to a single workspace. If you work across multiple Talonic workspaces — for example, separate environments for development and production — you will need a different API key for each. You can create multiple keys within the same workspace for different team members or applications, and revoke them independently without affecting other keys.\",\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: \"Never hardcode your `tlnc_` key in source code or share it in screenshots. Use environment variables or your MCP client's config file, which is typically stored in a user-specific directory.\",\n },\n ],\n related: [\n { label: \"Claude Desktop\", slug: \"claude-desktop\" },\n { label: \"Install Overview\", slug: \"install-overview\" },\n ],\n faq: [\n {\n question: \"How do I get a Talonic API key for MCP?\",\n answer:\n \"Sign up at app.talonic.com (free, no credit card), go to Settings > API Keys > Create New Key, and copy the tlnc_ value into your MCP client config.\",\n },\n {\n question: \"Is the free tier enough for development?\",\n answer:\n \"Yes. The free tier includes 50 extractions per day with no credit card required, which is sufficient for development and testing. Upgrade in the dashboard for production workloads.\",\n },\n {\n question: \"What should I do if my API key is compromised?\",\n answer:\n \"Revoke it immediately in the Talonic dashboard under Settings > API Keys, then generate a new one. Update your MCP client config with the new key and restart the client.\",\n },\n {\n question: \"Can I use the same API key across multiple MCP clients?\",\n answer:\n \"Yes. The same tlnc_ key works in Claude Desktop, Cursor, Cline, Continue, Cowork, or any other MCP client simultaneously. The key is tied to your workspace, not to a specific client. Rate limits apply per-key across all clients.\",\n },\n {\n question: \"How do I verify my API key is working?\",\n answer:\n \"After configuring your MCP client, ask the agent to call talonic_list_schemas. A successful response (even an empty list) confirms the key is valid and the server is connected. An authentication error means the key is missing, malformed, or revoked.\",\n },\n ],\n mentions: [\"API key\", \"tlnc_\", \"free tier\"],\n },\n]\n","import type { RawSection } from \"../types\"\n\nconst MCP_HOSTED_SNIPPET = `{\n \"mcpServers\": {\n \"talonic\": {\n \"url\": \"https://mcp.talonic.com/mcp\",\n \"headers\": {\n \"Authorization\": \"Bearer tlnc_your_key_here\"\n }\n }\n }\n}`\n\nconst MCP_CONFIG_SNIPPET = `{\n \"mcpServers\": {\n \"talonic\": {\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": {\n \"TALONIC_API_KEY\": \"tlnc_your_key_here\"\n }\n }\n }\n}`\n\nexport const sections: RawSection[] = [\n {\n slug: \"install-overview\",\n parentSlug: \"install\",\n title: \"Install Overview\",\n seoTitle: \"Install Talonic MCP — Talonic Docs\",\n description:\n \"Install the Talonic MCP server with a one-line npx invocation. No clone, no build. Works with every MCP client.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Three ways to connect. The recommended path for Claude.ai users is the hosted MCP via the **OAuth connector flow**: paste one URL into Claude.ai's connector settings, sign in with your Talonic account, approve the consent screen. No API key in your config, ever. For IDE-style clients (Cursor, Cline, Continue, Cowork) and Claude Desktop, the local `npx` install is the canonical path. A third hosted option, with the Talonic API key in an `Authorization` header, exists for clients that support custom headers on remote MCP servers.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"hosted-claude-ai\",\n text: \"Hosted via Claude.ai connector (OAuth, recommended)\",\n },\n {\n type: \"paragraph\",\n text: \"Claude.ai's `Add custom connector` flow does the OAuth 2.1 handshake for you. The MCP server lives at `https://mcp.talonic.com/mcp`; Claude.ai discovers the authorization server, registers itself dynamically (RFC 7591), and runs the PKCE authorization-code flow. The resulting access token is stored by Claude.ai and refreshed automatically (1-hour access token, 30-day refresh).\",\n },\n {\n type: \"list\",\n ordered: true,\n items: [\n \"Open `https://claude.ai/settings/connectors`.\",\n \"Click **Add custom connector**.\",\n \"URL: `https://mcp.talonic.com/mcp` — no query string, no headers.\",\n \"Click **Connect**. You are redirected to Talonic to sign in.\",\n \"Sign in with Google, Microsoft, or your company SSO.\",\n \"Approve the consent screen. The requested scopes are `extract:write`, `documents:read`, and `schemas:read`. Pick a workspace if you have multiple.\",\n \"You are returned to Claude.ai with the connector live. All nine tools are available in any new conversation.\",\n ],\n },\n {\n type: \"paragraph\",\n text: \"No API key appears in the connector config or in any URL the browser navigates to. To revoke access, remove the connector in Claude.ai or revoke the OAuth client from your Talonic dashboard. Your tools and tokens are scoped to the workspace you picked at consent time.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"local-npx\",\n text: \"Local stdio (npx)\",\n },\n {\n type: \"paragraph\",\n text: \"Recommended for IDE-style clients (Cursor, Cline, Continue, Cowork) and Claude Desktop, where the MCP host spawns the server as a local child process. Requires Node.js 18+. Your API key lives in the client's `env` block.\",\n },\n {\n type: \"code\",\n language: \"jsonc\",\n title: \"Local config\",\n code: `{\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": { \"TALONIC_API_KEY\": \"tlnc_...\" }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"The `-y` flag skips the npm install prompt. Pinning to `@latest` means new versions are picked up on the next client restart. For production deployments and CI, pin to a specific version (e.g. `@talonic/mcp@0.1.27`) so a future release cannot silently change tool descriptions, validation rules, or response shapes.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"hosted-bearer\",\n text: \"Hosted with a Bearer header (custom-header clients)\",\n },\n {\n type: \"paragraph\",\n text: \"For MCP clients that support remote servers with custom headers (mcp-inspector, custom integrations), connect to the hosted endpoint with the API key in an `Authorization` header. Claude.ai's connector UI does not currently support custom headers, which is why the OAuth flow above is the recommended path for Claude.ai users.\",\n },\n {\n type: \"code\",\n language: \"jsonc\",\n title: \"Hosted config (custom-header clients)\",\n code: `{\n \"url\": \"https://mcp.talonic.com/mcp\",\n \"headers\": { \"Authorization\": \"Bearer tlnc_...\" }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"All three install paths expose the same nine tools and two resources. The hosted server runs the latest version of `@talonic/mcp` automatically; the local `npx` install picks up the latest version on next client restart when pinned to `@latest`.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"verify-install\",\n text: \"Verify the connection\",\n },\n {\n type: \"paragraph\",\n text: \"After adding the config and restarting your MCP client, verify the connection by asking the agent to list your schemas. This is a lightweight read-only call that confirms the API key is valid and the server is reachable. If the call succeeds, all nine tools are ready to use.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Verification: ask the agent to call talonic_list_schemas\",\n code: `// Agent sends:\n{ }\n\n// Server responds (empty workspace):\n{\n \"schemas\": []\n}\n\n// Server responds (workspace with saved schemas):\n{\n \"schemas\": [\n {\n \"id\": \"sch_7a1b...\",\n \"short_id\": \"SCH-A1B2C3D4\",\n \"name\": \"Standard Invoice\",\n \"field_count\": 6\n }\n ]\n}`,\n },\n {\n type: \"paragraph\",\n text: \"If the verification fails, check three things in order: (1) your JSON config is syntactically valid — a missing comma or bracket is the most common cause, (2) the API key starts with `tlnc_` and has not been revoked, and (3) you fully restarted the MCP client after editing the config. For the local npx option, you can also test the server standalone by running `npx -y @talonic/mcp@latest --version` in a terminal to confirm it installs and prints a version number.\",\n },\n {\n type: \"paragraph\",\n text: \"The hosted and local options can be swapped at any time by editing your config. Some developers start with the hosted option for quick setup and switch to local npx when they need offline access or want to inspect server logs. The tools, parameters, and responses are identical regardless of which option you choose, so no agent-side changes are needed when switching.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"If you are behind a corporate proxy or firewall that blocks outbound HTTPS to `mcp.talonic.com`, use the local `npx` option and configure your proxy via standard `HTTPS_PROXY` environment variables.\",\n },\n ],\n related: [\n { label: \"Claude Desktop\", slug: \"claude-desktop\" },\n { label: \"Cursor\", slug: \"cursor\" },\n ],\n faq: [\n {\n question: \"How do I install the Talonic MCP server?\",\n answer:\n \"Use the hosted server at mcp.talonic.com/mcp — just set the URL and your API key in any MCP client config. No install needed. Alternatively, run locally via npx @talonic/mcp.\",\n },\n {\n question: \"What is the difference between hosted and local MCP server?\",\n answer:\n \"Both expose the same tools and resource. Hosted requires zero local dependencies and auto-updates. Local runs on your machine via npx and requires Node.js 18+. Latency is comparable since both call the same API.\",\n },\n {\n question: \"Do I need to update the MCP server manually?\",\n answer:\n \"With the hosted server, updates are automatic. With the local npx option, pinning to @latest means new versions are fetched on the next client restart.\",\n },\n {\n question: \"Can I switch between hosted and local without changing my workflow?\",\n answer:\n \"Yes. Both options expose identical tools, parameters, and responses. Edit the config to swap between hosted URL and local npx command, restart the client, and everything works the same. No agent-side or schema changes needed.\",\n },\n {\n question: \"What Node.js version do I need for the local option?\",\n answer:\n \"Node.js 18 or later. The npx command downloads and runs the MCP server package automatically. No global install is needed — npx handles it. Run node --version in a terminal to check your version.\",\n },\n ],\n mentions: [\"npx\", \"npm\", \"MCP client\", \"install\"],\n },\n {\n slug: \"claude-desktop\",\n parentSlug: \"install\",\n title: \"Claude Desktop\",\n seoTitle: \"Claude Desktop Setup — Talonic MCP\",\n description: \"Configure the Talonic MCP server in Claude Desktop on macOS and Windows.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Edit `~/Library/Application Support/Claude/claude_desktop_config.json` (macOS) or `%APPDATA%\\\\Claude\\\\claude_desktop_config.json` (Windows).\",\n },\n { type: \"heading\", level: 3, id: \"claude-desktop-hosted\", text: \"Hosted (recommended)\" },\n { type: \"code\", language: \"json\", code: MCP_HOSTED_SNIPPET },\n { type: \"heading\", level: 3, id: \"claude-desktop-local\", text: \"Local (npx)\" },\n { type: \"code\", language: \"json\", code: MCP_CONFIG_SNIPPET },\n {\n type: \"paragraph\",\n text: \"Fully restart Claude Desktop (Cmd+Q on macOS, not just close the window). Talonic appears in the connected servers list with all nine tools.\",\n },\n {\n type: \"paragraph\",\n text: \"Claude Desktop is the most popular MCP client for Talonic. It natively supports drag-and-drop file uploads, which pairs well with `talonic_extract` via the `file_data` parameter. When you drop a PDF into the chat, Claude automatically base64-encodes it and passes it to the MCP tool.\",\n },\n {\n type: \"paragraph\",\n text: \"After connecting, you can verify the setup by asking Claude to list your schemas (`talonic_list_schemas`) or extract data from a sample document. If the tools do not appear, check that your JSON is valid and the config file is in the correct directory for your operating system.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"claude-desktop-verify\",\n text: \"Verify the connection\",\n },\n {\n type: \"paragraph\",\n text: \"After restarting Claude Desktop, open a new conversation and ask Claude to list your schemas. A successful response confirms the MCP server is connected and your API key is valid. You should see the Talonic tools in the connected servers panel on the left side of the Claude Desktop window.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Verification prompt and expected response\",\n code: `// Ask Claude: \"List my Talonic schemas\"\n// Claude calls talonic_list_schemas with: {}\n\n// Expected response (new workspace):\n{\n \"schemas\": []\n}\n\n// If the key is invalid, you will see:\n{\n \"error\": \"authentication_error\",\n \"message\": \"Invalid or revoked API key. Check TALONIC_API_KEY in your config.\"\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Claude Desktop is the recommended client for document-heavy workflows because of its native file handling. When you drop a file into the chat, Claude reads the file bytes, base64-encodes them, and passes them to `talonic_extract` or `talonic_to_markdown` via the `file_data` parameter. This means you can go from a physical document scan to structured JSON in under ten seconds — drop the file, Claude picks the right tool, and the extracted data appears in the conversation.\",\n },\n {\n type: \"paragraph\",\n text: \"For multi-document workflows, Claude Desktop maintains conversation context across tool calls. You can extract data from several invoices in sequence, and Claude remembers all previous results. Ask follow-up questions like 'which of those invoices had the highest total?' and Claude reasons over the extracted data without re-calling the tools. This makes Claude Desktop particularly effective for batch review and comparison tasks.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Claude Desktop also renders the `talonic://schemas` resource in its UI, letting you browse saved schemas without making a tool call.\",\n },\n ],\n related: [\n { label: \"Cursor\", slug: \"cursor\" },\n { label: \"Tool Reference\", slug: \"talonic-extract\" },\n ],\n faq: [\n {\n question: \"How do I add Talonic to Claude Desktop?\",\n answer:\n \"Edit claude_desktop_config.json, add the Talonic MCP server config with your API key, and fully restart Claude Desktop (Cmd+Q on macOS).\",\n },\n {\n question: \"Why don't Talonic tools appear after adding the config?\",\n answer:\n \"Make sure you fully restart Claude Desktop (Cmd+Q, not just close the window). Also verify your JSON syntax is valid and the config file is in the correct directory for your OS.\",\n },\n {\n question: \"Does Claude Desktop support drag-and-drop with Talonic?\",\n answer:\n \"Yes. Claude Desktop natively supports drag-and-drop file uploads. When you drop a PDF, Claude base64-encodes it and passes it to talonic_extract via the file_data parameter.\",\n },\n {\n question: \"Where is the Claude Desktop config file on macOS vs Windows?\",\n answer:\n \"On macOS: ~/Library/Application Support/Claude/claude_desktop_config.json. On Windows: %APPDATA%\\\\Claude\\\\claude_desktop_config.json. Create the file if it does not exist. The directory must already exist — Claude Desktop creates it on first launch.\",\n },\n {\n question: \"Can I use both hosted and local Talonic in Claude Desktop?\",\n answer:\n \"You can configure either option, but not both simultaneously under the same server name. Choose hosted for zero-dependency setup or local npx for offline access. Switch by editing the config and restarting Claude Desktop.\",\n },\n ],\n mentions: [\"Claude Desktop\", \"macOS\", \"Windows\"],\n },\n {\n slug: \"cursor\",\n parentSlug: \"install\",\n title: \"Cursor\",\n seoTitle: \"Cursor Setup — Talonic MCP\",\n description: \"Configure the Talonic MCP server in Cursor IDE.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Edit `~/.cursor/mcp.json` (or open Cursor settings → MCP → edit config):\",\n },\n { type: \"heading\", level: 3, id: \"cursor-hosted\", text: \"Hosted (recommended)\" },\n { type: \"code\", language: \"json\", code: MCP_HOSTED_SNIPPET },\n { type: \"heading\", level: 3, id: \"cursor-local\", text: \"Local (npx)\" },\n { type: \"code\", language: \"json\", code: MCP_CONFIG_SNIPPET },\n {\n type: \"paragraph\",\n text: \"After saving the config, restart Cursor or reload the window. The Talonic tools appear in the MCP tool list and can be invoked from Cursor's AI chat panel. Cursor's agent mode is particularly effective with Talonic because it can read local files from your project and pass them directly to `talonic_extract` via `file_path`.\",\n },\n {\n type: \"paragraph\",\n text: \"A common Cursor workflow is extracting data from documents within a codebase — for example, parsing specification PDFs, extracting configuration from scanned documents, or converting legacy documentation to structured data. The `file_path` input works directly with paths relative to your Cursor workspace.\",\n },\n {\n type: \"paragraph\",\n text: \"Cursor caches MCP tool descriptions between sessions. If you upgrade the MCP server and notice outdated tool descriptions, restart Cursor to force a refresh of the tool metadata.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"cursor-workflow-example\",\n text: \"Example: extracting from a project file\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent extracts data from a spec PDF in the workspace\",\n code: `// User: \"Extract the requirements from docs/product-spec.pdf\"\n// Cursor agent calls talonic_extract with:\n{\n \"file_path\": \"./docs/product-spec.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"title\": { \"type\": \"string\" },\n \"requirements\": {\n \"type\": \"array\",\n \"items\": {\n \"type\": \"object\",\n \"properties\": {\n \"id\": { \"type\": \"string\" },\n \"description\": { \"type\": \"string\" },\n \"priority\": { \"type\": \"string\" }\n }\n }\n },\n \"deadline\": { \"type\": \"string\", \"format\": \"date\" }\n }\n }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Cursor's composer mode is particularly powerful with Talonic because the agent can extract data from a document and immediately use it to generate code. For example, you can ask Cursor to extract fields from an API specification PDF and then generate TypeScript interfaces matching the extracted schema. The agent chains `talonic_extract` with code generation in a single turn, eliminating manual data entry.\",\n },\n {\n type: \"paragraph\",\n text: \"When using the hosted MCP option in Cursor, the connection is established over HTTPS with no local process. This means Cursor starts faster and there is no Node.js dependency. For teams sharing a Cursor workspace configuration, the hosted option is simpler to standardise because every developer only needs an API key — no local Node.js version management needed.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Cursor supports both the hosted and local MCP options. The hosted option is simpler since Cursor can connect directly via HTTPS without spawning a local process.\",\n },\n ],\n related: [\n { label: \"Claude Desktop\", slug: \"claude-desktop\" },\n { label: \"Cline\", slug: \"cline\" },\n ],\n faq: [\n {\n question: \"How do I add Talonic MCP to Cursor?\",\n answer: \"Edit ~/.cursor/mcp.json and add the Talonic MCP server config with your API key.\",\n },\n {\n question: \"Can Cursor read local files for extraction?\",\n answer:\n \"Yes. Cursor's agent mode can read files from your project and pass them to talonic_extract via the file_path parameter, making it easy to extract data from documents within your codebase.\",\n },\n {\n question: \"Why are Talonic tool descriptions outdated in Cursor?\",\n answer:\n \"Cursor caches MCP tool descriptions between sessions. Restart Cursor to force a refresh after upgrading the MCP server.\",\n },\n {\n question: \"Can Cursor chain extraction with code generation?\",\n answer:\n \"Yes. In composer mode, Cursor can extract data from a document and immediately use the results to generate code — for example, extracting fields from an API spec PDF and generating TypeScript interfaces. The agent handles both steps in a single turn.\",\n },\n ],\n mentions: [\"Cursor\", \"IDE\"],\n },\n {\n slug: \"cline\",\n parentSlug: \"install\",\n title: \"Cline\",\n seoTitle: \"Cline Setup — Talonic MCP\",\n description: \"Configure the Talonic MCP server in the Cline VS Code extension.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Open the Cline panel → settings (gear icon) → MCP Servers → Edit. Save and restart the panel.\",\n },\n { type: \"heading\", level: 3, id: \"cline-hosted\", text: \"Hosted (recommended)\" },\n { type: \"code\", language: \"json\", code: MCP_HOSTED_SNIPPET },\n { type: \"heading\", level: 3, id: \"cline-local\", text: \"Local (npx)\" },\n { type: \"code\", language: \"json\", code: MCP_CONFIG_SNIPPET },\n {\n type: \"paragraph\",\n text: \"Cline runs inside VS Code and communicates with MCP servers over stdio (local) or HTTP (hosted). After adding the config, the Talonic tools become available in Cline's autonomous agent mode, where it can chain multiple tool calls without manual approval for each step.\",\n },\n {\n type: \"paragraph\",\n text: \"Cline's auto-approval feature works well with Talonic workflows. For example, the agent can search for documents, filter results, and extract data from the top match in a single turn. Configure Cline's auto-approve settings to control which Talonic tools run without confirmation.\",\n },\n {\n type: \"paragraph\",\n text: \"Because Cline operates within VS Code, it has access to your workspace file system. The `file_path` parameter on `talonic_extract` and `talonic_to_markdown` can reference any file in your open workspace, making it straightforward to process documents alongside code.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"cline-auto-approve-example\",\n text: \"Example: multi-step workflow with auto-approval\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Cline auto-approve config for Talonic read-only tools\",\n code: `// In Cline settings → Auto-approve, allow these tools:\n// - talonic_list_schemas (read-only, no cost)\n// - talonic_search (read-only, low cost)\n// - talonic_get_document (read-only, no cost)\n//\n// Keep these requiring approval:\n// - talonic_extract (costs credits)\n// - talonic_save_schema (writes to workspace)\n\n// Agent workflow in a single turn:\n// 1. talonic_search → finds matching documents (auto-approved)\n// 2. talonic_get_document → checks metadata (auto-approved)\n// 3. talonic_extract → extracts data (user approves)`,\n },\n {\n type: \"paragraph\",\n text: \"Cline's strength with Talonic is its autonomous agent mode combined with granular auto-approval. By auto-approving read-only tools like `talonic_search`, `talonic_list_schemas`, and `talonic_get_document`, the agent can explore the workspace freely and only pause for user confirmation on credit-consuming operations like `talonic_extract`. This creates a smooth experience where the agent does the discovery work autonomously and only asks for permission when it matters.\",\n },\n {\n type: \"paragraph\",\n text: \"For development teams using VS Code with Cline, the MCP server integrates naturally into code review workflows. A developer can ask the agent to extract data from a specification document, compare it against the implementation in the codebase, and flag any mismatches — all within the same VS Code window. The agent chains `talonic_extract` with file reads from the workspace to perform this cross-referencing automatically.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"If Cline shows the MCP server as disconnected after a VS Code update, re-open the Cline panel settings and verify the config is still present. Some VS Code updates can reset extension state.\",\n },\n ],\n related: [\n { label: \"Continue\", slug: \"continue\" },\n { label: \"Cursor\", slug: \"cursor\" },\n ],\n faq: [\n {\n question: \"How do I add Talonic MCP to Cline?\",\n answer:\n \"Open the Cline panel settings, go to MCP Servers, click Edit, and add the Talonic config entry.\",\n },\n {\n question: \"Does Cline support auto-approval for Talonic tools?\",\n answer:\n \"Yes. Configure Cline's auto-approve settings to allow specific Talonic tools to run without manual confirmation, enabling multi-step workflows in a single turn.\",\n },\n {\n question: \"Can Cline access local files for Talonic extraction?\",\n answer:\n \"Yes. Cline runs inside VS Code and has access to your workspace file system, so you can use file_path to reference any file in the open workspace.\",\n },\n {\n question: \"Which Talonic tools should I auto-approve in Cline?\",\n answer:\n \"Auto-approve read-only tools like talonic_list_schemas, talonic_search, and talonic_get_document. Keep talonic_extract and talonic_save_schema requiring manual approval since they consume credits or write to your workspace.\",\n },\n ],\n mentions: [\"Cline\", \"VS Code\"],\n },\n {\n slug: \"continue\",\n parentSlug: \"install\",\n title: \"Continue\",\n seoTitle: \"Continue Setup — Talonic MCP\",\n description: \"Configure the Talonic MCP server in Continue for VS Code and JetBrains.\",\n content: [\n { type: \"paragraph\", text: \"Edit `~/.continue/config.json`. Add to the `mcpServers` array:\" },\n { type: \"heading\", level: 3, id: \"continue-hosted\", text: \"Hosted (recommended)\" },\n {\n type: \"code\",\n language: \"json\",\n code: `{\n \"name\": \"talonic\",\n \"url\": \"https://mcp.talonic.com/mcp\",\n \"headers\": {\n \"Authorization\": \"Bearer tlnc_your_key_here\"\n }\n}`,\n },\n { type: \"heading\", level: 3, id: \"continue-local\", text: \"Local (npx)\" },\n {\n type: \"code\",\n language: \"json\",\n code: `{\n \"name\": \"talonic\",\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": {\n \"TALONIC_API_KEY\": \"tlnc_your_key_here\"\n }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Continue works across both VS Code and JetBrains IDEs, making Talonic tools available regardless of your editor choice. The `mcpServers` array in Continue's config supports multiple MCP servers, so Talonic runs alongside any other MCP tools you have configured.\",\n },\n {\n type: \"paragraph\",\n text: \"After saving the config, reload your IDE window to pick up the changes. Continue discovers Talonic's nine tools and two resources automatically. You can verify the connection by asking the agent to call `talonic_list_schemas` — it should return your saved schemas or an empty list.\",\n },\n {\n type: \"paragraph\",\n text: 'Continue\\'s config format uses a `name` field instead of a key in the `mcpServers` object. Make sure to include `\"name\": \"talonic\"` in the entry. The rest of the config — `command`, `args`, `env` for local, or `url` and `headers` for hosted — follows the same pattern as other MCP clients.',\n },\n {\n type: \"heading\",\n level: 3,\n id: \"continue-verify\",\n text: \"Verify the connection\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Verification: ask the agent to call talonic_list_schemas\",\n code: `// Agent sends (no parameters needed):\n{}\n\n// Successful response confirms connection:\n{\n \"schemas\": [\n {\n \"id\": \"sch_7a1b...\",\n \"short_id\": \"SCH-A1B2C3D4\",\n \"name\": \"Standard Invoice\",\n \"field_count\": 6\n }\n ]\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Continue is ideal for teams that use both VS Code and JetBrains IDEs and want a consistent Talonic experience across editors. Because the config file is shared, a schema saved from a Continue session in IntelliJ is immediately available in a VS Code session — no extra setup needed. This cross-editor consistency extends to all Talonic tools, not just schemas.\",\n },\n {\n type: \"paragraph\",\n text: \"When using Continue with the hosted Talonic server, the connection is established over HTTPS directly from the Continue extension. No local MCP process is spawned, which reduces resource usage in the IDE. For JetBrains users in particular, this avoids adding another background process alongside the already resource-intensive IDE. The local npx option remains available for offline work or when HTTPS connectivity is restricted.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Continue's MCP support works identically in VS Code and JetBrains. The same `~/.continue/config.json` file is shared across both editors.\",\n },\n ],\n related: [\n { label: \"Cowork\", slug: \"cowork\" },\n { label: \"Cline\", slug: \"cline\" },\n ],\n faq: [\n {\n question: \"How do I add Talonic MCP to Continue?\",\n answer:\n \"Edit ~/.continue/config.json and add a Talonic entry to the mcpServers array with your API key.\",\n },\n {\n question: \"Does Continue work with Talonic in JetBrains?\",\n answer:\n \"Yes. Continue shares the same config file (~/.continue/config.json) across VS Code and JetBrains, so Talonic works identically in both editors.\",\n },\n {\n question: \"Why does Continue use a different config format?\",\n answer:\n 'Continue uses an mcpServers array with a name field instead of an object keyed by server name. Include \"name\": \"talonic\" in the entry alongside the standard command/args/env or url/headers fields.',\n },\n {\n question: \"Can I run Talonic alongside other MCP servers in Continue?\",\n answer:\n \"Yes. Continue's mcpServers array supports multiple entries. Talonic runs alongside any other MCP servers you have configured. Each server is discovered independently and all tools are available in the same conversation.\",\n },\n ],\n mentions: [\"Continue\", \"VS Code\", \"JetBrains\"],\n },\n {\n slug: \"cowork\",\n parentSlug: \"install\",\n title: \"Cowork\",\n seoTitle: \"Cowork Setup — Talonic MCP\",\n description: \"Configure the Talonic MCP server in Cowork.\",\n content: [\n { type: \"paragraph\", text: \"Open Cowork settings → MCP Servers → Add.\" },\n { type: \"heading\", level: 3, id: \"cowork-hosted\", text: \"Hosted (recommended)\" },\n { type: \"code\", language: \"json\", code: MCP_HOSTED_SNIPPET },\n { type: \"heading\", level: 3, id: \"cowork-local\", text: \"Local (npx)\" },\n { type: \"code\", language: \"json\", code: MCP_CONFIG_SNIPPET },\n {\n type: \"paragraph\",\n text: \"Cowork is a chat-style MCP client that supports drag-and-drop file uploads and resource browsing. After adding the Talonic config, the nine tools appear in the tool picker and the `talonic://schemas` and `talonic://webhooks/reference` resources are browseable in the resources panel.\",\n },\n {\n type: \"paragraph\",\n text: \"Like Claude Desktop, Cowork renders MCP resources in its UI. This means your saved schemas are visible without making a tool call, which helps when you want to browse available schemas before starting an extraction workflow.\",\n },\n {\n type: \"paragraph\",\n text: \"After adding the config, restart Cowork to load the new MCP server. If you are using the hosted option, Cowork connects directly via HTTPS — no local process is spawned. For the local option, Cowork launches the `npx` command as a child process and communicates over stdio.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"cowork-workflow\",\n text: \"Example: browse schemas then extract\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent workflow in Cowork\",\n code: `// Step 1: User browses talonic://schemas in the resources panel\n// → Sees \"Standard Invoice\" (SCH-A1B2C3D4) with 6 fields\n\n// Step 2: User drops invoice.pdf into the chat\n// Agent calls talonic_extract:\n{\n \"file_data\": \"JVBERi0xLjQKJ...\",\n \"filename\": \"invoice.pdf\",\n \"schema_id\": \"SCH-A1B2C3D4\"\n}\n\n// Step 3: Agent presents extracted data:\n{\n \"data\": {\n \"vendor_name\": \"Meridian Energy AG\",\n \"total_amount\": 1500.00,\n \"due_date\": \"2026-06-15\"\n },\n \"confidence\": { \"overall\": 0.97 }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Cowork's resource browsing creates a natural workflow for Talonic users. Instead of asking the agent to list schemas via a tool call, you can visually browse the `talonic://schemas` resource in the sidebar, identify the right schema, and then ask the agent to extract using that schema by name or ID. This visual discovery step reduces back-and-forth in the conversation and helps users who are not familiar with their workspace's schema inventory.\",\n },\n {\n type: \"paragraph\",\n text: \"For teams onboarding new members, Cowork's visual schema browser is especially useful. A new team member can see all available extraction templates at a glance, understand what fields each schema extracts, and start processing documents immediately without needing to learn schema IDs or ask colleagues which templates exist. Combined with drag-and-drop file uploads, the barrier to entry is as low as it gets.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Cowork's resource panel lets you browse `talonic://schemas` visually, making it easy to discover existing schemas before designing new ones.\",\n },\n ],\n related: [\n { label: \"Claude Desktop\", slug: \"claude-desktop\" },\n { label: \"Tool Reference\", slug: \"talonic-extract\" },\n ],\n faq: [\n {\n question: \"How do I add Talonic MCP to Cowork?\",\n answer:\n \"Open Cowork settings, go to MCP Servers, click Add, and paste the standard Talonic config with your API key.\",\n },\n {\n question: \"Does Cowork support the talonic://schemas resource?\",\n answer:\n \"Yes. Cowork renders MCP resources in its UI, so you can browse your saved schemas visually in the resources panel without making a tool call.\",\n },\n {\n question: \"Does Cowork support drag-and-drop with Talonic?\",\n answer:\n \"Yes. Cowork supports drag-and-drop file uploads, which pairs with talonic_extract's file_data parameter for easy document extraction.\",\n },\n {\n question: \"How does Cowork compare to Claude Desktop for Talonic workflows?\",\n answer:\n \"Both support drag-and-drop and schema resource browsing. Cowork's resource panel provides a more visual schema discovery experience. Claude Desktop has deeper integration with Anthropic's Claude model. Choose based on your preferred chat interface and model provider.\",\n },\n ],\n mentions: [\"Cowork\"],\n },\n]\n","import type { RawSection } from \"../types\"\n\nexport const sections: RawSection[] = [\n {\n slug: \"talonic-extract\",\n parentSlug: \"tools\",\n title: \"talonic_extract\",\n seoTitle: \"talonic_extract Tool — Talonic MCP\",\n description:\n \"Extract structured, schema-validated data from a document. Returns clean JSON with per-field confidence scores.\",\n content: [\n { type: \"paragraph\", text: \"Extract structured, schema-validated data from a document.\" },\n {\n type: \"paragraph\",\n text: \"Inputs: one of `file_data` + `filename` (recommended for chat clients), `file_path`, `file_url`, or `document_id`, plus a `schema` (or `schema_id`). Returns clean JSON with per-field confidence scores.\",\n },\n {\n type: \"paragraph\",\n text: \"This is the primary tool in the Talonic MCP server. When an agent calls **`talonic_extract`**, the MCP server uploads the document to the Talonic API, runs OCR and field extraction against the provided schema, and returns structured JSON with confidence metadata. The entire pipeline — upload, OCR, extraction, validation — runs server-side in a single request.\",\n },\n {\n type: \"paragraph\",\n text: \"The response includes a `document.id` that persists in your workspace. Subsequent calls can reference this ID via the `document_id` parameter to re-extract with a different schema, retrieve markdown, or fetch metadata — all without re-uploading the file. This is both faster and cheaper than sending the file again.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"file_data\",\n type: \"string\",\n description: \"Base64-encoded file bytes. Recommended for chat clients (drag-and-drop).\",\n },\n {\n name: \"filename\",\n type: \"string\",\n description: \"Original filename (used for MIME type inference when using `file_data`).\",\n },\n { name: \"file_path\", type: \"string\", description: \"Local file path.\" },\n { name: \"file_url\", type: \"string\", description: \"Remote file URL.\" },\n {\n name: \"document_id\",\n type: \"string\",\n description: \"ID of a previously uploaded document.\",\n },\n {\n name: \"schema\",\n type: \"object\",\n description: \"Inline schema definition (JSON Schema or flat key-type map).\",\n },\n {\n name: \"schema_id\",\n type: \"string\",\n description: \"UUID or SCH-XXXXXXXX short ID of a saved schema.\",\n },\n {\n name: \"instructions\",\n type: \"string\",\n description: \"Natural-language guidance for the extractor.\",\n },\n {\n name: \"include_markdown\",\n type: \"boolean\",\n description: \"Include OCR markdown alongside structured data.\",\n },\n ],\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: \"Always provide a `schema` or `schema_id`. Auto-discovery extract (no schema) is not reliable in v0.1.\",\n },\n { type: \"heading\", level: 3, id: \"extract-inline-schema\", text: \"Example: inline schema\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"file_url\": \"https://example.com/invoice-2026-001.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"vendor_name\": { \"type\": \"string\" },\n \"invoice_number\": { \"type\": \"string\" },\n \"total_amount\": { \"type\": \"number\" },\n \"due_date\": { \"type\": \"string\", \"format\": \"date\" },\n \"line_items\": {\n \"type\": \"array\",\n \"items\": {\n \"type\": \"object\",\n \"properties\": {\n \"description\": { \"type\": \"string\" },\n \"amount\": { \"type\": \"number\" }\n }\n }\n }\n },\n \"required\": [\"vendor_name\", \"total_amount\"]\n },\n \"instructions\": \"Amounts are in EUR. Focus on the billing section.\"\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"extraction_id\": \"ext_8f3a...\",\n \"request_id\": \"req_2c91...\",\n \"status\": \"complete\",\n \"document\": {\n \"id\": \"doc_8f3a...\",\n \"filename\": \"invoice-2026-001.pdf\",\n \"pages\": 2,\n \"type_detected\": \"invoice\",\n \"language_detected\": \"de\"\n },\n \"data\": {\n \"vendor_name\": \"Meridian Energy AG\",\n \"invoice_number\": \"INV-2026-001\",\n \"total_amount\": 1500.00,\n \"due_date\": \"2026-06-15\",\n \"line_items\": [\n { \"description\": \"Consulting, April\", \"amount\": 1200.00 },\n { \"description\": \"Travel expenses\", \"amount\": 300.00 }\n ]\n },\n \"schema\": {\n \"source\": \"inline\"\n },\n \"confidence\": {\n \"overall\": 0.97,\n \"fields\": {\n \"vendor_name\": 0.98,\n \"invoice_number\": 0.95,\n \"total_amount\": 0.99,\n \"due_date\": 0.97\n }\n },\n \"processing\": {\n \"duration_ms\": 2840,\n \"pages_processed\": 2,\n \"region\": \"eu-central-1\"\n }\n}`,\n },\n { type: \"heading\", level: 3, id: \"extract-schema-id\", text: \"Example: saved schema\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"file_path\": \"./contracts/lease-agreement.pdf\",\n \"schema_id\": \"SCH-A1B2C3D4\"\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"extraction_id\": \"ext_b29f...\",\n \"request_id\": \"req_4c81...\",\n \"status\": \"complete\",\n \"document\": {\n \"id\": \"doc_91ad...\",\n \"filename\": \"lease-agreement.pdf\",\n \"pages\": 8,\n \"type_detected\": \"lease_agreement\",\n \"language_detected\": \"en\"\n },\n \"data\": {\n \"lessor\": \"Acme Holdings Ltd.\",\n \"lessee\": \"Meridian Energy AG\",\n \"premises_address\": \"12 Hauptstrasse, 10115 Berlin\",\n \"term_start\": \"2026-07-01\",\n \"term_end\": \"2031-06-30\",\n \"monthly_rent_eur\": 4250.00\n },\n \"schema\": {\n \"source\": \"saved\",\n \"id\": \"SCH-A1B2C3D4\"\n },\n \"confidence\": {\n \"overall\": 0.94,\n \"fields\": {\n \"lessor\": 0.97,\n \"lessee\": 0.97,\n \"premises_address\": 0.92,\n \"term_start\": 0.95,\n \"term_end\": 0.95,\n \"monthly_rent_eur\": 0.91\n }\n },\n \"processing\": {\n \"duration_ms\": 4380,\n \"pages_processed\": 8,\n \"region\": \"eu-central-1\"\n }\n}`,\n },\n ],\n related: [\n { label: \"talonic_to_markdown\", slug: \"talonic-to-markdown\" },\n { label: \"talonic_save_schema\", slug: \"talonic-save-schema\" },\n { label: \"Drag & Drop Files\", slug: \"drag-and-drop\" },\n ],\n faq: [\n {\n question: \"How does talonic_extract work?\",\n answer:\n \"Send a document (file_data, file_path, file_url, or document_id) with a schema or schema_id. The tool returns schema-validated JSON with per-field confidence scores.\",\n },\n {\n question: \"What is the fastest way to extract data from a document?\",\n answer:\n \"If the document is already in your workspace, pass its document_id instead of re-uploading. For new documents in chat clients, use file_data with base64-encoded bytes. For files on the web, use file_url to avoid downloading locally first.\",\n },\n {\n question: \"How long does an extraction typically take?\",\n answer:\n \"Processing time depends on document size. A 2-page invoice typically completes in 2-4 seconds. Larger documents (8+ pages) may take 4-8 seconds. The processing.duration_ms field in the response shows the exact server-side duration.\",\n },\n ],\n mentions: [\"extract\", \"schema\", \"confidence scores\", \"file_data\"],\n },\n {\n slug: \"talonic-search\",\n parentSlug: \"tools\",\n title: \"talonic_search\",\n seoTitle: \"talonic_search Tool — Talonic MCP\",\n description:\n \"Omnisearch across documents, fields, sources, and schemas in the workspace. Supports conceptual and fuzzy queries.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Omnisearch across documents, fields, sources, and schemas in the workspace. Use for conceptual or fuzzy queries.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_search`** is designed for discovery. When a user asks a question like 'do I have any contracts about indemnification?' or 'find documents from Acme', this is the right tool. It searches across document filenames, extracted field values, schema names, and source metadata using semantic and fuzzy matching.\",\n },\n {\n type: \"paragraph\",\n text: \"The response is grouped by entity type: `documents`, `fieldMatches`, `schemas`, `sources`, and `fields`. Each result includes a relevance `score` (0..1) so the agent can assess match quality. Results with scores below 0.5 are typically not relevant and can be omitted when presenting to the user.\",\n },\n {\n type: \"paragraph\",\n text: \"For queries that require exact field-value matching (like 'invoices over 1000 EUR'), use **`talonic_filter`** instead. Search is for exploration and discovery; filter is for precision queries against structured data.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"query\",\n type: \"string\",\n required: true,\n description: \"The search query. Supports fuzzy and conceptual matching.\",\n },\n {\n name: \"limit\",\n type: \"integer\",\n description: \"Maximum results per entity type. Default: 5.\",\n },\n ],\n },\n {\n type: \"paragraph\",\n text: \"A common agent pattern is using `talonic_search` as a first step to orient within a workspace, then following up with more specific tools. For example, an agent might search for 'Acme contracts' to discover relevant documents, note the canonical field names in the response, and then use `talonic_filter` with those field names to narrow down to contracts expiring within a specific date range. This search-then-filter pattern is both efficient and reliable.\",\n },\n {\n type: \"paragraph\",\n text: \"Search results are scoped to the authenticated workspace. The query runs against all documents, extracted field values, schema definitions, and source metadata within that workspace. There is no cross-workspace search — each API key sees only its own data. The `limit` parameter controls how many results are returned per entity type (documents, fields, schemas, sources), with a default of 5. Increase the limit when the user needs a broader view of matching content.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Search results include canonical field names in `fields[].canonicalName`. These names can be used directly in `talonic_filter` conditions, making search a good first step before building precise filters.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: 'Every `fieldMatches[]` and `fields[]` entry carries a `dataType` (`\"string\"`, `\"number\"`, `\"array\"`, etc.). Use it to pick the right `talonic_filter` operator on the first call — numeric operators (`gt`, `gte`, `lt`, `lte`, `between`) only resolve correctly when `dataType === \"number\"`. See the *Schema typing* section under `talonic_filter` for the full preventive / reactive pattern.',\n },\n { type: \"heading\", level: 3, id: \"search-example\", text: \"Example\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"query\": \"indemnification clauses Acme\",\n \"limit\": 10\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"documents\": [\n {\n \"id\": \"doc_4e7b...\",\n \"filename\": \"acme-services-agreement.pdf\",\n \"type_detected\": \"Services Agreement\",\n \"score\": 0.92\n }\n ],\n \"fieldMatches\": [\n {\n \"fieldName\": \"indemnification.cap_amount\",\n \"documentId\": \"doc_4e7b...\",\n \"value\": \"2x annual fees\",\n \"documentCount\": 3,\n \"filterable\": true,\n \"dataType\": \"string\",\n \"score\": 0.88\n }\n ],\n \"schemas\": [],\n \"sources\": [],\n \"fields\": [\n { \"canonicalName\": \"indemnification.cap_amount\", \"dataType\": \"string\", \"filterable\": true }\n ]\n}`,\n },\n { type: \"heading\", level: 3, id: \"search-then-filter\", text: \"Example: search then filter\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Step 1: discover field names with search\",\n code: `// Agent calls talonic_search:\n{\n \"query\": \"vendor invoices total amount\",\n \"limit\": 5\n}\n\n// Response includes canonical field names plus dataType:\n{\n \"fields\": [\n { \"canonicalName\": \"vendor.name\", \"dataType\": \"string\", \"filterable\": true },\n { \"canonicalName\": \"invoice.total_eur\", \"dataType\": \"number\", \"filterable\": true },\n { \"canonicalName\": \"invoice.due_date\", \"dataType\": \"string\", \"filterable\": true }\n ]\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Step 2: use discovered field names in talonic_filter\",\n code: `// Agent uses canonical names from search to build a filter:\n{\n \"conditions\": [\n { \"field\": \"invoice.total_eur\", \"operator\": \"gt\", \"value\": 500 }\n ],\n \"sort\": { \"field\": \"invoice.total_eur\", \"direction\": \"desc\" }\n}`,\n },\n ],\n related: [\n { label: \"talonic_filter\", slug: \"talonic-filter\" },\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"Agent Decision Guide\", slug: \"agent-decision-guide\" },\n ],\n faq: [\n {\n question: \"What does talonic_search do?\",\n answer:\n \"It searches across documents, fields, sources, and schemas in the workspace using fuzzy and conceptual matching.\",\n },\n {\n question: \"When should I use talonic_search vs talonic_filter?\",\n answer:\n \"Use search for discovery and fuzzy queries ('find Acme contracts'). Use filter for precise field-value conditions ('invoices over 1000 EUR'). Search is exploration; filter is precision.\",\n },\n {\n question: \"What do the search scores mean?\",\n answer:\n \"Each result includes a relevance score from 0 to 1. Scores above 0.7 are strong matches, 0.5-0.7 are partial matches, and below 0.5 are typically not relevant.\",\n },\n {\n question: \"Can I search for schemas by name?\",\n answer:\n \"Yes. talonic_search includes schemas in its results. If you search for 'invoice', any schema with 'invoice' in its name or description will appear in the schemas array of the response. This is useful for discovering existing templates before creating new ones.\",\n },\n {\n question: \"How do I use search results to build a filter?\",\n answer:\n \"The fields array in the search response includes canonicalName values with a filterable flag. Use canonicalName values where filterable is true as the field parameter in talonic_filter conditions. This search-then-filter pattern is the recommended workflow for precise queries.\",\n },\n ],\n mentions: [\"search\", \"omnisearch\", \"fuzzy\", \"discovery\"],\n },\n {\n slug: \"talonic-filter\",\n parentSlug: \"tools\",\n title: \"talonic_filter\",\n seoTitle: \"talonic_filter Tool — Talonic MCP\",\n description:\n \"Filter documents by extracted field values using composable conditions like eq, gt, between, and contains.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Filter documents by extracted field values using composable conditions (`eq`, `gt`, `between`, `contains`, etc.).\",\n },\n {\n type: \"paragraph\",\n text: \"Accepts canonical field names (e.g. `vendor.name`, `policy.0_coverage_type`) which the Talonic API resolves to IDs server-side, or UUIDs directly.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_filter`** is the precision counterpart to **`talonic_search`**. While search uses fuzzy matching for discovery, filter applies exact conditions against extracted field values. This makes it ideal for queries like 'show me all invoices from vendor X over 1000 EUR' or 'contracts expiring before 2026-12-31'.\",\n },\n {\n type: \"paragraph\",\n text: \"Multiple conditions are AND-ed together, allowing you to build precise queries that narrow results progressively. The optional `search` parameter lets you combine free-text search with structured filters in a single call, and `sort` controls the result ordering.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"conditions\",\n type: \"array\",\n required: true,\n description:\n \"Filter conditions, AND-ed together. Each has `field` or `field_id`, `operator`, and `value`.\",\n },\n {\n name: \"search\",\n type: \"string\",\n description: \"Optional free-text search applied alongside filters.\",\n },\n {\n name: \"sort\",\n type: \"object\",\n description: 'Sort by a field: `{ field, direction: \"asc\" | \"desc\" }`.',\n },\n { name: \"page\", type: \"integer\", description: \"Page number for pagination.\" },\n { name: \"limit\", type: \"integer\", description: \"Results per page. Default: 50.\" },\n ],\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: \"Only fields where the search response shows `filterable: true` can be used with `talonic_filter`; entries with `filterable: false` have no extracted data yet. The `is_not_empty` operator checks materialized values, which are updated within seconds of extraction completing.\",\n },\n { type: \"heading\", level: 3, id: \"filter-example\", text: \"Example\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"conditions\": [\n { \"field\": \"vendor.name\", \"operator\": \"eq\", \"value\": \"Meridian Energy AG\" },\n { \"field\": \"invoice.total_eur\", \"operator\": \"gt\", \"value\": 1000 }\n ],\n \"sort\": { \"field\": \"invoice.total_eur\", \"direction\": \"desc\" },\n \"limit\": 20\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"data\": [\n {\n \"document_id\": \"doc_8f3a...\",\n \"filename\": \"invoice-2026-001.pdf\",\n \"fields\": {\n \"vendor.name\": \"Meridian Energy AG\",\n \"invoice.total_eur\": 1500.00,\n \"invoice.due_date\": \"2026-06-15\"\n }\n },\n {\n \"document_id\": \"doc_c2d9...\",\n \"filename\": \"invoice-2026-003.pdf\",\n \"fields\": {\n \"vendor.name\": \"Meridian Energy AG\",\n \"invoice.total_eur\": 1200.00,\n \"invoice.due_date\": \"2026-04-30\"\n }\n }\n ],\n \"total\": 2,\n \"page\": 1\n}`,\n },\n { type: \"heading\", level: 3, id: \"filter-operators\", text: \"Available operators\" },\n {\n type: \"paragraph\",\n text: \"The following operators are available for filter conditions: `eq` (equals), `neq` (not equals), `gt` (greater than), `gte` (greater than or equal), `lt` (less than), `lte` (less than or equal), `between` (range, requires a two-element array as value), `contains` (substring match), `starts_with`, `ends_with`, `is_empty` (checks for null or empty values), and `is_not_empty` (checks for materialized values). Numeric operators (`gt`, `gte`, `lt`, `lte`, `between`) only resolve correctly when the schema field is typed as `number`. The next section explains how to handle that constraint.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"filter-schema-typing\",\n text: \"Schema typing (preventive + reactive)\",\n },\n {\n type: \"paragraph\",\n text: 'A numeric operator on a string-typed field that happens to hold numeric content (e.g. `\"€1,500.00\"`) silently returns zero matches — the comparison falls back to lexicographic ordering and almost never produces the result the user expects. There are two ways to handle this; pick the right one before constructing the call.',\n },\n {\n type: \"heading\",\n level: 3,\n id: \"filter-preventive\",\n text: \"Preventive — gate on `dataType`\",\n },\n {\n type: \"paragraph\",\n text: 'Call `talonic_search` first and read `dataType` on the field entry. If `dataType !== \"number\"`, do not issue a numeric operator on that field. Pick a string-friendly operator (`eq`, `contains`) or warn the user that the field needs a `data_type` change in the schema definition before the query can succeed. This avoids the silent-zero-matches outcome entirely.',\n },\n {\n type: \"heading\",\n level: 3,\n id: \"filter-reactive\",\n text: \"Reactive — handle `warnings[]`\",\n },\n {\n type: \"paragraph\",\n text: \"When a numeric operator is applied to a string-typed field anyway, the API attaches a `warnings[]` array to the filter response. Each entry has `code`, `message`, `field`/`field_id`, and a `suggestion`. The MCP tool surfaces this in `structuredContent` — agents should relay the `message` (and `suggestion`, when present) to the user rather than silently retrying.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Response with a warning\",\n code: `{\n \"data\": [],\n \"total\": 0,\n \"warnings\": [\n {\n \"code\": \"numeric_operator_on_string_field\",\n \"message\": \"Operator \\`gt\\` was applied to field \\`invoice_total\\` typed as string. Numeric comparisons against string-typed fields use lexicographic ordering and may return zero matches.\",\n \"field\": \"invoice_total\",\n \"field_id\": \"fld_inv_total\",\n \"suggestion\": \"Change the field's data_type to \\`number\\` in the schema definition.\"\n }\n ]\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"filter-combined-example\",\n text: \"Example: combined search and filter\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Combining free-text search with field-value filters\",\n code: `{\n \"conditions\": [\n { \"field\": \"invoice.due_date\", \"operator\": \"lte\", \"value\": \"2026-06-30\" },\n { \"field\": \"invoice.total_eur\", \"operator\": \"gte\", \"value\": 500 }\n ],\n \"search\": \"consulting services\",\n \"sort\": { \"field\": \"invoice.due_date\", \"direction\": \"asc\" },\n \"limit\": 10\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Pagination is supported via the `page` and `limit` parameters. The default page size is 50 results. For large workspaces with many matching documents, iterate through pages by incrementing `page` from 1. The response includes a `total` field showing the total number of matches, so the agent can determine how many pages remain and communicate this to the user.\",\n },\n {\n type: \"paragraph\",\n text: \"When building filters dynamically from user requests, agents should validate field names against the workspace's field registry first. The most reliable way is to call `talonic_search` to discover available canonical field names and check the `filterable` flag. Attempting to filter on a field that does not exist or is not yet filterable returns a `VALIDATION_ERROR` with a descriptive message. The agent should catch this error and suggest alternative field names rather than failing silently.\",\n },\n ],\n related: [\n { label: \"talonic_search\", slug: \"talonic-search\" },\n { label: \"Known Limitations\", slug: \"known-limitations\" },\n { label: \"Agent Decision Guide\", slug: \"agent-decision-guide\" },\n ],\n faq: [\n {\n question: \"How do I filter documents by field value?\",\n answer:\n \"Use talonic_filter with canonical field names and operators like eq, gt, between, contains. The API resolves field names to IDs server-side.\",\n },\n {\n question: \"How do I find the correct canonical field names for filtering?\",\n answer:\n \"Call talonic_search first — canonical field names appear in the fields[].canonicalName array. You can also inspect previously extracted documents to see their field structure.\",\n },\n {\n question: \"Can I combine free-text search with field filters?\",\n answer:\n \"Yes. Pass the search parameter alongside conditions to combine fuzzy text matching with structured field-value filters in a single call.\",\n },\n {\n question: \"What operators are available for talonic_filter?\",\n answer:\n \"Supported operators include eq, neq, gt, gte, lt, lte, between, contains, starts_with, ends_with, and is_empty. Numeric operators (gt, gte, lt, lte, between) require the schema field to be typed as number. String operators work on all field types.\",\n },\n {\n question: \"Why does my filter return zero results even though matching documents exist?\",\n answer:\n \"The most common cause is using a numeric operator (gt, lt, between) on a field that is typed as string in the schema. Currency symbols, commas, or locale formatting in the value also cause mismatches. Ensure the schema defines numeric fields as type number and that values are stored without formatting.\",\n },\n ],\n mentions: [\"filter\", \"canonical field names\", \"operators\", \"conditions\"],\n },\n {\n slug: \"talonic-get-document\",\n parentSlug: \"tools\",\n title: \"talonic_get_document\",\n seoTitle: \"talonic_get_document Tool — Talonic MCP\",\n description:\n \"Fetch full metadata for a single document by ID, including processing log and link URLs.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Fetch full metadata for a single document by ID, including processing log and link URLs.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_get_document`** retrieves comprehensive information about a document that has already been ingested into your Talonic workspace. This includes the file's status, page count, size, detected document type and language, the source that uploaded it, and direct links to the document in the Talonic dashboard and API.\",\n },\n {\n type: \"paragraph\",\n text: \"This tool is useful when the agent needs to check whether a document has finished processing, verify its detected type, or retrieve the dashboard link so the user can view the original. It does not return extracted data — for that, use **`talonic_extract`** with the same `document_id`.\",\n },\n {\n type: \"paragraph\",\n text: \"The `links.dashboard` URL in the response is particularly valuable for human-in-the-loop workflows. When the agent needs the user to verify an extraction against the original document, it can present this link as a direct way to view the source in the Talonic web interface.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"document_id\",\n type: \"string\",\n required: true,\n description: \"The document UUID.\",\n },\n ],\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"The `document_id` returned by `talonic_extract` and other tools is stable. You can call `talonic_get_document` at any time to check the document's current status and metadata.\",\n },\n { type: \"heading\", level: 3, id: \"get-document-example\", text: \"Example\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"document_id\": \"doc_8f3a1b2c-4d5e-6f7a-8b9c-0d1e2f3a4b5c\"\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"id\": \"doc_8f3a1b2c-4d5e-6f7a-8b9c-0d1e2f3a4b5c\",\n \"filename\": \"invoice-2026-001.pdf\",\n \"status\": \"completed\",\n \"pages\": 2,\n \"size_bytes\": 184320,\n \"mime_type\": \"application/pdf\",\n \"type_detected\": \"Invoice\",\n \"language_detected\": \"de\",\n \"source\": { \"id\": \"src_a1b2...\", \"type\": \"api\" },\n \"links\": {\n \"self\": \"https://api.talonic.com/v1/documents/doc_8f3a...\",\n \"extractions\": \"https://api.talonic.com/v1/documents/doc_8f3a.../extractions\",\n \"dashboard\": \"https://app.talonic.com/documents/doc_8f3a...\"\n }\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"get-document-workflow\",\n text: \"Example: human-in-the-loop verification\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent uses dashboard link for user verification\",\n code: `// After extracting data with low confidence on a critical field:\n// Agent calls talonic_get_document to get the dashboard link:\n{\n \"document_id\": \"doc_8f3a1b2c-4d5e-6f7a-8b9c-0d1e2f3a4b5c\"\n}\n\n// Agent presents to user:\n// \"The total_amount field has confidence 0.68.\n// Please verify against the original document:\n// https://app.talonic.com/documents/doc_8f3a...\"`,\n },\n {\n type: \"paragraph\",\n text: \"The `status` field in the response indicates the document's processing state. Common values are `completed` (ready for extraction and markdown retrieval), `processing` (still being ingested), and `failed` (ingestion encountered an error). Agents should check the status before attempting follow-up operations — calling `talonic_extract` on a document that is still `processing` will either wait or fail depending on the API's current behaviour.\",\n },\n {\n type: \"paragraph\",\n text: \"The `source` object in the response tells you how the document was uploaded. A `type` of `api` means it was uploaded via the MCP server or REST API, while `dashboard` means it was uploaded through the Talonic web interface. The `source.id` can be useful for filtering documents by upload source when a workspace has documents from multiple integration points.\",\n },\n {\n type: \"paragraph\",\n text: \"This tool is free to call — it does not consume extraction credits. Agents can call it as often as needed to check document status, retrieve links, or verify metadata without any cost concern. This makes it safe for polling scenarios where an agent needs to wait for a document to finish processing before proceeding with extraction.\",\n },\n ],\n related: [\n { label: \"talonic_to_markdown\", slug: \"talonic-to-markdown\" },\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n ],\n faq: [\n {\n question: \"How do I get document metadata via MCP?\",\n answer:\n \"Call talonic_get_document with the document UUID to get full metadata including processing log and link URLs.\",\n },\n {\n question: \"Does talonic_get_document return extracted data?\",\n answer:\n \"No. It returns metadata (filename, status, pages, type, language, links). For extracted field data, use talonic_extract with the same document_id.\",\n },\n {\n question: \"How can I link the user to the original document?\",\n answer:\n \"The response includes links.dashboard, which is a direct URL to view the document in the Talonic web interface. Present this to the user when they need to verify an extraction.\",\n },\n {\n question: \"Does talonic_get_document cost any credits?\",\n answer:\n \"No. It is a free metadata lookup that does not consume extraction credits. Agents can call it as often as needed to check document status, retrieve dashboard links, or verify metadata without cost concerns.\",\n },\n {\n question: \"What document statuses can talonic_get_document return?\",\n answer:\n \"Common statuses include completed (ready for extraction), processing (still being ingested), and failed (ingestion error). Check the status before attempting follow-up operations like extraction or markdown retrieval.\",\n },\n ],\n mentions: [\"document\", \"metadata\", \"processing log\", \"dashboard link\"],\n },\n {\n slug: \"talonic-to-markdown\",\n parentSlug: \"tools\",\n title: \"talonic_to_markdown\",\n seoTitle: \"talonic_to_markdown Tool — Talonic MCP\",\n description:\n \"Get OCR-converted markdown for a document. Accepts document_id, file_data + filename, file_path, or file_url.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Get OCR-converted markdown for a document. Accepts `document_id` (cheapest — no re-upload), `file_data` + `filename`, `file_path`, or `file_url`.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_to_markdown`** converts a document's visual content into clean, structured markdown. Tables are rendered as markdown tables, headings are preserved, and the text is ordered to match the visual layout of the original document. This is the right tool when the user wants the full text of a document for summarisation, translation, or general analysis without needing structured field extraction.\",\n },\n {\n type: \"paragraph\",\n text: \"If you have already ingested the document (via a previous `talonic_extract` or `talonic_to_markdown` call), pass the `document_id` to skip re-uploading. This is the cheapest and fastest path because the OCR has already been performed. For new documents, use `file_data` + `filename` in chat clients, `file_path` for local files, or `file_url` for remote files.\",\n },\n {\n type: \"paragraph\",\n text: \"The returned markdown is suitable for feeding into an LLM's context window for downstream tasks. Because the conversion preserves table structure and heading hierarchy, the LLM can reason about the document's content without losing structural information that raw text extraction would discard.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"document_id\",\n type: \"string\",\n description: \"ID of an already-ingested document (cheapest path).\",\n },\n {\n name: \"file_data\",\n type: \"string\",\n description: \"Base64-encoded file bytes. Pair with `filename`.\",\n },\n { name: \"filename\", type: \"string\", description: \"Original filename with extension.\" },\n { name: \"file_path\", type: \"string\", description: \"Local file path.\" },\n {\n name: \"file_url\",\n type: \"string\",\n description: \"Remote URL the API fetches server-side.\",\n },\n ],\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"If you need both structured data and markdown, use `talonic_extract` with `include_markdown: true` instead of making two separate calls. This saves one upload and one processing cycle.\",\n },\n { type: \"heading\", level: 3, id: \"to-markdown-example\", text: \"Example\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"document_id\": \"doc_8f3a1b2c-4d5e-6f7a-8b9c-0d1e2f3a4b5c\"\n}`,\n },\n {\n type: \"code\",\n language: \"markdown\",\n title: \"Tool response\",\n code: `# Invoice INV-2026-001\n\n**Meridian Energy AG**\nMusterstraße 42, 10115 Berlin\n\n| Item | Amount |\n|-----------------------|------------|\n| Consulting — April | €1,200.00 |\n| Travel expenses | €300.00 |\n| **Total** | **€1,500.00** |\n\nDue date: 15 June 2026\nPayment terms: Net 30`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"to-markdown-url-example\",\n text: \"Example: convert from URL\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input: convert a remote PDF to markdown\",\n code: `{\n \"file_url\": \"https://example.com/annual-report-2025.pdf\"\n}`,\n },\n {\n type: \"code\",\n language: \"markdown\",\n title: \"Tool response: structured markdown output\",\n code: `# Annual Report 2025\n\n## Financial Highlights\n\n| Metric | 2025 | 2024 | Change |\n|---------------------|------------|------------|---------|\n| Revenue | €12.4M | €9.8M | +26.5% |\n| Net Income | €2.1M | €1.4M | +50.0% |\n| Employees | 142 | 98 | +44.9% |\n\n## Board of Directors\n\n- **Chair**: Dr. Maria Fischer\n- **CEO**: Thomas Bergmann\n- **CFO**: Sarah Lindqvist`,\n },\n {\n type: \"paragraph\",\n text: \"The markdown output is designed to be LLM-friendly. Agents can feed the returned markdown directly into their context window for summarisation, translation, comparison, or question-answering tasks. Because the conversion preserves semantic structure (headings denote sections, tables retain rows and columns, lists maintain hierarchy), downstream LLM reasoning is significantly more accurate than working with raw OCR text that has lost all formatting cues.\",\n },\n {\n type: \"paragraph\",\n text: \"For multi-page documents, the markdown includes page break indicators and preserves the reading order across pages. Headers, footers, and page numbers are typically stripped or de-duplicated to produce a clean reading experience. If the document contains images with embedded text (like scanned letterheads or stamps), the OCR engine extracts visible text from those regions as well, though image-only content without text is omitted from the markdown output.\",\n },\n {\n type: \"paragraph\",\n text: \"When an agent needs to compare two versions of a document, `talonic_to_markdown` is the right starting point. Convert both documents to markdown, then use standard text diffing within the agent's context to identify changes. This is more reliable than visual comparison because the markdown normalises formatting differences and focuses on content. The stable document IDs make it easy to retrieve markdown for previously processed documents without re-uploading.\",\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"Drag & Drop Files\", slug: \"drag-and-drop\" },\n ],\n faq: [\n {\n question: \"How do I get markdown from a document via MCP?\",\n answer:\n \"Call talonic_to_markdown with a document_id (cheapest), or provide the file directly via file_data, file_path, or file_url.\",\n },\n {\n question: \"Does talonic_to_markdown preserve table structure?\",\n answer:\n \"Yes. Tables are rendered as markdown tables with proper column alignment. Headings and text ordering are also preserved to match the original document layout.\",\n },\n {\n question: \"Should I use talonic_to_markdown or talonic_extract with include_markdown?\",\n answer:\n \"If you only need the text, use talonic_to_markdown. If you need both structured fields and the full text, use talonic_extract with include_markdown: true to avoid two separate calls.\",\n },\n {\n question: \"Can I use talonic_to_markdown for document comparison?\",\n answer:\n \"Yes. Convert both document versions to markdown, then diff the text in the agent's context. Markdown normalises formatting differences and focuses on content, making comparison more reliable than visual methods. Use document_id for previously processed files to avoid re-uploading.\",\n },\n {\n question: \"Does talonic_to_markdown handle scanned documents?\",\n answer:\n \"Yes. The tool runs OCR on scanned PDFs, images (PNG, JPG, TIFF), and other image-based documents. Text is extracted from all visible regions including headers, stamps, and handwritten annotations where legible. The output is clean markdown regardless of whether the source is digital or scanned.\",\n },\n ],\n mentions: [\"markdown\", \"OCR\", \"document_id\", \"tables\"],\n },\n {\n slug: \"talonic-list-schemas\",\n parentSlug: \"tools\",\n title: \"talonic_list_schemas\",\n seoTitle: \"talonic_list_schemas Tool — Talonic MCP\",\n description: \"List all saved schemas in the workspace as compact summaries.\",\n content: [\n {\n type: \"paragraph\",\n text: \"List all saved schemas as compact summaries. Returns schema IDs (both UUID and `SCH-XXXXXXXX` short format), names, descriptions, version, and field counts.\",\n },\n {\n type: \"paragraph\",\n text: \"The full per-field JSON Schema definition is intentionally omitted from the list — across many schemas that payload is large and can get truncated by some clients. To inspect a schema's full field definitions, read the `talonic://schemas` resource, which clients that browse resources separately (Claude Desktop and Cowork) also render in the UI.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_list_schemas`** is a read-only tool that returns every saved schema in your workspace as a summary. Agents should call this before creating a new schema to avoid duplicates, and when the user asks about their available extraction templates. To read the full field structure of a specific schema, use the `talonic://schemas` resource.\",\n },\n {\n type: \"paragraph\",\n text: \"Each schema in the response includes both a UUID (`id`) and a human-friendly short ID (`short_id` in `SCH-XXXXXXXX` format). Either can be passed as `schema_id` to `talonic_extract`. The short ID is easier for users to reference in conversation, while the UUID is useful for programmatic workflows.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Call `talonic_list_schemas` before `talonic_save_schema` to check if a similar schema already exists. This prevents cluttering the workspace with near-duplicate schemas.\",\n },\n { type: \"heading\", level: 3, id: \"list-schemas-example\", text: \"Example\" },\n { type: \"paragraph\", text: \"No input parameters required.\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"schemas\": [\n {\n \"id\": \"sch_7a1b2c3d-4e5f-6a7b-8c9d-0e1f2a3b4c5d\",\n \"short_id\": \"SCH-A1B2C3D4\",\n \"name\": \"Standard Invoice\",\n \"description\": \"Extracts vendor, line items, totals, and payment terms.\",\n \"version\": 3,\n \"field_count\": 6,\n \"definition\": {\n \"type\": \"object\",\n \"properties\": {\n \"vendor_name\": { \"type\": \"string\" },\n \"invoice_number\": { \"type\": \"string\" },\n \"total_amount\": { \"type\": \"number\" },\n \"due_date\": { \"type\": \"string\", \"format\": \"date\" },\n \"currency\": { \"type\": \"string\" },\n \"line_items\": { \"type\": \"array\" }\n },\n \"required\": [\"vendor_name\", \"total_amount\"]\n }\n },\n {\n \"id\": \"sch_e5f6a7b8-c9d0-1e2f-3a4b-5c6d7e8f9a0b\",\n \"short_id\": \"SCH-E5F6A7B8\",\n \"name\": \"Certificate of Insurance\",\n \"description\": \"Extracts insured party, coverage types, limits, and expiry.\",\n \"version\": 1,\n \"field_count\": 8,\n \"definition\": { \"type\": \"object\", \"properties\": { \"...\" : {} } }\n }\n ]\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"list-schemas-workflow\",\n text: \"Example: check for duplicates before saving\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent checks existing schemas before creating a new one\",\n code: `// User: \"Create a schema for purchase orders\"\n// Agent first checks existing schemas:\n// talonic_list_schemas → {}\n\n// Response shows existing schemas:\n{\n \"schemas\": [\n {\n \"id\": \"sch_7a1b...\",\n \"short_id\": \"SCH-A1B2C3D4\",\n \"name\": \"Standard Invoice\",\n \"field_count\": 6\n },\n {\n \"id\": \"sch_c3d4...\",\n \"short_id\": \"SCH-C3D4E5F6\",\n \"name\": \"Purchase Order\",\n \"field_count\": 7\n }\n ]\n}\n\n// Agent: \"You already have a 'Purchase Order' schema (SCH-C3D4E5F6)\n// with 7 fields. Would you like to use it, or create a new one?\"`,\n },\n {\n type: \"paragraph\",\n text: \"Agents should call `talonic_list_schemas` proactively in several scenarios: before saving a new schema (to prevent duplicates), when the user asks about available extraction templates, and when starting a session that involves document extraction (to present schema options). The call is free and returns quickly, so there is no cost or latency penalty for checking frequently.\",\n },\n {\n type: \"paragraph\",\n text: \"The `version` field on each schema tracks how many times it has been updated through the Talonic dashboard. A schema at version 1 has never been modified since creation. Higher versions indicate the schema has been refined — potentially adding new fields, changing types, or updating required fields. Agents can use this information to inform the user about schema maturity when choosing between multiple similar schemas.\",\n },\n {\n type: \"paragraph\",\n text: \"The `field_count` in the response is a quick indicator of schema complexity without needing to parse the full definition. Schemas with fewer fields are faster to extract and produce more focused results. Schemas with many fields (10+) cover more ground but may have lower per-field confidence on complex documents. Agents can use field count to help users choose between a detailed schema and a simpler one for quick extractions.\",\n },\n ],\n related: [\n { label: \"talonic_save_schema\", slug: \"talonic-save-schema\" },\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n ],\n faq: [\n {\n question: \"How do I list schemas via MCP?\",\n answer:\n \"Call talonic_list_schemas to get all saved schemas with their definitions. The talonic://schemas resource also exposes this data.\",\n },\n {\n question: \"What is the difference between the UUID and SCH-XXXXXXXX ID?\",\n answer:\n \"Both reference the same schema. The UUID (id) is the full identifier, while SCH-XXXXXXXX (short_id) is a shorter, human-friendly format. Either can be passed as schema_id to talonic_extract.\",\n },\n {\n question: \"Does talonic_list_schemas require any parameters?\",\n answer:\n \"No. It takes no input parameters and returns all saved schemas in the workspace with their full definitions.\",\n },\n {\n question: \"Is talonic_list_schemas free to call?\",\n answer:\n \"Yes. It is a read-only metadata call that does not consume extraction credits. Agents can call it as often as needed to check for existing schemas, present options to the user, or verify a schema exists before using it in an extraction.\",\n },\n {\n question: \"How do I know which schema to use for a document?\",\n answer:\n \"Call talonic_list_schemas to see all available schemas with their names, descriptions, and field counts. Match the schema name and description to the document type. For example, use a 'Standard Invoice' schema for invoices and a 'Certificate of Insurance' schema for COIs. When unsure, start with an inline schema and save it after confirming the results.\",\n },\n ],\n mentions: [\"schemas\", \"list\", \"SCH-XXXXXXXX\", \"resource\"],\n },\n {\n slug: \"talonic-save-schema\",\n parentSlug: \"tools\",\n title: \"talonic_save_schema\",\n seoTitle: \"talonic_save_schema Tool — Talonic MCP\",\n description: \"Save a schema definition to the workspace for reuse across extractions.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Save a schema definition to the workspace for reuse. Returns a `schema_id` that can be passed to `talonic_extract`.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_save_schema`** persists an extraction template so it can be referenced by ID in future `talonic_extract` calls. This is useful when the same schema will be applied to many documents — for example, a standard invoice schema used across all vendor invoices, or a contract schema applied to every new agreement.\",\n },\n {\n type: \"paragraph\",\n text: \"The recommended workflow is to iterate on the schema inline first (passing it directly to `talonic_extract`), verify the extraction results with the user, and only call `talonic_save_schema` once the schema design is confirmed. This avoids cluttering the workspace with draft schemas that never get used.\",\n },\n {\n type: \"paragraph\",\n text: \"The response returns both a UUID (`id`) and a short ID (`short_id` in `SCH-XXXXXXXX` format). Either can be used as `schema_id` in subsequent `talonic_extract` calls. The `version` field starts at 1 and increments if the schema is updated through the Talonic dashboard.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"name\",\n type: \"string\",\n required: true,\n description: \"Human-readable schema name.\",\n },\n {\n name: \"definition\",\n type: \"object\",\n required: true,\n description:\n 'Schema definition. Full JSON Schema `{type: \"object\", properties: {...}}` recommended.',\n },\n {\n name: \"description\",\n type: \"string\",\n description: \"What this schema extracts and when to use it.\",\n },\n ],\n },\n {\n type: \"callout\",\n text: 'Prefer full JSON Schema format with `type: \"object\"` and `properties`. The flat key-type map format is not fully supported server-side yet.',\n },\n { type: \"heading\", level: 3, id: \"save-schema-example\", text: \"Example\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"name\": \"Standard Invoice\",\n \"description\": \"Extracts vendor, line items, totals, and payment terms from invoices.\",\n \"definition\": {\n \"type\": \"object\",\n \"properties\": {\n \"vendor_name\": { \"type\": \"string\" },\n \"invoice_number\": { \"type\": \"string\" },\n \"total_amount\": { \"type\": \"number\" },\n \"due_date\": { \"type\": \"string\", \"format\": \"date\" },\n \"line_items\": {\n \"type\": \"array\",\n \"items\": {\n \"type\": \"object\",\n \"properties\": {\n \"description\": { \"type\": \"string\" },\n \"amount\": { \"type\": \"number\" }\n }\n }\n }\n },\n \"required\": [\"vendor_name\", \"total_amount\"]\n }\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"id\": \"sch_7a1b2c3d-4e5f-6a7b-8c9d-0e1f2a3b4c5d\",\n \"short_id\": \"SCH-A1B2C3D4\",\n \"name\": \"Standard Invoice\",\n \"description\": \"Extracts vendor, line items, totals, and payment terms from invoices.\",\n \"version\": 1,\n \"field_count\": 5\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"save-schema-workflow\",\n text: \"Example: iterate inline then save\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Step 1: test the schema inline with talonic_extract\",\n code: `// Agent extracts with inline schema first:\n{\n \"file_url\": \"https://example.com/sample-po.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"po_number\": { \"type\": \"string\" },\n \"vendor\": { \"type\": \"string\" },\n \"items\": {\n \"type\": \"array\",\n \"items\": {\n \"type\": \"object\",\n \"properties\": {\n \"description\": { \"type\": \"string\" },\n \"quantity\": { \"type\": \"integer\" },\n \"unit_price\": { \"type\": \"number\" }\n }\n }\n },\n \"total\": { \"type\": \"number\" },\n \"delivery_date\": { \"type\": \"string\", \"format\": \"date\" }\n },\n \"required\": [\"po_number\", \"vendor\", \"total\"]\n }\n}\n// → User reviews results, confirms the schema looks right`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Step 2: save the confirmed schema for reuse\",\n code: `// Agent calls talonic_save_schema:\n{\n \"name\": \"Purchase Order\",\n \"description\": \"Extracts PO number, vendor, line items, total, and delivery date.\",\n \"definition\": {\n \"type\": \"object\",\n \"properties\": {\n \"po_number\": { \"type\": \"string\" },\n \"vendor\": { \"type\": \"string\" },\n \"items\": { \"type\": \"array\" },\n \"total\": { \"type\": \"number\" },\n \"delivery_date\": { \"type\": \"string\", \"format\": \"date\" }\n },\n \"required\": [\"po_number\", \"vendor\", \"total\"]\n }\n}\n\n// Response:\n{\n \"id\": \"sch_d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f9a\",\n \"short_id\": \"SCH-D4E5F6A7\",\n \"name\": \"Purchase Order\",\n \"version\": 1,\n \"field_count\": 5\n}\n// → Future extractions use: { \"schema_id\": \"SCH-D4E5F6A7\" }`,\n },\n {\n type: \"paragraph\",\n text: \"The `description` field is optional but strongly recommended. A clear description helps agents (and users) understand when to use a particular schema. Agents can read schema descriptions from `talonic_list_schemas` to auto-select the right schema based on the document type. For example, if the user drops a purchase order, the agent can scan saved schema descriptions for keywords like 'purchase order' or 'PO' and suggest the matching schema automatically.\",\n },\n {\n type: \"paragraph\",\n text: \"Schema naming conventions matter for discoverability. Use descriptive, consistent names like 'Standard Invoice', 'Certificate of Insurance', or 'Employment Contract' rather than abbreviations or internal codes. These names appear in `talonic_list_schemas` results and the `talonic://schemas` resource, where users and agents browse them to find the right template. A well-named schema library reduces friction across the entire team.\",\n },\n ],\n related: [\n { label: \"talonic_list_schemas\", slug: \"talonic-list-schemas\" },\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n ],\n faq: [\n {\n question: \"How do I save a schema via MCP?\",\n answer:\n \"Call talonic_save_schema with a name and JSON Schema definition. It returns a schema_id for reuse in talonic_extract calls.\",\n },\n {\n question: \"When should I save a schema vs use an inline schema?\",\n answer:\n \"Save a schema when you will reuse it across many documents (e.g., a standard invoice template). Use inline schemas for one-off extractions or when iterating on schema design with the user.\",\n },\n {\n question: \"Can I update a saved schema?\",\n answer:\n \"Schema updates are managed through the Talonic dashboard. The version field in the response tracks changes. Via MCP, you can save a new schema with a different name if the design changes significantly.\",\n },\n {\n question: \"What is the recommended workflow for schema design?\",\n answer:\n \"Iterate inline first: pass the schema directly to talonic_extract, review results with the user, adjust fields as needed. Once the user confirms the schema produces good results, call talonic_save_schema to persist it. This prevents cluttering the workspace with draft schemas that never get used.\",\n },\n {\n question: \"Should I include a description when saving a schema?\",\n answer:\n \"Yes. The description helps agents auto-select the right schema based on document type, and helps team members understand what each schema extracts. Use clear language like 'Extracts vendor, line items, totals, and payment terms from invoices' so both humans and AI agents can match schemas to documents.\",\n },\n ],\n mentions: [\"save schema\", \"JSON Schema\", \"reuse\", \"version\"],\n },\n {\n slug: \"talonic-get-balance\",\n parentSlug: \"tools\",\n title: \"talonic_get_balance\",\n seoTitle: \"talonic_get_balance Tool — Talonic MCP\",\n description:\n \"MCP tool that returns the current Talonic credit balance, EUR value, 30-day burn rate, projected runway, tier, and next monthly tier-reset timestamp.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Returns the workspace's current credit balance, EUR value, 30-day burn rate, projected runway in days, API tier, and the timestamp of the next monthly tier reset. Use it for budget-aware behaviour: read the balance before scheduling a large batch, or after a sequence of extractions to track spend.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"use-when\",\n text: \"When to use\",\n },\n {\n type: \"list\",\n items: [\n \"The user asks how many credits or how much budget they have left.\",\n \"Before kicking off a large or expensive operation (batch extract, re-extract many documents), to confirm budget headroom.\",\n \"The user asks how long the balance will last at the current rate.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"do-not-use\",\n text: \"When not to use\",\n },\n {\n type: \"list\",\n items: [\n \"For per-call cost of a single extraction: that is already on every `talonic_extract` response under `cost`.\",\n \"To top up credits: route the user to the dashboard. Auto top-up is guarded by a separate scope and is intentionally not exposed at the MCP layer.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"response-shape\",\n text: \"Response shape\",\n },\n {\n type: \"list\",\n items: [\n \"`balance_credits`: current credit balance (integer).\",\n \"`balance_eur`: current balance expressed in EUR (rounded to two decimals).\",\n \"`burn_rate_30d_credits`: total credits consumed in the trailing 30 days.\",\n \"`projected_runway_days`: days of runway at the current 30-day average burn rate. `-1` indicates no consumption in the trailing window (cannot compute a meaningful runway).\",\n \"`tier`: API tier of the workspace (`free`, `pro`, `enterprise`, etc.).\",\n \"`tier_resets_at`: ISO 8601 timestamp of the next monthly tier reset.\",\n ],\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"balance_credits\": 1888,\n \"balance_eur\": 9.44,\n \"burn_rate_30d_credits\": 360,\n \"projected_runway_days\": 157,\n \"tier\": \"pro\",\n \"tier_resets_at\": \"2026-06-01T00:00:00.000Z\"\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"balance-budget-check\",\n text: \"Example: budget check before batch extraction\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent checks balance before processing 50 documents\",\n code: `// User: \"Extract data from all 50 invoices in my workspace\"\n// Agent first checks budget:\n// talonic_get_balance → {}\n\n// Response:\n{\n \"balance_credits\": 120,\n \"balance_eur\": 0.60,\n \"burn_rate_30d_credits\": 360,\n \"projected_runway_days\": 10,\n \"tier\": \"free\",\n \"tier_resets_at\": \"2026-06-01T00:00:00.000Z\"\n}\n\n// Agent: \"You have 120 credits remaining. Extracting 50 documents\n// will cost approximately 50 credits, leaving 70 credits.\n// Your tier resets on June 1st. Shall I proceed?\"`,\n },\n {\n type: \"paragraph\",\n text: \"Budget-aware agents use `talonic_get_balance` to prevent unexpected credit depletion. Before starting a large batch extraction, the agent checks the remaining balance and estimates whether the batch will exceed available credits. If the balance is low, the agent can warn the user, suggest processing a subset, or recommend upgrading the plan. This proactive approach prevents mid-batch failures due to exhausted credits.\",\n },\n {\n type: \"paragraph\",\n text: \"The `tier` field indicates the workspace's API plan: `free`, `pro`, or `enterprise`. Each tier has different daily extraction limits and credit allowances. The `tier_resets_at` timestamp shows when the monthly credit cycle resets, which helps agents answer questions like 'when will my credits refresh?' or 'should I wait for the reset before processing this batch?'. Agents can use this information to advise users on timing large extraction jobs.\",\n },\n {\n type: \"paragraph\",\n text: \"The `burn_rate_30d_credits` field shows total consumption over the trailing 30 days, not a daily average. Agents can divide by 30 to estimate daily usage. Combined with `balance_credits`, this provides a clear picture of workspace sustainability. A high burn rate with a low balance signals the need for a plan upgrade or reduced usage before the next tier reset.\",\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"Pricing\", slug: \"pricing\" },\n ],\n faq: [\n {\n question: \"How do I check my Talonic credit balance from an agent?\",\n answer:\n \"Call talonic_get_balance with no arguments. Returns balance_credits, balance_eur, burn_rate_30d_credits, projected_runway_days, tier, and tier_resets_at. Read-only; safe to call at any time.\",\n },\n {\n question: \"What does projected_runway_days = -1 mean?\",\n answer:\n \"It means the workspace has had zero credit consumption in the trailing 30 days, so a meaningful runway projection cannot be computed. Treat -1 as 'unknown' rather than '0 days'.\",\n },\n {\n question: \"Should the agent check balance before every extraction?\",\n answer:\n \"Not for single extractions — that would add unnecessary latency. Check the balance before batch operations (10+ documents) or when the user explicitly asks about credits. For single extractions, proceed directly and let the API return a quota error if the balance is exhausted.\",\n },\n {\n question: \"How does the agent know the cost of an extraction?\",\n answer:\n \"Each talonic_extract response includes a cost field showing credits consumed for that extraction. Use talonic_get_balance before a batch to check available credits, and after to verify the remaining balance. Single extractions typically cost 1 credit each.\",\n },\n ],\n mentions: [\"credits\", \"balance\", \"EUR\", \"burn rate\", \"runway\", \"tier\", \"budget\"],\n },\n {\n slug: \"talonic-request-upload\",\n parentSlug: \"tools\",\n title: \"talonic_request_upload\",\n seoTitle: \"talonic_request_upload Tool — Talonic MCP\",\n description:\n \"Request a browser-handoff upload link for files that can't be delivered via tool-call arguments. Returns a pre-allocated document_id, an upload URL, and an expiry timestamp.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Request a one-time upload link for a file the agent cannot deliver directly. Returns a pre-allocated `document_id`, a browser-openable `upload_url` the user drops the file into, and an `expires_at` timestamp.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_request_upload`** exists to route around the **~32 KB tool-call argument cap** in hosted-connector environments like Claude.ai's web UI. Above that ceiling, `file_data` on `talonic_extract` is silently truncated and the extraction returns null fields. The browser-handoff flow sidesteps the cap entirely: the user opens the upload URL in a separate tab, drops the file, and the agent then references the resulting document by ID.\",\n },\n {\n type: \"paragraph\",\n text: \"Local-stdio installs (Claude Desktop, Cursor, Cline, Continue, Cowork) do not have this cap and should keep using `file_data` for small-to-medium files. This tool is for the hosted connector path or any sandboxed environment where you can't reliably stream the file through the tool call.\",\n },\n { type: \"heading\", level: 3, id: \"request-upload-use-when\", text: \"When to use\" },\n {\n type: \"list\",\n items: [\n \"The user has a file to extract and you are running in a hosted-connector environment (Claude.ai, ChatGPT) where `file_data` is not reliable.\",\n \"The file is larger than ~32 KB (typical for real invoices, contracts, COIs).\",\n \"The user explicitly asks for an upload link.\",\n ],\n },\n { type: \"heading\", level: 3, id: \"request-upload-do-not-use\", text: \"When not to use\" },\n {\n type: \"list\",\n items: [\n \"You can deliver the file directly via `file_data` (local-stdio installs with small files).\",\n \"The file is already accessible via a public URL — use `file_url` on `talonic_extract` instead.\",\n \"The document is already in the workspace — use `document_id` on `talonic_extract` instead.\",\n ],\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"filename\",\n type: \"string\",\n required: true,\n description:\n \"Filename with extension (e.g. `invoice.pdf`). Used to pre-allocate the document record and infer MIME type.\",\n },\n ],\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"filename\": \"invoice-2026-001.pdf\"\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"document_id\": \"doc_8f3a2b9c-1d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n \"upload_url\": \"https://app.talonic.com/u/069b8d9a-b05d-41df-8047-129af7c7aad5\",\n \"expires_at\": \"2026-05-28T20:35:00.000Z\"\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"request-upload-workflow\",\n text: \"End-to-end workflow\",\n },\n {\n type: \"list\",\n ordered: true,\n items: [\n \"Call `talonic_request_upload` with the filename. Capture `document_id`, `upload_url`, and `expires_at` from the response.\",\n \"Show the `upload_url` to the user and ask them to open it in a new browser tab and drop the file.\",\n 'Poll `talonic_get_document` with the `document_id` until `status` is `completed`. **Do not skip this step** — a user confirmation like \"uploaded\" only signals that the browser-side upload finished, not that server-side OCR and processing are done.',\n 'Once `status === \"completed\"`, call `talonic_extract` with the `document_id` and a `schema` or `schema_id` to pull out structured fields.',\n ],\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: 'Server-side processing (OCR + classification) typically takes 10–30 seconds after the browser upload completes. The agent must poll `talonic_get_document` until `status === \"completed\"` before calling `talonic_extract`. Calling extract too early returns errors that look like the file is missing.',\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Full sequence for a Claude.ai hosted-connector chat\",\n code: `// 1. Agent requests an upload link.\n// talonic_request_upload({ filename: \"rental-agreement.pdf\" })\n{\n \"document_id\": \"doc_1a2b3c4d-...\",\n \"upload_url\": \"https://app.talonic.com/u/069b8d9a-...\",\n \"expires_at\": \"2026-05-28T20:35:00.000Z\"\n}\n\n// 2. Agent: \"Open this link in a new tab and drop your file:\n// https://app.talonic.com/u/069b8d9a-...\n// I'll let you know once Talonic is done processing.\"\n\n// 3. After user drops the file, agent polls:\n// talonic_get_document({ document_id: \"doc_1a2b3c4d-...\" })\n// → status: \"processing\" → wait ~10s, poll again\n// → status: \"completed\" → ready to extract\n\n// 4. Agent extracts:\n// talonic_extract({\n// document_id: \"doc_1a2b3c4d-...\",\n// schema_id: \"SCH-RENTAL01\"\n// })\n// → structured JSON with per-field confidence scores`,\n },\n {\n type: \"paragraph\",\n text: \"The pre-allocated `document_id` is a real Talonic document from the moment the upload link is minted, but it stays in `pending` status until the user actually uploads. If the user closes the tab or the link expires (`expires_at`) without uploading, the document remains in `pending` and can be cleaned up via the dashboard. Re-issuing a fresh upload link for the same file is safe: the new link creates a new `document_id` with no link to the abandoned one.\",\n },\n {\n type: \"paragraph\",\n text: \"Agents should treat the `upload_url` as user-only information and never attempt to PUT to it themselves from the sandbox. Most sandboxed environments (Claude.ai's web tools, ChatGPT's Code Interpreter) cannot reach arbitrary S3-like endpoints, and even when they can, asking the user to open the link in their own browser preserves the user-agent boundary and avoids surprising the user with a backend upload they did not consent to.\",\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"talonic_get_document\", slug: \"talonic-get-document\" },\n { label: \"Drag & Drop Files\", slug: \"drag-and-drop\" },\n { label: \"Known Limitations\", slug: \"known-limitations\" },\n ],\n faq: [\n {\n question: \"When should the agent use `talonic_request_upload` instead of `file_data`?\",\n answer:\n \"In hosted-connector environments (Claude.ai web, ChatGPT) where tool-call arguments are capped around ~32 KB decoded payload. Real-world documents (100 KB+) get silently truncated when sent via file_data. Local-stdio installs (Claude Desktop, Cursor, Cline, Continue, Cowork) have no such cap and can keep using file_data.\",\n },\n {\n question: \"Does a user message like 'uploaded' mean the file is ready to extract?\",\n answer:\n \"No. That confirms only the browser-side upload finished. Server-side OCR and extraction typically need another 10–30 seconds. The agent must poll talonic_get_document until status is 'completed' before calling talonic_extract; calling earlier may return errors that look like the file is missing.\",\n },\n {\n question: \"What happens if the user never opens the upload link?\",\n answer:\n \"The pre-allocated document_id remains in pending status. The expires_at timestamp indicates when the upload URL stops accepting writes — typically a short window (minutes). Past that, request a fresh link with talonic_request_upload again; the new call mints a new document_id and a new URL.\",\n },\n {\n question: \"Can the agent PUT the file to the upload_url itself?\",\n answer:\n \"It usually cannot — Claude.ai's sandbox and similar hosted environments restrict outbound egress to arbitrary endpoints. Even where it would technically work, you should still hand the link to the user: it preserves the user-agent boundary (the user controls what file gets uploaded) and matches what every other browser-handoff flow looks like.\",\n },\n {\n question: \"Why a separate tool instead of changing `talonic_extract`?\",\n answer:\n \"Keeping the upload-link step explicit makes the agent's reasoning visible to the user (the user sees an upload link in chat and knows what's happening). Folding it into talonic_extract would either silently change the contract for small files or introduce a hidden mode switch — both bad for predictability.\",\n },\n ],\n mentions: [\n \"upload\",\n \"browser-handoff\",\n \"presigned URL\",\n \"document_id\",\n \"Claude.ai\",\n \"32 KB cap\",\n ],\n },\n]\n","import type { RawSection } from \"../types\"\n\nexport const sections: RawSection[] = [\n {\n slug: \"drag-and-drop\",\n parentSlug: \"features\",\n title: \"Drag & Drop Files\",\n seoTitle: \"Drag & Drop File Support — Talonic MCP\",\n description:\n \"Drop PDFs and documents directly into Claude Desktop, Cursor, or Cowork and extract data without file path configuration.\",\n content: [\n {\n type: \"paragraph\",\n text: \"When the user drag-drops a PDF (or any supported file) into a chat-style MCP host such as Claude Desktop, Cowork, or Cursor, the file lands in a host-owned sandbox directory the MCP server cannot read. The path the host hands the agent is meaningless to a separately-running `npx` MCP process.\",\n },\n {\n type: \"paragraph\",\n text: \"`@talonic/mcp@0.1.4` and later solve this by accepting **`file_data`** (base64-encoded file bytes) and **`filename`** on `talonic_extract` and `talonic_to_markdown`. The agent reads the file bytes from the conversation, base64-encodes them, and passes them through the MCP tool call. The MCP server decodes, infers MIME type from the filename, and uploads to the Talonic API.\",\n },\n {\n type: \"paragraph\",\n text: \"This approach works transparently across all chat-style MCP clients. The agent does not need to know where the file is stored on disk, and the user does not need to configure file paths or directory permissions. The entire flow — from drop to structured extraction — happens in a single conversation turn.\",\n },\n {\n type: \"paragraph\",\n text: \"Supported file types include PDF, PNG, JPG, TIFF, DOCX, XLSX, and other common document formats. The MCP server infers the MIME type from the `filename` extension, so always include the original file extension when passing `file_data`. If the extension is missing or unusual, the server may reject the upload with an `unsupported_file_type` error.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"drag-drop-example\",\n text: \"Example: drag-and-drop extraction flow\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"What the agent sends when a user drops a PDF\",\n code: `// User drops \"receipt-2026-05.pdf\" into the chat\n// The MCP client base64-encodes the file bytes automatically\n// Agent calls talonic_extract:\n{\n \"file_data\": \"JVBERi0xLjQKJcOkw7zDtsO8...\",\n \"filename\": \"receipt-2026-05.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"merchant\": { \"type\": \"string\" },\n \"date\": { \"type\": \"string\", \"format\": \"date\" },\n \"total\": { \"type\": \"number\" },\n \"payment_method\": { \"type\": \"string\" }\n },\n \"required\": [\"merchant\", \"total\"]\n }\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Extraction response from dropped file\",\n code: `{\n \"status\": \"complete\",\n \"document\": {\n \"id\": \"doc_f1e2...\",\n \"filename\": \"receipt-2026-05.pdf\",\n \"pages\": 1,\n \"type_detected\": \"receipt\"\n },\n \"data\": {\n \"merchant\": \"Coffee House Berlin\",\n \"date\": \"2026-05-07\",\n \"total\": 14.80,\n \"payment_method\": \"Visa ending 4242\"\n },\n \"confidence\": { \"overall\": 0.95 }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"The drag-and-drop flow works identically across Claude Desktop, Cowork, and other chat-style MCP clients that support file attachments. The key requirement is that the client encodes the file as base64 and passes it in the `file_data` parameter alongside the original `filename`. The MCP server uses the filename extension to determine the MIME type, decodes the base64 bytes, and uploads the file to the Talonic API in a single request.\",\n },\n {\n type: \"paragraph\",\n text: \"This `file_data` path works without limit in local-stdio installs (Claude Desktop, Cursor, Cline, Continue, Cowork). It does **not** work in the **Claude.ai hosted connector**, which caps tool-call arguments at ~32 KB decoded (~43 KB base64, measured against production) — a real PDF is silently truncated. In hosted connectors, use **`talonic_request_upload`**: it returns a browser link (`https://app.talonic.com/u/<token>`) the user opens to drop the file, after which the agent polls `talonic_get_document` until `status` is `completed` and then calls `talonic_extract` by `document_id`. `file_url` (a publicly reachable URL) and a pre-uploaded `document_id` also work.\",\n },\n {\n type: \"callout\",\n text: \"Tool descriptions advertise `file_data` as the recommended input for chat-style clients, so well-trained agents reach for it automatically. No client-side configuration required.\",\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"talonic_to_markdown\", slug: \"talonic-to-markdown\" },\n { label: \"Common Issues\", slug: \"common-issues\" },\n ],\n faq: [\n {\n question: \"Can I drag and drop files into Claude Desktop with Talonic?\",\n answer:\n \"Yes. Since @talonic/mcp@0.1.4, talonic_extract and talonic_to_markdown accept base64 file data directly, so you can drop a PDF into Claude Desktop and extract data without file path setup.\",\n },\n {\n question: \"What file types can I drag and drop?\",\n answer:\n \"PDF, PNG, JPG, TIFF, DOCX, XLSX, and other common document formats. The MCP server infers the MIME type from the filename extension.\",\n },\n {\n question: \"Why does drag-and-drop fail with an unsupported_file_type error?\",\n answer:\n \"The filename is missing a recognisable extension. Make sure the original filename with its extension is passed in the filename parameter alongside file_data.\",\n },\n {\n question: \"What happens if the dropped file is too large?\",\n answer:\n \"Base64 encoding increases payload size by about 33%. Most local MCP clients handle this fine, but hosted connectors may have payload limits. For large files (over 10 MB), use file_url with a public URL or upload via the Talonic dashboard and reference by document_id instead.\",\n },\n {\n question: \"Do I need to configure anything for drag-and-drop to work?\",\n answer:\n \"No. The file_data parameter is advertised in the tool descriptions, so MCP clients that support file attachments automatically encode and pass the file. Just drop the file into the chat and provide a schema — the agent handles the rest.\",\n },\n ],\n mentions: [\"drag-and-drop\", \"file_data\", \"base64\", \"Claude Desktop\"],\n },\n {\n slug: \"how-it-works\",\n parentSlug: \"features\",\n title: \"How It Works\",\n seoTitle: \"How Talonic MCP Works — Talonic Docs\",\n description:\n \"Architecture of the Talonic MCP server: MCP protocol over stdio to the agent, HTTPS with Bearer auth to api.talonic.com.\",\n content: [\n {\n type: \"code\",\n language: \"text\",\n title: \"Architecture\",\n code: `Agent (Claude Desktop / Cursor / Cline / etc.)\n ↓ MCP protocol over stdio\nTalonic MCP server (this package)\n ↓ HTTPS, Bearer auth\napi.talonic.com`,\n },\n {\n type: \"paragraph\",\n text: \"Each tool call is one HTTP request to the Talonic API, using your API key. The server handles auth, retries on transient failures (429, 5xx), MIME-type detection on file uploads, multipart serialisation, and structured error formatting.\",\n },\n {\n type: \"paragraph\",\n text: \"The MCP server acts as a thin translation layer between the MCP protocol and the Talonic REST API. It receives tool calls from the agent over **stdio** (local mode) or **streamable HTTP** (hosted mode), validates parameters, constructs the appropriate API request, and returns the response in the MCP-standard `content` format the agent expects.\",\n },\n {\n type: \"paragraph\",\n text: \"For file uploads, the server handles the complexity of multipart form encoding. It reads file bytes from `file_data` (base64), `file_path` (local disk), or `file_url` (remote URL), detects the MIME type from the filename extension, and streams the upload to `api.talonic.com`. This means the agent never needs to deal with multipart boundaries or content-type headers.\",\n },\n {\n type: \"paragraph\",\n text: \"Error handling is designed for agent consumption. API errors are reformatted into structured messages that include the error type, a human-readable description, and actionable next steps. For example, a missing schema error tells the agent to provide a `schema` or `schema_id`, rather than returning a raw 400 status code.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"request-lifecycle\",\n text: \"Request lifecycle\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"What happens during a talonic_extract call\",\n code: `// 1. Agent sends MCP tool call over stdio/HTTP:\n{\n \"tool\": \"talonic_extract\",\n \"arguments\": {\n \"file_url\": \"https://example.com/invoice.pdf\",\n \"schema\": { \"type\": \"object\", \"properties\": { \"total\": { \"type\": \"number\" } } }\n }\n}\n\n// 2. MCP server validates parameters, constructs API request:\n// POST https://api.talonic.com/v1/extract\n// Authorization: Bearer tlnc_...\n// Content-Type: multipart/form-data (for file uploads)\n\n// 3. API processes: download file → OCR → extract fields → validate schema\n\n// 4. MCP server formats response as MCP content:\n{\n \"content\": [\n {\n \"type\": \"text\",\n \"text\": \"{ \\\\\"status\\\\\": \\\\\"complete\\\\\", \\\\\"data\\\\\": { \\\\\"total\\\\\": 1500.00 }, ... }\"\n }\n ]\n}`,\n },\n {\n type: \"paragraph\",\n text: \"The MCP server is stateless between tool calls. It does not cache documents, schemas, or extraction results locally. Every tool call is an independent HTTP request to the Talonic API, which means the server can be restarted at any time without losing state. All persistence — documents, schemas, extraction history — lives in the Talonic cloud workspace, accessible via your API key.\",\n },\n {\n type: \"paragraph\",\n text: \"Authentication is handled transparently by the MCP server. For the local `npx` option, the server reads the `TALONIC_API_KEY` environment variable at startup and attaches it as a `Bearer` token to every API request. For the hosted option at `mcp.talonic.com`, the client passes the API key in the `Authorization` header, and the hosted server forwards it to the Talonic API. In neither case does the API key reach the AI agent — it stays within the MCP server process boundary.\",\n },\n {\n type: \"paragraph\",\n text: \"Transport modes differ between local and hosted deployments. The local `npx` server communicates with the MCP client over **stdio** (standard input/output), which is the default transport for locally-spawned MCP servers. The hosted server at `mcp.talonic.com` uses **streamable HTTP**, where the client sends HTTP requests and receives streamed responses. Both transports implement the same MCP protocol, so tool behaviour is identical regardless of transport mode.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"The MCP server automatically retries on `429` (rate limit) and `5xx` (server error) responses with exponential backoff. Agents do not need to implement retry logic themselves.\",\n },\n ],\n related: [\n { label: \"Environment Variables\", slug: \"env-variables\" },\n { label: \"Node SDK\", slug: \"introduction\" },\n { label: \"Install Overview\", slug: \"install-overview\" },\n ],\n faq: [\n {\n question: \"How does the Talonic MCP server work?\",\n answer:\n \"The MCP server communicates with AI agents over stdio using the MCP protocol. Each tool call translates to one HTTPS request to api.talonic.com with automatic auth, retries, and error formatting.\",\n },\n {\n question: \"Does the MCP server handle retries automatically?\",\n answer:\n \"Yes. The server retries on 429 (rate limit) and 5xx (server error) responses with exponential backoff. Agents do not need to implement retry logic.\",\n },\n {\n question: \"How are errors returned to the agent?\",\n answer:\n \"API errors are reformatted into structured messages with error type, description, and actionable next steps. The agent receives clear guidance instead of raw HTTP status codes.\",\n },\n {\n question: \"Does the MCP server store any data locally?\",\n answer:\n \"No. The server is stateless between tool calls. It does not cache documents, schemas, or results locally. All persistence lives in the Talonic cloud workspace. The server can be restarted at any time without losing state.\",\n },\n {\n question: \"Is my API key exposed to the AI agent?\",\n answer:\n \"No. The API key stays within the MCP server process boundary. For local setups, it is read from the TALONIC_API_KEY environment variable. For hosted setups, it is passed in the Authorization header. In neither case does the key reach the AI agent's context window.\",\n },\n ],\n mentions: [\"stdio\", \"HTTPS\", \"Bearer auth\", \"architecture\", \"retry\", \"error handling\"],\n },\n]\n","import type { RawSection } from \"../types\"\n\nexport const sections: RawSection[] = [\n {\n slug: \"env-variables\",\n parentSlug: \"configuration\",\n title: \"Environment Variables\",\n seoTitle: \"Configuration — Talonic MCP\",\n description:\n \"Environment variables for configuring the Talonic MCP server: API key and optional base URL override.\",\n content: [\n { type: \"paragraph\", text: \"Set via the `env` block in your MCP client config:\" },\n {\n type: \"param-table\",\n params: [\n {\n name: \"TALONIC_API_KEY\",\n type: \"string\",\n required: true,\n description: \"Your Talonic API key. Starts with `tlnc_`.\",\n },\n {\n name: \"TALONIC_BASE_URL\",\n type: \"string\",\n description: \"Override the API base URL.\",\n default: \"https://api.talonic.com\",\n },\n ],\n },\n {\n type: \"paragraph\",\n text: \"The `TALONIC_API_KEY` is the only required configuration. It authenticates every API call the MCP server makes on your behalf. The key must start with `tlnc_` — if you pass a key with a different prefix, the server will reject it at startup with a clear error message.\",\n },\n {\n type: \"paragraph\",\n text: \"The `TALONIC_BASE_URL` override is rarely needed. It exists for enterprise customers with a dedicated Talonic deployment or for developers testing against a staging environment. Most users should leave this unset, which defaults to `https://api.talonic.com`.\",\n },\n {\n type: \"paragraph\",\n text: \"Environment variables are set differently depending on your MCP client and deployment mode. For local `npx` setups, they go in the `env` block of the MCP client config JSON. For the hosted server at `mcp.talonic.com`, the API key is passed as a `Bearer` token in the `Authorization` header instead of an environment variable.\",\n },\n {\n type: \"paragraph\",\n text: \"If the MCP server cannot read the API key at startup, it exits with a descriptive error. Common causes include a malformed `env` block in the JSON config, a typo in the variable name, or the MCP client not passing environment variables through to the spawned process. Always fully restart the client after editing the config.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"env-local-config\",\n text: \"Local npx configuration example\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Full MCP client config with environment variables\",\n code: `{\n \"mcpServers\": {\n \"talonic\": {\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": {\n \"TALONIC_API_KEY\": \"tlnc_your_key_here\"\n }\n }\n }\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"env-base-url-override\",\n text: \"Base URL override for enterprise deployments\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Config with custom base URL for a dedicated Talonic deployment\",\n code: `{\n \"mcpServers\": {\n \"talonic\": {\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": {\n \"TALONIC_API_KEY\": \"tlnc_your_key_here\",\n \"TALONIC_BASE_URL\": \"https://api.talonic.yourcompany.com\"\n }\n }\n }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"For teams managing multiple environments (development, staging, production), each environment should use a separate API key pointing to a different Talonic workspace. This ensures that test documents and schemas do not mix with production data. Create separate config files or use environment-specific variable values to switch between workspaces. The `TALONIC_BASE_URL` override is only needed for enterprise customers with a dedicated Talonic deployment — all other users should leave it unset.\",\n },\n {\n type: \"paragraph\",\n text: \"Some MCP clients support reading environment variables from the system shell rather than the config file. If your client supports this, you can set `TALONIC_API_KEY` in your shell profile (`.bashrc`, `.zshrc`, or equivalent) and omit the `env` block from the config. This approach is slightly more secure because the key is not stored in a JSON file that might be accidentally committed to version control. However, most MCP clients require the `env` block explicitly, so check your client's documentation.\",\n },\n {\n type: \"paragraph\",\n text: \"When using the hosted server at `mcp.talonic.com`, environment variables are not used at all. Instead, the API key is passed in the `Authorization` header as a `Bearer` token. This means the `env` block is irrelevant for hosted configurations — only the `url` and `headers` fields matter. If you switch from local to hosted, remove the `env`, `command`, and `args` fields and replace them with `url` and `headers`.\",\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: \"Never commit your `TALONIC_API_KEY` to version control. If using a shared MCP config template, replace the key with a placeholder like `tlnc_your_key_here` before sharing.\",\n },\n ],\n related: [\n { label: \"Install Overview\", slug: \"install-overview\" },\n { label: \"Get an API Key\", slug: \"get-api-key\" },\n { label: \"Common Issues\", slug: \"common-issues\" },\n ],\n faq: [\n {\n question: \"What environment variables does the Talonic MCP server need?\",\n answer:\n \"TALONIC_API_KEY (required, starts with tlnc_) and optionally TALONIC_BASE_URL to override the API endpoint.\",\n },\n {\n question: \"Where do I set environment variables for the MCP server?\",\n answer:\n \"For local npx setups, set them in the env block of your MCP client config JSON. For the hosted server, the API key is passed as a Bearer token in the Authorization header instead.\",\n },\n {\n question: \"What happens if the API key is missing or invalid?\",\n answer:\n \"The MCP server exits at startup with a descriptive error message. Check that the env block in your config is correctly formatted and the key starts with tlnc_. Restart the client after fixing.\",\n },\n {\n question: \"Can I set the API key in my shell profile instead of the config file?\",\n answer:\n \"Some MCP clients support reading environment variables from the system shell. If yours does, set TALONIC_API_KEY in .bashrc or .zshrc and omit the env block from the config. However, most clients require the env block explicitly, so check your client documentation first.\",\n },\n {\n question: \"Do I need TALONIC_BASE_URL for normal usage?\",\n answer:\n \"No. TALONIC_BASE_URL defaults to https://api.talonic.com and only needs to be overridden for enterprise customers with a dedicated Talonic deployment or developers testing against a staging environment. Leave it unset for standard usage.\",\n },\n ],\n mentions: [\"TALONIC_API_KEY\", \"TALONIC_BASE_URL\", \"environment variables\"],\n },\n]\n","import type { RawSection } from \"../types\"\n\nexport const sections: RawSection[] = [\n {\n slug: \"common-issues\",\n parentSlug: \"troubleshooting\",\n title: \"Common Issues\",\n seoTitle: \"Troubleshooting — Talonic MCP\",\n description:\n \"Solutions for common Talonic MCP server issues: missing API key, server not appearing, extract errors, and filter validation.\",\n content: [\n {\n type: \"paragraph\",\n text: \"This section covers the most frequently encountered issues when setting up and using the Talonic MCP server. Each issue includes a description, the root cause, and the fix. If your problem is not listed here, check the Known Limitations section or reach out via GitHub issues.\",\n },\n {\n type: \"paragraph\",\n text: \"Most issues fall into two categories: **configuration problems** (the server does not start or connect) and **tool errors** (the server is running but a specific tool call fails). Configuration problems are almost always caused by malformed JSON, a missing API key, or not restarting the MCP client after editing the config.\",\n },\n {\n type: \"paragraph\",\n text: \"Tool errors typically include a structured error message with an error type and description. Read the error message carefully — it usually tells you exactly what is wrong and how to fix it. For example, a `VALIDATION_ERROR` on `talonic_filter` means the field name is not in the API's registry.\",\n },\n {\n type: \"paragraph\",\n text: \"When debugging, start by verifying the MCP server is running. Check the connected servers list in your MCP client. If Talonic is not listed, the issue is in your config or client setup. If it is listed but a tool call fails, the issue is with the tool input or API-side.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"missing-api-key\",\n text: \"TALONIC_API_KEY environment variable is required\",\n },\n {\n type: \"paragraph\",\n text: \"The `env` block in your MCP client config is missing or not being read. Double-check the JSON shape. After editing the config, fully restart the client (not just the conversation).\",\n },\n\n {\n type: \"heading\",\n level: 3,\n id: \"server-not-found\",\n text: \"Talonic does not appear in connected servers\",\n },\n {\n type: \"paragraph\",\n text: 'Make sure the `command` is `npx` and the `args` are exactly `[\"-y\", \"@talonic/mcp@latest\"]`. Sanity check: run `npx -y @talonic/mcp@latest --version` in any terminal — it should print a version number.',\n },\n\n {\n type: \"heading\",\n level: 3,\n id: \"extract-no-schema\",\n text: \"talonic_extract returns a validation error when no schema is given\",\n },\n {\n type: \"paragraph\",\n text: \"By design. To keep results reliable, the MCP layer asks for the fields you want when a call omits `schema`, `schema_id`, and `auto_schema`. The error hands back a ready-to-paste minimal JSON Schema (tailored to your `instructions`) so the retry succeeds immediately. Three ways forward: provide an inline `schema` (full JSON Schema recommended), pass a `schema_id` from `talonic_list_schemas`, or set `auto_schema: true` for open capture — Talonic discovers the fields and returns a suggested schema you can refine.\",\n },\n\n {\n type: \"heading\",\n level: 3,\n id: \"unsupported-file\",\n text: \"talonic_extract rejects with unsupported_file_type\",\n },\n {\n type: \"paragraph\",\n text: \"The MIME type was inferred as `application/octet-stream`. The SDK infers from common file extensions; if your filename has an unusual extension, this may occur. A future tool version will expose explicit `content_type` passthrough.\",\n },\n\n {\n type: \"heading\",\n level: 3,\n id: \"filter-validation\",\n text: 'talonic_filter VALIDATION_ERROR / \"No field matches name\"',\n },\n {\n type: \"paragraph\",\n text: \"The field name is not in the API's field registry. Field names must be canonical names (e.g. `vendor.name`, `policy.0_term_end`). Call `talonic_search` first; canonical names appear in `fields[].canonicalName`.\",\n },\n\n {\n type: \"heading\",\n level: 3,\n id: \"stale-descriptions\",\n text: \"Tool descriptions look wrong in my client\",\n },\n {\n type: \"paragraph\",\n text: \"Some MCP clients cache tool descriptions. Restart the client after a server update.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"auth-error\",\n text: \"Authentication error on every tool call\",\n },\n {\n type: \"paragraph\",\n text: \"If every tool call returns an authentication error, the credential the server is using is missing, malformed, or revoked. For the local npx option, check that the `env` block in your config has the correct variable name (`TALONIC_API_KEY`, not `TALONIC_KEY` or `API_KEY`) and that the value starts with `tlnc_`. For the hosted server with a custom-header client, verify the `Authorization` header is formatted as `Bearer tlnc_...` with a space after `Bearer`. For the Claude.ai connector OAuth flow, see the OAuth-specific entry below.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"oauth-flow\",\n text: \"Claude.ai connector: stuck on sign-in or callback\",\n },\n {\n type: \"paragraph\",\n text: \"The Claude.ai custom-connector flow uses OAuth 2.1 with PKCE against `app.talonic.com`. If the sign-in window opens but does not return to Claude.ai, or the connector reports `disconnected` after authorising, walk through these checks. Make sure you are signed in to the same Talonic account in `app.talonic.com` that owns the workspace you want to use. Allow third-party cookies for `app.talonic.com` and `claude.ai`; some browsers block the post-consent redirect otherwise. After granting consent, you should be redirected back to Claude.ai automatically; if the tab stays on `app.talonic.com`, click the Talonic logo or close the tab and reopen the connector to retry. If you have multiple Talonic accounts, sign out of `app.talonic.com` first, then start the connector flow again so the right account is used. As a last resort, remove the connector in Claude.ai and add it again with `https://mcp.talonic.com/mcp` as the URL.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"timeout-errors\",\n text: \"Tool calls time out on large documents\",\n },\n {\n type: \"paragraph\",\n text: \"Large documents (20+ pages) may take longer than some MCP clients' default timeout. The Talonic API processes documents up to 100 pages, but extraction time scales with page count. If you experience timeouts, try splitting large documents into smaller sections before uploading. Alternatively, check if your MCP client has a configurable timeout setting — increasing it to 60 seconds should accommodate most documents.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"debug-checklist\",\n text: \"Debug checklist\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Step-by-step debug commands\",\n code: `// 1. Verify the MCP server installs and runs:\n// Terminal: npx -y @talonic/mcp@latest --version\n// Expected: prints version number (e.g., 0.1.6)\n\n// 2. Verify your API key is valid:\n// Terminal: curl -H \"Authorization: Bearer tlnc_your_key\" https://api.talonic.com/v1/schemas\n// Expected: JSON response (even if empty schemas array)\n\n// 3. Validate your config JSON:\n// Paste your config into https://jsonlint.com\n// Common errors: trailing commas, missing quotes, wrong brackets\n\n// 4. Verify client picked up the config:\n// Check the connected servers list in your MCP client\n// If Talonic is missing, the config is not being read`,\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"When reporting issues, include the MCP server version (`npx -y @talonic/mcp@latest --version`), your MCP client name and version, and the full error message. This helps diagnose problems faster.\",\n },\n ],\n related: [\n { label: \"Known Limitations\", slug: \"known-limitations\" },\n { label: \"Upgrading\", slug: \"upgrading\" },\n { label: \"Environment Variables\", slug: \"env-variables\" },\n ],\n faq: [\n {\n question: \"Why does Talonic MCP not appear in Claude Desktop?\",\n answer:\n 'Check that command is \"npx\" and args are [\"-y\", \"@talonic/mcp@latest\"]. Run npx -y @talonic/mcp@latest --version in a terminal to verify. Fully restart Claude Desktop (Cmd+Q).',\n },\n {\n question: \"Why does talonic_extract fail with a validation error?\",\n answer:\n \"The most common cause is that no fields were specified. Provide a schema (inline JSON Schema) or a schema_id from talonic_list_schemas — or set auto_schema: true for open capture, where Talonic discovers the fields and returns a suggested schema. The validation error already hands back a ready-to-paste minimal schema, so the retry succeeds on the next call.\",\n },\n {\n question: \"How do I debug MCP server connection issues?\",\n answer:\n \"First verify the server runs standalone: npx -y @talonic/mcp@latest --version. Then check your config JSON is valid, the API key starts with tlnc_, and you have fully restarted your MCP client.\",\n },\n {\n question: \"Why do all tool calls return authentication errors?\",\n answer:\n \"The API key is missing, malformed, or revoked. Verify the key starts with tlnc_ in your config. For local setups, check the env block uses TALONIC_API_KEY (exact name). For hosted setups, check the Authorization header format is 'Bearer tlnc_...' with a space after Bearer. Regenerate the key in the dashboard if it was revoked.\",\n },\n {\n question: \"What should I do if large documents time out?\",\n answer:\n \"Documents over 20 pages may exceed some MCP clients' default timeout. Try splitting the document into smaller sections, or increase your MCP client's timeout setting to 60 seconds. The Talonic API supports documents up to 100 pages but processing time scales with page count.\",\n },\n ],\n mentions: [\"troubleshooting\", \"API key\", \"VALIDATION_ERROR\"],\n },\n {\n slug: \"known-limitations\",\n parentSlug: \"troubleshooting\",\n title: \"Known Limitations\",\n seoTitle: \"Known Limitations — Talonic MCP\",\n description:\n \"Current limitations in the Talonic MCP server v0.1: schema requirement, filter discoverability and typing, Claude.ai drag-and-drop stall, and unsurfaced cost.\",\n content: [\n {\n type: \"paragraph\",\n text: \"The Talonic MCP server v0.1 is production-ready but has a number of known limitations that are planned for future releases. Understanding these limitations helps agents make better decisions about when and how to use each tool.\",\n },\n {\n type: \"paragraph\",\n text: \"Most limitations relate to the extraction pipeline's maturity in v0.1. Certain filter operators, cost information, and per-field provenance have constraints. These are documented here so agent developers can set accurate expectations and build appropriate fallbacks.\",\n },\n {\n type: \"list\",\n items: [\n \"**`talonic_extract` needs to know which fields to pull.** Pass a `schema` (full JSON Schema recommended) or a `schema_id` — or set `auto_schema: true` for open capture, where Talonic discovers the fields and returns a suggested schema. A call that gives none of the three returns a validation error that hands back a ready-to-paste minimal schema, so the retry succeeds immediately.\",\n \"**Schema definition: prefer full JSON Schema.** The flat key-type map is documented as accepted; if you get a 'no fields' error from the API, fall back to JSON Schema.\",\n \"**Filter requires `filterable: true` fields.** Call `talonic_search` first; only entries in the response where `filterable: true` can be used as `field` (or `field_id`) on `talonic_filter`. Entries with `filterable: false` exist in the schema but have no extracted data yet.\",\n \"**Schema field type affects filter operators.** Numeric operators (`gt`, `gte`, `lt`, `lte`, `between`) only work on fields typed as `number` in the schema. Numeric values stored as strings (with currency symbols, locale formatting, etc.) silently return zero results. Type your schema fields appropriately at design time.\",\n \"**`is_not_empty` filter checks materialized data.** Results reflect values within seconds of extraction completing. For batch-mode documents, values are materialized after the batch poll cycle completes.\",\n \"**Dragging a file directly into a Claude.ai chat does not work through the hosted connector** — use `talonic_request_upload` instead. A base64-encoded real PDF exceeds Claude.ai's tool-call argument cap (~32 KB decoded / ~43 KB base64, measured against production), so `file_data` is silently truncated and the API returns `null` fields. This is a structural platform limit, not a Talonic bug. The supported path is the browser-handoff flow: `talonic_request_upload` returns an `app.talonic.com/u/<token>` link the user opens to drop the file; poll `talonic_get_document` until `status` is `completed`, then `talonic_extract` by `document_id`. Alternatives: `file_url` or a pre-uploaded `document_id`. Local-stdio installs (Claude Desktop, Cursor, Cline, Continue, Cowork) have no cap and use `file_data` directly.\",\n \"**Cost, EUR price, and remaining balance are not surfaced.** The API does not return them yet. Credit balance must be checked in the Talonic dashboard.\",\n ],\n },\n {\n type: \"paragraph\",\n text: \"Agents should handle these limitations gracefully. For the schema requirement, always construct or reference a schema before calling `talonic_extract`. For the missing cost information, direct users to the Talonic dashboard at `https://app.talonic.com` when they ask about pricing or credit balance.\",\n },\n {\n type: \"paragraph\",\n text: \"The `is_not_empty` operator is now available and checks the materialized values index, which updates within seconds of extraction completing. For batch-mode documents, materialization occurs after the batch poll cycle applies results.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"limitations-workarounds\",\n text: \"Workarounds summary\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Quick reference: limitation → workaround\",\n code: `// Schema required on talonic_extract\n// → Always pass schema (JSON Schema) or schema_id\n\n// is_not_empty checks materialized values (updated within seconds of extraction)\n\n// Drag-and-drop stalls on Claude.ai (hosted connector)\n// → Use file_url, document_id, or local stdio install\n\n// Numeric filter on string-typed field returns zero results\n// → Define numeric fields as type \"number\" in the schema\n\n// Filter on non-filterable field returns VALIDATION_ERROR\n// → Call talonic_search first, use fields where filterable: true`,\n },\n {\n type: \"paragraph\",\n text: \"When building agent workflows that will run unattended, design for these limitations explicitly. Check that every `talonic_extract` call includes a schema or schema_id. Validate filter field names against `talonic_search` results before constructing conditions. For file uploads in hosted connectors with size limits, prefer `file_url` or `document_id` over `file_data`. These defensive patterns ensure the agent handles edge cases gracefully instead of failing with cryptic errors.\",\n },\n {\n type: \"paragraph\",\n text: \"The Talonic team actively tracks these limitations and publishes fixes in minor version updates. Subscribe to the `@talonic/mcp` npm package changelog or watch the GitHub repository for release notes. Limitations that are resolved in newer versions are removed from this list. If you encounter a limitation not documented here, report it via GitHub issues with the MCP server version and a minimal reproduction case.\",\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: \"For predictable automated workflows, pin the fields with a `schema` or `schema_id`. When you don't yet know the fields, `auto_schema: true` (open capture) discovers them and returns a suggested schema you can save and reuse for stability.\",\n },\n ],\n related: [\n { label: \"Common Issues\", slug: \"common-issues\" },\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"talonic_filter\", slug: \"talonic-filter\" },\n ],\n faq: [\n {\n question: \"What are the known limitations of Talonic MCP?\",\n answer:\n \"talonic_extract needs fields specified via schema, schema_id, or auto_schema: true (open capture). Filter requires filterable: true fields (use talonic_search first to discover them). Numeric filter operators require schema fields typed as number. Drag-and-drop file uploads in Claude.ai currently stall via the hosted MCP; use file_url or document_id instead, or use the local stdio install. Cost and balance are not surfaced in tool responses yet.\",\n },\n {\n question: \"Can I extract without knowing the fields up front (schema-less)?\",\n answer:\n \"Yes. Set auto_schema: true on talonic_extract for open capture: Talonic discovers the document's fields and returns a suggested schema alongside the data. Refine and save that schema with talonic_save_schema for stable, repeatable extraction. For predictable production workflows, providing an explicit schema or schema_id is still recommended.\",\n },\n {\n question: \"How do I check my credit balance or costs?\",\n answer:\n \"Cost information is not surfaced in v0.1 tool responses. Check your credit balance and usage in the Talonic dashboard at app.talonic.com.\",\n },\n {\n question: \"How do I report a new limitation or bug?\",\n answer:\n \"Open an issue on the @talonic/mcp GitHub repository with the MCP server version (npx -y @talonic/mcp@latest --version), your MCP client name and version, and a minimal reproduction case. Include the full error message if applicable.\",\n },\n {\n question: \"How do I work around the Claude.ai drag-and-drop limitation?\",\n answer:\n \"Claude.ai's hosted connector truncates large tool-call arguments, which breaks base64 file uploads. Use file_url with a publicly reachable URL, upload the file via the Talonic dashboard and use document_id, or switch to a local stdio install (Claude Desktop, Cursor, Cline) which has no parameter size cap.\",\n },\n ],\n mentions: [\n \"limitations\",\n \"schema\",\n \"filterable\",\n \"is_not_empty\",\n \"drag-and-drop\",\n \"rate limits\",\n ],\n },\n {\n slug: \"upgrading\",\n parentSlug: \"troubleshooting\",\n title: \"Upgrading\",\n seoTitle: \"Upgrading from Older Versions — Talonic MCP\",\n description:\n \"How to upgrade from older @talonic/mcp versions that had the silent-bin bug affecting MCP client launches.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Versions before `0.1.3` had a bug where the bundled MCP server bin would exit silently when launched via the npm bin symlink, which is exactly how every MCP client invokes it. If you see no `talonic_*` tools despite correct config, you are hitting that bug.\",\n },\n {\n type: \"paragraph\",\n text: \"The fix: point your `args` at `@latest` (or `@0.1.3` explicitly) and fully restart the client:\",\n },\n { type: \"code\", language: \"jsonc\", code: '\"args\": [\"-y\", \"@talonic/mcp@latest\"]' },\n {\n type: \"paragraph\",\n text: \"Using `@latest` is the recommended approach because it ensures you automatically receive new features, bug fixes, and improved tool descriptions on every client restart. If you need version stability for a production workflow, pin to a specific version like `@0.1.6` instead.\",\n },\n {\n type: \"paragraph\",\n text: \"After updating the `args` in your MCP client config, you must fully restart the client application. Simply starting a new conversation is not enough — the MCP server process must be terminated and re-spawned. On Claude Desktop, use Cmd+Q (macOS) or close from the system tray (Windows). On Cursor and VS Code-based clients, reload the window.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"upgrade-verify\",\n text: \"Verify the upgrade\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Check the installed version after upgrading\",\n code: `// In a terminal, verify the latest version installs:\n// npx -y @talonic/mcp@latest --version\n// Expected output: 0.1.6 (or the latest published version)\n\n// In your MCP client, verify tools are available:\n// Ask the agent: \"What version of Talonic MCP are you using?\"\n// Or call talonic_list_schemas — a successful response\n// confirms the server is running the updated version.`,\n },\n {\n type: \"paragraph\",\n text: \"When upgrading between minor versions, tool parameters and response shapes remain backward-compatible. New versions may add optional parameters to existing tools or introduce new tools, but they will not remove or change existing parameters. This means your existing agent workflows and saved schemas continue to work without modification after an upgrade.\",\n },\n {\n type: \"paragraph\",\n text: \"If you are running a pinned version and want to check whether a newer version is available, run `npm view @talonic/mcp version` in a terminal. This shows the latest published version on npm without installing it. Compare this against your pinned version to decide whether to upgrade. The changelog in the npm package description summarises what changed between versions.\",\n },\n {\n type: \"paragraph\",\n text: \"For teams with multiple developers using the Talonic MCP server, coordinate upgrades by updating the shared MCP config file or template. If different team members run different versions, tool descriptions and capabilities may vary, leading to inconsistent agent behaviour. Using `@latest` for all team members ensures everyone has the same tools and avoids version-related debugging sessions.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"If you are using the hosted server at `mcp.talonic.com`, upgrades are automatic. You do not need to change any configuration — the hosted server always runs the latest version.\",\n },\n ],\n related: [\n { label: \"Install Overview\", slug: \"install-overview\" },\n { label: \"Common Issues\", slug: \"common-issues\" },\n ],\n faq: [\n {\n question: \"How do I upgrade the Talonic MCP server?\",\n answer:\n 'Set args to [\"-y\", \"@talonic/mcp@latest\"] in your MCP client config and fully restart the client. Versions before 0.1.3 had a silent-bin bug that prevented the server from booting.',\n },\n {\n question: \"Do I need to upgrade if I use the hosted server?\",\n answer:\n \"No. The hosted server at mcp.talonic.com is automatically updated to the latest version. No configuration changes are needed on your end.\",\n },\n {\n question: \"Should I pin to a specific version or use @latest?\",\n answer:\n \"Use @latest for development and most use cases — it picks up fixes automatically. Pin to a specific version (e.g., @0.1.6) only if you need strict version stability in production workflows.\",\n },\n {\n question: \"Are upgrades backward-compatible?\",\n answer:\n \"Yes. Minor version upgrades maintain backward compatibility — existing tool parameters and response shapes are preserved. New versions may add optional parameters or new tools, but will not break existing workflows, schemas, or agent integrations.\",\n },\n {\n question: \"How do I check if a newer version is available?\",\n answer:\n \"Run npm view @talonic/mcp version in a terminal to see the latest published version on npm. Compare against your pinned version or run npx -y @talonic/mcp@latest --version to see what @latest resolves to.\",\n },\n ],\n mentions: [\"upgrade\", \"silent-bin bug\", \"0.1.3\", \"@latest\"],\n },\n]\n","// ---------------------------------------------------------------------------\n// Structured content export for @talonic/mcp documentation.\n//\n// ⚠ This module is the source-of-truth for talonic.com/docs/mcp/* pages.\n// The website's <McpContentPage> calls getMcpSection(slug) at render time.\n// docs/sections.json in this repo is a SEPARATE surface that feeds the\n// SDK/API/Platform doc pages on the website, NOT the MCP doc pages.\n// Full architecture, \"add a new tool\" checklist, and failure modes:\n// docs/architecture/docs-pipeline.md\n//\n// Usage:\n// import { getMcpSection, getAllMcpSections, MCP_NAV_SECTIONS } from '@talonic/mcp/content'\n// ---------------------------------------------------------------------------\n\nexport type { DocBlock, DocSection, RawSection, Param, HttpMethod, NavSection } from \"./types\"\n\nexport { MCP_NAV_SECTIONS } from \"./seo\"\n\nimport type { DocSection, RawSection } from \"./types\"\nimport { deriveBreadcrumbs, derivePrevNext } from \"./helpers\"\nimport { MCP_NAV_SECTIONS } from \"./seo\"\n\n// --- Section imports ---\nimport { sections as overview } from \"./sections/overview\"\nimport { sections as install } from \"./sections/install\"\nimport { sections as tools } from \"./sections/tools\"\nimport { sections as features } from \"./sections/features\"\nimport { sections as configuration } from \"./sections/configuration\"\nimport { sections as troubleshooting } from \"./sections/troubleshooting\"\n\n// ---------------------------------------------------------------------------\n// Registry\n// ---------------------------------------------------------------------------\n\nconst ALL_RAW: RawSection[] = [\n ...overview,\n ...install,\n ...tools,\n ...features,\n ...configuration,\n ...troubleshooting,\n]\n\n// ---------------------------------------------------------------------------\n// Enrichment\n// ---------------------------------------------------------------------------\n\nfunction enrich(raw: RawSection[]): DocSection[] {\n return raw.map((r) => {\n const { prev, next } = derivePrevNext(MCP_NAV_SECTIONS, r.slug)\n return {\n ...r,\n breadcrumbs: deriveBreadcrumbs(MCP_NAV_SECTIONS, r.slug),\n prev,\n next,\n }\n })\n}\n\nlet _sections: DocSection[] | null = null\n\nfunction getSectionsAll(): DocSection[] {\n if (!_sections) {\n _sections = enrich(ALL_RAW)\n }\n return _sections\n}\n\n// ---------------------------------------------------------------------------\n// Public API\n// ---------------------------------------------------------------------------\n\n/** Get a single MCP section by slug, or null if not found. */\nexport function getMcpSection(slug: string): DocSection | null {\n return getSectionsAll().find((s) => s.slug === slug) ?? null\n}\n\n/** Get all MCP sections in reading order. */\nexport function getAllMcpSections(): DocSection[] {\n return getSectionsAll()\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../src/content/seo.ts","../src/content/helpers.ts","../src/content/sections/overview.ts","../src/content/sections/install.ts","../src/content/sections/tools.ts","../src/content/sections/features.ts","../src/content/sections/configuration.ts","../src/content/sections/troubleshooting.ts","../src/content/index.ts"],"names":["sections"],"mappings":";AAGO,IAAM,gBAAA,GAAiC;AAAA,EAC5C;AAAA,IACE,EAAA,EAAI,UAAA;AAAA,IACJ,KAAA,EAAO,UAAA;AAAA,IACP,QAAA,EAAU;AAAA,MACR,EAAE,EAAA,EAAI,kBAAA,EAAoB,KAAA,EAAO,cAAA,EAAe;AAAA,MAChD,EAAE,EAAA,EAAI,SAAA,EAAW,KAAA,EAAO,cAAA,EAAe;AAAA,MACvC,EAAE,EAAA,EAAI,aAAA,EAAe,KAAA,EAAO,gBAAA;AAAiB;AAC/C,GACF;AAAA,EACA;AAAA,IACE,EAAA,EAAI,SAAA;AAAA,IACJ,KAAA,EAAO,SAAA;AAAA,IACP,QAAA,EAAU;AAAA,MACR,EAAE,EAAA,EAAI,kBAAA,EAAoB,KAAA,EAAO,UAAA,EAAW;AAAA,MAC5C,EAAE,EAAA,EAAI,gBAAA,EAAkB,KAAA,EAAO,gBAAA,EAAiB;AAAA,MAChD,EAAE,EAAA,EAAI,QAAA,EAAU,KAAA,EAAO,QAAA,EAAS;AAAA,MAChC,EAAE,EAAA,EAAI,OAAA,EAAS,KAAA,EAAO,OAAA,EAAQ;AAAA,MAC9B,EAAE,EAAA,EAAI,UAAA,EAAY,KAAA,EAAO,UAAA,EAAW;AAAA,MACpC,EAAE,EAAA,EAAI,QAAA,EAAU,KAAA,EAAO,QAAA;AAAS;AAClC,GACF;AAAA,EACA;AAAA,IACE,EAAA,EAAI,OAAA;AAAA,IACJ,KAAA,EAAO,gBAAA;AAAA,IACP,QAAA,EAAU;AAAA,MACR,EAAE,EAAA,EAAI,iBAAA,EAAmB,KAAA,EAAO,iBAAA,EAAkB;AAAA,MAClD,EAAE,EAAA,EAAI,gBAAA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,EAAW;AACd,IAAA,SAAA,GAAY,OAAO,OAAO,CAAA;AAAA,EAC5B;AACA,EAAA,OAAO,SAAA;AACT;AAOO,SAAS,cAAc,IAAA,EAAiC;AAC7D,EAAA,OAAO,cAAA,GAAiB,IAAA,CAAK,CAAC,MAAM,CAAA,CAAE,IAAA,KAAS,IAAI,CAAA,IAAK,IAAA;AAC1D;AAGO,SAAS,iBAAA,GAAkC;AAChD,EAAA,OAAO,cAAA,EAAe;AACxB","file":"content.js","sourcesContent":["import type { NavSection } from \"./types\"\n\n/** MCP documentation navigation — synced to website */\nexport const MCP_NAV_SECTIONS: NavSection[] = [\n {\n id: \"overview\",\n label: \"Overview\",\n children: [\n { id: \"mcp-introduction\", label: \"Introduction\" },\n { id: \"why-mcp\", label: \"Why Use This\" },\n { id: \"get-api-key\", label: \"Get an API Key\" },\n ],\n },\n {\n id: \"install\",\n label: \"Install\",\n children: [\n { id: \"install-overview\", label: \"Overview\" },\n { id: \"claude-desktop\", label: \"Claude Desktop\" },\n { id: \"cursor\", label: \"Cursor\" },\n { id: \"cline\", label: \"Cline\" },\n { id: \"continue\", label: \"Continue\" },\n { id: \"cowork\", label: \"Cowork\" },\n ],\n },\n {\n id: \"tools\",\n label: \"Tool Reference\",\n children: [\n { id: \"talonic-extract\", label: \"talonic_extract\" },\n { id: \"talonic-search\", label: \"talonic_search\" },\n { id: \"talonic-filter\", label: \"talonic_filter\" },\n { id: \"talonic-get-document\", label: \"talonic_get_document\" },\n { id: \"talonic-to-markdown\", label: \"talonic_to_markdown\" },\n { id: \"talonic-list-schemas\", label: \"talonic_list_schemas\" },\n { id: \"talonic-save-schema\", label: \"talonic_save_schema\" },\n { id: \"talonic-get-balance\", label: \"talonic_get_balance\" },\n { id: \"talonic-request-upload\", label: \"talonic_request_upload\" },\n ],\n },\n {\n id: \"features\",\n label: \"Features\",\n children: [\n { id: \"drag-and-drop\", label: \"Drag & Drop Files\" },\n { id: \"how-it-works\", label: \"How It Works\" },\n ],\n },\n {\n id: \"configuration\",\n label: \"Configuration\",\n children: [{ id: \"env-variables\", label: \"Environment Variables\" }],\n },\n {\n id: \"troubleshooting\",\n label: \"Troubleshooting\",\n children: [\n { id: \"common-issues\", label: \"Common Issues\" },\n { id: \"known-limitations\", label: \"Known Limitations\" },\n { id: \"upgrading\", label: \"Upgrading\" },\n ],\n },\n]\n","// ---------------------------------------------------------------------------\n// Pure functions that derive breadcrumbs and prev/next from nav structure.\n// ---------------------------------------------------------------------------\n\ninterface NavChild {\n id: string\n label: string\n}\n\ninterface NavGroup {\n id: string\n label: string\n children?: NavChild[]\n}\n\nexport function deriveBreadcrumbs(\n sections: NavGroup[],\n leafId: string,\n): { label: string; slug: string }[] {\n const root = { label: \"MCP Server\", slug: \"mcp\" }\n\n for (const group of sections) {\n const child = group.children?.find((c) => c.id === leafId)\n if (child) {\n return [root, { label: group.label, slug: group.id }, { label: child.label, slug: child.id }]\n }\n }\n\n const topLevel = sections.find((s) => s.id === leafId)\n if (topLevel) {\n return [root, { label: topLevel.label, slug: topLevel.id }]\n }\n\n return [root]\n}\n\nexport function derivePrevNext(\n sections: NavGroup[],\n leafId: string,\n): { prev: { slug: string; label: string } | null; next: { slug: string; label: string } | null } {\n const flat: NavChild[] = sections.flatMap((s) => s.children ?? [{ id: s.id, label: s.label }])\n\n const idx = flat.findIndex((c) => c.id === leafId)\n if (idx === -1) return { prev: null, next: null }\n\n const prevItem = idx > 0 ? flat[idx - 1] : undefined\n const nextItem = idx < flat.length - 1 ? flat[idx + 1] : undefined\n\n return {\n prev: prevItem ? { slug: prevItem.id, label: prevItem.label } : null,\n next: nextItem ? { slug: nextItem.id, label: nextItem.label } : null,\n }\n}\n","import type { RawSection } from \"../types\"\n\nexport const sections: RawSection[] = [\n {\n slug: \"mcp-introduction\",\n parentSlug: \"overview\",\n title: \"Introduction\",\n seoTitle: \"MCP Server Introduction — Talonic Docs\",\n description:\n \"Official Talonic MCP server. Lets AI agents extract structured, schema-validated data from any document via the Model Context Protocol.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Official Talonic MCP server. Lets AI agents extract structured, schema-validated data from any document via the [Model Context Protocol](https://modelcontextprotocol.io).\",\n },\n {\n type: \"paragraph\",\n text: \"Eight tools and two resources: `talonic_extract`, `talonic_search`, `talonic_filter`, `talonic_get_document`, `talonic_to_markdown`, `talonic_list_schemas`, `talonic_save_schema`, `talonic_get_balance`, plus the `talonic://schemas` and `talonic://webhooks/reference` resources.\",\n },\n {\n type: \"paragraph\",\n text: \"Listed on the [official MCP Registry](https://registry.modelcontextprotocol.io/) as `io.github.talonicdev/talonic-mcp`. Verified end-to-end against production.\",\n },\n {\n type: \"paragraph\",\n text: \"The MCP server acts as a bridge between your AI agent and the Talonic document extraction API. Instead of writing custom HTTP integration code, agent developers get a standards-compliant MCP interface that any compatible client can discover and invoke automatically. The server handles authentication, file upload serialisation, retry logic, and structured error formatting so the agent can focus on the user's task.\",\n },\n {\n type: \"paragraph\",\n text: \"Installation takes under a minute. The recommended path is the hosted endpoint at `mcp.talonic.com` connected via Claude.ai's custom-connector flow, which uses OAuth 2.1 with PKCE and Dynamic Client Registration so no API key is pasted into config. For IDE-style clients, the local `npx` option uses a `TALONIC_API_KEY` environment variable and runs on any machine with Node.js 18 or later. A third path keeps the hosted endpoint but supplies a `Bearer tlnc_…` header for clients that do not yet handle the OAuth handshake.\",\n },\n {\n type: \"paragraph\",\n text: \"A typical agent conversation with Talonic starts when the user drops a document into the chat or asks the agent to process a file from a URL. The agent calls `talonic_extract` with a schema describing the fields to pull out, and receives structured JSON within seconds. From there, the agent can present the data, answer follow-up questions, or feed the extracted values into downstream workflows — all without the user leaving the conversation.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Quick-start: extract an invoice in one tool call\",\n code: `{\n \"file_url\": \"https://example.com/invoice.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"vendor\": { \"type\": \"string\" },\n \"total\": { \"type\": \"number\" },\n \"due_date\": { \"type\": \"string\", \"format\": \"date\" }\n },\n \"required\": [\"vendor\", \"total\"]\n }\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Response: structured data with confidence\",\n code: `{\n \"status\": \"complete\",\n \"data\": {\n \"vendor\": \"Acme Corp\",\n \"total\": 2450.00,\n \"due_date\": \"2026-07-01\"\n },\n \"confidence\": {\n \"overall\": 0.96,\n \"fields\": { \"vendor\": 0.98, \"total\": 0.99, \"due_date\": 0.94 }\n }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"The MCP server supports every major AI coding and chat client: Claude Desktop, Cursor, Cline, Continue, and Cowork. Each client has its own config format, but the setup pattern is the same — add a JSON entry pointing to the Talonic server (hosted URL or local npx command), supply your API key, and restart the client. The server then registers its tools and resources, which the agent can discover and invoke automatically during conversations.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"The MCP server is open-source and published to npm as `@talonic/mcp`. You can inspect the source, report issues, and contribute on GitHub.\",\n },\n ],\n related: [\n { label: \"Why Use This\", slug: \"why-mcp\" },\n { label: \"Claude Desktop\", slug: \"claude-desktop\" },\n { label: \"Node SDK\", slug: \"introduction\" },\n ],\n faq: [\n {\n question: \"What is the Talonic MCP server?\",\n answer:\n \"An official MCP server that gives AI agents (Claude Desktop, Cursor, Cline, etc.) the ability to extract structured data from documents using the Model Context Protocol.\",\n },\n {\n question: \"Is the Talonic MCP server on the official MCP Registry?\",\n answer:\n \"Yes. It is listed as io.github.talonicdev/talonic-mcp on registry.modelcontextprotocol.io, maintained by Anthropic and the MCP steering group.\",\n },\n {\n question: \"Do I need to install anything to use the Talonic MCP server?\",\n answer:\n \"Not necessarily. The hosted server at mcp.talonic.com requires zero local installation — just a URL and API key in your MCP client config. Alternatively, the local npx option requires Node.js 18+.\",\n },\n {\n question: \"What document types does the Talonic MCP server support?\",\n answer:\n \"The server supports PDF, PNG, JPG, TIFF, DOCX, XLSX, and other common document formats. Documents can be invoices, contracts, receipts, forms, certificates, or any structured or semi-structured document. The extraction pipeline handles OCR, layout analysis, and field extraction server-side.\",\n },\n {\n question: \"How many tools does the Talonic MCP server expose?\",\n answer:\n \"Eight tools and two resources. The tools are talonic_extract, talonic_search, talonic_filter, talonic_get_document, talonic_to_markdown, talonic_list_schemas, talonic_save_schema, and talonic_get_balance. The resources are talonic://schemas and talonic://webhooks/reference.\",\n },\n ],\n mentions: [\"MCP\", \"Model Context Protocol\", \"AI agents\", \"document extraction\"],\n },\n {\n slug: \"why-mcp\",\n parentSlug: \"overview\",\n title: \"Why Use This\",\n seoTitle: \"Why Talonic MCP — Talonic Docs\",\n description:\n \"Why AI agents should use the Talonic MCP server instead of raw OCR plus LLM calls for document extraction.\",\n content: [\n {\n type: \"paragraph\",\n text: \"When an agent needs to pull structured data out of a PDF, scan, image, or messy document, the usual approach is raw OCR plus an LLM call. Results are unreliable; tables get mangled, dates get misread, totals drift.\",\n },\n {\n type: \"paragraph\",\n text: \"With this MCP server installed, the agent has a `talonic_extract` tool that returns schema-validated JSON with per-field confidence scores, a detected document type, and stable IDs for follow-up calls. Seven other tools cover the rest of the workflow: searching the workspace, filtering by extracted field values, fetching a document's metadata, getting OCR markdown, listing saved schemas, saving new ones, and reading the workspace credit balance for budget-aware behaviour.\",\n },\n {\n type: \"paragraph\",\n text: \"The extraction pipeline runs server-side on Talonic's infrastructure, which means the agent does not need to manage OCR libraries, prompt engineering for data extraction, or post-processing heuristics. A single tool call replaces what would otherwise be a multi-step chain of OCR, schema validation, and confidence estimation inside the agent's own context window.\",\n },\n {\n type: \"paragraph\",\n text: \"Because each extraction returns **per-field confidence scores**, agents can make informed decisions about when to trust extracted values and when to escalate to the user for review. This is especially valuable for high-stakes fields like financial amounts, legal terms, and dates where silent errors are costly.\",\n },\n {\n type: \"paragraph\",\n text: \"Integration effort is minimal compared to building a custom extraction pipeline. A raw OCR + LLM approach requires choosing an OCR library, writing prompts for each document type, parsing unstructured LLM output into typed fields, implementing confidence estimation, and handling edge cases like rotated pages, multi-column layouts, and mixed languages. The Talonic MCP server replaces all of that with a single tool call that returns clean, validated JSON.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent conversation: comparing raw OCR vs Talonic\",\n code: `// Without Talonic — agent must chain multiple steps:\n// 1. OCR the PDF → raw text with layout errors\n// 2. Prompt LLM to extract fields → unstructured output\n// 3. Parse LLM output → fragile regex/JSON parsing\n// 4. Validate types → manual type coercion\n// 5. Estimate confidence → no signal available\n\n// With Talonic — single tool call:\n{\n \"file_url\": \"https://example.com/contract.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"parties\": { \"type\": \"array\", \"items\": { \"type\": \"string\" } },\n \"effective_date\": { \"type\": \"string\", \"format\": \"date\" },\n \"term_months\": { \"type\": \"integer\" },\n \"governing_law\": { \"type\": \"string\" }\n }\n }\n}\n// → Returns validated JSON + confidence scores in ~3 seconds`,\n },\n {\n type: \"paragraph\",\n text: \"The workspace model is another key advantage. Every document processed through the MCP server is stored in your Talonic workspace with a stable `document_id`. This means an agent can extract an invoice today, and a week later the user can ask 'what was the total on that Meridian invoice?' — the agent searches the workspace, finds the document, and retrieves the previously extracted data without re-uploading or re-processing. This persistent workspace turns the MCP server from a one-shot tool into a long-term document intelligence layer.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Every document processed through the MCP server is stored in your Talonic workspace with a stable `document_id`. Subsequent operations — re-extraction with a different schema, markdown retrieval, metadata lookup — reuse that ID without re-uploading the file, saving both time and credits.\",\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"Get an API Key\", slug: \"get-api-key\" },\n ],\n faq: [\n {\n question: \"Why use Talonic MCP instead of OCR + LLM?\",\n answer:\n \"Raw OCR + LLM calls produce unreliable results — mangled tables, misread dates, drifting totals. Talonic returns schema-validated JSON with per-field confidence scores and stable IDs for follow-up calls.\",\n },\n {\n question: \"Does the MCP server handle retries and errors automatically?\",\n answer:\n \"Yes. The server retries on transient failures (429 rate limits, 5xx server errors) and returns structured error messages the agent can reason about, rather than raw HTTP status codes.\",\n },\n {\n question: \"Can I re-extract a document with a different schema without re-uploading?\",\n answer:\n \"Yes. Pass the document_id from a previous extraction to talonic_extract with a new schema. The server reuses the already-ingested document, which is faster and costs fewer credits.\",\n },\n {\n question: \"What confidence scores does Talonic provide?\",\n answer:\n \"Every extraction includes confidence.overall (0 to 1) and confidence.fields with a per-field score. Agents can use these to decide when to trust values automatically and when to escalate to the user for review. Scores above 0.9 are highly reliable; below 0.7 warrants human verification.\",\n },\n {\n question: \"How does Talonic handle multi-language documents?\",\n answer:\n \"The extraction pipeline auto-detects the document language and returns it in the language_detected field. OCR and field extraction work across Latin, Cyrillic, CJK, and Arabic scripts. No language configuration is needed — the server handles detection and adaptation automatically.\",\n },\n ],\n mentions: [\"OCR\", \"schema-validated\", \"confidence scores\", \"structured data\"],\n },\n {\n slug: \"agent-decision-guide\",\n parentSlug: \"overview\",\n title: \"Agent Decision Guide\",\n seoTitle: \"Agent Decision Guide — Talonic MCP\",\n description:\n \"How an AI agent should pick between Talonic's tools, handle low-confidence results, and avoid unnecessary calls.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Use this guide to pick the right Talonic tool for the user's request. Match the user's intent to one of the scenarios below before calling a tool. The wrong tool returns the wrong data, costs unnecessary credits, and slows the conversation.\",\n },\n {\n type: \"paragraph\",\n text: \"The eleven tools are designed for distinct use cases with minimal overlap. **`talonic_extract`** is for structured field extraction with a schema, **`talonic_request_upload`** hands the user a browser link for files too large to pass through a hosted connector (Claude.ai), **`talonic_to_markdown`** is for full-text conversion, **`talonic_search`** handles fuzzy discovery, **`talonic_filter`** handles precise field-value queries, **`talonic_get_document`** returns metadata, the schema tools (**`talonic_list_schemas`**, **`talonic_save_schema`**) manage reusable extraction templates, and the billing tools (**`talonic_get_balance`** for the remaining balance, **`talonic_get_pricing`** for per-unit rates, **`talonic_get_usage`** for per-function spend) let the agent stay budget-aware before and after large batches.\",\n },\n {\n type: \"paragraph\",\n text: \"A well-built agent should check conversation history before making any tool call. If the user already extracted data from a document in an earlier turn, re-use that result rather than calling `talonic_extract` again. Repeat calls cost credits and add latency without providing new information.\",\n },\n {\n type: \"paragraph\",\n text: \"When in doubt about which tool to use, consider the user's underlying intent: do they want specific field values (extract), the full document text (to_markdown), to find documents (search/filter), or to manage extraction templates (schema tools)? This mental model covers every scenario.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"decide-extract-vs-markdown\",\n text: \"User has a file (or just dropped one in)\",\n },\n {\n type: \"list\",\n items: [\n \"**They want specific fields**: vendor, total, dates, parties, line items. Use `talonic_extract` with a `schema` (full JSON Schema is most reliable) or a `schema_id` from `talonic_list_schemas`. Don't know the fields yet? Set `auto_schema: true` for open capture — Talonic discovers them and returns a suggested schema to refine.\",\n \"**They want the full text content**, e.g. for summarisation, translation, or general analysis. Use `talonic_to_markdown`. It returns OCR-converted markdown without forcing a schema.\",\n \"**They want both**: extract once with a schema (which also yields markdown when `include_markdown: true` is set), avoiding two uploads.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"decide-find-existing\",\n text: \"User is asking about existing documents in the workspace\",\n },\n {\n type: \"list\",\n items: [\n \"**Conceptual or fuzzy** (e.g. 'do I have any docs about indemnification?', 'find Acme contracts'): use `talonic_search`.\",\n \"**Value-based on extracted fields** (e.g. 'invoices over 1000 EUR', 'contracts expiring before 2026-12-31'): use `talonic_filter`. Use `is_not_empty` for presence checks and `is_empty` for absence checks.\",\n \"**They reference a specific document_id**: use `talonic_get_document` for metadata, `talonic_to_markdown` (with `document_id`) for text, or `talonic_extract` (with `document_id`) to re-extract with a new schema. Re-using a document_id is cheaper than re-uploading.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"decide-schema-mgmt\",\n text: \"User is working with schemas\",\n },\n {\n type: \"list\",\n items: [\n \"**One-off extraction**: pass the schema inline on `talonic_extract`. Do not save it.\",\n \"**The same schema across many documents**: call `talonic_save_schema` once, then pass the returned id (UUID or `SCH-XXXXXXXX`) as `schema_id` on every future `talonic_extract` call. Either id form is accepted.\",\n \"**Discovering existing schemas** before designing a new one: call `talonic_list_schemas`. The `talonic://schemas` resource is the same list rendered as a browseable resource for clients that support it.\",\n \"**Avoid clutter**: do not save a schema until the user has reviewed and confirmed the design. Iterate inline first.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"decide-confidence\",\n text: \"Handling confidence and human review\",\n },\n {\n type: \"paragraph\",\n text: \"Every `talonic_extract` response includes `confidence.overall` (0..1) and `confidence.fields` (per-field 0..1). Use these to decide when to escalate.\",\n },\n {\n type: \"list\",\n items: [\n \"**`confidence.overall` below ~0.7**: tell the user the extraction may be unreliable, show the top low-confidence fields, and ask them to confirm before taking any downstream action (payment, contract execution, data import).\",\n \"**Per-field confidence below ~0.7**: surface those fields with a 'needs review' marker. Do not silently use them in calculations or external API calls.\",\n \"**Critical fields at any confidence**: financial amounts, legal terms, names, dates. Always confirm with the user before acting on them, even at high confidence.\",\n \"**Provenance is not surfaced in v0.1.** Per-field source page or bounding box is not in the response. If the user needs to verify a specific field against the source, send them to the document via `links.dashboard` from the response.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"decide-not-call\",\n text: \"When not to call Talonic\",\n },\n {\n type: \"list\",\n items: [\n \"**The user's question is general knowledge or conversation.** Do not pre-emptively extract or search.\",\n \"**The needed data is already in conversation history** from a previous tool call. Re-use it. Repeat calls cost credits and slow the response.\",\n \"**The user wants to discuss or revise** an extraction you already produced. Reason over the previous result instead of re-extracting.\",\n \"**Schema design iteration**. Iterate the schema with the user via `talonic_extract` with an inline schema; only call `talonic_save_schema` once they confirm.\",\n \"**Cost, EUR price, and remaining credit balance are not surfaced in v0.1 tool responses.** If the user asks 'how much will this cost' or 'how many credits do I have left', point them to the Talonic dashboard at https://app.talonic.com.\",\n ],\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"talonic_filter\", slug: \"talonic-filter\" },\n { label: \"talonic_search\", slug: \"talonic-search\" },\n { label: \"Known Limitations\", slug: \"known-limitations\" },\n ],\n faq: [\n {\n question: \"When should an agent use talonic_extract vs talonic_to_markdown?\",\n answer:\n \"Use talonic_extract when the user wants specific structured fields (with a schema). Use talonic_to_markdown when the user wants the full text content for summarisation or analysis without a schema.\",\n },\n {\n question: \"When should an agent use talonic_search vs talonic_filter?\",\n answer:\n \"Use talonic_search for conceptual or fuzzy queries across the workspace. Use talonic_filter when the user wants documents matching specific structured field values like 'invoices over 1000 EUR'.\",\n },\n {\n question: \"How should an agent handle low-confidence extractions?\",\n answer:\n \"Treat confidence below ~0.7 as needing human review. Surface low-confidence fields explicitly and confirm critical fields (amounts, dates, names) with the user before any downstream action.\",\n },\n ],\n mentions: [\"decision guide\", \"agent\", \"tool selection\", \"confidence\", \"human review\", \"cost\"],\n },\n {\n slug: \"get-api-key\",\n parentSlug: \"overview\",\n title: \"Get an API Key\",\n seoTitle: \"Get an API Key — Talonic MCP\",\n description:\n \"Get a Talonic API key in 30 seconds. Each user runs against their own isolated workspace with private documents and schemas.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Each user runs against their own isolated Talonic workspace. Your documents and schemas are private to you.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"If you are connecting from Claude.ai's custom-connector flow, you can skip the API-key steps below. The connector launches an OAuth 2.1 sign-in to `app.talonic.com` and the MCP server then uses a short-lived bearer token on your behalf. Get an API key when you want to install locally via `npx`, drive the hosted endpoint from a custom-header client, or use the Node SDK.\",\n },\n {\n type: \"list\",\n ordered: true,\n items: [\n \"Sign up at [app.talonic.com](https://app.talonic.com). Free tier: 50 extractions per day, no credit card.\",\n \"Settings → API Keys → Create New Key.\",\n \"Copy the `tlnc_` value into your MCP client config (snippets below).\",\n ],\n },\n {\n type: \"paragraph\",\n text: \"The API key authenticates every tool call the MCP server makes on your behalf. It is passed as a `TALONIC_API_KEY` environment variable in the local `npx` setup, or as a `Bearer` token in the `Authorization` header for the hosted server. The key is never sent to the AI agent itself — it stays within the MCP server process.\",\n },\n {\n type: \"paragraph\",\n text: \"Keep your API key private. Do not commit it to version control or share it in public MCP config examples. If a key is compromised, revoke it immediately in the Talonic dashboard under Settings → API Keys and generate a new one.\",\n },\n {\n type: \"paragraph\",\n text: \"The free tier includes 50 extractions per day, which is enough for development and testing. For production workloads or higher volume, upgrade your plan in the Talonic dashboard. All plans share the same API — the key determines your rate limits and quota.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Local npx config with API key\",\n code: `{\n \"mcpServers\": {\n \"talonic\": {\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": {\n \"TALONIC_API_KEY\": \"tlnc_your_key_here\"\n }\n }\n }\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Hosted config with API key as Bearer token\",\n code: `{\n \"mcpServers\": {\n \"talonic\": {\n \"url\": \"https://mcp.talonic.com/mcp\",\n \"headers\": {\n \"Authorization\": \"Bearer tlnc_your_key_here\"\n }\n }\n }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"After adding your API key to the config, verify the connection by asking your agent to call `talonic_list_schemas`. If the key is valid, the tool returns your saved schemas (or an empty list if you have not saved any yet). If the key is invalid or missing, the server returns a clear authentication error that tells the agent the key needs to be checked. This is the fastest way to confirm your setup is working end-to-end.\",\n },\n {\n type: \"paragraph\",\n text: \"Each API key is scoped to a single workspace. If you work across multiple Talonic workspaces — for example, separate environments for development and production — you will need a different API key for each. You can create multiple keys within the same workspace for different team members or applications, and revoke them independently without affecting other keys.\",\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: \"Never hardcode your `tlnc_` key in source code or share it in screenshots. Use environment variables or your MCP client's config file, which is typically stored in a user-specific directory.\",\n },\n ],\n related: [\n { label: \"Claude Desktop\", slug: \"claude-desktop\" },\n { label: \"Install Overview\", slug: \"install-overview\" },\n ],\n faq: [\n {\n question: \"How do I get a Talonic API key for MCP?\",\n answer:\n \"Sign up at app.talonic.com (free, no credit card), go to Settings > API Keys > Create New Key, and copy the tlnc_ value into your MCP client config.\",\n },\n {\n question: \"Is the free tier enough for development?\",\n answer:\n \"Yes. The free tier includes 50 extractions per day with no credit card required, which is sufficient for development and testing. Upgrade in the dashboard for production workloads.\",\n },\n {\n question: \"What should I do if my API key is compromised?\",\n answer:\n \"Revoke it immediately in the Talonic dashboard under Settings > API Keys, then generate a new one. Update your MCP client config with the new key and restart the client.\",\n },\n {\n question: \"Can I use the same API key across multiple MCP clients?\",\n answer:\n \"Yes. The same tlnc_ key works in Claude Desktop, Cursor, Cline, Continue, Cowork, or any other MCP client simultaneously. The key is tied to your workspace, not to a specific client. Rate limits apply per-key across all clients.\",\n },\n {\n question: \"How do I verify my API key is working?\",\n answer:\n \"After configuring your MCP client, ask the agent to call talonic_list_schemas. A successful response (even an empty list) confirms the key is valid and the server is connected. An authentication error means the key is missing, malformed, or revoked.\",\n },\n ],\n mentions: [\"API key\", \"tlnc_\", \"free tier\"],\n },\n]\n","import type { RawSection } from \"../types\"\n\nconst MCP_HOSTED_SNIPPET = `{\n \"mcpServers\": {\n \"talonic\": {\n \"url\": \"https://mcp.talonic.com/mcp\",\n \"headers\": {\n \"Authorization\": \"Bearer tlnc_your_key_here\"\n }\n }\n }\n}`\n\nconst MCP_CONFIG_SNIPPET = `{\n \"mcpServers\": {\n \"talonic\": {\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": {\n \"TALONIC_API_KEY\": \"tlnc_your_key_here\"\n }\n }\n }\n}`\n\nexport const sections: RawSection[] = [\n {\n slug: \"install-overview\",\n parentSlug: \"install\",\n title: \"Install Overview\",\n seoTitle: \"Install Talonic MCP — Talonic Docs\",\n description:\n \"Install the Talonic MCP server with a one-line npx invocation. No clone, no build. Works with every MCP client.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Three ways to connect. The recommended path for Claude.ai users is the hosted MCP via the **OAuth connector flow**: paste one URL into Claude.ai's connector settings, sign in with your Talonic account, approve the consent screen. No API key in your config, ever. For IDE-style clients (Cursor, Cline, Continue, Cowork) and Claude Desktop, the local `npx` install is the canonical path. A third hosted option, with the Talonic API key in an `Authorization` header, exists for clients that support custom headers on remote MCP servers.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"hosted-claude-ai\",\n text: \"Hosted via Claude.ai connector (OAuth, recommended)\",\n },\n {\n type: \"paragraph\",\n text: \"Claude.ai's `Add custom connector` flow does the OAuth 2.1 handshake for you. The MCP server lives at `https://mcp.talonic.com/mcp`; Claude.ai discovers the authorization server, registers itself dynamically (RFC 7591), and runs the PKCE authorization-code flow. The resulting access token is stored by Claude.ai and refreshed automatically (1-hour access token, 30-day refresh).\",\n },\n {\n type: \"list\",\n ordered: true,\n items: [\n \"Open `https://claude.ai/settings/connectors`.\",\n \"Click **Add custom connector**.\",\n \"URL: `https://mcp.talonic.com/mcp` — no query string, no headers.\",\n \"Click **Connect**. You are redirected to Talonic to sign in.\",\n \"Sign in with Google, Microsoft, or your company SSO.\",\n \"Approve the consent screen. The requested scopes are `extract:write`, `documents:read`, and `schemas:read`. Pick a workspace if you have multiple.\",\n \"You are returned to Claude.ai with the connector live. All eleven tools are available in any new conversation.\",\n ],\n },\n {\n type: \"paragraph\",\n text: \"No API key appears in the connector config or in any URL the browser navigates to. To revoke access, remove the connector in Claude.ai or revoke the OAuth client from your Talonic dashboard. Your tools and tokens are scoped to the workspace you picked at consent time.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"local-npx\",\n text: \"Local stdio (npx)\",\n },\n {\n type: \"paragraph\",\n text: \"Recommended for IDE-style clients (Cursor, Cline, Continue, Cowork) and Claude Desktop, where the MCP host spawns the server as a local child process. Requires Node.js 18+. Your API key lives in the client's `env` block.\",\n },\n {\n type: \"code\",\n language: \"jsonc\",\n title: \"Local config\",\n code: `{\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": { \"TALONIC_API_KEY\": \"tlnc_...\" }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"The `-y` flag skips the npm install prompt. Pinning to `@latest` means new versions are picked up on the next client restart. For production deployments and CI, pin to a specific version (e.g. `@talonic/mcp@0.1.27`) so a future release cannot silently change tool descriptions, validation rules, or response shapes.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"hosted-bearer\",\n text: \"Hosted with a Bearer header (custom-header clients)\",\n },\n {\n type: \"paragraph\",\n text: \"For MCP clients that support remote servers with custom headers (mcp-inspector, custom integrations), connect to the hosted endpoint with the API key in an `Authorization` header. Claude.ai's connector UI does not currently support custom headers, which is why the OAuth flow above is the recommended path for Claude.ai users.\",\n },\n {\n type: \"code\",\n language: \"jsonc\",\n title: \"Hosted config (custom-header clients)\",\n code: `{\n \"url\": \"https://mcp.talonic.com/mcp\",\n \"headers\": { \"Authorization\": \"Bearer tlnc_...\" }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"All three install paths expose the same eleven tools and two resources. The hosted server runs the latest version of `@talonic/mcp` automatically; the local `npx` install picks up the latest version on next client restart when pinned to `@latest`.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"verify-install\",\n text: \"Verify the connection\",\n },\n {\n type: \"paragraph\",\n text: \"After adding the config and restarting your MCP client, verify the connection by asking the agent to list your schemas. This is a lightweight read-only call that confirms the API key is valid and the server is reachable. If the call succeeds, all eleven tools are ready to use.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Verification: ask the agent to call talonic_list_schemas\",\n code: `// Agent sends:\n{ }\n\n// Server responds (empty workspace):\n{\n \"schemas\": []\n}\n\n// Server responds (workspace with saved schemas):\n{\n \"schemas\": [\n {\n \"id\": \"sch_7a1b...\",\n \"short_id\": \"SCH-A1B2C3D4\",\n \"name\": \"Standard Invoice\",\n \"field_count\": 6\n }\n ]\n}`,\n },\n {\n type: \"paragraph\",\n text: \"If the verification fails, check three things in order: (1) your JSON config is syntactically valid — a missing comma or bracket is the most common cause, (2) the API key starts with `tlnc_` and has not been revoked, and (3) you fully restarted the MCP client after editing the config. For the local npx option, you can also test the server standalone by running `npx -y @talonic/mcp@latest --version` in a terminal to confirm it installs and prints a version number.\",\n },\n {\n type: \"paragraph\",\n text: \"The hosted and local options can be swapped at any time by editing your config. Some developers start with the hosted option for quick setup and switch to local npx when they need offline access or want to inspect server logs. The tools, parameters, and responses are identical regardless of which option you choose, so no agent-side changes are needed when switching.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"If you are behind a corporate proxy or firewall that blocks outbound HTTPS to `mcp.talonic.com`, use the local `npx` option and configure your proxy via standard `HTTPS_PROXY` environment variables.\",\n },\n ],\n related: [\n { label: \"Claude Desktop\", slug: \"claude-desktop\" },\n { label: \"Cursor\", slug: \"cursor\" },\n ],\n faq: [\n {\n question: \"How do I install the Talonic MCP server?\",\n answer:\n \"Use the hosted server at mcp.talonic.com/mcp — just set the URL and your API key in any MCP client config. No install needed. Alternatively, run locally via npx @talonic/mcp.\",\n },\n {\n question: \"What is the difference between hosted and local MCP server?\",\n answer:\n \"Both expose the same tools and resource. Hosted requires zero local dependencies and auto-updates. Local runs on your machine via npx and requires Node.js 18+. Latency is comparable since both call the same API.\",\n },\n {\n question: \"Do I need to update the MCP server manually?\",\n answer:\n \"With the hosted server, updates are automatic. With the local npx option, pinning to @latest means new versions are fetched on the next client restart.\",\n },\n {\n question: \"Can I switch between hosted and local without changing my workflow?\",\n answer:\n \"Yes. Both options expose identical tools, parameters, and responses. Edit the config to swap between hosted URL and local npx command, restart the client, and everything works the same. No agent-side or schema changes needed.\",\n },\n {\n question: \"What Node.js version do I need for the local option?\",\n answer:\n \"Node.js 18 or later. The npx command downloads and runs the MCP server package automatically. No global install is needed — npx handles it. Run node --version in a terminal to check your version.\",\n },\n ],\n mentions: [\"npx\", \"npm\", \"MCP client\", \"install\"],\n },\n {\n slug: \"claude-desktop\",\n parentSlug: \"install\",\n title: \"Claude Desktop\",\n seoTitle: \"Claude Desktop Setup — Talonic MCP\",\n description: \"Configure the Talonic MCP server in Claude Desktop on macOS and Windows.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Edit `~/Library/Application Support/Claude/claude_desktop_config.json` (macOS) or `%APPDATA%\\\\Claude\\\\claude_desktop_config.json` (Windows).\",\n },\n { type: \"heading\", level: 3, id: \"claude-desktop-hosted\", text: \"Hosted (recommended)\" },\n { type: \"code\", language: \"json\", code: MCP_HOSTED_SNIPPET },\n { type: \"heading\", level: 3, id: \"claude-desktop-local\", text: \"Local (npx)\" },\n { type: \"code\", language: \"json\", code: MCP_CONFIG_SNIPPET },\n {\n type: \"paragraph\",\n text: \"Fully restart Claude Desktop (Cmd+Q on macOS, not just close the window). Talonic appears in the connected servers list with all eleven tools.\",\n },\n {\n type: \"paragraph\",\n text: \"Claude Desktop is the most popular MCP client for Talonic. It natively supports drag-and-drop file uploads, which pairs well with `talonic_extract` via the `file_data` parameter. When you drop a PDF into the chat, Claude automatically base64-encodes it and passes it to the MCP tool.\",\n },\n {\n type: \"paragraph\",\n text: \"After connecting, you can verify the setup by asking Claude to list your schemas (`talonic_list_schemas`) or extract data from a sample document. If the tools do not appear, check that your JSON is valid and the config file is in the correct directory for your operating system.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"claude-desktop-verify\",\n text: \"Verify the connection\",\n },\n {\n type: \"paragraph\",\n text: \"After restarting Claude Desktop, open a new conversation and ask Claude to list your schemas. A successful response confirms the MCP server is connected and your API key is valid. You should see the Talonic tools in the connected servers panel on the left side of the Claude Desktop window.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Verification prompt and expected response\",\n code: `// Ask Claude: \"List my Talonic schemas\"\n// Claude calls talonic_list_schemas with: {}\n\n// Expected response (new workspace):\n{\n \"schemas\": []\n}\n\n// If the key is invalid, you will see:\n{\n \"error\": \"authentication_error\",\n \"message\": \"Invalid or revoked API key. Check TALONIC_API_KEY in your config.\"\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Claude Desktop is the recommended client for document-heavy workflows because of its native file handling. When you drop a file into the chat, Claude reads the file bytes, base64-encodes them, and passes them to `talonic_extract` or `talonic_to_markdown` via the `file_data` parameter. This means you can go from a physical document scan to structured JSON in under ten seconds — drop the file, Claude picks the right tool, and the extracted data appears in the conversation.\",\n },\n {\n type: \"paragraph\",\n text: \"For multi-document workflows, Claude Desktop maintains conversation context across tool calls. You can extract data from several invoices in sequence, and Claude remembers all previous results. Ask follow-up questions like 'which of those invoices had the highest total?' and Claude reasons over the extracted data without re-calling the tools. This makes Claude Desktop particularly effective for batch review and comparison tasks.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Claude Desktop also renders the `talonic://schemas` resource in its UI, letting you browse saved schemas without making a tool call.\",\n },\n ],\n related: [\n { label: \"Cursor\", slug: \"cursor\" },\n { label: \"Tool Reference\", slug: \"talonic-extract\" },\n ],\n faq: [\n {\n question: \"How do I add Talonic to Claude Desktop?\",\n answer:\n \"Edit claude_desktop_config.json, add the Talonic MCP server config with your API key, and fully restart Claude Desktop (Cmd+Q on macOS).\",\n },\n {\n question: \"Why don't Talonic tools appear after adding the config?\",\n answer:\n \"Make sure you fully restart Claude Desktop (Cmd+Q, not just close the window). Also verify your JSON syntax is valid and the config file is in the correct directory for your OS.\",\n },\n {\n question: \"Does Claude Desktop support drag-and-drop with Talonic?\",\n answer:\n \"Yes. Claude Desktop natively supports drag-and-drop file uploads. When you drop a PDF, Claude base64-encodes it and passes it to talonic_extract via the file_data parameter.\",\n },\n {\n question: \"Where is the Claude Desktop config file on macOS vs Windows?\",\n answer:\n \"On macOS: ~/Library/Application Support/Claude/claude_desktop_config.json. On Windows: %APPDATA%\\\\Claude\\\\claude_desktop_config.json. Create the file if it does not exist. The directory must already exist — Claude Desktop creates it on first launch.\",\n },\n {\n question: \"Can I use both hosted and local Talonic in Claude Desktop?\",\n answer:\n \"You can configure either option, but not both simultaneously under the same server name. Choose hosted for zero-dependency setup or local npx for offline access. Switch by editing the config and restarting Claude Desktop.\",\n },\n ],\n mentions: [\"Claude Desktop\", \"macOS\", \"Windows\"],\n },\n {\n slug: \"cursor\",\n parentSlug: \"install\",\n title: \"Cursor\",\n seoTitle: \"Cursor Setup — Talonic MCP\",\n description: \"Configure the Talonic MCP server in Cursor IDE.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Edit `~/.cursor/mcp.json` (or open Cursor settings → MCP → edit config):\",\n },\n { type: \"heading\", level: 3, id: \"cursor-hosted\", text: \"Hosted (recommended)\" },\n { type: \"code\", language: \"json\", code: MCP_HOSTED_SNIPPET },\n { type: \"heading\", level: 3, id: \"cursor-local\", text: \"Local (npx)\" },\n { type: \"code\", language: \"json\", code: MCP_CONFIG_SNIPPET },\n {\n type: \"paragraph\",\n text: \"After saving the config, restart Cursor or reload the window. The Talonic tools appear in the MCP tool list and can be invoked from Cursor's AI chat panel. Cursor's agent mode is particularly effective with Talonic because it can read local files from your project and pass them directly to `talonic_extract` via `file_path`.\",\n },\n {\n type: \"paragraph\",\n text: \"A common Cursor workflow is extracting data from documents within a codebase — for example, parsing specification PDFs, extracting configuration from scanned documents, or converting legacy documentation to structured data. The `file_path` input works directly with paths relative to your Cursor workspace.\",\n },\n {\n type: \"paragraph\",\n text: \"Cursor caches MCP tool descriptions between sessions. If you upgrade the MCP server and notice outdated tool descriptions, restart Cursor to force a refresh of the tool metadata.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"cursor-workflow-example\",\n text: \"Example: extracting from a project file\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent extracts data from a spec PDF in the workspace\",\n code: `// User: \"Extract the requirements from docs/product-spec.pdf\"\n// Cursor agent calls talonic_extract with:\n{\n \"file_path\": \"./docs/product-spec.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"title\": { \"type\": \"string\" },\n \"requirements\": {\n \"type\": \"array\",\n \"items\": {\n \"type\": \"object\",\n \"properties\": {\n \"id\": { \"type\": \"string\" },\n \"description\": { \"type\": \"string\" },\n \"priority\": { \"type\": \"string\" }\n }\n }\n },\n \"deadline\": { \"type\": \"string\", \"format\": \"date\" }\n }\n }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Cursor's composer mode is particularly powerful with Talonic because the agent can extract data from a document and immediately use it to generate code. For example, you can ask Cursor to extract fields from an API specification PDF and then generate TypeScript interfaces matching the extracted schema. The agent chains `talonic_extract` with code generation in a single turn, eliminating manual data entry.\",\n },\n {\n type: \"paragraph\",\n text: \"When using the hosted MCP option in Cursor, the connection is established over HTTPS with no local process. This means Cursor starts faster and there is no Node.js dependency. For teams sharing a Cursor workspace configuration, the hosted option is simpler to standardise because every developer only needs an API key — no local Node.js version management needed.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Cursor supports both the hosted and local MCP options. The hosted option is simpler since Cursor can connect directly via HTTPS without spawning a local process.\",\n },\n ],\n related: [\n { label: \"Claude Desktop\", slug: \"claude-desktop\" },\n { label: \"Cline\", slug: \"cline\" },\n ],\n faq: [\n {\n question: \"How do I add Talonic MCP to Cursor?\",\n answer: \"Edit ~/.cursor/mcp.json and add the Talonic MCP server config with your API key.\",\n },\n {\n question: \"Can Cursor read local files for extraction?\",\n answer:\n \"Yes. Cursor's agent mode can read files from your project and pass them to talonic_extract via the file_path parameter, making it easy to extract data from documents within your codebase.\",\n },\n {\n question: \"Why are Talonic tool descriptions outdated in Cursor?\",\n answer:\n \"Cursor caches MCP tool descriptions between sessions. Restart Cursor to force a refresh after upgrading the MCP server.\",\n },\n {\n question: \"Can Cursor chain extraction with code generation?\",\n answer:\n \"Yes. In composer mode, Cursor can extract data from a document and immediately use the results to generate code — for example, extracting fields from an API spec PDF and generating TypeScript interfaces. The agent handles both steps in a single turn.\",\n },\n ],\n mentions: [\"Cursor\", \"IDE\"],\n },\n {\n slug: \"cline\",\n parentSlug: \"install\",\n title: \"Cline\",\n seoTitle: \"Cline Setup — Talonic MCP\",\n description: \"Configure the Talonic MCP server in the Cline VS Code extension.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Open the Cline panel → settings (gear icon) → MCP Servers → Edit. Save and restart the panel.\",\n },\n { type: \"heading\", level: 3, id: \"cline-hosted\", text: \"Hosted (recommended)\" },\n { type: \"code\", language: \"json\", code: MCP_HOSTED_SNIPPET },\n { type: \"heading\", level: 3, id: \"cline-local\", text: \"Local (npx)\" },\n { type: \"code\", language: \"json\", code: MCP_CONFIG_SNIPPET },\n {\n type: \"paragraph\",\n text: \"Cline runs inside VS Code and communicates with MCP servers over stdio (local) or HTTP (hosted). After adding the config, the Talonic tools become available in Cline's autonomous agent mode, where it can chain multiple tool calls without manual approval for each step.\",\n },\n {\n type: \"paragraph\",\n text: \"Cline's auto-approval feature works well with Talonic workflows. For example, the agent can search for documents, filter results, and extract data from the top match in a single turn. Configure Cline's auto-approve settings to control which Talonic tools run without confirmation.\",\n },\n {\n type: \"paragraph\",\n text: \"Because Cline operates within VS Code, it has access to your workspace file system. The `file_path` parameter on `talonic_extract` and `talonic_to_markdown` can reference any file in your open workspace, making it straightforward to process documents alongside code.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"cline-auto-approve-example\",\n text: \"Example: multi-step workflow with auto-approval\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Cline auto-approve config for Talonic read-only tools\",\n code: `// In Cline settings → Auto-approve, allow these tools:\n// - talonic_list_schemas (read-only, no cost)\n// - talonic_search (read-only, low cost)\n// - talonic_get_document (read-only, no cost)\n//\n// Keep these requiring approval:\n// - talonic_extract (costs credits)\n// - talonic_save_schema (writes to workspace)\n\n// Agent workflow in a single turn:\n// 1. talonic_search → finds matching documents (auto-approved)\n// 2. talonic_get_document → checks metadata (auto-approved)\n// 3. talonic_extract → extracts data (user approves)`,\n },\n {\n type: \"paragraph\",\n text: \"Cline's strength with Talonic is its autonomous agent mode combined with granular auto-approval. By auto-approving read-only tools like `talonic_search`, `talonic_list_schemas`, and `talonic_get_document`, the agent can explore the workspace freely and only pause for user confirmation on credit-consuming operations like `talonic_extract`. This creates a smooth experience where the agent does the discovery work autonomously and only asks for permission when it matters.\",\n },\n {\n type: \"paragraph\",\n text: \"For development teams using VS Code with Cline, the MCP server integrates naturally into code review workflows. A developer can ask the agent to extract data from a specification document, compare it against the implementation in the codebase, and flag any mismatches — all within the same VS Code window. The agent chains `talonic_extract` with file reads from the workspace to perform this cross-referencing automatically.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"If Cline shows the MCP server as disconnected after a VS Code update, re-open the Cline panel settings and verify the config is still present. Some VS Code updates can reset extension state.\",\n },\n ],\n related: [\n { label: \"Continue\", slug: \"continue\" },\n { label: \"Cursor\", slug: \"cursor\" },\n ],\n faq: [\n {\n question: \"How do I add Talonic MCP to Cline?\",\n answer:\n \"Open the Cline panel settings, go to MCP Servers, click Edit, and add the Talonic config entry.\",\n },\n {\n question: \"Does Cline support auto-approval for Talonic tools?\",\n answer:\n \"Yes. Configure Cline's auto-approve settings to allow specific Talonic tools to run without manual confirmation, enabling multi-step workflows in a single turn.\",\n },\n {\n question: \"Can Cline access local files for Talonic extraction?\",\n answer:\n \"Yes. Cline runs inside VS Code and has access to your workspace file system, so you can use file_path to reference any file in the open workspace.\",\n },\n {\n question: \"Which Talonic tools should I auto-approve in Cline?\",\n answer:\n \"Auto-approve read-only tools like talonic_list_schemas, talonic_search, and talonic_get_document. Keep talonic_extract and talonic_save_schema requiring manual approval since they consume credits or write to your workspace.\",\n },\n ],\n mentions: [\"Cline\", \"VS Code\"],\n },\n {\n slug: \"continue\",\n parentSlug: \"install\",\n title: \"Continue\",\n seoTitle: \"Continue Setup — Talonic MCP\",\n description: \"Configure the Talonic MCP server in Continue for VS Code and JetBrains.\",\n content: [\n { type: \"paragraph\", text: \"Edit `~/.continue/config.json`. Add to the `mcpServers` array:\" },\n { type: \"heading\", level: 3, id: \"continue-hosted\", text: \"Hosted (recommended)\" },\n {\n type: \"code\",\n language: \"json\",\n code: `{\n \"name\": \"talonic\",\n \"url\": \"https://mcp.talonic.com/mcp\",\n \"headers\": {\n \"Authorization\": \"Bearer tlnc_your_key_here\"\n }\n}`,\n },\n { type: \"heading\", level: 3, id: \"continue-local\", text: \"Local (npx)\" },\n {\n type: \"code\",\n language: \"json\",\n code: `{\n \"name\": \"talonic\",\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": {\n \"TALONIC_API_KEY\": \"tlnc_your_key_here\"\n }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Continue works across both VS Code and JetBrains IDEs, making Talonic tools available regardless of your editor choice. The `mcpServers` array in Continue's config supports multiple MCP servers, so Talonic runs alongside any other MCP tools you have configured.\",\n },\n {\n type: \"paragraph\",\n text: \"After saving the config, reload your IDE window to pick up the changes. Continue discovers Talonic's eleven tools and two resources automatically. You can verify the connection by asking the agent to call `talonic_list_schemas` — it should return your saved schemas or an empty list.\",\n },\n {\n type: \"paragraph\",\n text: 'Continue\\'s config format uses a `name` field instead of a key in the `mcpServers` object. Make sure to include `\"name\": \"talonic\"` in the entry. The rest of the config — `command`, `args`, `env` for local, or `url` and `headers` for hosted — follows the same pattern as other MCP clients.',\n },\n {\n type: \"heading\",\n level: 3,\n id: \"continue-verify\",\n text: \"Verify the connection\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Verification: ask the agent to call talonic_list_schemas\",\n code: `// Agent sends (no parameters needed):\n{}\n\n// Successful response confirms connection:\n{\n \"schemas\": [\n {\n \"id\": \"sch_7a1b...\",\n \"short_id\": \"SCH-A1B2C3D4\",\n \"name\": \"Standard Invoice\",\n \"field_count\": 6\n }\n ]\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Continue is ideal for teams that use both VS Code and JetBrains IDEs and want a consistent Talonic experience across editors. Because the config file is shared, a schema saved from a Continue session in IntelliJ is immediately available in a VS Code session — no extra setup needed. This cross-editor consistency extends to all Talonic tools, not just schemas.\",\n },\n {\n type: \"paragraph\",\n text: \"When using Continue with the hosted Talonic server, the connection is established over HTTPS directly from the Continue extension. No local MCP process is spawned, which reduces resource usage in the IDE. For JetBrains users in particular, this avoids adding another background process alongside the already resource-intensive IDE. The local npx option remains available for offline work or when HTTPS connectivity is restricted.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Continue's MCP support works identically in VS Code and JetBrains. The same `~/.continue/config.json` file is shared across both editors.\",\n },\n ],\n related: [\n { label: \"Cowork\", slug: \"cowork\" },\n { label: \"Cline\", slug: \"cline\" },\n ],\n faq: [\n {\n question: \"How do I add Talonic MCP to Continue?\",\n answer:\n \"Edit ~/.continue/config.json and add a Talonic entry to the mcpServers array with your API key.\",\n },\n {\n question: \"Does Continue work with Talonic in JetBrains?\",\n answer:\n \"Yes. Continue shares the same config file (~/.continue/config.json) across VS Code and JetBrains, so Talonic works identically in both editors.\",\n },\n {\n question: \"Why does Continue use a different config format?\",\n answer:\n 'Continue uses an mcpServers array with a name field instead of an object keyed by server name. Include \"name\": \"talonic\" in the entry alongside the standard command/args/env or url/headers fields.',\n },\n {\n question: \"Can I run Talonic alongside other MCP servers in Continue?\",\n answer:\n \"Yes. Continue's mcpServers array supports multiple entries. Talonic runs alongside any other MCP servers you have configured. Each server is discovered independently and all tools are available in the same conversation.\",\n },\n ],\n mentions: [\"Continue\", \"VS Code\", \"JetBrains\"],\n },\n {\n slug: \"cowork\",\n parentSlug: \"install\",\n title: \"Cowork\",\n seoTitle: \"Cowork Setup — Talonic MCP\",\n description: \"Configure the Talonic MCP server in Cowork.\",\n content: [\n { type: \"paragraph\", text: \"Open Cowork settings → MCP Servers → Add.\" },\n { type: \"heading\", level: 3, id: \"cowork-hosted\", text: \"Hosted (recommended)\" },\n { type: \"code\", language: \"json\", code: MCP_HOSTED_SNIPPET },\n { type: \"heading\", level: 3, id: \"cowork-local\", text: \"Local (npx)\" },\n { type: \"code\", language: \"json\", code: MCP_CONFIG_SNIPPET },\n {\n type: \"paragraph\",\n text: \"Cowork is a chat-style MCP client that supports drag-and-drop file uploads and resource browsing. After adding the Talonic config, the eleven tools appear in the tool picker and the `talonic://schemas` and `talonic://webhooks/reference` resources are browseable in the resources panel.\",\n },\n {\n type: \"paragraph\",\n text: \"Like Claude Desktop, Cowork renders MCP resources in its UI. This means your saved schemas are visible without making a tool call, which helps when you want to browse available schemas before starting an extraction workflow.\",\n },\n {\n type: \"paragraph\",\n text: \"After adding the config, restart Cowork to load the new MCP server. If you are using the hosted option, Cowork connects directly via HTTPS — no local process is spawned. For the local option, Cowork launches the `npx` command as a child process and communicates over stdio.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"cowork-workflow\",\n text: \"Example: browse schemas then extract\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent workflow in Cowork\",\n code: `// Step 1: User browses talonic://schemas in the resources panel\n// → Sees \"Standard Invoice\" (SCH-A1B2C3D4) with 6 fields\n\n// Step 2: User drops invoice.pdf into the chat\n// Agent calls talonic_extract:\n{\n \"file_data\": \"JVBERi0xLjQKJ...\",\n \"filename\": \"invoice.pdf\",\n \"schema_id\": \"SCH-A1B2C3D4\"\n}\n\n// Step 3: Agent presents extracted data:\n{\n \"data\": {\n \"vendor_name\": \"Meridian Energy AG\",\n \"total_amount\": 1500.00,\n \"due_date\": \"2026-06-15\"\n },\n \"confidence\": { \"overall\": 0.97 }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Cowork's resource browsing creates a natural workflow for Talonic users. Instead of asking the agent to list schemas via a tool call, you can visually browse the `talonic://schemas` resource in the sidebar, identify the right schema, and then ask the agent to extract using that schema by name or ID. This visual discovery step reduces back-and-forth in the conversation and helps users who are not familiar with their workspace's schema inventory.\",\n },\n {\n type: \"paragraph\",\n text: \"For teams onboarding new members, Cowork's visual schema browser is especially useful. A new team member can see all available extraction templates at a glance, understand what fields each schema extracts, and start processing documents immediately without needing to learn schema IDs or ask colleagues which templates exist. Combined with drag-and-drop file uploads, the barrier to entry is as low as it gets.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Cowork's resource panel lets you browse `talonic://schemas` visually, making it easy to discover existing schemas before designing new ones.\",\n },\n ],\n related: [\n { label: \"Claude Desktop\", slug: \"claude-desktop\" },\n { label: \"Tool Reference\", slug: \"talonic-extract\" },\n ],\n faq: [\n {\n question: \"How do I add Talonic MCP to Cowork?\",\n answer:\n \"Open Cowork settings, go to MCP Servers, click Add, and paste the standard Talonic config with your API key.\",\n },\n {\n question: \"Does Cowork support the talonic://schemas resource?\",\n answer:\n \"Yes. Cowork renders MCP resources in its UI, so you can browse your saved schemas visually in the resources panel without making a tool call.\",\n },\n {\n question: \"Does Cowork support drag-and-drop with Talonic?\",\n answer:\n \"Yes. Cowork supports drag-and-drop file uploads, which pairs with talonic_extract's file_data parameter for easy document extraction.\",\n },\n {\n question: \"How does Cowork compare to Claude Desktop for Talonic workflows?\",\n answer:\n \"Both support drag-and-drop and schema resource browsing. Cowork's resource panel provides a more visual schema discovery experience. Claude Desktop has deeper integration with Anthropic's Claude model. Choose based on your preferred chat interface and model provider.\",\n },\n ],\n mentions: [\"Cowork\"],\n },\n]\n","import type { RawSection } from \"../types\"\n\nexport const sections: RawSection[] = [\n {\n slug: \"talonic-extract\",\n parentSlug: \"tools\",\n title: \"talonic_extract\",\n seoTitle: \"talonic_extract Tool — Talonic MCP\",\n description:\n \"Extract structured, schema-validated data from a document. Returns clean JSON with per-field confidence scores.\",\n content: [\n { type: \"paragraph\", text: \"Extract structured, schema-validated data from a document.\" },\n {\n type: \"paragraph\",\n text: \"Inputs: one of `file_data` + `filename` (recommended for chat clients), `file_path`, `file_url`, or `document_id`, plus a `schema` (or `schema_id`). Returns clean JSON with per-field confidence scores.\",\n },\n {\n type: \"paragraph\",\n text: \"This is the primary tool in the Talonic MCP server. When an agent calls **`talonic_extract`**, the MCP server uploads the document to the Talonic API, runs OCR and field extraction against the provided schema, and returns structured JSON with confidence metadata. The entire pipeline — upload, OCR, extraction, validation — runs server-side in a single request.\",\n },\n {\n type: \"paragraph\",\n text: \"The response includes a `document.id` that persists in your workspace. Subsequent calls can reference this ID via the `document_id` parameter to re-extract with a different schema, retrieve markdown, or fetch metadata — all without re-uploading the file. This is both faster and cheaper than sending the file again.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"file_data\",\n type: \"string\",\n description: \"Base64-encoded file bytes. Recommended for chat clients (drag-and-drop).\",\n },\n {\n name: \"filename\",\n type: \"string\",\n description: \"Original filename (used for MIME type inference when using `file_data`).\",\n },\n { name: \"file_path\", type: \"string\", description: \"Local file path.\" },\n { name: \"file_url\", type: \"string\", description: \"Remote file URL.\" },\n {\n name: \"document_id\",\n type: \"string\",\n description: \"ID of a previously uploaded document.\",\n },\n {\n name: \"schema\",\n type: \"object\",\n description: \"Inline schema definition (JSON Schema or flat key-type map).\",\n },\n {\n name: \"schema_id\",\n type: \"string\",\n description: \"UUID or SCH-XXXXXXXX short ID of a saved schema.\",\n },\n {\n name: \"instructions\",\n type: \"string\",\n description: \"Natural-language guidance for the extractor.\",\n },\n {\n name: \"include_markdown\",\n type: \"boolean\",\n description: \"Include OCR markdown alongside structured data.\",\n },\n ],\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: \"Always provide a `schema` or `schema_id`. Auto-discovery extract (no schema) is not reliable in v0.1.\",\n },\n { type: \"heading\", level: 3, id: \"extract-inline-schema\", text: \"Example: inline schema\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"file_url\": \"https://example.com/invoice-2026-001.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"vendor_name\": { \"type\": \"string\" },\n \"invoice_number\": { \"type\": \"string\" },\n \"total_amount\": { \"type\": \"number\" },\n \"due_date\": { \"type\": \"string\", \"format\": \"date\" },\n \"line_items\": {\n \"type\": \"array\",\n \"items\": {\n \"type\": \"object\",\n \"properties\": {\n \"description\": { \"type\": \"string\" },\n \"amount\": { \"type\": \"number\" }\n }\n }\n }\n },\n \"required\": [\"vendor_name\", \"total_amount\"]\n },\n \"instructions\": \"Amounts are in EUR. Focus on the billing section.\"\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"extraction_id\": \"ext_8f3a...\",\n \"request_id\": \"req_2c91...\",\n \"status\": \"complete\",\n \"document\": {\n \"id\": \"doc_8f3a...\",\n \"filename\": \"invoice-2026-001.pdf\",\n \"pages\": 2,\n \"type_detected\": \"invoice\",\n \"language_detected\": \"de\"\n },\n \"data\": {\n \"vendor_name\": \"Meridian Energy AG\",\n \"invoice_number\": \"INV-2026-001\",\n \"total_amount\": 1500.00,\n \"due_date\": \"2026-06-15\",\n \"line_items\": [\n { \"description\": \"Consulting, April\", \"amount\": 1200.00 },\n { \"description\": \"Travel expenses\", \"amount\": 300.00 }\n ]\n },\n \"schema\": {\n \"source\": \"inline\"\n },\n \"confidence\": {\n \"overall\": 0.97,\n \"fields\": {\n \"vendor_name\": 0.98,\n \"invoice_number\": 0.95,\n \"total_amount\": 0.99,\n \"due_date\": 0.97\n }\n },\n \"processing\": {\n \"duration_ms\": 2840,\n \"pages_processed\": 2,\n \"region\": \"eu-central-1\"\n }\n}`,\n },\n { type: \"heading\", level: 3, id: \"extract-schema-id\", text: \"Example: saved schema\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"file_path\": \"./contracts/lease-agreement.pdf\",\n \"schema_id\": \"SCH-A1B2C3D4\"\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"extraction_id\": \"ext_b29f...\",\n \"request_id\": \"req_4c81...\",\n \"status\": \"complete\",\n \"document\": {\n \"id\": \"doc_91ad...\",\n \"filename\": \"lease-agreement.pdf\",\n \"pages\": 8,\n \"type_detected\": \"lease_agreement\",\n \"language_detected\": \"en\"\n },\n \"data\": {\n \"lessor\": \"Acme Holdings Ltd.\",\n \"lessee\": \"Meridian Energy AG\",\n \"premises_address\": \"12 Hauptstrasse, 10115 Berlin\",\n \"term_start\": \"2026-07-01\",\n \"term_end\": \"2031-06-30\",\n \"monthly_rent_eur\": 4250.00\n },\n \"schema\": {\n \"source\": \"saved\",\n \"id\": \"SCH-A1B2C3D4\"\n },\n \"confidence\": {\n \"overall\": 0.94,\n \"fields\": {\n \"lessor\": 0.97,\n \"lessee\": 0.97,\n \"premises_address\": 0.92,\n \"term_start\": 0.95,\n \"term_end\": 0.95,\n \"monthly_rent_eur\": 0.91\n }\n },\n \"processing\": {\n \"duration_ms\": 4380,\n \"pages_processed\": 8,\n \"region\": \"eu-central-1\"\n }\n}`,\n },\n ],\n related: [\n { label: \"talonic_to_markdown\", slug: \"talonic-to-markdown\" },\n { label: \"talonic_save_schema\", slug: \"talonic-save-schema\" },\n { label: \"Drag & Drop Files\", slug: \"drag-and-drop\" },\n ],\n faq: [\n {\n question: \"How does talonic_extract work?\",\n answer:\n \"Send a document (file_data, file_path, file_url, or document_id) with a schema or schema_id. The tool returns schema-validated JSON with per-field confidence scores.\",\n },\n {\n question: \"What is the fastest way to extract data from a document?\",\n answer:\n \"If the document is already in your workspace, pass its document_id instead of re-uploading. For new documents in chat clients, use file_data with base64-encoded bytes. For files on the web, use file_url to avoid downloading locally first.\",\n },\n {\n question: \"How long does an extraction typically take?\",\n answer:\n \"Processing time depends on document size. A 2-page invoice typically completes in 2-4 seconds. Larger documents (8+ pages) may take 4-8 seconds. The processing.duration_ms field in the response shows the exact server-side duration.\",\n },\n ],\n mentions: [\"extract\", \"schema\", \"confidence scores\", \"file_data\"],\n },\n {\n slug: \"talonic-search\",\n parentSlug: \"tools\",\n title: \"talonic_search\",\n seoTitle: \"talonic_search Tool — Talonic MCP\",\n description:\n \"Omnisearch across documents, fields, sources, and schemas in the workspace. Supports conceptual and fuzzy queries.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Omnisearch across documents, fields, sources, and schemas in the workspace. Use for conceptual or fuzzy queries.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_search`** is designed for discovery. When a user asks a question like 'do I have any contracts about indemnification?' or 'find documents from Acme', this is the right tool. It searches across document filenames, extracted field values, schema names, and source metadata using semantic and fuzzy matching.\",\n },\n {\n type: \"paragraph\",\n text: \"The response is grouped by entity type: `documents`, `fieldMatches`, `schemas`, `sources`, and `fields`. Each result includes a relevance `score` (0..1) so the agent can assess match quality. Results with scores below 0.5 are typically not relevant and can be omitted when presenting to the user.\",\n },\n {\n type: \"paragraph\",\n text: \"For queries that require exact field-value matching (like 'invoices over 1000 EUR'), use **`talonic_filter`** instead. Search is for exploration and discovery; filter is for precision queries against structured data.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"query\",\n type: \"string\",\n required: true,\n description: \"The search query. Supports fuzzy and conceptual matching.\",\n },\n {\n name: \"limit\",\n type: \"integer\",\n description: \"Maximum results per entity type. Default: 5.\",\n },\n ],\n },\n {\n type: \"paragraph\",\n text: \"A common agent pattern is using `talonic_search` as a first step to orient within a workspace, then following up with more specific tools. For example, an agent might search for 'Acme contracts' to discover relevant documents, note the canonical field names in the response, and then use `talonic_filter` with those field names to narrow down to contracts expiring within a specific date range. This search-then-filter pattern is both efficient and reliable.\",\n },\n {\n type: \"paragraph\",\n text: \"Search results are scoped to the authenticated workspace. The query runs against all documents, extracted field values, schema definitions, and source metadata within that workspace. There is no cross-workspace search — each API key sees only its own data. The `limit` parameter controls how many results are returned per entity type (documents, fields, schemas, sources), with a default of 5. Increase the limit when the user needs a broader view of matching content.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Search results include canonical field names in `fields[].canonicalName`. These names can be used directly in `talonic_filter` conditions, making search a good first step before building precise filters.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: 'Every `fieldMatches[]` and `fields[]` entry carries a `dataType` (`\"string\"`, `\"number\"`, `\"array\"`, etc.). Use it to pick the right `talonic_filter` operator on the first call — numeric operators (`gt`, `gte`, `lt`, `lte`, `between`) only resolve correctly when `dataType === \"number\"`. See the *Schema typing* section under `talonic_filter` for the full preventive / reactive pattern.',\n },\n { type: \"heading\", level: 3, id: \"search-example\", text: \"Example\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"query\": \"indemnification clauses Acme\",\n \"limit\": 10\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"documents\": [\n {\n \"id\": \"doc_4e7b...\",\n \"filename\": \"acme-services-agreement.pdf\",\n \"type_detected\": \"Services Agreement\",\n \"score\": 0.92\n }\n ],\n \"fieldMatches\": [\n {\n \"fieldName\": \"indemnification.cap_amount\",\n \"documentId\": \"doc_4e7b...\",\n \"value\": \"2x annual fees\",\n \"documentCount\": 3,\n \"filterable\": true,\n \"dataType\": \"string\",\n \"score\": 0.88\n }\n ],\n \"schemas\": [],\n \"sources\": [],\n \"fields\": [\n { \"canonicalName\": \"indemnification.cap_amount\", \"dataType\": \"string\", \"filterable\": true }\n ]\n}`,\n },\n { type: \"heading\", level: 3, id: \"search-then-filter\", text: \"Example: search then filter\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Step 1: discover field names with search\",\n code: `// Agent calls talonic_search:\n{\n \"query\": \"vendor invoices total amount\",\n \"limit\": 5\n}\n\n// Response includes canonical field names plus dataType:\n{\n \"fields\": [\n { \"canonicalName\": \"vendor.name\", \"dataType\": \"string\", \"filterable\": true },\n { \"canonicalName\": \"invoice.total_eur\", \"dataType\": \"number\", \"filterable\": true },\n { \"canonicalName\": \"invoice.due_date\", \"dataType\": \"string\", \"filterable\": true }\n ]\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Step 2: use discovered field names in talonic_filter\",\n code: `// Agent uses canonical names from search to build a filter:\n{\n \"conditions\": [\n { \"field\": \"invoice.total_eur\", \"operator\": \"gt\", \"value\": 500 }\n ],\n \"sort\": { \"field\": \"invoice.total_eur\", \"direction\": \"desc\" }\n}`,\n },\n ],\n related: [\n { label: \"talonic_filter\", slug: \"talonic-filter\" },\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"Agent Decision Guide\", slug: \"agent-decision-guide\" },\n ],\n faq: [\n {\n question: \"What does talonic_search do?\",\n answer:\n \"It searches across documents, fields, sources, and schemas in the workspace using fuzzy and conceptual matching.\",\n },\n {\n question: \"When should I use talonic_search vs talonic_filter?\",\n answer:\n \"Use search for discovery and fuzzy queries ('find Acme contracts'). Use filter for precise field-value conditions ('invoices over 1000 EUR'). Search is exploration; filter is precision.\",\n },\n {\n question: \"What do the search scores mean?\",\n answer:\n \"Each result includes a relevance score from 0 to 1. Scores above 0.7 are strong matches, 0.5-0.7 are partial matches, and below 0.5 are typically not relevant.\",\n },\n {\n question: \"Can I search for schemas by name?\",\n answer:\n \"Yes. talonic_search includes schemas in its results. If you search for 'invoice', any schema with 'invoice' in its name or description will appear in the schemas array of the response. This is useful for discovering existing templates before creating new ones.\",\n },\n {\n question: \"How do I use search results to build a filter?\",\n answer:\n \"The fields array in the search response includes canonicalName values with a filterable flag. Use canonicalName values where filterable is true as the field parameter in talonic_filter conditions. This search-then-filter pattern is the recommended workflow for precise queries.\",\n },\n ],\n mentions: [\"search\", \"omnisearch\", \"fuzzy\", \"discovery\"],\n },\n {\n slug: \"talonic-filter\",\n parentSlug: \"tools\",\n title: \"talonic_filter\",\n seoTitle: \"talonic_filter Tool — Talonic MCP\",\n description:\n \"Filter documents by extracted field values using composable conditions like eq, gt, between, and contains.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Filter documents by extracted field values using composable conditions (`eq`, `gt`, `between`, `contains`, etc.).\",\n },\n {\n type: \"paragraph\",\n text: \"Accepts canonical field names (e.g. `vendor.name`, `policy.0_coverage_type`) which the Talonic API resolves to IDs server-side, or UUIDs directly.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_filter`** is the precision counterpart to **`talonic_search`**. While search uses fuzzy matching for discovery, filter applies exact conditions against extracted field values. This makes it ideal for queries like 'show me all invoices from vendor X over 1000 EUR' or 'contracts expiring before 2026-12-31'.\",\n },\n {\n type: \"paragraph\",\n text: \"Multiple conditions are AND-ed together, allowing you to build precise queries that narrow results progressively. The optional `search` parameter lets you combine free-text search with structured filters in a single call, and `sort` controls the result ordering.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"conditions\",\n type: \"array\",\n required: true,\n description:\n \"Filter conditions, AND-ed together. Each has `field` or `field_id`, `operator`, and `value`.\",\n },\n {\n name: \"search\",\n type: \"string\",\n description: \"Optional free-text search applied alongside filters.\",\n },\n {\n name: \"sort\",\n type: \"object\",\n description: 'Sort by a field: `{ field, direction: \"asc\" | \"desc\" }`.',\n },\n { name: \"page\", type: \"integer\", description: \"Page number for pagination.\" },\n { name: \"limit\", type: \"integer\", description: \"Results per page. Default: 50.\" },\n ],\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: \"Only fields where the search response shows `filterable: true` can be used with `talonic_filter`; entries with `filterable: false` have no extracted data yet. The `is_not_empty` operator checks materialized values, which are updated within seconds of extraction completing.\",\n },\n { type: \"heading\", level: 3, id: \"filter-example\", text: \"Example\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"conditions\": [\n { \"field\": \"vendor.name\", \"operator\": \"eq\", \"value\": \"Meridian Energy AG\" },\n { \"field\": \"invoice.total_eur\", \"operator\": \"gt\", \"value\": 1000 }\n ],\n \"sort\": { \"field\": \"invoice.total_eur\", \"direction\": \"desc\" },\n \"limit\": 20\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"data\": [\n {\n \"document_id\": \"doc_8f3a...\",\n \"filename\": \"invoice-2026-001.pdf\",\n \"fields\": {\n \"vendor.name\": \"Meridian Energy AG\",\n \"invoice.total_eur\": 1500.00,\n \"invoice.due_date\": \"2026-06-15\"\n }\n },\n {\n \"document_id\": \"doc_c2d9...\",\n \"filename\": \"invoice-2026-003.pdf\",\n \"fields\": {\n \"vendor.name\": \"Meridian Energy AG\",\n \"invoice.total_eur\": 1200.00,\n \"invoice.due_date\": \"2026-04-30\"\n }\n }\n ],\n \"total\": 2,\n \"page\": 1\n}`,\n },\n { type: \"heading\", level: 3, id: \"filter-operators\", text: \"Available operators\" },\n {\n type: \"paragraph\",\n text: \"The following operators are available for filter conditions: `eq` (equals), `neq` (not equals), `gt` (greater than), `gte` (greater than or equal), `lt` (less than), `lte` (less than or equal), `between` (range, requires a two-element array as value), `contains` (substring match), `starts_with`, `ends_with`, `is_empty` (checks for null or empty values), and `is_not_empty` (checks for materialized values). Numeric operators (`gt`, `gte`, `lt`, `lte`, `between`) only resolve correctly when the schema field is typed as `number`. The next section explains how to handle that constraint.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"filter-schema-typing\",\n text: \"Schema typing (preventive + reactive)\",\n },\n {\n type: \"paragraph\",\n text: 'A numeric operator on a string-typed field that happens to hold numeric content (e.g. `\"€1,500.00\"`) silently returns zero matches — the comparison falls back to lexicographic ordering and almost never produces the result the user expects. There are two ways to handle this; pick the right one before constructing the call.',\n },\n {\n type: \"heading\",\n level: 3,\n id: \"filter-preventive\",\n text: \"Preventive — gate on `dataType`\",\n },\n {\n type: \"paragraph\",\n text: 'Call `talonic_search` first and read `dataType` on the field entry. If `dataType !== \"number\"`, do not issue a numeric operator on that field. Pick a string-friendly operator (`eq`, `contains`) or warn the user that the field needs a `data_type` change in the schema definition before the query can succeed. This avoids the silent-zero-matches outcome entirely.',\n },\n {\n type: \"heading\",\n level: 3,\n id: \"filter-reactive\",\n text: \"Reactive — handle `warnings[]`\",\n },\n {\n type: \"paragraph\",\n text: \"When a numeric operator is applied to a string-typed field anyway, the API attaches a `warnings[]` array to the filter response. Each entry has `code`, `message`, `field`/`field_id`, and a `suggestion`. The MCP tool surfaces this in `structuredContent` — agents should relay the `message` (and `suggestion`, when present) to the user rather than silently retrying.\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Response with a warning\",\n code: `{\n \"data\": [],\n \"total\": 0,\n \"warnings\": [\n {\n \"code\": \"numeric_operator_on_string_field\",\n \"message\": \"Operator \\`gt\\` was applied to field \\`invoice_total\\` typed as string. Numeric comparisons against string-typed fields use lexicographic ordering and may return zero matches.\",\n \"field\": \"invoice_total\",\n \"field_id\": \"fld_inv_total\",\n \"suggestion\": \"Change the field's data_type to \\`number\\` in the schema definition.\"\n }\n ]\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"filter-combined-example\",\n text: \"Example: combined search and filter\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Combining free-text search with field-value filters\",\n code: `{\n \"conditions\": [\n { \"field\": \"invoice.due_date\", \"operator\": \"lte\", \"value\": \"2026-06-30\" },\n { \"field\": \"invoice.total_eur\", \"operator\": \"gte\", \"value\": 500 }\n ],\n \"search\": \"consulting services\",\n \"sort\": { \"field\": \"invoice.due_date\", \"direction\": \"asc\" },\n \"limit\": 10\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Pagination is supported via the `page` and `limit` parameters. The default page size is 50 results. For large workspaces with many matching documents, iterate through pages by incrementing `page` from 1. The response includes a `total` field showing the total number of matches, so the agent can determine how many pages remain and communicate this to the user.\",\n },\n {\n type: \"paragraph\",\n text: \"When building filters dynamically from user requests, agents should validate field names against the workspace's field registry first. The most reliable way is to call `talonic_search` to discover available canonical field names and check the `filterable` flag. Attempting to filter on a field that does not exist or is not yet filterable returns a `VALIDATION_ERROR` with a descriptive message. The agent should catch this error and suggest alternative field names rather than failing silently.\",\n },\n ],\n related: [\n { label: \"talonic_search\", slug: \"talonic-search\" },\n { label: \"Known Limitations\", slug: \"known-limitations\" },\n { label: \"Agent Decision Guide\", slug: \"agent-decision-guide\" },\n ],\n faq: [\n {\n question: \"How do I filter documents by field value?\",\n answer:\n \"Use talonic_filter with canonical field names and operators like eq, gt, between, contains. The API resolves field names to IDs server-side.\",\n },\n {\n question: \"How do I find the correct canonical field names for filtering?\",\n answer:\n \"Call talonic_search first — canonical field names appear in the fields[].canonicalName array. You can also inspect previously extracted documents to see their field structure.\",\n },\n {\n question: \"Can I combine free-text search with field filters?\",\n answer:\n \"Yes. Pass the search parameter alongside conditions to combine fuzzy text matching with structured field-value filters in a single call.\",\n },\n {\n question: \"What operators are available for talonic_filter?\",\n answer:\n \"Supported operators include eq, neq, gt, gte, lt, lte, between, contains, starts_with, ends_with, and is_empty. Numeric operators (gt, gte, lt, lte, between) require the schema field to be typed as number. String operators work on all field types.\",\n },\n {\n question: \"Why does my filter return zero results even though matching documents exist?\",\n answer:\n \"The most common cause is using a numeric operator (gt, lt, between) on a field that is typed as string in the schema. Currency symbols, commas, or locale formatting in the value also cause mismatches. Ensure the schema defines numeric fields as type number and that values are stored without formatting.\",\n },\n ],\n mentions: [\"filter\", \"canonical field names\", \"operators\", \"conditions\"],\n },\n {\n slug: \"talonic-get-document\",\n parentSlug: \"tools\",\n title: \"talonic_get_document\",\n seoTitle: \"talonic_get_document Tool — Talonic MCP\",\n description:\n \"Fetch full metadata for a single document by ID, including processing log and link URLs.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Fetch full metadata for a single document by ID, including processing log and link URLs.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_get_document`** retrieves comprehensive information about a document that has already been ingested into your Talonic workspace. This includes the file's status, page count, size, detected document type and language, the source that uploaded it, and direct links to the document in the Talonic dashboard and API.\",\n },\n {\n type: \"paragraph\",\n text: \"This tool is useful when the agent needs to check whether a document has finished processing, verify its detected type, or retrieve the dashboard link so the user can view the original. It does not return extracted data — for that, use **`talonic_extract`** with the same `document_id`.\",\n },\n {\n type: \"paragraph\",\n text: \"The `links.dashboard` URL in the response is particularly valuable for human-in-the-loop workflows. When the agent needs the user to verify an extraction against the original document, it can present this link as a direct way to view the source in the Talonic web interface.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"document_id\",\n type: \"string\",\n required: true,\n description: \"The document UUID.\",\n },\n ],\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"The `document_id` returned by `talonic_extract` and other tools is stable. You can call `talonic_get_document` at any time to check the document's current status and metadata.\",\n },\n { type: \"heading\", level: 3, id: \"get-document-example\", text: \"Example\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"document_id\": \"doc_8f3a1b2c-4d5e-6f7a-8b9c-0d1e2f3a4b5c\"\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"id\": \"doc_8f3a1b2c-4d5e-6f7a-8b9c-0d1e2f3a4b5c\",\n \"filename\": \"invoice-2026-001.pdf\",\n \"status\": \"completed\",\n \"pages\": 2,\n \"size_bytes\": 184320,\n \"mime_type\": \"application/pdf\",\n \"type_detected\": \"Invoice\",\n \"language_detected\": \"de\",\n \"source\": { \"id\": \"src_a1b2...\", \"type\": \"api\" },\n \"links\": {\n \"self\": \"https://api.talonic.com/v1/documents/doc_8f3a...\",\n \"extractions\": \"https://api.talonic.com/v1/documents/doc_8f3a.../extractions\",\n \"dashboard\": \"https://app.talonic.com/documents/doc_8f3a...\"\n }\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"get-document-workflow\",\n text: \"Example: human-in-the-loop verification\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent uses dashboard link for user verification\",\n code: `// After extracting data with low confidence on a critical field:\n// Agent calls talonic_get_document to get the dashboard link:\n{\n \"document_id\": \"doc_8f3a1b2c-4d5e-6f7a-8b9c-0d1e2f3a4b5c\"\n}\n\n// Agent presents to user:\n// \"The total_amount field has confidence 0.68.\n// Please verify against the original document:\n// https://app.talonic.com/documents/doc_8f3a...\"`,\n },\n {\n type: \"paragraph\",\n text: \"The `status` field in the response indicates the document's processing state. Common values are `completed` (ready for extraction and markdown retrieval), `processing` (still being ingested), and `failed` (ingestion encountered an error). Agents should check the status before attempting follow-up operations — calling `talonic_extract` on a document that is still `processing` will either wait or fail depending on the API's current behaviour.\",\n },\n {\n type: \"paragraph\",\n text: \"The `source` object in the response tells you how the document was uploaded. A `type` of `api` means it was uploaded via the MCP server or REST API, while `dashboard` means it was uploaded through the Talonic web interface. The `source.id` can be useful for filtering documents by upload source when a workspace has documents from multiple integration points.\",\n },\n {\n type: \"paragraph\",\n text: \"This tool is free to call — it does not consume extraction credits. Agents can call it as often as needed to check document status, retrieve links, or verify metadata without any cost concern. This makes it safe for polling scenarios where an agent needs to wait for a document to finish processing before proceeding with extraction.\",\n },\n ],\n related: [\n { label: \"talonic_to_markdown\", slug: \"talonic-to-markdown\" },\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n ],\n faq: [\n {\n question: \"How do I get document metadata via MCP?\",\n answer:\n \"Call talonic_get_document with the document UUID to get full metadata including processing log and link URLs.\",\n },\n {\n question: \"Does talonic_get_document return extracted data?\",\n answer:\n \"No. It returns metadata (filename, status, pages, type, language, links). For extracted field data, use talonic_extract with the same document_id.\",\n },\n {\n question: \"How can I link the user to the original document?\",\n answer:\n \"The response includes links.dashboard, which is a direct URL to view the document in the Talonic web interface. Present this to the user when they need to verify an extraction.\",\n },\n {\n question: \"Does talonic_get_document cost any credits?\",\n answer:\n \"No. It is a free metadata lookup that does not consume extraction credits. Agents can call it as often as needed to check document status, retrieve dashboard links, or verify metadata without cost concerns.\",\n },\n {\n question: \"What document statuses can talonic_get_document return?\",\n answer:\n \"Common statuses include completed (ready for extraction), processing (still being ingested), and failed (ingestion error). Check the status before attempting follow-up operations like extraction or markdown retrieval.\",\n },\n ],\n mentions: [\"document\", \"metadata\", \"processing log\", \"dashboard link\"],\n },\n {\n slug: \"talonic-to-markdown\",\n parentSlug: \"tools\",\n title: \"talonic_to_markdown\",\n seoTitle: \"talonic_to_markdown Tool — Talonic MCP\",\n description:\n \"Get OCR-converted markdown for a document. Accepts document_id, file_data + filename, file_path, or file_url.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Get OCR-converted markdown for a document. Accepts `document_id` (cheapest — no re-upload), `file_data` + `filename`, `file_path`, or `file_url`.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_to_markdown`** converts a document's visual content into clean, structured markdown. Tables are rendered as markdown tables, headings are preserved, and the text is ordered to match the visual layout of the original document. This is the right tool when the user wants the full text of a document for summarisation, translation, or general analysis without needing structured field extraction.\",\n },\n {\n type: \"paragraph\",\n text: \"If you have already ingested the document (via a previous `talonic_extract` or `talonic_to_markdown` call), pass the `document_id` to skip re-uploading. This is the cheapest and fastest path because the OCR has already been performed. For new documents, use `file_data` + `filename` in chat clients, `file_path` for local files, or `file_url` for remote files.\",\n },\n {\n type: \"paragraph\",\n text: \"The returned markdown is suitable for feeding into an LLM's context window for downstream tasks. Because the conversion preserves table structure and heading hierarchy, the LLM can reason about the document's content without losing structural information that raw text extraction would discard.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"document_id\",\n type: \"string\",\n description: \"ID of an already-ingested document (cheapest path).\",\n },\n {\n name: \"file_data\",\n type: \"string\",\n description: \"Base64-encoded file bytes. Pair with `filename`.\",\n },\n { name: \"filename\", type: \"string\", description: \"Original filename with extension.\" },\n { name: \"file_path\", type: \"string\", description: \"Local file path.\" },\n {\n name: \"file_url\",\n type: \"string\",\n description: \"Remote URL the API fetches server-side.\",\n },\n ],\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"If you need both structured data and markdown, use `talonic_extract` with `include_markdown: true` instead of making two separate calls. This saves one upload and one processing cycle.\",\n },\n { type: \"heading\", level: 3, id: \"to-markdown-example\", text: \"Example\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"document_id\": \"doc_8f3a1b2c-4d5e-6f7a-8b9c-0d1e2f3a4b5c\"\n}`,\n },\n {\n type: \"code\",\n language: \"markdown\",\n title: \"Tool response\",\n code: `# Invoice INV-2026-001\n\n**Meridian Energy AG**\nMusterstraße 42, 10115 Berlin\n\n| Item | Amount |\n|-----------------------|------------|\n| Consulting — April | €1,200.00 |\n| Travel expenses | €300.00 |\n| **Total** | **€1,500.00** |\n\nDue date: 15 June 2026\nPayment terms: Net 30`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"to-markdown-url-example\",\n text: \"Example: convert from URL\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input: convert a remote PDF to markdown\",\n code: `{\n \"file_url\": \"https://example.com/annual-report-2025.pdf\"\n}`,\n },\n {\n type: \"code\",\n language: \"markdown\",\n title: \"Tool response: structured markdown output\",\n code: `# Annual Report 2025\n\n## Financial Highlights\n\n| Metric | 2025 | 2024 | Change |\n|---------------------|------------|------------|---------|\n| Revenue | €12.4M | €9.8M | +26.5% |\n| Net Income | €2.1M | €1.4M | +50.0% |\n| Employees | 142 | 98 | +44.9% |\n\n## Board of Directors\n\n- **Chair**: Dr. Maria Fischer\n- **CEO**: Thomas Bergmann\n- **CFO**: Sarah Lindqvist`,\n },\n {\n type: \"paragraph\",\n text: \"The markdown output is designed to be LLM-friendly. Agents can feed the returned markdown directly into their context window for summarisation, translation, comparison, or question-answering tasks. Because the conversion preserves semantic structure (headings denote sections, tables retain rows and columns, lists maintain hierarchy), downstream LLM reasoning is significantly more accurate than working with raw OCR text that has lost all formatting cues.\",\n },\n {\n type: \"paragraph\",\n text: \"For multi-page documents, the markdown includes page break indicators and preserves the reading order across pages. Headers, footers, and page numbers are typically stripped or de-duplicated to produce a clean reading experience. If the document contains images with embedded text (like scanned letterheads or stamps), the OCR engine extracts visible text from those regions as well, though image-only content without text is omitted from the markdown output.\",\n },\n {\n type: \"paragraph\",\n text: \"When an agent needs to compare two versions of a document, `talonic_to_markdown` is the right starting point. Convert both documents to markdown, then use standard text diffing within the agent's context to identify changes. This is more reliable than visual comparison because the markdown normalises formatting differences and focuses on content. The stable document IDs make it easy to retrieve markdown for previously processed documents without re-uploading.\",\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"Drag & Drop Files\", slug: \"drag-and-drop\" },\n ],\n faq: [\n {\n question: \"How do I get markdown from a document via MCP?\",\n answer:\n \"Call talonic_to_markdown with a document_id (cheapest), or provide the file directly via file_data, file_path, or file_url.\",\n },\n {\n question: \"Does talonic_to_markdown preserve table structure?\",\n answer:\n \"Yes. Tables are rendered as markdown tables with proper column alignment. Headings and text ordering are also preserved to match the original document layout.\",\n },\n {\n question: \"Should I use talonic_to_markdown or talonic_extract with include_markdown?\",\n answer:\n \"If you only need the text, use talonic_to_markdown. If you need both structured fields and the full text, use talonic_extract with include_markdown: true to avoid two separate calls.\",\n },\n {\n question: \"Can I use talonic_to_markdown for document comparison?\",\n answer:\n \"Yes. Convert both document versions to markdown, then diff the text in the agent's context. Markdown normalises formatting differences and focuses on content, making comparison more reliable than visual methods. Use document_id for previously processed files to avoid re-uploading.\",\n },\n {\n question: \"Does talonic_to_markdown handle scanned documents?\",\n answer:\n \"Yes. The tool runs OCR on scanned PDFs, images (PNG, JPG, TIFF), and other image-based documents. Text is extracted from all visible regions including headers, stamps, and handwritten annotations where legible. The output is clean markdown regardless of whether the source is digital or scanned.\",\n },\n ],\n mentions: [\"markdown\", \"OCR\", \"document_id\", \"tables\"],\n },\n {\n slug: \"talonic-list-schemas\",\n parentSlug: \"tools\",\n title: \"talonic_list_schemas\",\n seoTitle: \"talonic_list_schemas Tool — Talonic MCP\",\n description: \"List all saved schemas in the workspace as compact summaries.\",\n content: [\n {\n type: \"paragraph\",\n text: \"List all saved schemas as compact summaries. Returns schema IDs (both UUID and `SCH-XXXXXXXX` short format), names, descriptions, version, and field counts.\",\n },\n {\n type: \"paragraph\",\n text: \"The full per-field JSON Schema definition is intentionally omitted from the list — across many schemas that payload is large and can get truncated by some clients. To inspect a schema's full field definitions, read the `talonic://schemas` resource, which clients that browse resources separately (Claude Desktop and Cowork) also render in the UI.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_list_schemas`** is a read-only tool that returns every saved schema in your workspace as a summary. Agents should call this before creating a new schema to avoid duplicates, and when the user asks about their available extraction templates. To read the full field structure of a specific schema, use the `talonic://schemas` resource.\",\n },\n {\n type: \"paragraph\",\n text: \"Each schema in the response includes both a UUID (`id`) and a human-friendly short ID (`short_id` in `SCH-XXXXXXXX` format). Either can be passed as `schema_id` to `talonic_extract`. The short ID is easier for users to reference in conversation, while the UUID is useful for programmatic workflows.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"Call `talonic_list_schemas` before `talonic_save_schema` to check if a similar schema already exists. This prevents cluttering the workspace with near-duplicate schemas.\",\n },\n { type: \"heading\", level: 3, id: \"list-schemas-example\", text: \"Example\" },\n { type: \"paragraph\", text: \"No input parameters required.\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"schemas\": [\n {\n \"id\": \"sch_7a1b2c3d-4e5f-6a7b-8c9d-0e1f2a3b4c5d\",\n \"short_id\": \"SCH-A1B2C3D4\",\n \"name\": \"Standard Invoice\",\n \"description\": \"Extracts vendor, line items, totals, and payment terms.\",\n \"version\": 3,\n \"field_count\": 6,\n \"definition\": {\n \"type\": \"object\",\n \"properties\": {\n \"vendor_name\": { \"type\": \"string\" },\n \"invoice_number\": { \"type\": \"string\" },\n \"total_amount\": { \"type\": \"number\" },\n \"due_date\": { \"type\": \"string\", \"format\": \"date\" },\n \"currency\": { \"type\": \"string\" },\n \"line_items\": { \"type\": \"array\" }\n },\n \"required\": [\"vendor_name\", \"total_amount\"]\n }\n },\n {\n \"id\": \"sch_e5f6a7b8-c9d0-1e2f-3a4b-5c6d7e8f9a0b\",\n \"short_id\": \"SCH-E5F6A7B8\",\n \"name\": \"Certificate of Insurance\",\n \"description\": \"Extracts insured party, coverage types, limits, and expiry.\",\n \"version\": 1,\n \"field_count\": 8,\n \"definition\": { \"type\": \"object\", \"properties\": { \"...\" : {} } }\n }\n ]\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"list-schemas-workflow\",\n text: \"Example: check for duplicates before saving\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent checks existing schemas before creating a new one\",\n code: `// User: \"Create a schema for purchase orders\"\n// Agent first checks existing schemas:\n// talonic_list_schemas → {}\n\n// Response shows existing schemas:\n{\n \"schemas\": [\n {\n \"id\": \"sch_7a1b...\",\n \"short_id\": \"SCH-A1B2C3D4\",\n \"name\": \"Standard Invoice\",\n \"field_count\": 6\n },\n {\n \"id\": \"sch_c3d4...\",\n \"short_id\": \"SCH-C3D4E5F6\",\n \"name\": \"Purchase Order\",\n \"field_count\": 7\n }\n ]\n}\n\n// Agent: \"You already have a 'Purchase Order' schema (SCH-C3D4E5F6)\n// with 7 fields. Would you like to use it, or create a new one?\"`,\n },\n {\n type: \"paragraph\",\n text: \"Agents should call `talonic_list_schemas` proactively in several scenarios: before saving a new schema (to prevent duplicates), when the user asks about available extraction templates, and when starting a session that involves document extraction (to present schema options). The call is free and returns quickly, so there is no cost or latency penalty for checking frequently.\",\n },\n {\n type: \"paragraph\",\n text: \"The `version` field on each schema tracks how many times it has been updated through the Talonic dashboard. A schema at version 1 has never been modified since creation. Higher versions indicate the schema has been refined — potentially adding new fields, changing types, or updating required fields. Agents can use this information to inform the user about schema maturity when choosing between multiple similar schemas.\",\n },\n {\n type: \"paragraph\",\n text: \"The `field_count` in the response is a quick indicator of schema complexity without needing to parse the full definition. Schemas with fewer fields are faster to extract and produce more focused results. Schemas with many fields (10+) cover more ground but may have lower per-field confidence on complex documents. Agents can use field count to help users choose between a detailed schema and a simpler one for quick extractions.\",\n },\n ],\n related: [\n { label: \"talonic_save_schema\", slug: \"talonic-save-schema\" },\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n ],\n faq: [\n {\n question: \"How do I list schemas via MCP?\",\n answer:\n \"Call talonic_list_schemas to get all saved schemas with their definitions. The talonic://schemas resource also exposes this data.\",\n },\n {\n question: \"What is the difference between the UUID and SCH-XXXXXXXX ID?\",\n answer:\n \"Both reference the same schema. The UUID (id) is the full identifier, while SCH-XXXXXXXX (short_id) is a shorter, human-friendly format. Either can be passed as schema_id to talonic_extract.\",\n },\n {\n question: \"Does talonic_list_schemas require any parameters?\",\n answer:\n \"No. It takes no input parameters and returns all saved schemas in the workspace with their full definitions.\",\n },\n {\n question: \"Is talonic_list_schemas free to call?\",\n answer:\n \"Yes. It is a read-only metadata call that does not consume extraction credits. Agents can call it as often as needed to check for existing schemas, present options to the user, or verify a schema exists before using it in an extraction.\",\n },\n {\n question: \"How do I know which schema to use for a document?\",\n answer:\n \"Call talonic_list_schemas to see all available schemas with their names, descriptions, and field counts. Match the schema name and description to the document type. For example, use a 'Standard Invoice' schema for invoices and a 'Certificate of Insurance' schema for COIs. When unsure, start with an inline schema and save it after confirming the results.\",\n },\n ],\n mentions: [\"schemas\", \"list\", \"SCH-XXXXXXXX\", \"resource\"],\n },\n {\n slug: \"talonic-save-schema\",\n parentSlug: \"tools\",\n title: \"talonic_save_schema\",\n seoTitle: \"talonic_save_schema Tool — Talonic MCP\",\n description: \"Save a schema definition to the workspace for reuse across extractions.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Save a schema definition to the workspace for reuse. Returns a `schema_id` that can be passed to `talonic_extract`.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_save_schema`** persists an extraction template so it can be referenced by ID in future `talonic_extract` calls. This is useful when the same schema will be applied to many documents — for example, a standard invoice schema used across all vendor invoices, or a contract schema applied to every new agreement.\",\n },\n {\n type: \"paragraph\",\n text: \"The recommended workflow is to iterate on the schema inline first (passing it directly to `talonic_extract`), verify the extraction results with the user, and only call `talonic_save_schema` once the schema design is confirmed. This avoids cluttering the workspace with draft schemas that never get used.\",\n },\n {\n type: \"paragraph\",\n text: \"The response returns both a UUID (`id`) and a short ID (`short_id` in `SCH-XXXXXXXX` format). Either can be used as `schema_id` in subsequent `talonic_extract` calls. The `version` field starts at 1 and increments if the schema is updated through the Talonic dashboard.\",\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"name\",\n type: \"string\",\n required: true,\n description: \"Human-readable schema name.\",\n },\n {\n name: \"definition\",\n type: \"object\",\n required: true,\n description:\n 'Schema definition. Full JSON Schema `{type: \"object\", properties: {...}}` recommended.',\n },\n {\n name: \"description\",\n type: \"string\",\n description: \"What this schema extracts and when to use it.\",\n },\n ],\n },\n {\n type: \"callout\",\n text: 'Prefer full JSON Schema format with `type: \"object\"` and `properties`. The flat key-type map format is not fully supported server-side yet.',\n },\n { type: \"heading\", level: 3, id: \"save-schema-example\", text: \"Example\" },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"name\": \"Standard Invoice\",\n \"description\": \"Extracts vendor, line items, totals, and payment terms from invoices.\",\n \"definition\": {\n \"type\": \"object\",\n \"properties\": {\n \"vendor_name\": { \"type\": \"string\" },\n \"invoice_number\": { \"type\": \"string\" },\n \"total_amount\": { \"type\": \"number\" },\n \"due_date\": { \"type\": \"string\", \"format\": \"date\" },\n \"line_items\": {\n \"type\": \"array\",\n \"items\": {\n \"type\": \"object\",\n \"properties\": {\n \"description\": { \"type\": \"string\" },\n \"amount\": { \"type\": \"number\" }\n }\n }\n }\n },\n \"required\": [\"vendor_name\", \"total_amount\"]\n }\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"id\": \"sch_7a1b2c3d-4e5f-6a7b-8c9d-0e1f2a3b4c5d\",\n \"short_id\": \"SCH-A1B2C3D4\",\n \"name\": \"Standard Invoice\",\n \"description\": \"Extracts vendor, line items, totals, and payment terms from invoices.\",\n \"version\": 1,\n \"field_count\": 5\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"save-schema-workflow\",\n text: \"Example: iterate inline then save\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Step 1: test the schema inline with talonic_extract\",\n code: `// Agent extracts with inline schema first:\n{\n \"file_url\": \"https://example.com/sample-po.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"po_number\": { \"type\": \"string\" },\n \"vendor\": { \"type\": \"string\" },\n \"items\": {\n \"type\": \"array\",\n \"items\": {\n \"type\": \"object\",\n \"properties\": {\n \"description\": { \"type\": \"string\" },\n \"quantity\": { \"type\": \"integer\" },\n \"unit_price\": { \"type\": \"number\" }\n }\n }\n },\n \"total\": { \"type\": \"number\" },\n \"delivery_date\": { \"type\": \"string\", \"format\": \"date\" }\n },\n \"required\": [\"po_number\", \"vendor\", \"total\"]\n }\n}\n// → User reviews results, confirms the schema looks right`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Step 2: save the confirmed schema for reuse\",\n code: `// Agent calls talonic_save_schema:\n{\n \"name\": \"Purchase Order\",\n \"description\": \"Extracts PO number, vendor, line items, total, and delivery date.\",\n \"definition\": {\n \"type\": \"object\",\n \"properties\": {\n \"po_number\": { \"type\": \"string\" },\n \"vendor\": { \"type\": \"string\" },\n \"items\": { \"type\": \"array\" },\n \"total\": { \"type\": \"number\" },\n \"delivery_date\": { \"type\": \"string\", \"format\": \"date\" }\n },\n \"required\": [\"po_number\", \"vendor\", \"total\"]\n }\n}\n\n// Response:\n{\n \"id\": \"sch_d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f9a\",\n \"short_id\": \"SCH-D4E5F6A7\",\n \"name\": \"Purchase Order\",\n \"version\": 1,\n \"field_count\": 5\n}\n// → Future extractions use: { \"schema_id\": \"SCH-D4E5F6A7\" }`,\n },\n {\n type: \"paragraph\",\n text: \"The `description` field is optional but strongly recommended. A clear description helps agents (and users) understand when to use a particular schema. Agents can read schema descriptions from `talonic_list_schemas` to auto-select the right schema based on the document type. For example, if the user drops a purchase order, the agent can scan saved schema descriptions for keywords like 'purchase order' or 'PO' and suggest the matching schema automatically.\",\n },\n {\n type: \"paragraph\",\n text: \"Schema naming conventions matter for discoverability. Use descriptive, consistent names like 'Standard Invoice', 'Certificate of Insurance', or 'Employment Contract' rather than abbreviations or internal codes. These names appear in `talonic_list_schemas` results and the `talonic://schemas` resource, where users and agents browse them to find the right template. A well-named schema library reduces friction across the entire team.\",\n },\n ],\n related: [\n { label: \"talonic_list_schemas\", slug: \"talonic-list-schemas\" },\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n ],\n faq: [\n {\n question: \"How do I save a schema via MCP?\",\n answer:\n \"Call talonic_save_schema with a name and JSON Schema definition. It returns a schema_id for reuse in talonic_extract calls.\",\n },\n {\n question: \"When should I save a schema vs use an inline schema?\",\n answer:\n \"Save a schema when you will reuse it across many documents (e.g., a standard invoice template). Use inline schemas for one-off extractions or when iterating on schema design with the user.\",\n },\n {\n question: \"Can I update a saved schema?\",\n answer:\n \"Schema updates are managed through the Talonic dashboard. The version field in the response tracks changes. Via MCP, you can save a new schema with a different name if the design changes significantly.\",\n },\n {\n question: \"What is the recommended workflow for schema design?\",\n answer:\n \"Iterate inline first: pass the schema directly to talonic_extract, review results with the user, adjust fields as needed. Once the user confirms the schema produces good results, call talonic_save_schema to persist it. This prevents cluttering the workspace with draft schemas that never get used.\",\n },\n {\n question: \"Should I include a description when saving a schema?\",\n answer:\n \"Yes. The description helps agents auto-select the right schema based on document type, and helps team members understand what each schema extracts. Use clear language like 'Extracts vendor, line items, totals, and payment terms from invoices' so both humans and AI agents can match schemas to documents.\",\n },\n ],\n mentions: [\"save schema\", \"JSON Schema\", \"reuse\", \"version\"],\n },\n {\n slug: \"talonic-get-balance\",\n parentSlug: \"tools\",\n title: \"talonic_get_balance\",\n seoTitle: \"talonic_get_balance Tool — Talonic MCP\",\n description:\n \"MCP tool that returns the current Talonic credit balance, EUR value, 30-day burn rate, projected runway, tier, and next monthly tier-reset timestamp.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Returns the workspace's current credit balance, EUR value, 30-day burn rate, projected runway in days, API tier, and the timestamp of the next monthly tier reset. Use it for budget-aware behaviour: read the balance before scheduling a large batch, or after a sequence of extractions to track spend.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"use-when\",\n text: \"When to use\",\n },\n {\n type: \"list\",\n items: [\n \"The user asks how many credits or how much budget they have left.\",\n \"Before kicking off a large or expensive operation (batch extract, re-extract many documents), to confirm budget headroom.\",\n \"The user asks how long the balance will last at the current rate.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"do-not-use\",\n text: \"When not to use\",\n },\n {\n type: \"list\",\n items: [\n \"For per-call cost of a single extraction: that is already on every `talonic_extract` response under `cost`.\",\n \"To top up credits: route the user to the dashboard. Auto top-up is guarded by a separate scope and is intentionally not exposed at the MCP layer.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"response-shape\",\n text: \"Response shape\",\n },\n {\n type: \"list\",\n items: [\n \"`balance_credits`: current credit balance (integer).\",\n \"`balance_eur`: current balance expressed in EUR (rounded to two decimals).\",\n \"`burn_rate_30d_credits`: total credits consumed in the trailing 30 days.\",\n \"`projected_runway_days`: days of runway at the current 30-day average burn rate. `-1` indicates no consumption in the trailing window (cannot compute a meaningful runway).\",\n \"`tier`: API tier of the workspace (`free`, `pro`, `enterprise`, etc.).\",\n \"`tier_resets_at`: ISO 8601 timestamp of the next monthly tier reset.\",\n ],\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"balance_credits\": 1888,\n \"balance_eur\": 9.44,\n \"burn_rate_30d_credits\": 360,\n \"projected_runway_days\": 157,\n \"tier\": \"pro\",\n \"tier_resets_at\": \"2026-06-01T00:00:00.000Z\"\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"balance-budget-check\",\n text: \"Example: budget check before batch extraction\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent checks balance before processing 50 documents\",\n code: `// User: \"Extract data from all 50 invoices in my workspace\"\n// Agent first checks budget:\n// talonic_get_balance → {}\n\n// Response:\n{\n \"balance_credits\": 120,\n \"balance_eur\": 0.60,\n \"burn_rate_30d_credits\": 360,\n \"projected_runway_days\": 10,\n \"tier\": \"free\",\n \"tier_resets_at\": \"2026-06-01T00:00:00.000Z\"\n}\n\n// Agent: \"You have 120 credits remaining. Extracting 50 documents\n// will cost approximately 50 credits, leaving 70 credits.\n// Your tier resets on June 1st. Shall I proceed?\"`,\n },\n {\n type: \"paragraph\",\n text: \"Budget-aware agents use `talonic_get_balance` to prevent unexpected credit depletion. Before starting a large batch extraction, the agent checks the remaining balance and estimates whether the batch will exceed available credits. If the balance is low, the agent can warn the user, suggest processing a subset, or recommend upgrading the plan. This proactive approach prevents mid-batch failures due to exhausted credits.\",\n },\n {\n type: \"paragraph\",\n text: \"The `tier` field indicates the workspace's API plan: `free`, `pro`, or `enterprise`. Each tier has different daily extraction limits and credit allowances. The `tier_resets_at` timestamp shows when the monthly credit cycle resets, which helps agents answer questions like 'when will my credits refresh?' or 'should I wait for the reset before processing this batch?'. Agents can use this information to advise users on timing large extraction jobs.\",\n },\n {\n type: \"paragraph\",\n text: \"The `burn_rate_30d_credits` field shows total consumption over the trailing 30 days, not a daily average. Agents can divide by 30 to estimate daily usage. Combined with `balance_credits`, this provides a clear picture of workspace sustainability. A high burn rate with a low balance signals the need for a plan upgrade or reduced usage before the next tier reset.\",\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"Pricing\", slug: \"pricing\" },\n ],\n faq: [\n {\n question: \"How do I check my Talonic credit balance from an agent?\",\n answer:\n \"Call talonic_get_balance with no arguments. Returns balance_credits, balance_eur, burn_rate_30d_credits, projected_runway_days, tier, and tier_resets_at. Read-only; safe to call at any time.\",\n },\n {\n question: \"What does projected_runway_days = -1 mean?\",\n answer:\n \"It means the workspace has had zero credit consumption in the trailing 30 days, so a meaningful runway projection cannot be computed. Treat -1 as 'unknown' rather than '0 days'.\",\n },\n {\n question: \"Should the agent check balance before every extraction?\",\n answer:\n \"Not for single extractions — that would add unnecessary latency. Check the balance before batch operations (10+ documents) or when the user explicitly asks about credits. For single extractions, proceed directly and let the API return a quota error if the balance is exhausted.\",\n },\n {\n question: \"How does the agent know the cost of an extraction?\",\n answer:\n \"Each talonic_extract response includes a cost field showing credits consumed for that extraction. Use talonic_get_balance before a batch to check available credits, and after to verify the remaining balance. Single extractions typically cost 1 credit each.\",\n },\n ],\n mentions: [\"credits\", \"balance\", \"EUR\", \"burn rate\", \"runway\", \"tier\", \"budget\"],\n },\n {\n slug: \"talonic-get-pricing\",\n parentSlug: \"tools\",\n title: \"talonic_get_pricing\",\n seoTitle: \"talonic_get_pricing Tool — Talonic MCP\",\n description:\n \"MCP tool that returns the machine-readable Talonic credit pricing catalog: fixed per-unit credit rates, EUR equivalents, the credits-per-EUR conversion, and processing-mode multipliers, so an agent can predict spend before running anything.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Returns the credit pricing catalog: fixed per-unit credit rates, their EUR equivalents, the credits-per-EUR conversion rate, and processing-mode multipliers (such as batch at 0.5x). Because the rates are fixed rather than token-based, an agent can read them and compute the exact cost of a planned job before spending a credit. The endpoint is public, so it works even before an API key is provisioned.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"use-when\",\n text: \"When to use\",\n },\n {\n type: \"list\",\n items: [\n \"Estimating the cost of a planned extraction, structuring, or matching job before running it.\",\n \"Answering a user question about how much Talonic costs per page or per operation.\",\n \"Deciding whether a workload fits a budget, especially before signing up.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"do-not-use\",\n text: \"When not to use\",\n },\n {\n type: \"list\",\n items: [\n \"For the workspace's remaining credit balance: use `talonic_get_balance`.\",\n \"For what the workspace has already spent and on what: use `talonic_get_usage`.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"response-shape\",\n text: \"Response shape\",\n },\n {\n type: \"list\",\n items: [\n \"`currency`: billing currency for the EUR equivalents (always `EUR`).\",\n \"`credits_per_eur`: conversion rate between credits and EUR (1,000 credits = 1 EUR at the standard rate).\",\n \"`multipliers`: processing-mode multipliers keyed by mode (e.g. `realtime: 1`, `batch: 0.5`).\",\n \"`units`: array of catalog lines, each with `unit`, `label`, `credits`, `eur`, and `free`.\",\n ],\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"currency\": \"EUR\",\n \"credits_per_eur\": 1000,\n \"multipliers\": { \"realtime\": 1, \"batch\": 0.5 },\n \"units\": [\n { \"unit\": \"page_ingest\", \"label\": \"Document page ingestion\", \"credits\": 100, \"eur\": 0.1, \"free\": false },\n { \"unit\": \"structuring_cell\", \"label\": \"Structuring cell (LLM-reasoned)\", \"credits\": 20, \"eur\": 0.02, \"free\": false },\n { \"unit\": \"registry_resolved_cell\", \"label\": \"Structuring cell (Field Registry resolved)\", \"credits\": 0, \"eur\": 0, \"free\": true },\n { \"unit\": \"intelligence_op\", \"label\": \"Intelligence operation (matching, cases, reconciliation)\", \"credits\": 100, \"eur\": 0.1, \"free\": false },\n { \"unit\": \"delivery\", \"label\": \"Delivery (webhook / export)\", \"credits\": 0, \"eur\": 0, \"free\": true },\n { \"unit\": \"validation\", \"label\": \"Validation / quality check\", \"credits\": 0, \"eur\": 0, \"free\": true }\n ]\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"pricing-estimate-example\",\n text: \"Example: quote a workload before running it\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Agent estimates the cost of a 20-page batch extraction\",\n code: `// User: \"How much will it cost to extract this 20-page contract in batch mode?\"\n// Agent reads pricing:\n// talonic_get_pricing → {}\n\n// page_ingest = 100 credits, batch multiplier = 0.5\n// 20 pages * 100 credits * 0.5 = 1000 credits = 1.00 EUR\n\n// Agent: \"Extracting 20 pages in batch mode costs about 1,000 credits\n// (1.00 EUR). Realtime would be 2,000 credits (2.00 EUR). Proceed in batch?\"`,\n },\n {\n type: \"paragraph\",\n text: \"Cost-aware agents call `talonic_get_pricing` to turn a workload into a concrete quote before committing to it. Multiply the relevant per-unit rate by the expected unit count, then apply the processing-mode multiplier. Because the catalog also returns the credits-per-EUR rate, the agent can present the estimate in either credits or euros without hardcoding any number.\",\n },\n {\n type: \"paragraph\",\n text: \"The catalog distinguishes billable units from free ones. Document page ingestion, structuring cells filled by fresh model reasoning, and intelligence operations carry a cost; Field Registry resolved cells, delivery, and validation are free. A document whose fields are answered entirely from the Field Registry therefore incurs only its page-ingestion cost, which an agent can surface as a reason to reuse schemas across similar documents.\",\n },\n ],\n related: [\n { label: \"talonic_get_usage\", slug: \"talonic-get-usage\" },\n { label: \"talonic_get_balance\", slug: \"talonic-get-balance\" },\n ],\n faq: [\n {\n question: \"Does talonic_get_pricing require an API key?\",\n answer:\n \"No. The pricing catalog is public, so an agent can read rates before signing up or provisioning a key. Call it with no arguments; it is read-only and safe to call at any time.\",\n },\n {\n question: \"How does an agent compute the cost of a job from the catalog?\",\n answer:\n \"Multiply the per-unit credits by the number of units (pages, cells, or operations), then apply the processing-mode multiplier (1 for realtime, 0.5 for batch). Divide by credits_per_eur to express the result in euros.\",\n },\n {\n question: \"Which operations are free in the catalog?\",\n answer:\n \"Field Registry resolved cells, delivery, and validation cost zero credits. Only fresh ingestion, fresh model-reasoned structuring cells, and intelligence operations (matching, cases, reconciliation) are billable.\",\n },\n ],\n mentions: [\n \"pricing\",\n \"credit catalog\",\n \"cost estimation\",\n \"per-page pricing\",\n \"batch discount\",\n \"credits per EUR\",\n \"budget\",\n ],\n },\n {\n slug: \"talonic-get-usage\",\n parentSlug: \"tools\",\n title: \"talonic_get_usage\",\n seoTitle: \"talonic_get_usage Tool — Talonic MCP\",\n description:\n \"MCP tool that returns per-function credit consumption for the workspace over a trailing window, so an agent can see where credits went across extraction, structuring, and intelligence operations.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Returns the workspace's credit consumption grouped by platform function over a trailing window, plus the total. Where `talonic_get_balance` reports what is left, this tool reports where the credits went: how much each function (page ingestion, structuring cells, intelligence operations) cost over the period. The breakdown is ordered by spend, highest first, so the dominant cost driver is the first row.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"use-when\",\n text: \"When to use\",\n },\n {\n type: \"list\",\n items: [\n \"The user asks what they have spent credits on, or which function dominates their spend.\",\n \"Reviewing burn by function to decide whether to shift work to batch mode or trim an operation.\",\n \"Producing a spend report for the last N days.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"do-not-use\",\n text: \"When not to use\",\n },\n {\n type: \"list\",\n items: [\n \"For the remaining balance and runway: use `talonic_get_balance`.\",\n \"For per-unit rates before running a job: use `talonic_get_pricing`.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"arguments\",\n text: \"Arguments\",\n },\n {\n type: \"list\",\n items: [\n \"`days` (optional): trailing reporting window in days. Default 30, clamped between 1 and 365.\",\n ],\n },\n {\n type: \"heading\",\n level: 3,\n id: \"response-shape\",\n text: \"Response shape\",\n },\n {\n type: \"list\",\n items: [\n \"`period_days`: length of the reporting window in days.\",\n \"`total_credits`: total credits consumed across all functions in the window.\",\n \"`by_function`: array of `{ operation_type, operations, credits }`, highest spend first.\",\n ],\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{ \"days\": 30 }`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"period_days\": 30,\n \"total_credits\": 48200,\n \"by_function\": [\n { \"operation_type\": \"page_ingest\", \"operations\": 412, \"credits\": 41200 },\n { \"operation_type\": \"structuring_cell\", \"operations\": 300, \"credits\": 6000 },\n { \"operation_type\": \"intelligence_op\", \"operations\": 10, \"credits\": 1000 }\n ]\n}`,\n },\n {\n type: \"paragraph\",\n text: \"Agents use `talonic_get_usage` to attribute spend to the functions that caused it. Pairing it with `talonic_get_balance` gives a full picture: balance shows how much is left, usage shows what consumed it, and pricing shows the rate of each function. An agent noticing that page ingestion dominates spend might suggest batch mode for the 0.5x discount, or reusing schemas so more cells resolve from the Field Registry for free.\",\n },\n {\n type: \"paragraph\",\n text: \"The figures read from the credit transaction ledger, so they reconcile exactly with the balance and history reported elsewhere. The `operation_type` values match the unit identifiers in the pricing catalog, which lets an agent join usage to rates and explain not just how many credits a function consumed but why. To express any figure in euros, divide by the credits-per-EUR rate from the pricing catalog.\",\n },\n ],\n related: [\n { label: \"talonic_get_pricing\", slug: \"talonic-get-pricing\" },\n { label: \"talonic_get_balance\", slug: \"talonic-get-balance\" },\n ],\n faq: [\n {\n question: \"How is talonic_get_usage different from talonic_get_balance?\",\n answer:\n \"Balance reports what is left (and runway); usage reports what was spent, grouped by function. Use balance to check headroom and usage to attribute spend to extraction, structuring, or intelligence operations.\",\n },\n {\n question: \"What window does talonic_get_usage cover?\",\n answer:\n \"The last 30 days by default. Pass days to change it, anywhere from 1 to 365. The response echoes period_days so the agent can confirm the window it summarized.\",\n },\n {\n question: \"Why is the breakdown empty?\",\n answer:\n \"Per-function rows populate as billable operations are charged. While metering runs in shadow mode the ledger records what each operation would cost without deducting, so the breakdown can be empty until enforcement is enabled. Pricing still returns the rates in the meantime.\",\n },\n ],\n mentions: [\n \"credit usage\",\n \"per-function spend\",\n \"credit consumption\",\n \"burn rate\",\n \"operation type\",\n \"spend report\",\n ],\n },\n {\n slug: \"talonic-request-upload\",\n parentSlug: \"tools\",\n title: \"talonic_request_upload\",\n seoTitle: \"talonic_request_upload Tool — Talonic MCP\",\n description:\n \"Request a browser-handoff upload link for files that can't be delivered via tool-call arguments. Returns a pre-allocated document_id, an upload URL, and an expiry timestamp.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Request a one-time upload link for a file the agent cannot deliver directly. Returns a pre-allocated `document_id`, a browser-openable `upload_url` the user drops the file into, and an `expires_at` timestamp.\",\n },\n {\n type: \"paragraph\",\n text: \"**`talonic_request_upload`** exists to route around the **~32 KB tool-call argument cap** in hosted-connector environments like Claude.ai's web UI. Above that ceiling, `file_data` on `talonic_extract` is silently truncated and the extraction returns null fields. The browser-handoff flow sidesteps the cap entirely: the user opens the upload URL in a separate tab, drops the file, and the agent then references the resulting document by ID.\",\n },\n {\n type: \"paragraph\",\n text: \"Local-stdio installs (Claude Desktop, Cursor, Cline, Continue, Cowork) do not have this cap and should keep using `file_data` for small-to-medium files. This tool is for the hosted connector path or any sandboxed environment where you can't reliably stream the file through the tool call.\",\n },\n { type: \"heading\", level: 3, id: \"request-upload-use-when\", text: \"When to use\" },\n {\n type: \"list\",\n items: [\n \"The user has a file to extract and you are running in a hosted-connector environment (Claude.ai, ChatGPT) where `file_data` is not reliable.\",\n \"The file is larger than ~32 KB (typical for real invoices, contracts, COIs).\",\n \"The user explicitly asks for an upload link.\",\n ],\n },\n { type: \"heading\", level: 3, id: \"request-upload-do-not-use\", text: \"When not to use\" },\n {\n type: \"list\",\n items: [\n \"You can deliver the file directly via `file_data` (local-stdio installs with small files).\",\n \"The file is already accessible via a public URL — use `file_url` on `talonic_extract` instead.\",\n \"The document is already in the workspace — use `document_id` on `talonic_extract` instead.\",\n ],\n },\n {\n type: \"param-table\",\n params: [\n {\n name: \"filename\",\n type: \"string\",\n required: true,\n description:\n \"Filename with extension (e.g. `invoice.pdf`). Used to pre-allocate the document record and infer MIME type.\",\n },\n ],\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool input\",\n code: `{\n \"filename\": \"invoice-2026-001.pdf\"\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Tool response\",\n code: `{\n \"document_id\": \"doc_8f3a2b9c-1d4e-5f6a-7b8c-9d0e1f2a3b4c\",\n \"upload_url\": \"https://app.talonic.com/u/069b8d9a-b05d-41df-8047-129af7c7aad5\",\n \"expires_at\": \"2026-05-28T20:35:00.000Z\"\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"request-upload-workflow\",\n text: \"End-to-end workflow\",\n },\n {\n type: \"list\",\n ordered: true,\n items: [\n \"Call `talonic_request_upload` with the filename. Capture `document_id`, `upload_url`, and `expires_at` from the response.\",\n \"Show the `upload_url` to the user and ask them to open it in a new browser tab and drop the file.\",\n 'Poll `talonic_get_document` with the `document_id` until `status` is `completed`. **Do not skip this step** — a user confirmation like \"uploaded\" only signals that the browser-side upload finished, not that server-side OCR and processing are done.',\n 'Once `status === \"completed\"`, call `talonic_extract` with the `document_id` and a `schema` or `schema_id` to pull out structured fields.',\n ],\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: 'Server-side processing (OCR + classification) typically takes 10–30 seconds after the browser upload completes. The agent must poll `talonic_get_document` until `status === \"completed\"` before calling `talonic_extract`. Calling extract too early returns errors that look like the file is missing.',\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Full sequence for a Claude.ai hosted-connector chat\",\n code: `// 1. Agent requests an upload link.\n// talonic_request_upload({ filename: \"rental-agreement.pdf\" })\n{\n \"document_id\": \"doc_1a2b3c4d-...\",\n \"upload_url\": \"https://app.talonic.com/u/069b8d9a-...\",\n \"expires_at\": \"2026-05-28T20:35:00.000Z\"\n}\n\n// 2. Agent: \"Open this link in a new tab and drop your file:\n// https://app.talonic.com/u/069b8d9a-...\n// I'll let you know once Talonic is done processing.\"\n\n// 3. After user drops the file, agent polls:\n// talonic_get_document({ document_id: \"doc_1a2b3c4d-...\" })\n// → status: \"processing\" → wait ~10s, poll again\n// → status: \"completed\" → ready to extract\n\n// 4. Agent extracts:\n// talonic_extract({\n// document_id: \"doc_1a2b3c4d-...\",\n// schema_id: \"SCH-RENTAL01\"\n// })\n// → structured JSON with per-field confidence scores`,\n },\n {\n type: \"paragraph\",\n text: \"The pre-allocated `document_id` is a real Talonic document from the moment the upload link is minted, but it stays in `pending` status until the user actually uploads. If the user closes the tab or the link expires (`expires_at`) without uploading, the document remains in `pending` and can be cleaned up via the dashboard. Re-issuing a fresh upload link for the same file is safe: the new link creates a new `document_id` with no link to the abandoned one.\",\n },\n {\n type: \"paragraph\",\n text: \"Agents should treat the `upload_url` as user-only information and never attempt to PUT to it themselves from the sandbox. Most sandboxed environments (Claude.ai's web tools, ChatGPT's Code Interpreter) cannot reach arbitrary S3-like endpoints, and even when they can, asking the user to open the link in their own browser preserves the user-agent boundary and avoids surprising the user with a backend upload they did not consent to.\",\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"talonic_get_document\", slug: \"talonic-get-document\" },\n { label: \"Drag & Drop Files\", slug: \"drag-and-drop\" },\n { label: \"Known Limitations\", slug: \"known-limitations\" },\n ],\n faq: [\n {\n question: \"When should the agent use `talonic_request_upload` instead of `file_data`?\",\n answer:\n \"In hosted-connector environments (Claude.ai web, ChatGPT) where tool-call arguments are capped around ~32 KB decoded payload. Real-world documents (100 KB+) get silently truncated when sent via file_data. Local-stdio installs (Claude Desktop, Cursor, Cline, Continue, Cowork) have no such cap and can keep using file_data.\",\n },\n {\n question: \"Does a user message like 'uploaded' mean the file is ready to extract?\",\n answer:\n \"No. That confirms only the browser-side upload finished. Server-side OCR and extraction typically need another 10–30 seconds. The agent must poll talonic_get_document until status is 'completed' before calling talonic_extract; calling earlier may return errors that look like the file is missing.\",\n },\n {\n question: \"What happens if the user never opens the upload link?\",\n answer:\n \"The pre-allocated document_id remains in pending status. The expires_at timestamp indicates when the upload URL stops accepting writes — typically a short window (minutes). Past that, request a fresh link with talonic_request_upload again; the new call mints a new document_id and a new URL.\",\n },\n {\n question: \"Can the agent PUT the file to the upload_url itself?\",\n answer:\n \"It usually cannot — Claude.ai's sandbox and similar hosted environments restrict outbound egress to arbitrary endpoints. Even where it would technically work, you should still hand the link to the user: it preserves the user-agent boundary (the user controls what file gets uploaded) and matches what every other browser-handoff flow looks like.\",\n },\n {\n question: \"Why a separate tool instead of changing `talonic_extract`?\",\n answer:\n \"Keeping the upload-link step explicit makes the agent's reasoning visible to the user (the user sees an upload link in chat and knows what's happening). Folding it into talonic_extract would either silently change the contract for small files or introduce a hidden mode switch — both bad for predictability.\",\n },\n ],\n mentions: [\n \"upload\",\n \"browser-handoff\",\n \"presigned URL\",\n \"document_id\",\n \"Claude.ai\",\n \"32 KB cap\",\n ],\n },\n]\n","import type { RawSection } from \"../types\"\n\nexport const sections: RawSection[] = [\n {\n slug: \"drag-and-drop\",\n parentSlug: \"features\",\n title: \"Drag & Drop Files\",\n seoTitle: \"Drag & Drop File Support — Talonic MCP\",\n description:\n \"Drop PDFs and documents directly into Claude Desktop, Cursor, or Cowork and extract data without file path configuration.\",\n content: [\n {\n type: \"paragraph\",\n text: \"When the user drag-drops a PDF (or any supported file) into a chat-style MCP host such as Claude Desktop, Cowork, or Cursor, the file lands in a host-owned sandbox directory the MCP server cannot read. The path the host hands the agent is meaningless to a separately-running `npx` MCP process.\",\n },\n {\n type: \"paragraph\",\n text: \"`@talonic/mcp@0.1.4` and later solve this by accepting **`file_data`** (base64-encoded file bytes) and **`filename`** on `talonic_extract` and `talonic_to_markdown`. The agent reads the file bytes from the conversation, base64-encodes them, and passes them through the MCP tool call. The MCP server decodes, infers MIME type from the filename, and uploads to the Talonic API.\",\n },\n {\n type: \"paragraph\",\n text: \"This approach works transparently across all chat-style MCP clients. The agent does not need to know where the file is stored on disk, and the user does not need to configure file paths or directory permissions. The entire flow — from drop to structured extraction — happens in a single conversation turn.\",\n },\n {\n type: \"paragraph\",\n text: \"Supported file types include PDF, PNG, JPG, TIFF, DOCX, XLSX, and other common document formats. The MCP server infers the MIME type from the `filename` extension, so always include the original file extension when passing `file_data`. If the extension is missing or unusual, the server may reject the upload with an `unsupported_file_type` error.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"drag-drop-example\",\n text: \"Example: drag-and-drop extraction flow\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"What the agent sends when a user drops a PDF\",\n code: `// User drops \"receipt-2026-05.pdf\" into the chat\n// The MCP client base64-encodes the file bytes automatically\n// Agent calls talonic_extract:\n{\n \"file_data\": \"JVBERi0xLjQKJcOkw7zDtsO8...\",\n \"filename\": \"receipt-2026-05.pdf\",\n \"schema\": {\n \"type\": \"object\",\n \"properties\": {\n \"merchant\": { \"type\": \"string\" },\n \"date\": { \"type\": \"string\", \"format\": \"date\" },\n \"total\": { \"type\": \"number\" },\n \"payment_method\": { \"type\": \"string\" }\n },\n \"required\": [\"merchant\", \"total\"]\n }\n}`,\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Extraction response from dropped file\",\n code: `{\n \"status\": \"complete\",\n \"document\": {\n \"id\": \"doc_f1e2...\",\n \"filename\": \"receipt-2026-05.pdf\",\n \"pages\": 1,\n \"type_detected\": \"receipt\"\n },\n \"data\": {\n \"merchant\": \"Coffee House Berlin\",\n \"date\": \"2026-05-07\",\n \"total\": 14.80,\n \"payment_method\": \"Visa ending 4242\"\n },\n \"confidence\": { \"overall\": 0.95 }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"The drag-and-drop flow works identically across Claude Desktop, Cowork, and other chat-style MCP clients that support file attachments. The key requirement is that the client encodes the file as base64 and passes it in the `file_data` parameter alongside the original `filename`. The MCP server uses the filename extension to determine the MIME type, decodes the base64 bytes, and uploads the file to the Talonic API in a single request.\",\n },\n {\n type: \"paragraph\",\n text: \"This `file_data` path works without limit in local-stdio installs (Claude Desktop, Cursor, Cline, Continue, Cowork). It does **not** work in the **Claude.ai hosted connector**, which caps tool-call arguments at ~32 KB decoded (~43 KB base64, measured against production) — a real PDF is silently truncated. In hosted connectors, use **`talonic_request_upload`**: it returns a browser link (`https://app.talonic.com/u/<token>`) the user opens to drop the file, after which the agent polls `talonic_get_document` until `status` is `completed` and then calls `talonic_extract` by `document_id`. `file_url` (a publicly reachable URL) and a pre-uploaded `document_id` also work.\",\n },\n {\n type: \"callout\",\n text: \"Tool descriptions advertise `file_data` as the recommended input for chat-style clients, so well-trained agents reach for it automatically. No client-side configuration required.\",\n },\n ],\n related: [\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"talonic_to_markdown\", slug: \"talonic-to-markdown\" },\n { label: \"Common Issues\", slug: \"common-issues\" },\n ],\n faq: [\n {\n question: \"Can I drag and drop files into Claude Desktop with Talonic?\",\n answer:\n \"Yes. Since @talonic/mcp@0.1.4, talonic_extract and talonic_to_markdown accept base64 file data directly, so you can drop a PDF into Claude Desktop and extract data without file path setup.\",\n },\n {\n question: \"What file types can I drag and drop?\",\n answer:\n \"PDF, PNG, JPG, TIFF, DOCX, XLSX, and other common document formats. The MCP server infers the MIME type from the filename extension.\",\n },\n {\n question: \"Why does drag-and-drop fail with an unsupported_file_type error?\",\n answer:\n \"The filename is missing a recognisable extension. Make sure the original filename with its extension is passed in the filename parameter alongside file_data.\",\n },\n {\n question: \"What happens if the dropped file is too large?\",\n answer:\n \"Base64 encoding increases payload size by about 33%. Most local MCP clients handle this fine, but hosted connectors may have payload limits. For large files (over 10 MB), use file_url with a public URL or upload via the Talonic dashboard and reference by document_id instead.\",\n },\n {\n question: \"Do I need to configure anything for drag-and-drop to work?\",\n answer:\n \"No. The file_data parameter is advertised in the tool descriptions, so MCP clients that support file attachments automatically encode and pass the file. Just drop the file into the chat and provide a schema — the agent handles the rest.\",\n },\n ],\n mentions: [\"drag-and-drop\", \"file_data\", \"base64\", \"Claude Desktop\"],\n },\n {\n slug: \"how-it-works\",\n parentSlug: \"features\",\n title: \"How It Works\",\n seoTitle: \"How Talonic MCP Works — Talonic Docs\",\n description:\n \"Architecture of the Talonic MCP server: MCP protocol over stdio to the agent, HTTPS with Bearer auth to api.talonic.com.\",\n content: [\n {\n type: \"code\",\n language: \"text\",\n title: \"Architecture\",\n code: `Agent (Claude Desktop / Cursor / Cline / etc.)\n ↓ MCP protocol over stdio\nTalonic MCP server (this package)\n ↓ HTTPS, Bearer auth\napi.talonic.com`,\n },\n {\n type: \"paragraph\",\n text: \"Each tool call is one HTTP request to the Talonic API, using your API key. The server handles auth, retries on transient failures (429, 5xx), MIME-type detection on file uploads, multipart serialisation, and structured error formatting.\",\n },\n {\n type: \"paragraph\",\n text: \"The MCP server acts as a thin translation layer between the MCP protocol and the Talonic REST API. It receives tool calls from the agent over **stdio** (local mode) or **streamable HTTP** (hosted mode), validates parameters, constructs the appropriate API request, and returns the response in the MCP-standard `content` format the agent expects.\",\n },\n {\n type: \"paragraph\",\n text: \"For file uploads, the server handles the complexity of multipart form encoding. It reads file bytes from `file_data` (base64), `file_path` (local disk), or `file_url` (remote URL), detects the MIME type from the filename extension, and streams the upload to `api.talonic.com`. This means the agent never needs to deal with multipart boundaries or content-type headers.\",\n },\n {\n type: \"paragraph\",\n text: \"Error handling is designed for agent consumption. API errors are reformatted into structured messages that include the error type, a human-readable description, and actionable next steps. For example, a missing schema error tells the agent to provide a `schema` or `schema_id`, rather than returning a raw 400 status code.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"request-lifecycle\",\n text: \"Request lifecycle\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"What happens during a talonic_extract call\",\n code: `// 1. Agent sends MCP tool call over stdio/HTTP:\n{\n \"tool\": \"talonic_extract\",\n \"arguments\": {\n \"file_url\": \"https://example.com/invoice.pdf\",\n \"schema\": { \"type\": \"object\", \"properties\": { \"total\": { \"type\": \"number\" } } }\n }\n}\n\n// 2. MCP server validates parameters, constructs API request:\n// POST https://api.talonic.com/v1/extract\n// Authorization: Bearer tlnc_...\n// Content-Type: multipart/form-data (for file uploads)\n\n// 3. API processes: download file → OCR → extract fields → validate schema\n\n// 4. MCP server formats response as MCP content:\n{\n \"content\": [\n {\n \"type\": \"text\",\n \"text\": \"{ \\\\\"status\\\\\": \\\\\"complete\\\\\", \\\\\"data\\\\\": { \\\\\"total\\\\\": 1500.00 }, ... }\"\n }\n ]\n}`,\n },\n {\n type: \"paragraph\",\n text: \"The MCP server is stateless between tool calls. It does not cache documents, schemas, or extraction results locally. Every tool call is an independent HTTP request to the Talonic API, which means the server can be restarted at any time without losing state. All persistence — documents, schemas, extraction history — lives in the Talonic cloud workspace, accessible via your API key.\",\n },\n {\n type: \"paragraph\",\n text: \"Authentication is handled transparently by the MCP server. For the local `npx` option, the server reads the `TALONIC_API_KEY` environment variable at startup and attaches it as a `Bearer` token to every API request. For the hosted option at `mcp.talonic.com`, the client passes the API key in the `Authorization` header, and the hosted server forwards it to the Talonic API. In neither case does the API key reach the AI agent — it stays within the MCP server process boundary.\",\n },\n {\n type: \"paragraph\",\n text: \"Transport modes differ between local and hosted deployments. The local `npx` server communicates with the MCP client over **stdio** (standard input/output), which is the default transport for locally-spawned MCP servers. The hosted server at `mcp.talonic.com` uses **streamable HTTP**, where the client sends HTTP requests and receives streamed responses. Both transports implement the same MCP protocol, so tool behaviour is identical regardless of transport mode.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"The MCP server automatically retries on `429` (rate limit) and `5xx` (server error) responses with exponential backoff. Agents do not need to implement retry logic themselves.\",\n },\n ],\n related: [\n { label: \"Environment Variables\", slug: \"env-variables\" },\n { label: \"Node SDK\", slug: \"introduction\" },\n { label: \"Install Overview\", slug: \"install-overview\" },\n ],\n faq: [\n {\n question: \"How does the Talonic MCP server work?\",\n answer:\n \"The MCP server communicates with AI agents over stdio using the MCP protocol. Each tool call translates to one HTTPS request to api.talonic.com with automatic auth, retries, and error formatting.\",\n },\n {\n question: \"Does the MCP server handle retries automatically?\",\n answer:\n \"Yes. The server retries on 429 (rate limit) and 5xx (server error) responses with exponential backoff. Agents do not need to implement retry logic.\",\n },\n {\n question: \"How are errors returned to the agent?\",\n answer:\n \"API errors are reformatted into structured messages with error type, description, and actionable next steps. The agent receives clear guidance instead of raw HTTP status codes.\",\n },\n {\n question: \"Does the MCP server store any data locally?\",\n answer:\n \"No. The server is stateless between tool calls. It does not cache documents, schemas, or results locally. All persistence lives in the Talonic cloud workspace. The server can be restarted at any time without losing state.\",\n },\n {\n question: \"Is my API key exposed to the AI agent?\",\n answer:\n \"No. The API key stays within the MCP server process boundary. For local setups, it is read from the TALONIC_API_KEY environment variable. For hosted setups, it is passed in the Authorization header. In neither case does the key reach the AI agent's context window.\",\n },\n ],\n mentions: [\"stdio\", \"HTTPS\", \"Bearer auth\", \"architecture\", \"retry\", \"error handling\"],\n },\n]\n","import type { RawSection } from \"../types\"\n\nexport const sections: RawSection[] = [\n {\n slug: \"env-variables\",\n parentSlug: \"configuration\",\n title: \"Environment Variables\",\n seoTitle: \"Configuration — Talonic MCP\",\n description:\n \"Environment variables for configuring the Talonic MCP server: API key and optional base URL override.\",\n content: [\n { type: \"paragraph\", text: \"Set via the `env` block in your MCP client config:\" },\n {\n type: \"param-table\",\n params: [\n {\n name: \"TALONIC_API_KEY\",\n type: \"string\",\n required: true,\n description: \"Your Talonic API key. Starts with `tlnc_`.\",\n },\n {\n name: \"TALONIC_BASE_URL\",\n type: \"string\",\n description: \"Override the API base URL.\",\n default: \"https://api.talonic.com\",\n },\n ],\n },\n {\n type: \"paragraph\",\n text: \"The `TALONIC_API_KEY` is the only required configuration. It authenticates every API call the MCP server makes on your behalf. The key must start with `tlnc_` — if you pass a key with a different prefix, the server will reject it at startup with a clear error message.\",\n },\n {\n type: \"paragraph\",\n text: \"The `TALONIC_BASE_URL` override is rarely needed. It exists for enterprise customers with a dedicated Talonic deployment or for developers testing against a staging environment. Most users should leave this unset, which defaults to `https://api.talonic.com`.\",\n },\n {\n type: \"paragraph\",\n text: \"Environment variables are set differently depending on your MCP client and deployment mode. For local `npx` setups, they go in the `env` block of the MCP client config JSON. For the hosted server at `mcp.talonic.com`, the API key is passed as a `Bearer` token in the `Authorization` header instead of an environment variable.\",\n },\n {\n type: \"paragraph\",\n text: \"If the MCP server cannot read the API key at startup, it exits with a descriptive error. Common causes include a malformed `env` block in the JSON config, a typo in the variable name, or the MCP client not passing environment variables through to the spawned process. Always fully restart the client after editing the config.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"env-local-config\",\n text: \"Local npx configuration example\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Full MCP client config with environment variables\",\n code: `{\n \"mcpServers\": {\n \"talonic\": {\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": {\n \"TALONIC_API_KEY\": \"tlnc_your_key_here\"\n }\n }\n }\n}`,\n },\n {\n type: \"heading\",\n level: 3,\n id: \"env-base-url-override\",\n text: \"Base URL override for enterprise deployments\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Config with custom base URL for a dedicated Talonic deployment\",\n code: `{\n \"mcpServers\": {\n \"talonic\": {\n \"command\": \"npx\",\n \"args\": [\"-y\", \"@talonic/mcp@latest\"],\n \"env\": {\n \"TALONIC_API_KEY\": \"tlnc_your_key_here\",\n \"TALONIC_BASE_URL\": \"https://api.talonic.yourcompany.com\"\n }\n }\n }\n}`,\n },\n {\n type: \"paragraph\",\n text: \"For teams managing multiple environments (development, staging, production), each environment should use a separate API key pointing to a different Talonic workspace. This ensures that test documents and schemas do not mix with production data. Create separate config files or use environment-specific variable values to switch between workspaces. The `TALONIC_BASE_URL` override is only needed for enterprise customers with a dedicated Talonic deployment — all other users should leave it unset.\",\n },\n {\n type: \"paragraph\",\n text: \"Some MCP clients support reading environment variables from the system shell rather than the config file. If your client supports this, you can set `TALONIC_API_KEY` in your shell profile (`.bashrc`, `.zshrc`, or equivalent) and omit the `env` block from the config. This approach is slightly more secure because the key is not stored in a JSON file that might be accidentally committed to version control. However, most MCP clients require the `env` block explicitly, so check your client's documentation.\",\n },\n {\n type: \"paragraph\",\n text: \"When using the hosted server at `mcp.talonic.com`, environment variables are not used at all. Instead, the API key is passed in the `Authorization` header as a `Bearer` token. This means the `env` block is irrelevant for hosted configurations — only the `url` and `headers` fields matter. If you switch from local to hosted, remove the `env`, `command`, and `args` fields and replace them with `url` and `headers`.\",\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: \"Never commit your `TALONIC_API_KEY` to version control. If using a shared MCP config template, replace the key with a placeholder like `tlnc_your_key_here` before sharing.\",\n },\n ],\n related: [\n { label: \"Install Overview\", slug: \"install-overview\" },\n { label: \"Get an API Key\", slug: \"get-api-key\" },\n { label: \"Common Issues\", slug: \"common-issues\" },\n ],\n faq: [\n {\n question: \"What environment variables does the Talonic MCP server need?\",\n answer:\n \"TALONIC_API_KEY (required, starts with tlnc_) and optionally TALONIC_BASE_URL to override the API endpoint.\",\n },\n {\n question: \"Where do I set environment variables for the MCP server?\",\n answer:\n \"For local npx setups, set them in the env block of your MCP client config JSON. For the hosted server, the API key is passed as a Bearer token in the Authorization header instead.\",\n },\n {\n question: \"What happens if the API key is missing or invalid?\",\n answer:\n \"The MCP server exits at startup with a descriptive error message. Check that the env block in your config is correctly formatted and the key starts with tlnc_. Restart the client after fixing.\",\n },\n {\n question: \"Can I set the API key in my shell profile instead of the config file?\",\n answer:\n \"Some MCP clients support reading environment variables from the system shell. If yours does, set TALONIC_API_KEY in .bashrc or .zshrc and omit the env block from the config. However, most clients require the env block explicitly, so check your client documentation first.\",\n },\n {\n question: \"Do I need TALONIC_BASE_URL for normal usage?\",\n answer:\n \"No. TALONIC_BASE_URL defaults to https://api.talonic.com and only needs to be overridden for enterprise customers with a dedicated Talonic deployment or developers testing against a staging environment. Leave it unset for standard usage.\",\n },\n ],\n mentions: [\"TALONIC_API_KEY\", \"TALONIC_BASE_URL\", \"environment variables\"],\n },\n]\n","import type { RawSection } from \"../types\"\n\nexport const sections: RawSection[] = [\n {\n slug: \"common-issues\",\n parentSlug: \"troubleshooting\",\n title: \"Common Issues\",\n seoTitle: \"Troubleshooting — Talonic MCP\",\n description:\n \"Solutions for common Talonic MCP server issues: missing API key, server not appearing, extract errors, and filter validation.\",\n content: [\n {\n type: \"paragraph\",\n text: \"This section covers the most frequently encountered issues when setting up and using the Talonic MCP server. Each issue includes a description, the root cause, and the fix. If your problem is not listed here, check the Known Limitations section or reach out via GitHub issues.\",\n },\n {\n type: \"paragraph\",\n text: \"Most issues fall into two categories: **configuration problems** (the server does not start or connect) and **tool errors** (the server is running but a specific tool call fails). Configuration problems are almost always caused by malformed JSON, a missing API key, or not restarting the MCP client after editing the config.\",\n },\n {\n type: \"paragraph\",\n text: \"Tool errors typically include a structured error message with an error type and description. Read the error message carefully — it usually tells you exactly what is wrong and how to fix it. For example, a `VALIDATION_ERROR` on `talonic_filter` means the field name is not in the API's registry.\",\n },\n {\n type: \"paragraph\",\n text: \"When debugging, start by verifying the MCP server is running. Check the connected servers list in your MCP client. If Talonic is not listed, the issue is in your config or client setup. If it is listed but a tool call fails, the issue is with the tool input or API-side.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"missing-api-key\",\n text: \"TALONIC_API_KEY environment variable is required\",\n },\n {\n type: \"paragraph\",\n text: \"The `env` block in your MCP client config is missing or not being read. Double-check the JSON shape. After editing the config, fully restart the client (not just the conversation).\",\n },\n\n {\n type: \"heading\",\n level: 3,\n id: \"server-not-found\",\n text: \"Talonic does not appear in connected servers\",\n },\n {\n type: \"paragraph\",\n text: 'Make sure the `command` is `npx` and the `args` are exactly `[\"-y\", \"@talonic/mcp@latest\"]`. Sanity check: run `npx -y @talonic/mcp@latest --version` in any terminal — it should print a version number.',\n },\n\n {\n type: \"heading\",\n level: 3,\n id: \"extract-no-schema\",\n text: \"talonic_extract returns a validation error when no schema is given\",\n },\n {\n type: \"paragraph\",\n text: \"By design. To keep results reliable, the MCP layer asks for the fields you want when a call omits `schema`, `schema_id`, and `auto_schema`. The error hands back a ready-to-paste minimal JSON Schema (tailored to your `instructions`) so the retry succeeds immediately. Three ways forward: provide an inline `schema` (full JSON Schema recommended), pass a `schema_id` from `talonic_list_schemas`, or set `auto_schema: true` for open capture — Talonic discovers the fields and returns a suggested schema you can refine.\",\n },\n\n {\n type: \"heading\",\n level: 3,\n id: \"unsupported-file\",\n text: \"talonic_extract rejects with unsupported_file_type\",\n },\n {\n type: \"paragraph\",\n text: \"The MIME type was inferred as `application/octet-stream`. The SDK infers from common file extensions; if your filename has an unusual extension, this may occur. A future tool version will expose explicit `content_type` passthrough.\",\n },\n\n {\n type: \"heading\",\n level: 3,\n id: \"filter-validation\",\n text: 'talonic_filter VALIDATION_ERROR / \"No field matches name\"',\n },\n {\n type: \"paragraph\",\n text: \"The field name is not in the API's field registry. Field names must be canonical names (e.g. `vendor.name`, `policy.0_term_end`). Call `talonic_search` first; canonical names appear in `fields[].canonicalName`.\",\n },\n\n {\n type: \"heading\",\n level: 3,\n id: \"stale-descriptions\",\n text: \"Tool descriptions look wrong in my client\",\n },\n {\n type: \"paragraph\",\n text: \"Some MCP clients cache tool descriptions. Restart the client after a server update.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"auth-error\",\n text: \"Authentication error on every tool call\",\n },\n {\n type: \"paragraph\",\n text: \"If every tool call returns an authentication error, the credential the server is using is missing, malformed, or revoked. For the local npx option, check that the `env` block in your config has the correct variable name (`TALONIC_API_KEY`, not `TALONIC_KEY` or `API_KEY`) and that the value starts with `tlnc_`. For the hosted server with a custom-header client, verify the `Authorization` header is formatted as `Bearer tlnc_...` with a space after `Bearer`. For the Claude.ai connector OAuth flow, see the OAuth-specific entry below.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"oauth-flow\",\n text: \"Claude.ai connector: stuck on sign-in or callback\",\n },\n {\n type: \"paragraph\",\n text: \"The Claude.ai custom-connector flow uses OAuth 2.1 with PKCE against `app.talonic.com`. If the sign-in window opens but does not return to Claude.ai, or the connector reports `disconnected` after authorising, walk through these checks. Make sure you are signed in to the same Talonic account in `app.talonic.com` that owns the workspace you want to use. Allow third-party cookies for `app.talonic.com` and `claude.ai`; some browsers block the post-consent redirect otherwise. After granting consent, you should be redirected back to Claude.ai automatically; if the tab stays on `app.talonic.com`, click the Talonic logo or close the tab and reopen the connector to retry. If you have multiple Talonic accounts, sign out of `app.talonic.com` first, then start the connector flow again so the right account is used. As a last resort, remove the connector in Claude.ai and add it again with `https://mcp.talonic.com/mcp` as the URL.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"timeout-errors\",\n text: \"Tool calls time out on large documents\",\n },\n {\n type: \"paragraph\",\n text: \"Large documents (20+ pages) may take longer than some MCP clients' default timeout. The Talonic API processes documents up to 100 pages, but extraction time scales with page count. If you experience timeouts, try splitting large documents into smaller sections before uploading. Alternatively, check if your MCP client has a configurable timeout setting — increasing it to 60 seconds should accommodate most documents.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"debug-checklist\",\n text: \"Debug checklist\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Step-by-step debug commands\",\n code: `// 1. Verify the MCP server installs and runs:\n// Terminal: npx -y @talonic/mcp@latest --version\n// Expected: prints version number (e.g., 0.1.6)\n\n// 2. Verify your API key is valid:\n// Terminal: curl -H \"Authorization: Bearer tlnc_your_key\" https://api.talonic.com/v1/schemas\n// Expected: JSON response (even if empty schemas array)\n\n// 3. Validate your config JSON:\n// Paste your config into https://jsonlint.com\n// Common errors: trailing commas, missing quotes, wrong brackets\n\n// 4. Verify client picked up the config:\n// Check the connected servers list in your MCP client\n// If Talonic is missing, the config is not being read`,\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"When reporting issues, include the MCP server version (`npx -y @talonic/mcp@latest --version`), your MCP client name and version, and the full error message. This helps diagnose problems faster.\",\n },\n ],\n related: [\n { label: \"Known Limitations\", slug: \"known-limitations\" },\n { label: \"Upgrading\", slug: \"upgrading\" },\n { label: \"Environment Variables\", slug: \"env-variables\" },\n ],\n faq: [\n {\n question: \"Why does Talonic MCP not appear in Claude Desktop?\",\n answer:\n 'Check that command is \"npx\" and args are [\"-y\", \"@talonic/mcp@latest\"]. Run npx -y @talonic/mcp@latest --version in a terminal to verify. Fully restart Claude Desktop (Cmd+Q).',\n },\n {\n question: \"Why does talonic_extract fail with a validation error?\",\n answer:\n \"The most common cause is that no fields were specified. Provide a schema (inline JSON Schema) or a schema_id from talonic_list_schemas — or set auto_schema: true for open capture, where Talonic discovers the fields and returns a suggested schema. The validation error already hands back a ready-to-paste minimal schema, so the retry succeeds on the next call.\",\n },\n {\n question: \"How do I debug MCP server connection issues?\",\n answer:\n \"First verify the server runs standalone: npx -y @talonic/mcp@latest --version. Then check your config JSON is valid, the API key starts with tlnc_, and you have fully restarted your MCP client.\",\n },\n {\n question: \"Why do all tool calls return authentication errors?\",\n answer:\n \"The API key is missing, malformed, or revoked. Verify the key starts with tlnc_ in your config. For local setups, check the env block uses TALONIC_API_KEY (exact name). For hosted setups, check the Authorization header format is 'Bearer tlnc_...' with a space after Bearer. Regenerate the key in the dashboard if it was revoked.\",\n },\n {\n question: \"What should I do if large documents time out?\",\n answer:\n \"Documents over 20 pages may exceed some MCP clients' default timeout. Try splitting the document into smaller sections, or increase your MCP client's timeout setting to 60 seconds. The Talonic API supports documents up to 100 pages but processing time scales with page count.\",\n },\n ],\n mentions: [\"troubleshooting\", \"API key\", \"VALIDATION_ERROR\"],\n },\n {\n slug: \"known-limitations\",\n parentSlug: \"troubleshooting\",\n title: \"Known Limitations\",\n seoTitle: \"Known Limitations — Talonic MCP\",\n description:\n \"Current limitations in the Talonic MCP server v0.1: schema requirement, filter discoverability and typing, Claude.ai drag-and-drop stall, and unsurfaced cost.\",\n content: [\n {\n type: \"paragraph\",\n text: \"The Talonic MCP server v0.1 is production-ready but has a number of known limitations that are planned for future releases. Understanding these limitations helps agents make better decisions about when and how to use each tool.\",\n },\n {\n type: \"paragraph\",\n text: \"Most limitations relate to the extraction pipeline's maturity in v0.1. Certain filter operators, cost information, and per-field provenance have constraints. These are documented here so agent developers can set accurate expectations and build appropriate fallbacks.\",\n },\n {\n type: \"list\",\n items: [\n \"**`talonic_extract` needs to know which fields to pull.** Pass a `schema` (full JSON Schema recommended) or a `schema_id` — or set `auto_schema: true` for open capture, where Talonic discovers the fields and returns a suggested schema. A call that gives none of the three returns a validation error that hands back a ready-to-paste minimal schema, so the retry succeeds immediately.\",\n \"**Schema definition: prefer full JSON Schema.** The flat key-type map is documented as accepted; if you get a 'no fields' error from the API, fall back to JSON Schema.\",\n \"**Filter requires `filterable: true` fields.** Call `talonic_search` first; only entries in the response where `filterable: true` can be used as `field` (or `field_id`) on `talonic_filter`. Entries with `filterable: false` exist in the schema but have no extracted data yet.\",\n \"**Schema field type affects filter operators.** Numeric operators (`gt`, `gte`, `lt`, `lte`, `between`) only work on fields typed as `number` in the schema. Numeric values stored as strings (with currency symbols, locale formatting, etc.) silently return zero results. Type your schema fields appropriately at design time.\",\n \"**`is_not_empty` filter checks materialized data.** Results reflect values within seconds of extraction completing. For batch-mode documents, values are materialized after the batch poll cycle completes.\",\n \"**Dragging a file directly into a Claude.ai chat does not work through the hosted connector** — use `talonic_request_upload` instead. A base64-encoded real PDF exceeds Claude.ai's tool-call argument cap (~32 KB decoded / ~43 KB base64, measured against production), so `file_data` is silently truncated and the API returns `null` fields. This is a structural platform limit, not a Talonic bug. The supported path is the browser-handoff flow: `talonic_request_upload` returns an `app.talonic.com/u/<token>` link the user opens to drop the file; poll `talonic_get_document` until `status` is `completed`, then `talonic_extract` by `document_id`. Alternatives: `file_url` or a pre-uploaded `document_id`. Local-stdio installs (Claude Desktop, Cursor, Cline, Continue, Cowork) have no cap and use `file_data` directly.\",\n \"**Cost, EUR price, and remaining balance are not surfaced.** The API does not return them yet. Credit balance must be checked in the Talonic dashboard.\",\n ],\n },\n {\n type: \"paragraph\",\n text: \"Agents should handle these limitations gracefully. For the schema requirement, always construct or reference a schema before calling `talonic_extract`. For the missing cost information, direct users to the Talonic dashboard at `https://app.talonic.com` when they ask about pricing or credit balance.\",\n },\n {\n type: \"paragraph\",\n text: \"The `is_not_empty` operator is now available and checks the materialized values index, which updates within seconds of extraction completing. For batch-mode documents, materialization occurs after the batch poll cycle applies results.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"limitations-workarounds\",\n text: \"Workarounds summary\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Quick reference: limitation → workaround\",\n code: `// Schema required on talonic_extract\n// → Always pass schema (JSON Schema) or schema_id\n\n// is_not_empty checks materialized values (updated within seconds of extraction)\n\n// Drag-and-drop stalls on Claude.ai (hosted connector)\n// → Use file_url, document_id, or local stdio install\n\n// Numeric filter on string-typed field returns zero results\n// → Define numeric fields as type \"number\" in the schema\n\n// Filter on non-filterable field returns VALIDATION_ERROR\n// → Call talonic_search first, use fields where filterable: true`,\n },\n {\n type: \"paragraph\",\n text: \"When building agent workflows that will run unattended, design for these limitations explicitly. Check that every `talonic_extract` call includes a schema or schema_id. Validate filter field names against `talonic_search` results before constructing conditions. For file uploads in hosted connectors with size limits, prefer `file_url` or `document_id` over `file_data`. These defensive patterns ensure the agent handles edge cases gracefully instead of failing with cryptic errors.\",\n },\n {\n type: \"paragraph\",\n text: \"The Talonic team actively tracks these limitations and publishes fixes in minor version updates. Subscribe to the `@talonic/mcp` npm package changelog or watch the GitHub repository for release notes. Limitations that are resolved in newer versions are removed from this list. If you encounter a limitation not documented here, report it via GitHub issues with the MCP server version and a minimal reproduction case.\",\n },\n {\n type: \"callout\",\n variant: \"warning\",\n text: \"For predictable automated workflows, pin the fields with a `schema` or `schema_id`. When you don't yet know the fields, `auto_schema: true` (open capture) discovers them and returns a suggested schema you can save and reuse for stability.\",\n },\n ],\n related: [\n { label: \"Common Issues\", slug: \"common-issues\" },\n { label: \"talonic_extract\", slug: \"talonic-extract\" },\n { label: \"talonic_filter\", slug: \"talonic-filter\" },\n ],\n faq: [\n {\n question: \"What are the known limitations of Talonic MCP?\",\n answer:\n \"talonic_extract needs fields specified via schema, schema_id, or auto_schema: true (open capture). Filter requires filterable: true fields (use talonic_search first to discover them). Numeric filter operators require schema fields typed as number. Drag-and-drop file uploads in Claude.ai currently stall via the hosted MCP; use file_url or document_id instead, or use the local stdio install. Cost and balance are not surfaced in tool responses yet.\",\n },\n {\n question: \"Can I extract without knowing the fields up front (schema-less)?\",\n answer:\n \"Yes. Set auto_schema: true on talonic_extract for open capture: Talonic discovers the document's fields and returns a suggested schema alongside the data. Refine and save that schema with talonic_save_schema for stable, repeatable extraction. For predictable production workflows, providing an explicit schema or schema_id is still recommended.\",\n },\n {\n question: \"How do I check my credit balance or costs?\",\n answer:\n \"Cost information is not surfaced in v0.1 tool responses. Check your credit balance and usage in the Talonic dashboard at app.talonic.com.\",\n },\n {\n question: \"How do I report a new limitation or bug?\",\n answer:\n \"Open an issue on the @talonic/mcp GitHub repository with the MCP server version (npx -y @talonic/mcp@latest --version), your MCP client name and version, and a minimal reproduction case. Include the full error message if applicable.\",\n },\n {\n question: \"How do I work around the Claude.ai drag-and-drop limitation?\",\n answer:\n \"Claude.ai's hosted connector truncates large tool-call arguments, which breaks base64 file uploads. Use file_url with a publicly reachable URL, upload the file via the Talonic dashboard and use document_id, or switch to a local stdio install (Claude Desktop, Cursor, Cline) which has no parameter size cap.\",\n },\n ],\n mentions: [\n \"limitations\",\n \"schema\",\n \"filterable\",\n \"is_not_empty\",\n \"drag-and-drop\",\n \"rate limits\",\n ],\n },\n {\n slug: \"upgrading\",\n parentSlug: \"troubleshooting\",\n title: \"Upgrading\",\n seoTitle: \"Upgrading from Older Versions — Talonic MCP\",\n description:\n \"How to upgrade from older @talonic/mcp versions that had the silent-bin bug affecting MCP client launches.\",\n content: [\n {\n type: \"paragraph\",\n text: \"Versions before `0.1.3` had a bug where the bundled MCP server bin would exit silently when launched via the npm bin symlink, which is exactly how every MCP client invokes it. If you see no `talonic_*` tools despite correct config, you are hitting that bug.\",\n },\n {\n type: \"paragraph\",\n text: \"The fix: point your `args` at `@latest` (or `@0.1.3` explicitly) and fully restart the client:\",\n },\n { type: \"code\", language: \"jsonc\", code: '\"args\": [\"-y\", \"@talonic/mcp@latest\"]' },\n {\n type: \"paragraph\",\n text: \"Using `@latest` is the recommended approach because it ensures you automatically receive new features, bug fixes, and improved tool descriptions on every client restart. If you need version stability for a production workflow, pin to a specific version like `@0.1.6` instead.\",\n },\n {\n type: \"paragraph\",\n text: \"After updating the `args` in your MCP client config, you must fully restart the client application. Simply starting a new conversation is not enough — the MCP server process must be terminated and re-spawned. On Claude Desktop, use Cmd+Q (macOS) or close from the system tray (Windows). On Cursor and VS Code-based clients, reload the window.\",\n },\n {\n type: \"heading\",\n level: 3,\n id: \"upgrade-verify\",\n text: \"Verify the upgrade\",\n },\n {\n type: \"code\",\n language: \"json\",\n title: \"Check the installed version after upgrading\",\n code: `// In a terminal, verify the latest version installs:\n// npx -y @talonic/mcp@latest --version\n// Expected output: 0.1.6 (or the latest published version)\n\n// In your MCP client, verify tools are available:\n// Ask the agent: \"What version of Talonic MCP are you using?\"\n// Or call talonic_list_schemas — a successful response\n// confirms the server is running the updated version.`,\n },\n {\n type: \"paragraph\",\n text: \"When upgrading between minor versions, tool parameters and response shapes remain backward-compatible. New versions may add optional parameters to existing tools or introduce new tools, but they will not remove or change existing parameters. This means your existing agent workflows and saved schemas continue to work without modification after an upgrade.\",\n },\n {\n type: \"paragraph\",\n text: \"If you are running a pinned version and want to check whether a newer version is available, run `npm view @talonic/mcp version` in a terminal. This shows the latest published version on npm without installing it. Compare this against your pinned version to decide whether to upgrade. The changelog in the npm package description summarises what changed between versions.\",\n },\n {\n type: \"paragraph\",\n text: \"For teams with multiple developers using the Talonic MCP server, coordinate upgrades by updating the shared MCP config file or template. If different team members run different versions, tool descriptions and capabilities may vary, leading to inconsistent agent behaviour. Using `@latest` for all team members ensures everyone has the same tools and avoids version-related debugging sessions.\",\n },\n {\n type: \"callout\",\n variant: \"info\",\n text: \"If you are using the hosted server at `mcp.talonic.com`, upgrades are automatic. You do not need to change any configuration — the hosted server always runs the latest version.\",\n },\n ],\n related: [\n { label: \"Install Overview\", slug: \"install-overview\" },\n { label: \"Common Issues\", slug: \"common-issues\" },\n ],\n faq: [\n {\n question: \"How do I upgrade the Talonic MCP server?\",\n answer:\n 'Set args to [\"-y\", \"@talonic/mcp@latest\"] in your MCP client config and fully restart the client. Versions before 0.1.3 had a silent-bin bug that prevented the server from booting.',\n },\n {\n question: \"Do I need to upgrade if I use the hosted server?\",\n answer:\n \"No. The hosted server at mcp.talonic.com is automatically updated to the latest version. No configuration changes are needed on your end.\",\n },\n {\n question: \"Should I pin to a specific version or use @latest?\",\n answer:\n \"Use @latest for development and most use cases — it picks up fixes automatically. Pin to a specific version (e.g., @0.1.6) only if you need strict version stability in production workflows.\",\n },\n {\n question: \"Are upgrades backward-compatible?\",\n answer:\n \"Yes. Minor version upgrades maintain backward compatibility — existing tool parameters and response shapes are preserved. New versions may add optional parameters or new tools, but will not break existing workflows, schemas, or agent integrations.\",\n },\n {\n question: \"How do I check if a newer version is available?\",\n answer:\n \"Run npm view @talonic/mcp version in a terminal to see the latest published version on npm. Compare against your pinned version or run npx -y @talonic/mcp@latest --version to see what @latest resolves to.\",\n },\n ],\n mentions: [\"upgrade\", \"silent-bin bug\", \"0.1.3\", \"@latest\"],\n },\n]\n","// ---------------------------------------------------------------------------\n// Structured content export for @talonic/mcp documentation.\n//\n// ⚠ This module is the source-of-truth for talonic.com/docs/mcp/* pages.\n// The website's <McpContentPage> calls getMcpSection(slug) at render time.\n// docs/sections.json in this repo is a SEPARATE surface that feeds the\n// SDK/API/Platform doc pages on the website, NOT the MCP doc pages.\n// Full architecture, \"add a new tool\" checklist, and failure modes:\n// docs/architecture/docs-pipeline.md\n//\n// Usage:\n// import { getMcpSection, getAllMcpSections, MCP_NAV_SECTIONS } from '@talonic/mcp/content'\n// ---------------------------------------------------------------------------\n\nexport type { DocBlock, DocSection, RawSection, Param, HttpMethod, NavSection } from \"./types\"\n\nexport { MCP_NAV_SECTIONS } from \"./seo\"\n\nimport type { DocSection, RawSection } from \"./types\"\nimport { deriveBreadcrumbs, derivePrevNext } from \"./helpers\"\nimport { MCP_NAV_SECTIONS } from \"./seo\"\n\n// --- Section imports ---\nimport { sections as overview } from \"./sections/overview\"\nimport { sections as install } from \"./sections/install\"\nimport { sections as tools } from \"./sections/tools\"\nimport { sections as features } from \"./sections/features\"\nimport { sections as configuration } from \"./sections/configuration\"\nimport { sections as troubleshooting } from \"./sections/troubleshooting\"\n\n// ---------------------------------------------------------------------------\n// Registry\n// ---------------------------------------------------------------------------\n\nconst ALL_RAW: RawSection[] = [\n ...overview,\n ...install,\n ...tools,\n ...features,\n ...configuration,\n ...troubleshooting,\n]\n\n// ---------------------------------------------------------------------------\n// Enrichment\n// ---------------------------------------------------------------------------\n\nfunction enrich(raw: RawSection[]): DocSection[] {\n return raw.map((r) => {\n const { prev, next } = derivePrevNext(MCP_NAV_SECTIONS, r.slug)\n return {\n ...r,\n breadcrumbs: deriveBreadcrumbs(MCP_NAV_SECTIONS, r.slug),\n prev,\n next,\n }\n })\n}\n\nlet _sections: DocSection[] | null = null\n\nfunction getSectionsAll(): DocSection[] {\n if (!_sections) {\n _sections = enrich(ALL_RAW)\n }\n return _sections\n}\n\n// ---------------------------------------------------------------------------\n// Public API\n// ---------------------------------------------------------------------------\n\n/** Get a single MCP section by slug, or null if not found. */\nexport function getMcpSection(slug: string): DocSection | null {\n return getSectionsAll().find((s) => s.slug === slug) ?? null\n}\n\n/** Get all MCP sections in reading order. */\nexport function getAllMcpSections(): DocSection[] {\n return getSectionsAll()\n}\n"]}
|