PDF Processor
The robomotion pdfprocessor CLI handles PDF file operations. It creates, merges, splits, extracts text from, and converts PDF files. It supports page-level operations, metadata handling, and various format conversions.
When to use
- Extract text content from PDF files
- Merge multiple PDFs into one or split PDFs by pages
- Create new PDF files from content
- Convert between PDF and other formats
Prerequisites
robomotionCLI installed- Package installed:
robomotion install pdfprocessor - No external credentials needed — works with local PDF files
Workflow
- Install:
robomotion install pdfprocessor - Extract text:
robomotion pdfprocessor extract_text --file-path <pdf> - Merge:
robomotion pdfprocessor merge --files <pdf1,pdf2> --output <out.pdf>
Commands Reference
robomotion pdfprocessor pdf_export_form_to_json --pdf-path --json-path-to-save --output jsonExport PDF form fields and data to a JSON filerobomotion pdfprocessor pdf_fill_form_from_json --json-path --source-pdf-path --pdf-path-to-save --output jsonFill PDF form fields with data from a JSON filerobomotion pdfprocessor pdf_create_from_json --json-path [--in-pdf-path] [--out-pdf-path] --output jsonCreate a PDF document from a JSON definition filerobomotion pdfprocessor pdf_extract_images --pdf-path --directory-to-extract-images [--from-selected-pages] --output jsonExtract images from a PDF file to a specified directoryrobomotion pdfprocessor pdf_split --pdf-path --directory-to-save-pages --page-number(s)-to-split [--custom-pages] --output jsonSplit a PDF file into multiple files by page numbersrobomotion pdfprocessor pdf_merge --pdf-paths --custom-paths --pdf-path-to-save --output jsonMerge multiple PDF files into a single PDF documentrobomotion pdfprocessor pdf_optimize --pdf-path [--pdf-path-to-save] --output jsonOptimize a PDF file to reduce its file sizerobomotion pdfprocessor pdf_encrypt --pdf-path [--pdf-path-to-save] [--mode] [--key-length] --output jsonEncrypt a PDF file with password protectionrobomotion pdfprocessor pdf_decrypt --pdf-path [--pdf-path-to-save] [--mode] [--key-length] --output jsonDecrypt a password-protected PDF filerobomotion pdfprocessor pdf_change_password --pdf-path [--pdf-path-to-save] [--mode] [--key-length] [--change-owner-or-user] --output jsonChange the owner or user password of an encrypted PDF file
Environment
- ROBOMOTION_API_TOKEN (if vault credentials are needed)