brama routes rm¶
Retire one alias: remove its entry from the route registry and commit the document through the same staging file, validation and rename every other registry write uses. The running gateway stops serving the alias on the next request, without a restart.
Invocation¶
brama routes rm <ALIAS> [--file <FILE> | --gateway <ORIGIN> | --gateway-consumer <NAME>] [--bearer-role <ROLE>] [--json]
| Input | Required/default | Meaning |
|---|---|---|
<ALIAS> | required | The alias to remove. |
--file <FILE> | optional; BRAMA_INFERENCE_ROUTES_FILE, then ~/.config/brama/inference-routes.json | The registry to write. |
--gateway-consumer <NAME> / --gateway <ORIGIN> | optional; not with --file | Remove the alias on the gateway that serves it, through DELETE /v1/admin/routes, as brama routes set does for a change. |
--bearer-role <ROLE> | optional with a gateway | The vault role whose item’s token field is the console’s bearer; without it the bearer is read from stdin. |
--json | optional; off | Print one object instead of human-readable lines. |
What remains¶
A name the gateway knows does not stop existing when its route goes: the six required aliases and the two decision aliases keep being reported by brama aliases, in state no_route, with the sentence that says how to declare one again. A name nobody declared simply disappears from the listing.
Output and state¶
$ brama routes rm decision-model
registry: ~/.config/brama/inference-routes.json
change: decision-model removed
best-decision-model best
The report names the registry, the change it committed, how many routes remain, and one line per alias left in the document. With --json the answer is {"registry", "change", "document"}. Exit code is 0 on success.
Refusals¶
| Sentence | Meaning |
|---|---|
route alias `<alias>` is invalid | The name is not one a caller could present. |
route removal error: route alias not found | The registry holds no entry for that name; nothing was written. |
route removal error: <reason> | The registry could not be read or replaced, in the file's own words. It is left as it was. |
the gateway refused to remove <alias>: <status>: <its whole answer> | The serving gateway refused: required route aliases cannot be deleted, route alias not found, runtime route registry is not configured, or a bearer that is not the console’s. |
Every refusal exits 1 and prints on standard error.
See brama routes set, the route registry, or the CLI tree.