# uip maestro case cases and uip maestro case stages

> Syntax and options for `uip maestro case cases get` and `uip maestro case stages get`, which read the case-definition and stage structure of a local case management JSON file.

`uip maestro case cases` reads the root metadata of a local case management definition file (name, case identifier, whether the case app is enabled). `uip maestro case stages` reads a stage/exception-stage/trigger node inside that same file — the phases a case moves through. See [`uip maestro case`](./uip-maestro-case.md) for the file format and the rest of the subsystem.

## Synopsis

```text
uip maestro case cases get <file>
uip maestro case stages get <file> <stage-id>
```

## uip maestro case cases get

Show root metadata from an existing case management JSON file. Read-only, no options beyond the file argument.

### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<file>` | yes | Path to the case management JSON file to read. |

### Example

```bash
uip maestro case cases get invoice-review.json
```

### Data shape (--output json)

```json
{
  "Code": "CaseRetrieved",
  "Data": {
    "File": "invoice-review.json",
    "Id": "root",
    "Name": "Invoice Review",
    "CaseIdentifier": "Invoice Review",
    "CaseIdentifierType": "constant",
    "CaseAppEnabled": false,
    "Version": "20.0.0",
    "PublishVersion": 2,
    "Description": null
  }
}
```

`PublishVersion` reflects how many times this definition has been published; absent/`null` if it never has.

## uip maestro case stages get

Print a stage (or exception stage, or trigger) node plus every edge connected to it. Read-only.

### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<file>` | yes | Path to the case management JSON file. |
| `<stage-id>` | yes | ID of the stage node to retrieve. |

### Example

```bash
uip maestro case stages get case.json Stage_a1b2c3d4
```

### Data shape (--output json)

```json
{
  "Code": "StageFound",
  "Data": {
    "Stage": {
      "id": "Stage_a1b2c3d4",
      "type": "case-management:Stage",
      "data": { "label": "Review" }
    },
    "ConnectedEdges": []
  }
}
```

`Stage` is the raw node object as stored on disk (shape varies by `type`). `ConnectedEdges` lists every edge in the file whose `source` or `target` is this stage ID — see [`uip maestro case triggers`](./uip-maestro-case-triggers.md) for the edge/connection commands.

To add, relabel, move, or remove a stage, edit `caseplan.json`'s node array directly, then run `uip maestro case validate <file>`. See the `uipath-maestro-case` skill (`references/plugins/`) for the exact stage/exception-stage/trigger JSON shapes, including the auto-generated `Stage_<random>` ID convention and left-to-right canvas positioning.

## Related

- [`uip maestro case`](./uip-maestro-case.md) — subsystem overview, file format, `init`/`pack`/`debug`/`validate`/`spec`.
- [`uip maestro case triggers`](./uip-maestro-case-triggers.md) — edges connecting stages, and case-level triggers.
- [`uip maestro case tasks`](./uip-maestro-case-tasks.md) — tasks that live inside a stage.

## See also

- [Maestro tool overview](./uip-maestro-bpmn.md)
- [Global options](./global-options.md)
- [Exit codes](./exit-codes.md)
