MCP ToolsDesign Layers
design_toggle_visibility
Show or hide a design layer.
Show or hide a design layer. Hidden layers are excluded from the design composite rendering. If visible is omitted, the current state is toggled.
Input Schema
| Parameter | Type | Required | Description |
|---|---|---|---|
sketchId | string | No | Target sketch ID. Defaults to the currently active sketch. |
layerId | string | Yes | The ID of the layer to show or hide. |
visible | boolean | No | Set to true to show, false to hide. Omit to toggle. |
Output Shape
{
"layerId": "layer_b6d7f8",
"name": "Grain",
"visible": false
}Side Effects
- The layer's visibility changes in the UI (eye icon updates).
- Hidden layers are excluded from the design composite.
- The composite re-renders to reflect the change.
Error Cases
| Error | Cause |
|---|---|
SKETCH_NOT_FOUND | The specified sketchId does not exist or no sketch is active. |
LAYER_NOT_FOUND | No layer with the given layerId exists in the sketch. |
Golden Path Example
Request
{
"layerId": "layer_b6d7f8"
}Response
{
"layerId": "layer_b6d7f8",
"name": "Grain",
"visible": false
}