Thin Python SDK and CLI for the hosted Docspeed /v1/* customer API, plus shared metadata used by the hosted Docspeed remote MCP service.
pip install docspeedCLI installs also work with:
pipx install docspeed
uv tool install docspeedfrom docspeed import Docspeed
with Docspeed(api_key="docspeed_sk_...") as client:
uploaded = client.files.upload("sample.pdf")
parsed = client.parse(
{
"input": {"file_id": uploaded.file_id},
"execution_mode": "sync",
"profile": "grounded",
"grounding": "ocr_lines",
"include_artifacts": True,
}
)
print(parsed.markdown[:500])docspeed --api-key "$DOCSPEED_API_KEY" parse --file sample.pdf --execution-mode sync --profile fastThe package is intentionally thin:
- hosted API client only
- streaming multipart uploads for large files
- core dependencies limited to
httpx,pydantic, andtyper - provider-native agent SDKs are not required
parse supports two hosted profiles on the same endpoint:
groundedis the default for richer support-aware parse output used by extraction and evidence-heavy review workflowsfastis the quicker hosted ingest path for agent reading, OCR lines, bounding boxes, and page refs
Docspeed 0.2.x adds shared MCP-friendly tool metadata and timeout continuation helpers for the hosted remote MCP endpoint:
- endpoint:
https://mcp.docspeed.ai/mcp - auth:
Authorization: Bearer <DOCSPEED_API_KEY> - tool surface: files, page images, parse/layout/OCR/classify/split, tables/equations/charts, schema-auto, extract, chat, agents, and jobs
Long-running MCP tools return structured continuation guidance when the internal wait budget expires, including job_id, next_tool, and next_arguments.
{
"mcpServers": {
"docspeed": {
"type": "streamable-http",
"url": "https://mcp.docspeed.ai/mcp",
"headers": {
"Authorization": "Bearer ${DOCSPEED_API_KEY}"
}
}
}
}Use the hosted MCP server URL with a Docspeed API key in the MCP server configuration for your agent runtime. The Python SDK remains provider-SDK-free in the base install, and optional provider-native adapters still belong behind extras rather than core dependencies.