Skip to main content
Glama

help

Get guidance on using pdfdancer-mcp server tools to search documentation and retrieve content from indexed PDF resources.

Instructions

Explains the purpose of this server and how to use it.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • src/index.ts:195-213 (registration)
    Registers the 'help' tool with McpServer, providing title, description, and an inline async handler function that renders and returns the help documentation.
    server.registerTool( 'help', { title: 'PDFDancer MCP help', description: 'Explains the purpose of this server and how to use it.' }, async () => { const text = renderHelpDocument(helpDocument); return { content: [ { type: 'text' as const, text } ], structuredContent: helpDocument }; } );
  • The handler function for the 'help' tool. It renders the static helpDocument using renderHelpDocument and returns it as both plain text content and structuredContent.
    async () => { const text = renderHelpDocument(helpDocument); return { content: [ { type: 'text' as const, text } ], structuredContent: helpDocument }; }
  • Helper function that converts the HelpDocument object into a formatted Markdown string for display.
    function renderHelpDocument(doc: HelpDocument): string { const sections = doc.sections .map(section => `### ${section.heading}\n${section.items.join('\n')}`) .join('\n\n'); return `# ${doc.title}\n\n${doc.overview}\n\n${sections}`.trim(); }
  • Static HelpDocument object containing the overview, sections, and details about the MCP server and PDFDancer documentation.
    const helpDocument: HelpDocument = { title: 'PDFDancer SDK Documentation', overview: 'This MCP server provides coding agents with searchable access to official PDFDancer SDK documentation. Use these tools to discover how to build PDF manipulation applications with pixel-perfect control over PDF documents using PDFDancer SDKs for Python, TypeScript, and Java.', sections: [ { heading: 'What is PDFDancer?', items: [ '- **Pixel-perfect PDF control**: Edit any PDF with exact coordinate positioning and surgical text replacement', '- **Edit existing PDFs**: Modify PDFs you did not create - invoices, forms, contracts, reports from any source', '- **Smart text handling**: Paragraph-aware editing that preserves layout and formatting', '- **Embedded font support**: Add text with embedded fonts for consistent rendering across all viewers', '- **Form manipulation**: Programmatically fill, update, or delete AcroForm fields', '- **Multi-language SDKs**: Available for Python 3.10+, TypeScript (Node.js 20+), and Java 11+', '- **Vector graphics control**: Full control over lines, curves, shapes, and complex drawings' ] }, { heading: 'Available MCP Tools', items: [ '- **help**: Display this overview', '- **version**: Get the current version of the pdfdancer-mcp server', '- **search-docs**: Search PDFDancer documentation by keyword to find relevant APIs and examples (max 10 results)', '- **get-docs**: Retrieve complete documentation for a specific route with code examples' ] }, { heading: 'Search Syntax (Lunr.js)', items: [ '- **Simple keywords** (OR logic): `Java images add` → matches documents with ANY word', '- **Require ALL words**: `+Java +images +add` → matches only documents with ALL words (recommended for precise results)', '- **Exclude words**: `+React -deprecated` → must have "React", must NOT have "deprecated"', '- **Boost importance**: `authentication^10 tutorial` → prioritizes "authentication" results', '- **Field search**: `title:installation` → searches only in title field', '- **Wildcard**: `install*` → matches "install", "installation", "installer"', '- **Fuzzy search**: `javascript~2` → tolerates up to 2 character differences (typos)', '- **Exact phrase**: `title:"Java images"` → searches for exact phrase in title', '- **Available fields**: title, content, tags, sidebarParentCategories' ] }, { heading: 'Typical workflow for building PDFDancer applications', items: [ '1. **Search documentation**: Use `search-docs` with keywords like "authentication", "edit text", "add paragraph", or "forms" to find relevant APIs', '2. **Get detailed docs**: Use `get-docs` with the route from search results to retrieve complete documentation with code examples', '3. **Implement features**: Use the SDK to open existing PDFs, locate elements by text or coordinates, edit content, add new elements, and save results' ] } ], };
  • TypeScript interface defining the structure of the help document used by the 'help' tool.
    interface HelpDocument extends JsonObject { title: string; overview: string; sections: Array<{ heading: string; items: string[]; }>; }

Other Tools

Latest Blog Posts

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/MenschMachine/pdfdancer-mcp'

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