Investigate native always-allow support in Claude permission protocol

Open
#137 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
typescript
Domain
api

Research direction

Start by reviewing the Claude control protocol behavior described here, especially control_response and control_request, and compare it with the session-level behavior in issue #136. Determine whether a native always-allow flag such as allowAlways can prevent future matching requests; done means documenting whether the protocol supports this or confirming that the daemon workaround remains necessary.

Written by the indexing model from the issue text.

Description

Context

Claude Code's control protocol for permissions only supports binary "allow" / "deny" responses via control_response. There is no protocol-level mechanism to communicate "always allow this tool" — the native Claude Code TUI handles this entirely client-side by remembering the user's choice and auto-replying to matching future requests.

Current Workaround

We are implementing session-level always-allow caching in the sandbox-agent daemon layer (#136 related). When a user replies "always" via the Gigacode/OpenCode UI, the daemon stores the decision and auto-replies "allow" to matching future control_request events from Claude.

Proposal

Investigate whether Claude's control protocol could natively support an "always allow" behavior flag (e.g. "behavior": "allowAlways") that would tell the Claude agent process to stop emitting control_request for matching tools, rather than requiring the daemon to intercept and auto-reply.

This would reduce latency (no round-trip through the daemon for auto-approved permissions) and align with how Codex (acceptForSession) and OpenCode (always) handle this natively.

Priority

Low — the daemon-side workaround is sufficient. This is a nice-to-have for protocol cleanliness.

🤖 Generated with Claude Code

Dominant language
TypeScript
Stars
1.6k
Forks
125
PR merge metrics
No merged PRs in 30d

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from rivet-dev/sandbox-agent

All issues in rivet-dev/sandbox-agent

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.