Skip to main content
Glama
okra-project

okraPDF PDF MCP server

Official
by okra-project

Resolve PDF URL

resolve_pdf_url

Resolve an open-access PDF URL into a stable document_id for subsequent okraPDF parsing, rendering, and citation tasks. Use for public records or documents you have rights to process.

Instructions

Resolve a lawfully-reachable PDF URL to a stable okraPDF document_id using the D1 URL registry when later okraPDF tool calls need that document_id: execute_code SQL/search/docs.read, render_ui, view_document/review_extraction, verify_source with parsed-node evidence, or workflow runs. Intended for open/public-record sources (SEC EDGAR, gov, public-domain, permissively-licensed arXiv) and for documents the user supplies or has the rights to process. Do NOT use it to fetch behind a paywall, login, or anti-bot wall, and do NOT treat the resulting derivative as a public mirror of a copyrighted source — see internal/content-rights-policy.md (mirror levels). If you only need to read or understand the PDF content for reasoning, use normal web_fetch/browser reading first; for arXiv papers, prefer the arxiv.org/html/... page when available because it is cleaner and cheaper than OCR. Do not use this for "verify", "cite", "prove", "source", or "where in the PDF" requests; call verify_source directly with pdf_url + page/pages instead. Opens the live document viewer immediately while ingest/parse/page previews finish. Do not set wait_for/wait_ms unless the very next tool call depends on query/page/visual readiness.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYesLawfully-reachable HTTPS URL for a PDF (open/public-record source or a doc you have rights to; not paywalled/license-gated — those are refused). arXiv /abs and /html URLs normalize to the direct PDF URL.
pagesNoOptional page range/list used with wait_for="page" and passed to the live viewer, e.g. "23" or "1-3".
wait_msNoOptional readiness wait budget. Defaults to 0 so the resolver returns quickly after starting ingest. Only set this when the very next tool call depends on parse/page/visual readiness.
wait_forNoOptional readiness target for wait_ms. document=phase ready, query=nodes ready, page=requested pages have images, visual=initial viewer preview images ready.
processorNoOCR processor/vendor id for the parse. Defaults to "gemini-vision" (layout-aware Gemini Flash VLM) so view_document gets bbox-bearing citation overlays. Pass "textlayer" for a fast text-only parse without overlays.
open_viewerNoWhether to open the live MCP document viewer. Defaults to true; the tool is UI-bound so hosts can show progress immediately.
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and largely delivers. It discloses the live viewer opening, default wait_ms=0 fast return, wait_for semantics, processor default (gemini-vision with bbox overlays), open_viewer default, and refusal of protected sources. Minor gaps: exact behavior on refusal or error not described, and the internal policy file is referenced but not summarized.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is longer than average but every sentence adds a distinct piece of guidance: purpose, legal constraints, alternatives, viewer behavior, and wait semantics. It is front-loaded with the primary verb+resource. Could be slightly tighter, but none of the content is redundant or filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool has 6 parameters, no annotations, and no output schema, the description is remarkably complete. It covers purpose, legal boundaries, when to use alternatives, what the tool does immediately (open viewer, start ingest), the wait/readiness model, and parameter defaults. The absence of a returned-output schema is partially mitigated by the description naming the resolved document_id as the core output.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, but the description adds substantial meaning beyond schemas: url gets legal/source-type context and arXiv normalization; pages is linked to wait_for='page' and the viewer; wait_ms explains its default and when to set it; wait_for expands each enum phase; processor explains default vs textlayer tradeoff; open_viewer explains the UI-bound default. This goes well beyond a baseline 3.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb+resource: 'Resolve a lawfully-reachable PDF URL to a stable okraPDF document_id using the D1 URL registry.' It names downstream tools that need this ID and explicitly distinguishes itself from verify_source and web_fetch/browser reading, clearly separating it from siblings.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides explicit when/when-not guidance: disallows paywalled/login/anti-bot sources, directs pure reading to web_fetch/browser, recommends arXiv HTML over OCR, and explicitly steers verification requests to verify_source with pdf_url + page/pages. Alternatives are named and conditions are concrete.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/okra-project/pdf-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server