Skip to main content
Glama

PDF Redaction MCP Server

redact_area

Mark specific rectangular areas on PDF pages for redaction by defining coordinates, allowing precise content removal before final document saving.

Instructions

Redact a specific rectangular area on a PDF page.

This tool adds a redaction annotation for a specific rectangular area defined by coordinates. The redactions are not yet applied to the document - use save_redacted_pdf to apply and save.

Args: pdf_path: Path to the PDF file (must be already loaded) page_number: Page number to redact (1-indexed) x0: Left x coordinate of the rectangle y0: Top y coordinate of the rectangle x1: Right x coordinate of the rectangle y1: Bottom y coordinate of the rectangle fill_color: RGB color tuple (0-1 range) for the redaction box. Default is black. ctx: MCP context for logging

Returns: Confirmation message

Raises: ToolError: If the PDF is not loaded, page doesn't exist, or redaction fails

Input Schema

NameRequiredDescriptionDefault
fill_colorNoRGB color for redaction (values 0-1). Default is black (0,0,0)
page_numberYesPage number (1-indexed)
pdf_pathYesPath to the loaded PDF file
x0YesLeft x coordinate
x1YesRight x coordinate
y0YesTop y coordinate
y1YesBottom y coordinate

Input Schema (JSON Schema)

{ "properties": { "fill_color": { "default": [ 0, 0, 0 ], "description": "RGB color for redaction (values 0-1). Default is black (0,0,0)", "maxItems": 3, "minItems": 3, "prefixItems": [ { "type": "number" }, { "type": "number" }, { "type": "number" } ], "type": "array" }, "page_number": { "description": "Page number (1-indexed)", "minimum": 1, "type": "integer" }, "pdf_path": { "description": "Path to the loaded PDF file", "type": "string" }, "x0": { "description": "Left x coordinate", "type": "number" }, "x1": { "description": "Right x coordinate", "type": "number" }, "y0": { "description": "Top y coordinate", "type": "number" }, "y1": { "description": "Bottom y coordinate", "type": "number" } }, "required": [ "pdf_path", "page_number", "x0", "y0", "x1", "y1" ], "type": "object" }

Other Tools from PDF Redaction MCP Server

Related Tools

    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/marc-hanheide/redact_mcp'

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