Skip to content

parseApprovalsArg

parseApprovalsArg(args): ApprovalsAction | null

Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/modules/slashCommands.ts:655

CFG-27/EXT-70 — parse the /approvals argument: no arg SHOWS the current posture; any of the five kebab-case rung names switches to it; trust / untrust move which of a server’s annotation hints are believed (§4.7.1). Returns null for an unrecognized first argument so the command renders a usage hint instead of guessing.

The retired auto / ask spellings are NOT accepted as aliases — this is still alpha, and a silent alias would leave the user believing in a vocabulary the gate no longer has.

Only the subcommand token is lower-cased. A server key is the user’s own mcpServers key (§4.7.5) and is case-sensitive, so folding it would name a different server — one that believes nothing, silently, while the notice reported success. A hint is matched case-insensitively against the fixed vocabulary and echoed back in its canonical spelling, so readonlyhint resolves rather than vanishing, and what lands in the policy is the name the derivation reads.

string[]

ApprovalsAction | null