Skip to main content
Glama
pdf-inspector-mcp

pdf-inspector-mcp

by jayluxferro

pdf-inspector-mcp

MCP (Model Context Protocol) server wrapping the pdf-inspector Python library for AI-agent PDF processing.

Install

uv pip install pdf-inspector-mcp

Or from source:

git clone https://github.com/jayluxferro/pdf-inspector-mcp.git
cd pdf-inspector-mcp
uv pip install -e .

Related MCP server: document-parser

Usage

From a local clone:

{
  "mcpServers": {
    "pdf-inspector": {
      "command": "uv",
      "args": [
        "run",
        "--directory",
        "path/to/pdf-inspector-mcp",
        "pdf-inspector-mcp"
      ]
    }
  }
}

Or ephemerally with uvx (no clone needed):

{
  "mcpServers": {
    "pdf-inspector": {
      "command": "uvx",
      "args": ["pdf-inspector-mcp"]
    }
  }
}

Tools

Tool

Description

process_pdf

Full pipeline: detect type + extract text + Markdown

detect_pdf

Fast detection only (PdfResult without Markdown)

classify_pdf

Lightweight classification (PdfClassification)

extract_text

Plain text extraction

extract_text_with_positions

Text with X/Y coordinates and font metadata

extract_text_in_regions

Text in bounding-box page regions

extract_pages_markdown

Per-page Markdown with layout info

Every tool accepts either path (file path) or data (base64-encoded PDF bytes).

Requirements

Available Tools

7 tools
classify_pdfA

Lightweight PDF classification: type, page count, OCR pages, confidence.

Faster than detect_pdf — returns a PdfClassification without full analysis.

Args: path: Absolute path to a PDF file on the local filesystem. data: Base64-encoded PDF bytes.

Inputs: data, path. Returns: result

detect_pdfA

Fast PDF detection: returns type, page count, and pages needing OCR.

Use this for quick classification without full text extraction.

Args: path: Absolute path to a PDF file on the local filesystem. data: Base64-encoded PDF bytes.

Inputs: data, path. Returns: result

extract_pages_markdownA

Extract per-page Markdown with layout metadata.

Returns page-by-page Markdown along with tables, columns, and OCR info. Pages are 0-indexed; returned page numbers are 1-indexed.

Args: path: Absolute path to a PDF file on the local filesystem. data: Base64-encoded PDF bytes. pages: Optional list of 0-indexed page numbers to extract.

Inputs: data, path, pages. Returns: result

extract_textB

Extract plain text from a PDF file.

Args: path: Absolute path to a PDF file on the local filesystem. data: Base64-encoded PDF bytes.

Inputs: data, path. Returns: result

extract_text_in_regionsB

Extract text from specific bounding-box regions on pages.

Args: path: Absolute path to a PDF file on the local filesystem. data: Base64-encoded PDF bytes. page_regions: List of {"page": int, "regions": [{"x": float, "y": float, "width": float, "height": float}, ...]} dicts.

Inputs: data, path, page_regions. Returns: result

extract_text_with_positionsA

Extract text items with position, font, and style metadata.

Returns a list of TextItem objects each with: text, x, y, width, height, font, font_size, page, is_bold, is_italic, is_underline, is_strikeout, item_type.

Args: path: Absolute path to a PDF file on the local filesystem. data: Base64-encoded PDF bytes. pages: Optional list of 0-indexed page numbers to extract.

Inputs: data, path, pages. Returns: result

process_pdfA

Full PDF processing: detect type, extract text, and convert to Markdown.

Args: path: Absolute path to a PDF file on the local filesystem. data: Base64-encoded PDF bytes. pages: Optional list of 0-indexed page numbers to process.

Inputs: data, path, pages. Returns: result

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.6/5.0

    Scored across 7 tools

    Disambiguation2/5

    detect_pdf and classify_pdf are nearly identical, both returning type, page count, and OCR pages, with only minor differences in speed/confidence. process_pdf also overlaps with all extraction tools, making tool boundaries unclear.

    Naming Consistency5/5

    All tools follow a consistent verb_noun snake_case pattern (e.g., process_pdf, extract_text, extract_pages_markdown). No mixed conventions or vague verbs.

    Tool Count4/5

    Seven tools is within a reasonable range, but the redundancy between detect_pdf and classify_pdf suggests the count could be trimmed. Still, it does not feel overwhelming.

    Completeness4/5

    The set covers detection, classification, plain text extraction, positioned text extraction, region-based extraction, and markdown conversion. Minor gaps like PDF metadata or OCR output are not critical to the inspection purpose.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      Not graded
      maintenance
      Provides AI agents with comprehensive document parsing capabilities including PDF text extraction, OCR, HTML-to-markdown conversion, table extraction, and summarization, optimized for agent workflows.
      72 npm
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables AI agents to inspect and convert PDF, PowerPoint, Excel, and many other file formats into clean, structured Markdown, with chunking support for long documents.
      Apache 2.0