nodes.updateBatch
updateBatch(updates: object[]): Promise<void>Apply property updates to multiple nodes in a single call.
Each entry in updates is dispatched as an "UpdateNode" command. All
entries dispatched synchronously collapse into a single undo step (one
auto-commit window), so api.history.undo() reverts the full batch in one
click. Emits a single "nodes:updated" event after all updates have been
applied.
updates | object[] | Array of { id, properties } descriptors. |
Returns: Promise<void>
Example
await api.nodes.updateBatch([
{ id: "s1", properties: { score: 10 } },
{ id: "s2", properties: { score: 20 } },
]);