Add node
node_addAdd a node to an IlluGen graph, optionally setting parameters and position, then save the project file. Returns the new node's id, type, and any warnings.
Instructions
Adds a node to the graph with IlluGen's default values, optionally setting some parameters.
Writes the project file in place. Parameter values are checked: an unknown name or invalid enum value fails
with suggestions and nothing is saved; a value outside the UI range is kept and reported in warnings.
Connect the new node with link_add afterwards.
Returns: id (string id of the new node), type, and warnings if any.Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Absolute path of the .illugen project file. | |
| graph | No | Graph to work in: empty for the top-level graph, or the id or label of a Node_Subgraph node ('outer/inner' for nested subgraphs). | |
| label | No | Optional display label. A unique label can then replace the id in the other tools. | |
| params | No | Parameter values to set, {name: value}, names and kinds from describe_node_type. Vectors and colors as lists ([x, y], [r, g, b, a]), enums as strings. Omitted parameters keep IlluGen's defaults. | |
| position | No | [x, y] position in the node editor. Default: to the right of the right-most node. | |
| node_type | Yes | Node type from list_node_types, e.g. 'Node_Grayscale_Noise' (case, spaces and 'Node_' prefix optional). |