MCP Server
Docsfra ships a hosted MCP (Model Context Protocol) server, so any MCP client — Claude Code, Claude Desktop, Cursor, or your own agents — can use Docsfra directly as a tool: upload documents, search them, ask questions with page-and-box citations, and read the derived AI layers. No integration code required.
Endpoint:
https://api.docsfra.com/mcp(Streamable HTTP)Auth: your own Docsfra API key in the
Authorizationheader —Bearer dip_live_...orBearer dip_test_...(test keys are metered but never billed). Calls are billed at the standard artifact/query rates.
Connecting
Claude Code (CLI):
claude mcp add --transport http docsfra https://api.docsfra.com/mcp \
--header "Authorization: Bearer dip_live_..."
Cursor / generic JSON config:
{
"mcpServers": {
"docsfra": {
"url": "https://api.docsfra.com/mcp",
"headers": { "Authorization": "Bearer dip_live_..." }
}
}
}
claude.ai custom connectors (OAuth)
claude.ai's web connectors don't use API-key headers — they use OAuth, and Docsfra supports the full flow (dynamic client registration + PKCE):
- In claude.ai: Settings → Connectors → Add custom connector
- Paste
https://api.docsfra.com/mcp— no key needed - Your browser opens the Docsfra Console: sign in (if needed) and approve
On approval a dedicated API key (named MCP: <client>) is created for your
selected tenant and handed to claude.ai as its access token. Revoking access
is simply deleting that key in Console → API Keys.
No header support?
Some MCP clients can't set custom headers. Append your key to the URL instead — no other configuration needed:
https://api.docsfra.com/mcp?key=dip_live_...
The key value is masked in our access logs. The Authorization header
remains the preferred method. Tip: the Console shows one-click copyable,
key-embedded setup snippets right when you create an API key.
Tools
| Tool | What it does |
|---|---|
upload_document | Upload a small file (base64, ~200 KB'a kadar pratik — kısa PDF/.eml). Returns the job id. Anything larger: upload via Console or POST /v1/documents, then search/ask here. |
get_job | Poll a job: status, ai_status, page count, cost, fresh result URLs. |
search_documents | Hybrid (vector + full-text + rerank) search across your documents; optional single-document scope. |
ask | RAG question answering grounded only in your documents; every answer carries citations (document, page, and bounding box where layout permits). |
cross_check | Compare two or more processed documents' verified reasoning claims (no upper limit); returns cross-document contradiction/support findings, both sides cited with page and exact quote. |
get_document_memory | Identity card, summary, timeline and the segment map (merged scans auto-split into sub-documents with page ranges). |
get_document_entities | Typed entity graph with OCR reconciliation: canonical values, competing OCR variants, confidence and needs_review flags. |
get_document_reasoning | Verified reasoning claims (obligation / condition / deadline / prohibition / …), each anchored to a verbatim quote found in the document — hallucination-shielded. |
A typical agent flow
upload_document→ job idget_jobuntilstatus=completedandai_status=readyget_document_memory→ understand what the file contains (segments)askscoped to the document → cited answers;get_document_reasoning/get_document_entitiesfor structured cross-checks
All authorization, tenant isolation and billing are enforced by the same
/v1 API contract documented in the rest of these pages — the MCP server is
a thin, stateless surface over it and never stores your key.