Skip to main content
Filter MCP tools to control which capabilities agents have access to, improving security and reducing complexity.
The user restricts which MCP tools the agent sees; only whitelisted tools appear in the tool list.

How It Works

Quick Start

1

Whitelist Specific Tools

Only allow safe file operations:
The user asks about files on disk; MCP tools are filtered before the model sees them.
2

Blacklist Dangerous Tools

Block destructive operations:

How It Works

Precedence Rule: If both allowed_tools and disabled_tools are specified, allowed_tools wins (include takes precedence over exclude).

Configuration Options


Common Patterns

Safety-First Agent

Restrict to read-only operations:

Remove Dangerous Operations

Block specific risky tools:

Multi-Server Filtering

Apply different filters to different servers:

When to Use Which Filter

Use allowed_tools when:
  • Security is critical
  • You know exactly which tools you need
  • Working with untrusted or powerful servers
Use disabled_tools when:
  • You want most tools but need to block a few
  • Rapid prototyping with tool discovery
  • Working with generally safe servers

Best Practices

For security-sensitive applications, use allowed_tools to explicitly control capabilities. It’s safer to add tools as needed than to discover dangerous ones later.
When using filters, comment why specific tools are allowed or blocked. This helps with maintenance and team understanding.
Before deploying, verify that your filtered tool set provides the capabilities your agent needs. Use praisonai mcp list-tools and praisonai mcp tools search to inspect available tools.
Some tools might depend on others. When whitelisting, ensure you include all necessary tools for complete workflows.

Load MCP Tools

Wire configured MCP servers into agents with one line

MCP Client Protocol

Protocol interface for MCP client implementations