Reorder the pages of a PDF
pdf_reorderReorder a PDF's pages by listing the desired page order and writing the updated file to a new path. Every page must be specified exactly once so no content is lost.
Instructions
Call this tool to write a new PDF with pages in the order you give. The order must name every page exactly once, so nothing drops by accident; use pdf_pages for a subset. Pro.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | The source PDF | |
| order | Yes | The 1-based page numbers in their new order, e.g. [3,1,2] for a three-page file. Every page must appear exactly once | |
| out_path | Yes | Where to write the reordered PDF | |
| overwrite | No | Replace out_path if it exists. Default false |