Skip to main content
PDFMonkey logo
  • Category: documents
  • Auth: API_KEY
  • Composio-managed OAuth available? N/A
  • Tools: 18
  • Triggers: 0
  • Slug: PDFMONKEY
  • Version: 20261101_00

Tools

Slug: PDFMONKEY_CREATE_DOCUMENTTool to create a Document. Use when you need to instantiate a PDF from a template; set status=‘pending’ to queue immediate generation. Ensure valid document_template_id is provided.

Input Parameters

object
required
Document creation parameters wrapper. Must include document_template_id (non-deleted template UUID) and payload: a flat JSON object whose keys exactly match the template’s field names — nested objects or mismatched keys silently produce blank or misfilled fields. Also accepts status='pending' to queue immediate generation.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_CREATE_DOCUMENT_SYNCCreates a document using the synchronous generation endpoint and returns a DocumentCard. Set status to ‘pending’ to start generation; the endpoint waits for completion.

Input Parameters

object
required
Container for document attributes Required sub-fields: document_template_id (must reference a valid, non-deleted template) and payload (flat JSON object whose keys exactly match template field names — nested objects or key typos silently produce blank or misfilled fields). Some nominally optional sub-fields like pdf_engine_draft_id may be required at runtime; check API error messages to identify missing inputs.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_CREATE_TEMPLATECreate a reusable PDFMonkey document template with HTML/Liquid content and CSS styles for generating documents. Draft content and settings can be used to preview changes before publishing.

Input Parameters

integer ("300" | "1200" | "3600" | "86400" | "604800" | "2592000" | "31536000" | "0")
Document auto-deletion time-to-live in seconds. Options: 300 (5min), 1200 (20min), 3600 (1hr), 86400 (1 day), 604800 (1 week), 2592000 (30 days), 31536000 (1 year), 0 (never). Defaults based on plan.
string
Published HTML + Liquid template body used when generating documents. Leave empty and use body_draft for testing first.
string
Workspace (application) UUID. If omitted, the default workspace is used.
object
Document printing settings for PDF generation or preview.
string
Draft HTML + Liquid template body for previewing changes before publishing.
string
required
Human-readable name for the template (e.g., ‘Invoice Template’, ‘Contract PDF’)
string
Published CSS/SCSS stylesheet for document styling.
string
JSON string of sample data for the published template.
string ("code" | "visual")
Template editing mode: ‘code’ for HTML/Liquid editing, ‘visual’ for drag-and-drop editor. Defaults to ‘code’.
string
UUID of the PDF engine to use for document generation. Get available engines via List PDF Engines action.
object
Document printing settings for PDF generation or preview.
string
Draft CSS/SCSS stylesheet for previewing style changes.
string
JSON string of sample data for testing/previewing the draft template.
string
UUID of the PDF engine to use for previewing. If omitted, uses pdf_engine_id or default engine. Omitting may cause a 422 validation error (‘Pdf engine draft must exist’); provide a valid UUID if creation fails.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_DELETE_DOCUMENTPermanently deletes a document and its generated file by ID. On success, returns the document ID, a deleted flag, and the HTTP status code.

Input Parameters

string
required
UUID of the document to delete

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_DELETE_TEMPLATEPermanently deletes a document template by ID. Documents linked to the template lose their template reference.

Input Parameters

string
required
The UUID of the document template to delete. Can be obtained from LIST_TEMPLATES or CREATE_TEMPLATE actions.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_DOWNLOAD_DOCUMENT_FILETool to download a generated PDF file via a presigned URL. Use after obtaining a valid download_url from the Document details endpoint. Verify document status is ‘success’ (not ‘draft’ or ‘pending’) via PDFMONKEY_GET_DOCUMENT before downloading to avoid incomplete files. The URL expires after 1 hour; fetch a new URL upon expiry (403 Forbidden).

Input Parameters

string
required
Time-limited presigned URL returned by the Documents API. Valid for 1 hour; if expired, retrieve a new URL via the Document details endpoint.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_GET_CURRENT_USERTool to retrieve details about the currently authenticated user. Use when you need account info (quota, plan, email, locale) after authentication.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_GET_DOCUMENTTool to fetch a Document by its ID. Returns the full document record including payload, meta, logs, and download URL. Note: download_url is time-limited; if a download attempt fails, call GetDocument again to obtain a fresh URL. Check the status field for a finalized (non-draft) state before passing the record to downstream processing tools.

Input Parameters

string
required
UUID of the document to retrieve

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_GET_DOCUMENT_CARDTool to fetch a DocumentCard by ID. Use when you have a DocumentCard ID and need its download URLs, status, and metadata. Use after generating or updating a DocumentCard.

Input Parameters

string
required
UUID of the DocumentCard to fetch

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_GET_TEMPLATETool to fetch a Document Template by ID. Use when you need the template’s content, styles, settings, and preview URL.

Input Parameters

string
required
UUID of the document template to retrieve. Get template IDs from the list_templates action.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_LIST_DOCUMENT_CARDSTool to list DocumentCards. Use when you need to retrieve multiple DocumentCards with optional pagination and filtering by template, status, workspace, or update time.

Input Parameters

string ("success" | "failure" | "draft")
Filter by document status
integer
Page number to return (default 1)
string
Filter by workspace UUID
integer
Return documents updated after given Unix timestamp
array
Filter by one or more document template UUIDs

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_LIST_PDF_ENGINESLists all available PDF rendering engines in PDFMonkey. Returns engine IDs, version names, numeric versions, and deprecation status. Use this to select a PDF engine when creating templates or generating documents. Recommended: Use the latest non-deprecated engine (e.g., v5 or highest version).

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_LIST_TEMPLATESList all document template cards for a workspace. Use this action to: - Retrieve all templates available in a workspace - Filter templates by folder (or get only root folder templates with folders=‘none’) - Paginate through large template lists - Sort templates by identifier, creation date, or last update date Returns template cards with metadata including IDs, names, auth tokens, and timestamps.

Input Parameters

integer
Page number to return (1-indexed). Defaults to 1 if not specified.
string ("identifier" | "created_at" | "updated_at")
Attribute by which to sort results. Options: ‘identifier’, ‘created_at’, ‘updated_at’. If not specified, defaults to API default sorting.
string
Comma-separated folder IDs to filter templates; use ‘none’ to list only those in the root folder. If not provided, returns templates from all folders.
string
required
The workspace ID (UUID) to list templates from. Required to scope the query to a specific workspace. An incorrect UUID returns an empty list rather than an error, so verify the workspace_id before concluding no templates exist.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_LIST_WORKSPACESDiscover PDFMonkey workspaces (applications) available to the authenticated user.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_PREVIEW_TEMPLATEFetches the template preview viewer page from PDFMonkey’s preview_url. Returns an HTML viewer page that displays the rendered template draft. Use this after obtaining a template’s preview_url via Get Template or List Templates.

Input Parameters

string
required
The preview_url from a Template object (obtained via Get Template or List Templates). This URL points to PDFMonkey’s PDF viewer page that displays the rendered template draft. Example format: https://preview.pdfmonkey.io/pdf/web/viewer.html?file=…

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_UPDATE_DOCUMENTUpdates an existing PDFMonkey document’s payload, metadata, template, or status. Common use cases: - Modify document data (payload) before generation - Change the template used for the document - Add or update custom metadata - Trigger PDF regeneration by setting status to ‘pending’ Note: To regenerate a document with updated data, update the payload and set status=‘pending’.

Input Parameters

string
required
UUID of the document to update. Must be a valid existing document ID.
object
required
Object containing the fields to update. Include only the fields you want to change.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: PDFMONKEY_UPDATE_TEMPLATETool to update a document template’s properties. Use when you need to modify an existing template’s content, styles, settings, engine, folder, or TTL.

Input Parameters

string
required
UUID of the document template to update
integer
Auto-deletion TTL for generated documents (seconds), e.g., 300, 1200, 3600, etc.
string
Published HTML+Liquid body used to generate documents
object
Settings input for updating templates - all fields optional.
string
Draft HTML+Liquid body used for preview
string
Human-readable name of the template (optional, only if you want to rename)
string
Published (S)CSS used to generate documents
string
Sample data for reverting changes
string ("code" | "visual")
Edition mode of the template: ‘code’ or ‘visual’
string
PDF engine UUID used to generate documents
object
Settings input for updating templates - all fields optional.
string
Draft (S)CSS used for preview
string
Draft sample data for preview
string
Template folder UUID to organize the template, or null to place in root
string
PDF engine UUID used to preview changes

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not