Recolor design element
recolor_design_elementChange the color of one element in an existing design. On a text element it sets the text color. On a shape or a slide background it sets the fill: a solid color, or a gradient. Pass color for a solid color or gradient for a gradient. The change is saved to the design. The response has the updated design structure (element aliases and positions) and a rendered preview.
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": {
"workspace_key": "<workspace_key>",
"design_id": "<design_id>",
"element": "<element>"
},
"name": "recolor_design_element"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| color | No | The new color: a hex color such as "#1A1A1A" (8-digit #RRGGBBAA for transparency) or a brand color token from get_brand_kit such as "primary". | |
| element | Yes | The element to change: its alias from the design structure ("text-1", "image-1", "bg", "logo", or slide-scoped "s2-text-1"), or its raw id ("shape:..."). | |
| gradient | No | Shapes and backgrounds only: a gradient fill, { "gradient": ["#RRGGBB", ...], "angle": <degrees> }. | |
| design_id | Yes | The design id (from compose_design or generate_post) or the key from a /designs/<key> URL. | |
| workspace_key | Yes | Key of the workspace to act in. Call list_workspaces to see the workspaces you have access to and their keys. |