apply_color
Apply a named color swatch to an object's fill or stroke on a specified page. Use it to set object colors by swatch name and page/object index in InDesign.
Instructions
Apply color to an object
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": {
"objectIndex": "<objectIndex>",
"swatchName": "<swatchName>"
},
"name": "apply_color"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| property | No | fill | |
| pageIndex | No | Page index | |
| swatchName | Yes | Color swatch name | |
| objectIndex | Yes | Object index on page |