blender_edit_nodes
Edit any node tree in Blender — add/remove nodes, connect/disconnect sockets, set input values and properties. Supports shader, compositor, and geometry contexts.
Instructions
Edit any node tree in Blender — add/remove nodes, connect/disconnect sockets, set node input values and properties. Supports all 7 node tree contexts. Operations are executed in order within a single call.
Use this when: you need to build or modify shader, compositor, or geometry node graphs.
Do NOT use for: high-level PBR properties (use blender_manage_material), reading node trees (use blender_get_node_tree first).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tree_type | Yes | Type of node tree to edit. | |
| context | Yes | Context within the tree type. SHADER: OBJECT|WORLD|LINESTYLE|NODE_GROUP. COMPOSITOR: SCENE|NODE_GROUP. GEOMETRY: MODIFIER|TOOL|NODE_GROUP. | |
| target | No | Target name. For SHADER/OBJECT: material name. For SHADER/WORLD: world name. For GEOMETRY/MODIFIER: 'ObjectName/ModifierName'. For COMPOSITOR/SCENE: omit or scene name. For NODE_GROUP: node group name in bpy.data.node_groups. | |
| operations | Yes | Array of node operations to execute in order. |