Bulk update elements
Set, add to or remove one property for all elements of a selection. Without confirm only previews: the number of affected elements and the skipped ones, whose type does not have the property. With confirm writes only that property’s lines (SR-102). Never id, type or status (element.setStatus takes several refs).
Command element.bulkUpdate. Writes files in the working tree, never to Git. It is refused while the workspace is read-only. Changes element files, and no change can be checked against a missing or faulty metamodel.
| Field | Type | Required | Description |
|---|---|---|---|
selection |
selection |
yes | Which elements a command works on: a saved filter, an inline filter, a package, a baseline or explicit IDs, optionally seen through a variant view. |
property |
key |
yes | A property of the metamodel; not the title key, not a relation kind. |
operation |
one of "set", "add", "remove" |
yes | set: replace the value. add: append the items an element does not hold yet (a property with many). remove: without value the property, with value these items (many). |
value |
inputValue |
no | For set and add. A choice by key or name; relation targets as for element.update. |
confirm |
boolean |
no | Write the change; without it nothing is written. A written file also gets the current titles of its same-repository relation targets (decision on #307), which the preview does not show. Default: false. |
expected |
integer |
no | The count of the preview: with confirm, refused (nothing written) when the change now affects another number of elements. |
Output
Section titled “Output”| Field | Type | Required | Description |
|---|---|---|---|
applied |
boolean |
yes | True when the files were written (confirm). |
count |
integer |
yes | Number of affected elements (SR-071 AK2). |
affected |
array of object |
yes | The elements whose file the change rewrites, in store order. |
affected[].id |
uuid |
yes | Element ID: random UUID version 4, lower case, never changes (D-017, SR-002). |
affected[].shortId |
shortId |
yes | Display ID: type prefix, dash, the trailing hex characters of the UUID with dashes removed, at least 6, more until unique in the workspace (D-017, SR-002 AK3). The file name uses 12 (D-056). |
unchanged |
integer |
yes | Elements of the selection that have the result already. |
skipped |
array of object |
yes | Elements left out because the metamodel does not allow the property for them (SR-071 AK3). |
skipped[].id |
uuid |
yes | Element ID: random UUID version 4, lower case, never changes (D-017, SR-002). |
skipped[].shortId |
shortId |
yes | Display ID: type prefix, dash, the trailing hex characters of the UUID with dashes removed, at least 6, more until unique in the workspace (D-017, SR-002 AK3). The file name uses 12 (D-056). |
skipped[].reason |
one of "not-a-property", "unknown-type" |
yes | |
skipped[].message |
string |
yes | |
files |
array of string |
yes | Written files relative to the workspace root; empty in a preview. |
problems |
array of problem |
yes | Hints at the property in the affected elements after the change: value kind (SR-085), target types (SR-086). |
incomplete |
incomplete |
no | True when a result is incomplete because targets are in repositories that are not available locally (SR-006 AK2, SR-036 AK3). |
In the command prompt (Ctrl+Shift+P, macOS ⌘⇧P): the command Bulk update elements.
reqseq element bulk-update, with --json for the output as JSON. Its help:
Usage: reqseq element bulk-update <property> <operation> [options]
Set, add to or remove one property for all elements of a selection. Without`confirm` only previews: the number of affected elements and the skipped ones,whose type does not have the property. With `confirm` writes only thatproperty's lines (SR-102). Never id, type or status (element.setStatus takesseveral refs).
Arguments: property A property of the metamodel; not the title key, not a relation kind. operation set: replace the value. add: append the items an element does not hold yet (a property with many). remove: without value the property, with value these items (many). one of: set, add, remove
Options: --property <value> instead of the argument <property> --operation <value> instead of the argument <operation> --confirm Write the change; without it nothing is written. A written file also gets the current titles of its same-repository relation targets (decision on #307), which the preview does not show. default: false --no-confirm set confirm to false --expected <number> The count of the preview: with confirm, refused (nothing written) when the change now affects another number of elements. --input <json|@file|-> command input as JSON: inline, from a file, or from standard input --workspace <path> workspace root (default: nearest folder upwards with reqseq-workspace.yaml) --json print exactly the command output as JSON --yaml print the whole command output as YAML, problems one per line -h, --help show help
Only via --input: selection, valuePOST /v1/commands/element.bulkUpdate on the local API (reqseq serve api), with the input as the JSON body; the answer is the output.
Tool element_bulkUpdate of the MCP server (reqseq mcp), with the input as its arguments.