PDF Generator API icon

PDF Generator API

Generate PDFs, manage templates, convert HTML/URLs to PDF, and perform PDF operations like watermarking, encryption, and optimization

PDF Service → Add Watermark

AI-generated

Summary

Adds a text watermark, image watermark, or both to a PDF using the PDF Generator API. Choose a public PDF URL or provide base64 PDF content, configure each selected watermark, and choose whether the processed PDF is returned as base64 JSON, a download URL, or binary data.

Inputs

  • PDF Source (required) — Choose From URL (default) or From Base64. Supply the corresponding required PDF URL or base64 content.
  • PDF URL / PDF Base64 (required) — Public URL to the source PDF when PDF Source is From URL, or base64-encoded PDF content when From Base64.
  • Output Format (required) — Select Base64 (JSON, default), URL (JSON), or File (Binary).
  • Watermark Type (required) — Select Text (default), Image, or both. At least one type must be selected and configured.
  • Watermark Text (required) — Text to add when Text is selected; defaults to CONFIDENTIAL. The operation errors if selected and empty.
  • Text Watermark Options — Optional text styling: color (default #FF0000), font size (default 48; UI range 7–80), opacity (default 0.5; range 0–1), position (default center; nine page positions), and rotation (default 0°; range −180° to 180°).
  • Watermark Image URL (required) — Image URL to use when Image is selected. The operation errors if selected and empty.
  • Image Watermark Options — Optional image placement and styling: position (default center; nine page positions), rotation (default 0°; range −180° to 180°), and scale (default 1; range 0.1–5).

Output shape

One n8n item per input item, containing either JSON response data or a binary PDF with JSON metadata.

Base64 and URL formats return JSON with success, operation, format, and the API response fields. File format attaches the PDF as binary under the key processed-document.pdf and returns JSON metadata including filename and file size. The node sends the selected watermark configuration to the API's PDF watermark endpoint.

Links

Discussion