Skip to content
BENIBIX Learn

allowedTools Option

Also known as allowedTools, allowed_tools, Agent SDK allowed tools, Claude Agent SDK allowedTools

The option that lists tools the agent may use with no prompt.

Think of it like

It is like a list of toys a kid may take and not ask.

Example

Leo's agent reads code and runs tests. He allows Read, Glob and Bash(npm test), so it never stops to ask for those.

Why it matters

An agent that stops for each read is slow. One that asks for nothing is a risk.

Definition

allowedTools is an Agent SDK option that lists tools Claude may use with no approval step. In Python it is allowed_tools. A rule can name a whole tool, such as Read, or part of one, such as Bash(npm *). It does not limit Claude to those tools. A call to a tool not on the list goes to the permission mode instead.

Example code

typescript
allowedTools: ["Read", "Glob", "Bash(npm test)"]
Let these run with no approval.

Common mistake

Thinking it blocks every tool not on the list. It does not. Use disallowedTools to block.

Key takeaways

  1. 1
    Pre-approves tools. No prompt.
  2. 2
    Not a full list. Others still exist.
  3. 3
    Scoped rules work. Bash(npm *).

Compare