Tasks
PDF Tools
Converts, splits, merges, OCRs, extracts from, and inspects PDF files. Useful for document preparation, data extraction, and file processing in Stubber workflows.
The PDF Tools task runs one PDF function on one or more files. The function parameter selects what to do, for example pdf_to_text or merge_pdfs, and each function has its own parameters.
Example PDF Tool
Parameters
files required array
The files on which to perform the PDF function. Each item is a file object, for example a file uploaded on a form field such as ~~stubpost.data.pdf_file.0.
function required string
The function that is to be performed on the PDF files. See the list of PDF Tools below.
timeout_seconds optional number
How long to wait for the function to finish, in seconds. Defaults to 300. Large files and OCR can take longer.
Result
Running a PDF Tool performs the function on the files and returns the newly created files in files and attachments,
including their fileuuid, filename, and contentType. Functions that create more than one file, such as splitting a PDF,
return every file.
In the case of Get PDF Details, the details of the
file are returned in pdf_details as no new file is created.
A run that fails, for example because of an invalid parameter or a wrong password, returns an error and no files.
List of PDF Tools
- Convert File to PDF
- Convert Markdown File to PDF
- Convert PDF to a Text File
- Convert PDF to a Word Document
- Convert PDF to XML File
- Extract CSV from PDF
- Extract Images from a PDF
- PDF to Single Page
- Split PDF by Pages
- Split PDF by Chapters
- Split PDF Pages into Sections
- Split PDF by Page Count
- Extract PDF Pages
- Get PDF Details
- Merge PDFs
- Overlay PDFs
- OCR PDF
- Remove Password from PDF