Skip to content

Code review batch 7: consistent update-command contract (#121)#156

Merged
yorkable merged 1 commit into
mainfrom
update-contract-consistency
Jun 11, 2026
Merged

Code review batch 7: consistent update-command contract (#121)#156
yorkable merged 1 commit into
mainfrom
update-contract-consistency

Conversation

@yorkable

Copy link
Copy Markdown
Contributor

#121data-sources, services, voice-groups, roles, and incidents update previously took no positional (the id had to live inside --file) — an inconsistent contract vs agents/prompts/tools, and still exposed to the #68 silent-wrong-resource risk. They now accept an optional positional id reconciled with the body via ensureBodyIdentifier, matching the rest of the CLI. New test per resource.

organizations update is the singular current-org multipart command and is intentionally unchanged.

Closes #121.

🤖 Generated with Claude Code

…ands (#121)

data-sources, services, voice-groups, roles, and incidents `update` previously
took no positional — the id had to live inside --file, an inconsistent contract
vs agents/prompts/tools and still exposed to the #68 silent-wrong-resource risk.
They now accept an optional positional id reconciled with the body via
ensureBodyIdentifier (numeric), matching the rest of the CLI. New tests for each.

(organizations `update` is the singular current-org multipart command and is
intentionally unchanged.)

go test -race ./... green.

Co-Authored-By: Claude Fable 5 <[email protected]>
@yorkable
yorkable merged commit 406e57e into main Jun 11, 2026
1 check passed
@yorkable
yorkable deleted the update-contract-consistency branch June 11, 2026 23:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

update commands have 3 inconsistent contracts; 6 resources lack the body-id guard

1 participant