Extract pages into a new PDF
pdf_pagesExtract selected pages from a PDF into a new file in the order you specify, without modifying the source.
Instructions
Call this tool to pull selected pages into one new PDF, in the order written: "2,4-6" gives four pages. Asking for a page twice copies it twice. The input is never modified. Free tier: files up to 30 pages.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"path": "<path>",
"pages": "<pages>",
"out_path": "<out_path>"
},
"name": "pdf_pages"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | The source PDF | |
| pages | Yes | 1-based pages and ranges to keep, in output order, e.g. "2,4-6" or "5,1,1" | |
| out_path | Yes | Where to write the extracted PDF | |
| overwrite | No | Replace out_path if it exists. Default false |