fix(team): add updatedInput: {} to all allow control_responses
Claude Code CLI Zod schema requires updatedInput to be a record
when behavior is 'allow'. Without it, MCP tool approvals fail with
'Tool permission request failed: ZodError: expected record, received
undefined'.
Add empty updatedInput: {} to all allow responses (autoAllow,
timeout-allow, and manual allow).
This commit is contained in:
parent
7258de90c3
commit
dcf775d86c
1 changed files with 2 additions and 2 deletions
|
|
@ -6014,7 +6014,7 @@ export class TeamProvisioningService {
|
|||
response: {
|
||||
subtype: 'success',
|
||||
request_id: requestId,
|
||||
response: { behavior: 'allow' },
|
||||
response: { behavior: 'allow', updatedInput: {} },
|
||||
},
|
||||
};
|
||||
|
||||
|
|
@ -6239,7 +6239,7 @@ export class TeamProvisioningService {
|
|||
|
||||
// IMPORTANT: request_id is NESTED inside response, NOT top-level
|
||||
// (asymmetry with control_request — confirmed by Python SDK, Elixir SDK and issue #29991)
|
||||
const allowResponse: Record<string, unknown> = { behavior: 'allow' };
|
||||
const allowResponse: Record<string, unknown> = { behavior: 'allow', updatedInput: {} };
|
||||
// For AskUserQuestion: pass user's answers via updatedInput so the CLI
|
||||
// can deliver them without re-prompting. Format follows --permission-prompt-tool spec.
|
||||
if (allow && message) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue