Skip to main content
Glama

XPS to PDF API - convert Windows XPS and OXPS documents to PDF (or JPG/PNG pages)

xps_to_pdf
Read-onlyIdempotent

Send a Microsoft XPS (.xps) or OpenXPS (.oxps) file as base64 and get a PDF back with real, searchable text (vector output, not a screenshot), all documents of the file in one PDF, or every page as a JPG / PNG picture (ZIP). Damaged or non-XPS files get a clear error. Open-source libgxps on our server, 0 AI, nothing stored. For document pipelines, print-to-file archives, helpdesks and no-code flows. Free: 5 calls/day per IP. Paid: Radar API key (from €9/mo at https://radarbg.com/pricing#starter via X-API-Key) or $0.002/call via x402 at https://radarbg.com/x402/xps-to-pdf.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

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

Input Schema

NameRequiredDescriptionDefault
formatNopdf (default), or jpg / png pictures of every page (one file or a ZIP)pdf
fileNameNoOptional file name, e.g. scan.xps
fileContentNoThe .xps or .oxps file as base64, max 50 MB (empty = built-in example)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.3/5.0
Behavior5/5

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

Annotations only declare readOnly/openWorld/idempotent, and the description goes well beyond them: vector output with real searchable text, all documents merged into a single PDF vs. per-page JPG/PNG in a ZIP, explicit error behavior for damaged or non-XPS files, no storage, no AI, engine used (libgxps), rate limits (5 free calls/day per IP), and both auth paths (X-API-Key or x402). That is unusually complete behavioral and commercial disclosure for a conversion call.

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?

Single paragraph, front-loaded with the input/output contract and the error and privacy facts before the commercial details. The pricing and URL tail ('from €9/mo at https://... via X-API-Key or $0.002/call via x402 at https://...') is longer than an agent strictly needs for invocation, keeping it off a 5.

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?

With no output schema, the description still explains the return shape well (PDF, or ZIP of page images) and covers failures, rate limits and auth. It leaves out operational specifics such as typical processing time, output size limits, or whether conversion is synchronous, which matters for a 50 MB binary upload tool.

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 format, fileName and fileContent including the 50 MB base64 cap and the empty-payload example fallback. The description restates the format outcome (single PDF, or JPG/PNG pages in a ZIP) and adds the vector-text quality note, but contributes little parameter meaning the schema does not already carry, so the 3 baseline 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?

Names a specific verb and resource ('convert Windows XPS and OXPS documents to PDF') and states the exact accepted input formats (.xps/.oxps as base64), which distinguishes it cleanly from generic converters like excel_to_pdf or images_to_pdf in the sibling list. An agent can decide on this tool purely from the first sentence.

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

Usage Guidelines4/5

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

Usage is gated clearly by input type (Microsoft XPS or OpenXPS files) and the description names its audience (document pipelines, print-to-file archives, helpdesks, no-code flows), which implicitly says when it applies. It stops short of explicitly excluding alternatives such as pdf_to_image or pdf_to_pdfa, so the routing is inferred from the file format rather than stated.

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