Agent2PDF LogoAgent2PDF

Developer Documentation

Use the web app or call the API—your Markdown, professional PDFs in seconds.

Quick Start

Web: Sign up and use the editor in your browser—paste Markdown, pick a template, and download PDF. No code required.

API: Create an account, go to Settings → API Keys to create a key. For agents (X-API-Key), use POST /api/v1/jobs then poll GET /api/v1/jobs/{job_id} for download_url; sync POST /v1/pdf/generate is for Web (Bearer) only.

Authentication

Include your API key in the request header:

Authorization: Bearer YOUR_API_KEY

Create and manage API keys in the dashboard: Settings → API Keys (after signing in).

Generate PDF

Base URL: https://api.agent2pdf.com

Endpoint (Web/Bearer): POST https://api.agent2pdf.com/api/v1/pdf/generate — With X-API-Key this returns 403; use POST /api/v1/jobs and poll GET /api/v1/jobs/{job_id} for download_url.

Body (JSON):

{
  "markdown": "# Hello\n\nYour Markdown here.",
  "template_type": "report",
  "title": "My Document"
}

template_type options: invoice, tech_spec, report, resume, letter, meeting, general.

Response includes pdf_base64, filename, and size.

Templates & Branding

In the web app, set your logo and brand colors under Settings → Style. These apply to PDFs generated via the web editor and, when using your API key, to API-generated PDFs as well. Pro plans support custom templates and removing the default footer.

Rate Limits & Pricing

Free tier includes a limited number of generations per month. See Pricing for details and limits.

Get API Key

Sign up or log in to create an API key and start generating PDFs from your apps, CI/CD, or MCP.

Log in to get API key