PDF.co API icon

PDF.co API

Generate PDF, extract data from PDF, split PDF, merge PDF, convert PDF. Fill PDF forms, add text and images to pdf and much more with pdf.co!

Compress PDF

AI-generated

Overview

This node compresses a PDF file from a given URL. It is useful for reducing the file size of PDF documents to save storage space or facilitate faster sharing and downloading. Common scenarios include compressing invoices, reports, or any PDF files before sending them via email or uploading to cloud storage.

Use Case Examples

  1. Compress a PDF invoice from a URL before attaching it to an email.
  2. Reduce the size of a PDF report hosted online to optimize storage usage.

Properties

Name Meaning
Authentication Select the authentication method to access the PDF compression service (API Key or OAuth2).
PDF URL The URL of the source PDF file to compress.
Advanced Options Additional optional settings for the compression process.

Output

JSON

  • compressedPdfUrl - URL of the compressed PDF file.
  • fileName - Name of the output compressed PDF file.
  • callbackStatus - Status of the callback webhook if provided.

Dependencies

  • Requires access to PDF.co API service for PDF compression.
  • Supports API Key or OAuth2 authentication methods.

Troubleshooting

  • Ensure the PDF URL is accessible and correct; errors may occur if the URL is invalid or the file is not reachable.
  • If using password-protected PDFs, provide the correct password to avoid decryption errors.
  • Check authentication credentials (API Key or OAuth2) are valid and have necessary permissions.
  • If using a webhook callback, ensure the callback URL is reachable and correctly configured to receive data.

Links

Discussion