Add Layer
photopea_add_layerAdd a new empty layer to the active document, making it active. Use this before drawing operations such as fill selection or add gradient to isolate edits on a separate layer.
Instructions
Add a new empty layer to the active document. The new layer becomes the active layer. Use this before operations that draw onto a layer, such as fill_selection or add_gradient.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "photopea_add_layer"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Display name for the new layer in the layers panel | |
| opacity | No | Layer opacity percentage (0 = fully transparent, 100 = fully opaque, default 100) | |
| blendMode | No | Blend mode (e.g. normal, multiply, screen, overlay, darken, lighten). Defaults to normal. |