Skip to main content
Glama

AutoPay

extract

Document extraction: PDF/image (url or file_base64, max 10 MB) -> typed fields, line items, OCR text, document type ($0.025 per page, max 5 pages billed; synchronous, charged only on success). Pay with X-PAYMENT (x402 USDC on Base) or a prepaid API key.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "extract"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlNoPublic http(s) URL of a PDF or image (max 10 MB)
regionNoOptional regional variant, e.g. EU, US, IN
filenameNoOptional file name, e.g. invoice.pdf
file_base64NoAlternative to url: base64 file content (max 10 MB decoded)
document_typeNoOptional: invoice, receipt, purchase_order, bank_statement, contract, cv, ... (default auto)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior4/5

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

With no annotations provided, the description carries the full disclosure burden and handles it well: 10 MB input cap, max 5 pages billed, synchronous execution, billed only on success, and required payment via x402 USDC or API key. It omits error/timeout behavior and whether url and file_base64 are mutually exclusive (only the schema implies 'alternative'), which keeps it short of a 5.

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?

One dense paragraph, front-loaded with the operation and I/O before cost and payment details. Every clause (size cap, page cap, sync, success-only billing, auth) is decision-relevant; there is no 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?

For a 5-parameter tool with zero required params and no output schema, the description covers the input contract, the shape of the result, cost ceiling, sync vs async nature, and authentication. Those are precisely the facts an agent needs before spending money and waiting on a synchronous call.

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

Parameters3/5

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

Schema description coverage is 100%, so the schema already documents url, file_base64, region, filename and document_type. The description only restates the url-or-file_base64 choice and the 10 MB limit, adding nothing about region variants or how document_type interacts with automatic detection; baseline 3 applies.

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 states a specific verb and resource ('Document extraction'), names the accepted inputs (PDF/image, url or file_base64) and enumerates the returned artifacts (typed fields, line items, OCR text, document type). No sibling (fetch, search, verify, security_scan_*) overlaps this scope, so an agent can route to it unambiguously.

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

Usage Guidelines3/5

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

Usage context is implied by 'Document extraction' plus the page and size limits, but there is no explicit when-to-use/when-not and no named alternative among the siblings for tasks like retrieving an already-extracted result (get_job) or fetching a raw file (fetch). Operational guidance about payment ('X-PAYMENT … or a prepaid API key') is a prerequisite, not a selection heuristic.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources