Show affected elements
Elements affected by a change of one element, with path and distance.
Command trace.affected. Reads the workspace and changes no file.
| Field | Type | Required | Description |
|---|---|---|---|
ref |
elementRef |
yes | UUID, short ID or identifier (e.g. SR-036), any case; several matches give ref.ambiguous. |
limit |
integer |
no | Default: 200. |
offset |
integer |
no | Default: 0. |
Output
Section titled “Output”| Field | Type | Required | Description |
|---|---|---|---|
affected |
array of object |
yes | The page of limit affected elements from offset (total counts all). The affected elements: every element that has a relation or an inline reference (in the text or in a property marked markdown, SR-127) to the element, directly or through the chain (SR-024 AK1), each once at its shortest distance, breadth first, the element itself never. Distance 1: every element whose file holds a relation (any relation kind or relation-valued property) or an inline reference to it. From there onward along the derivation chain (meaning derivation, SR-013) and inline references that point at an affected element. |
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). |
affected[].identifier |
string |
no | Its identifier (the value of its property with the meaning identifier, such as SR-036, #305), for display next to shortId; left out when it has none. |
affected[].type |
string |
yes | |
affected[].title |
string |
yes | |
affected[].repository |
string |
yes | |
affected[].file |
string |
yes | Path relative to the repository. |
affected[].distance |
integer |
yes | Steps from the element: 1 when this element’s file points at it directly. |
affected[].path |
array of object |
yes | The way: the element asked for first, this element last, each element in between that points at the one before it; each named by UUID and repository (D-058). |
affected[].path[].id |
uuid |
yes | Element ID: random UUID version 4, lower case, never changes (D-017, SR-002). |
affected[].path[].repository |
string |
yes | |
affected[].via |
object |
yes | How this element points at the one before it on the path: a relation stored under key (a relation kind or a relation-valued property), or an inline reference in its text or in a property marked markdown. |
affected[].via.kind |
one of "relation", "reference" |
yes | |
affected[].via.key |
key |
no | Fixed metamodel key of a type, property, relation kind or status value. Readable English, lower case, dashes (D-043, SR-010 AK2). |
total |
integer |
yes | The number of all affected elements; affected holds the page of limit from offset. |
records |
array of evidenceRecord |
yes | The evidence records of an older version of the element (SR-024 AK4): its records in the evidence folders (SR-028, SR-093) whose version is not its current one, newest first. Empty when its current version cannot be computed (its file no longer holds it, an embedded image cannot be read). |
incomplete |
incomplete |
yes | True while a repository of the workspace file is not on this machine: elements there may point at the element (SR-006 AK2). |
In the command prompt (Ctrl+Shift+P, macOS ⌘⇧P): the command Show affected elements.
reqseq trace affected, with --json for the output as JSON. Its help:
Usage: reqseq trace affected <ref> [options]
Elements affected by a change of one element, with path and distance.
Options: --ref <value> instead of the argument <ref> --limit <number> default: 200 --offset <number> default: 0 --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 helpPOST /v1/commands/trace.affected on the local API (reqseq serve api), with the input as the JSON body; the answer is the output.
Tool trace_affected of the MCP server (reqseq mcp), with the input as its arguments.