Skip to main content
Glama
diyaluo

pdf-extract-mcp

by diyaluo

extract_pdf

Convert tables from digital PDF bank statements, invoices, or bills into CSV, JSON, or Excel, with PII redacted by default. Scanned PDFs are not supported.

Instructions

Extract tables from a digital (text-layer) PDF bank statement / invoice / bill into CSV, JSON rows, or Excel bytes (base64). PII is redacted by default. Scanned/image PDFs are rejected (no OCR in free tier).

Args: pdf_base64: PDF content as base64 (preferred — no third-party fetch). pdf_url: Direct HTTPS URL to a .pdf (alternative to base64). output: "csv" | "json" | "xlsx". redact_pii: keep true unless you explicitly need raw PII (paid only). api_key: paid key to bypass free quota (optional).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
outputNocsv
api_keyNo
pdf_urlNo
pdf_base64No
redact_piiNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
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 does well: PII redaction on by default, OCR absence and scanned-PDF rejection, a free quota that api_key bypasses, and the note that base64 avoids a third-party fetch. It stops short of describing quota size/rate limits or failure modes for corrupt or oversized PDFs.

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

Conciseness5/5

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

A front-loaded one-sentence summary of what/when/limits, followed by a tight Args block that maps one line per parameter. No filler sentences and no repetition of schema mechanics.

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

Completeness4/5

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

For a 5-param tool with no annotations and no output schema, the description covers selection, safety-relevant behavior (redaction, rejection rules), and output encodings including that xlsx arrives as base64. It does not sketch the shape of returned JSON rows or error responses, which is the one remaining gap.

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 description coverage is 0%, so the description must compensate for all five parameters and it does: it names the output enum values, explains the base64-vs-url tradeoff, gives the intent and default rationale for redact_pii, and clarifies api_key is an optional paid quota bypass. This is meaning well beyond the bare anyOf/string typings.

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?

States a specific verb+resource (extract tables from a digital text-layer PDF) and narrows the document domain to bank statements/invoices/bills. It also names the output formats and the hard boundary (scanned/image PDFs rejected, no OCR), which no sibling or schema field conveys. An agent can distinguish this from the 'health' sibling instantly.

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?

Explicitly frames pdf_base64 as preferred and pdf_url as the alternative, tells the agent to keep redact_pii true unless raw PII is genuinely required (paid only), and states when the tool is NOT usable (scanned/image PDFs). This is when-to-use, when-not, and alternative-selection guidance in a few lines.

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

Deploy Server

Other Tools