Reparent Node
node_insert_childMove a Figma node to a new parent at a specified index. Rearrange a design's hierarchy by changing a node's parent, with optional position control.
Instructions
Reparent a node under a new parent at an optional index. Valid range is 0 to parent's child count. Omit index to append.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| index | No | Position in parent's children array (default: append). The output index reports the actual resolved position (same-parent reorder shifts indices). | |
| childId | Yes | ID of the child node to reparent | |
| parentId | Yes | ID of the new parent node | |
| childNodeName | Yes | The child node's current exact name, passed back verbatim from `node_info`. | |
| parentNodeName | Yes | The parent node's current exact name, passed back verbatim from `node_info`. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| error | No | ||
| index | No | Index at which the child was inserted | |
| childId | No | ID of the reparented child node | |
| newParentId | No | ID of the new parent node |