{"protocolVersion":"2024-11-05","mcp":"1.0.0","serverInfo":{"name":"mdapi","version":"1.0.0"},"capabilities":{"tools":{"listChanged":false},"resources":{"subscribe":false,"listChanged":false}},"tools":[{"name":"convert","description":"Converts documents, images, webpages, or text to Markdown. Supports: webpages, PDF, DOCX, XLSX, XLS, ODT, ODS, JPEG, JPG, PNG, WebP, SVG, HTML, XML, JSON, CSV, TXT. Use 'url' for public URLs, 'file'+'filename' for local files, or 'text' for direct text input. Optional 'prompt' for LLM processing, 'result' to control output format, and 'stream=true' for SSE streaming. Returns {success, markdown, resource, mimetype, prompt_result} or SSE chunks.","inputSchema":{"type":"object","properties":{"url":{"type":"string","format":"uri","description":"Public URL to convert (webpage, PDF, DOCX, image, etc.)"},"file":{"type":"string","format":"binary","description":"Local file content as base64 (alternative to url)"},"filename":{"type":"string","description":"Original filename with extension (required if using file)"},"text":{"type":"string","description":"Direct text content to process (alternative to url/file)"},"prompt":{"type":"string","description":"Custom instructions for LLM processing (e.g., 'Summarize this', 'Extract key points')"},"result":{"type":"string","enum":["markdown","prompt","both"],"description":"Response format: 'markdown' (default, raw markdown), 'prompt' (LLM processed result only), 'both' (markdown + prompt_result)"},"stream":{"type":"string","description":"Enable streaming: 'true' for SSE response"},"token":{"type":"string","description":"Access token for paid tier (optional)"},"memo":{"type":"string","description":"Payment reference required for token activation (use once with token)"}}}}],"resources":[{"uri":"https://mdapi.io/mcp","name":"MCP Server Manifest","mimeType":"application/json","description":"Model Context Protocol server manifest"},{"uri":"https://mdapi.io/health","name":"Health Check","mimeType":"application/json","description":"Service health status"},{"uri":"https://mdapi.io/llms.txt","name":"API Documentation","mimeType":"text/plain","description":"API documentation (condensed)"},{"uri":"https://mdapi.io/llms-full.txt","name":"Full API Documentation","mimeType":"text/plain","description":"API documentation (full)"},{"uri":"https://mdapi.io/.well-known/ai-discovery.json","name":"AI Discovery","mimeType":"application/json","description":"Unified AI agent discovery combining MCP, ACP, A2A"},{"uri":"https://mdapi.io/.well-known/agent.json","name":"AI Agent Discovery","mimeType":"application/json","description":"Agent metadata for AI frameworks"},{"uri":"https://mdapi.io/.well-known/agent-card.json","name":"A2A Agent Card","mimeType":"application/json","description":"Agent card for A2A protocol"},{"uri":"https://mdapi.io/.well-known/acp.json","name":"ACP Manifest","mimeType":"application/json","description":"Agent Client Protocol manifest for IDE agents"},{"uri":"https://mdapi.io/.well-known/x402.json","name":"x402 Payment Manifest","mimeType":"application/json","description":"x402 v2 payment manifest for autonomous agents"},{"uri":"https://mdapi.io/.well-known/openapi.json","name":"OpenAPI Specification (JSON)","mimeType":"application/json","description":"Full API specification in OpenAPI JSON format"},{"uri":"https://mdapi.io/.well-known/openapi.yaml","name":"OpenAPI Specification (YAML)","mimeType":"text/yaml","description":"Full API specification in OpenAPI YAML format"},{"uri":"https://mdapi.io/.well-known/mapi.md","name":"MAPI Specification","mimeType":"text/markdown","description":"MAPI specification in Markdown format"},{"uri":"https://mdapi.io/.well-known/skill.md","name":"Skill Specification","mimeType":"text/markdown","description":"Skill specification in Markdown format"}],"instructions":"Use 'convert' tool with url, file, or text parameter. Supports all formats: webpages, PDF, DOCX, XLSX, XLS, ODT, ODS, images (JPEG, JPG, PNG, WebP, SVG), text (HTML, XML, JSON, CSV, TXT). Optional 'prompt' for LLM processing (e.g., 'Summarize', 'Extract entities') and 'result' to control output ('markdown' for raw markdown, 'prompt' for LLM result only, 'both' for both). Returns JSON with success, markdown, prompt_result, resource, mimetype, token_status, token_balance, and token_expires. Free tier available, paid tier at $0.01/request via x402 protocol. IMPORTANT: Paid tokens must be activated first with memo before use.","tokenActivation":{"description":"Before using a paid token, activate it with memo from payment","steps":["Receive 402 with X-Token-Required, X-Memo-Required headers","Send USDC on Solana to wallet with memo","Activate: repeat request with token+memo","After activation: use token only"],"examples":{"activate":"POST /mcp -d '{\"method\":\"tools/call\",\"params\":{\"name\":\"convert\",\"arguments\":{\"url\":\"https://example.com\",\"token\":\"TOKEN\",\"memo\":\"MEMO\"}}}'","useActivated":"POST /mcp -d '{\"method\":\"tools/call\",\"params\":{\"name\":\"convert\",\"arguments\":{\"url\":\"https://example.com\",\"token\":\"TOKEN\"}}}'"}}}