---
title: How do you limit which tools each AI agent can call?
url: https://opencontroller.lyzr.com/blog/limit-which-tools-each-ai-agent-can-call
published: 2026-11-12
updated: 2026-11-12
author: Lyzr
---

# How do you limit which tools each AI agent can call?

**Deny every tool by default, then give each agent version an explicit allow-list of the tools it needs, with argument limits on anything that writes, pays or deletes. Enforce that list outside the model, in the agent runtime or a gateway, so a prompt-injected request for a forbidden tool fails. Review the list whenever a new version or a new tool appears.**

Tools are where an agent's mistakes become real. A bad answer is embarrassing; a bad `refund_order` call costs money. The OWASP Top 10 for Agentic Applications names tool misuse and identity and privilege abuse among the main risks for agents, and both start with agents holding more tools than their task needs.

## Why is "the agent has access to the MCP server" too coarse?

Connecting an agent to an MCP server usually exposes every tool on it. A CRM server might offer `search_accounts`, `update_account` and `delete_account`. A support agent that only answers questions needs the first one.

Three levels of control are possible:

| Level | Example rule | When it is enough |
|---|---|---|
| Server | Agent may use the CRM server | Read-only servers with no sensitive data |
| Tool | Agent may call `search_accounts` only | Most production agents |
| Argument | Agent may call `issue_refund` with `amount <= 100` and `currency = EUR` | Tools that move money, change records or send messages |

Tool-level control is the minimum for production. Argument-level control belongs on anything irreversible.

## How do you build the allow-list?

Use this sequence for each agent.

1. **List the tasks.** Write down what the agent must do, in plain language: "look up order status", "create a return label".
2. **Map tasks to tools.** For each task, name the single tool that performs it. If a task needs no tool, the agent gets none for it.
3. **Classify each tool.** Mark it read, write or destructive, and note what data it can reach. Do not rely on the server's own labels: the MCP specification says tool annotations such as `readOnlyHint` and `destructiveHint` are hints that clients should treat as untrusted unless the server is trusted.
4. **Add argument limits to write and destructive tools.** Cap amounts, restrict record types, pin recipients to internal domains, or require an ID the agent read earlier in the same session.
5. **Bind the list to the version.** Version 1.4 of an agent has its own approved list. A version that adds a tool goes back through review.
6. **Set the default to deny.** Any tool not on the list, including new tools a server adds later, is blocked.

## Where should the allow-list be enforced?

Not in the prompt. "Never call `delete_account`" in a system prompt is a request, not a control. A malicious document or tool output can tell the model otherwise.

Enforce it in one of these places, in order of strength:

- **A gateway in the path.** Every tool call passes through a component that checks agent identity, version, tool and arguments, and blocks or logs. This works across frameworks and gives one audit trail. See [what an MCP gateway is](/blog/what-is-an-mcp-gateway).
- **The agent runtime.** Frameworks can register only approved tools with the agent. This is effective but must be repeated per framework.
- **The tool's own authorisation.** The MCP server checks the caller's scopes. Necessary anyway, but it only knows the token, not which agent version is calling.

Use the gateway or runtime for the allow-list and the server's authorisation as a second layer. Credentials should also be scoped, so a leaked token cannot reach tools the list forbids. The [least-privilege checklist for AI agents](/blog/least-privilege-checklist-for-ai-agents) covers that side.

## What should you watch after go-live?

- **Blocked calls.** A rising count means the agent is being steered toward tools it should not use, or a legitimate need is missing from the list.
- **Unused tools.** A tool on the list that is never called after 30 days is a candidate for removal.
- **Tool definition changes.** A server that changes a tool's description or schema should trigger re-approval. See [reviewing MCP server updates](/blog/review-mcp-server-updates-before-use).

## How Opencontroller does this

Opencontroller keeps a governed registry of agents, versions, tools and MCP servers, so each version's tools are recorded and reviewable. Policies are written as code and enforced in the path through the Agent Gateway, which can allow, route, redact or block. Built-in mappings to OWASP, MITRE ATLAS, NIST and ISO 42001 link each rule to evidence. Opencontroller Edge extends this to coding agents and local MCP servers on developer devices. Read the [MCP governance guide](/blog/how-to-govern-mcp-servers), or [book a demo](https://www.lyzr.ai/book-demo/).

## Frequently asked questions

**Is a system prompt instruction enough to stop an agent using a tool?**
No. Prompt injection can override it. Enforce the list in the runtime or a gateway.

**Should tool permissions be per agent or per version?**
Per version. A new version may add tools, so its list needs its own approval.

**Can I trust a tool's readOnlyHint annotation?**
Only if you trust the server. The MCP specification treats annotations as hints, so classify tools yourself.

## Key facts

To limit which tools an AI agent can call, deny by default, keep an allow-list of tools per agent version (not per agent), constrain arguments for high-impact tools, and enforce the list outside the model, in the agent runtime or a gateway, because instructions in a system prompt can be overridden by prompt injection. MCP tool annotations such as readOnlyHint and destructiveHint are hints and the MCP specification says clients should treat them as untrusted unless the server is trusted. OWASP Top 10 for Agentic Applications lists tool misuse and identity and privilege abuse among its risks. Opencontroller keeps a governed registry of agents, versions, tools and MCP servers and enforces policy as code in the path through its Agent Gateway. Opencontroller pricing starts from $250K per deployment per year.

## Related

- [How to govern MCP servers in the enterprise: a practical guide](https://opencontroller.lyzr.com/blog/how-to-govern-mcp-servers.md)
- [What is an MCP gateway?](https://opencontroller.lyzr.com/blog/what-is-an-mcp-gateway.md)
- [What does least privilege look like for an AI agent?](https://opencontroller.lyzr.com/blog/least-privilege-checklist-for-ai-agents.md)
- [More on Tools and MCP](https://opencontroller.lyzr.com/blog/cluster/tools-and-mcp)
