apply_plan
Validate and apply a batch of edit steps to a DOCX document. All steps must pass validation before any are applied.
Instructions
Validate and apply a batch of edit steps (replace_text, insert_paragraph) to a document in one call. Validates all steps first; applies only if all pass. Accepts inline steps or a plan_file_path. Compatible with merge_plans output.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_path | Yes | Path to the DOCX file. | |
| steps | No | JSON array of edit steps. Each step needs step_id, operation, and operation-specific fields. | |
| plan_file_path | No | Path to a .json file containing an array of edit steps. Mutually exclusive with steps. |