0CodeKit icon

0CodeKit

A toolbox of no-code utilities

Actions114

PDF → Split PDF Files

AI-generated

Overview

This node operation splits PDF files based on user-defined criteria. It supports splitting by specific page ranges or by intervals, allowing users to extract parts of a PDF file into separate files. This is useful for workflows that require processing or distributing sections of large PDF documents, such as splitting reports, invoices, or eBooks.

Use Case Examples

  1. Splitting a PDF into chapters by specifying page ranges for each chapter.
  2. Splitting a PDF into smaller files of equal page intervals for easier sharing or processing.

Properties

Name Meaning
Code Variables Variables defined in the code editor that can be used within the node's logic, allowing dynamic input values.
URL or Binary Data Specifies whether the PDF input is provided as a public URL or as binary data buffer.
URL Public URL of the PDF file to be split (required if input type is URL).
Binary Data Buffer of the PDF file to be split (required if input type is binary data).
Pages Pages inside the PDF file (used when input is binary data).
How Do You Want to Split the PDF? Method to split the PDF, either by page ranges or by interval.
Page Ranges Specify the start and end pages for each range to split the PDF into multiple parts (used if split method is page ranges).
Interval Number of pages per split part when splitting by interval.

Output

JSON

  • splitResult - Result of the PDF split operation, typically an array of split PDF files or metadata about the split parts.

Dependencies

  • An API key credential for the 0CodeKit service is required to perform the PDF splitting operation.

Troubleshooting

  • Ensure the input PDF URL is publicly accessible if using URL input type, otherwise the node will fail to fetch the file.
  • When using binary data input, verify that the buffer contains valid PDF data.
  • Page ranges must be valid and within the bounds of the PDF file; invalid ranges may cause errors.
  • If splitting by interval, ensure the interval number is a positive integer and makes sense for the PDF length.

Discussion