What is OpenClaw?
OpenClaw is a self-hosted AI agent framework that runs on your hardware. It supports multi-agent workflows, tool execution, and integrations with MCP servers — all controlled through a local gateway. Unbound provides an OpenClaw plugin that enforces tool policies via thebefore_tool_call hook. This means every tool call your OpenClaw agent makes — terminal commands, MCP tools, and more — can be checked against your organization’s security policies before execution.
How It Works
The Unbound plugin intercepts tool calls at two levels:- Terminal commands (
exectool): Sent to the Unbound gateway for LLM-based command classification and policy matching. Commands likerm,curl,git push, etc. are classified into command families and matched against your configured policies. - MCP tools (
mcp__server__toolformat): Sent to the gateway for direct string matching against MCP tool policies. No LLM classification needed — policies match on server name and tool name.
| Gateway Decision | OpenClaw Behavior |
|---|---|
allow | Tool call proceeds normally |
deny | Tool call is blocked with a reason message |
ask | Tool call is blocked (OpenClaw has no interactive ask UI) |
Prerequisites
Before setting up the integration, ensure you have:- OpenClaw: Version 2026.2.0 or higher
- Unbound Security account: With an application and API key (Create Application)
- Tool policies configured: Set up terminal command or MCP tool policies in the Unbound dashboard (Tool Policies)
Installation
Step 1: Install the Plugin
Step 2: Configure the Plugin
Add the plugin configuration to your~/.openclaw/openclaw.json:
Step 3: Set Your API Key
Set theUNBOUND_API_KEY environment variable in your shell profile:
Step 4 (Optional): Use Unbound as Your LLM Provider
You can route OpenClaw’s LLM calls through Unbound for full visibility and guardrail coverage. Add a custom provider to your config:Configuration Reference
| Option | Type | Default | Description |
|---|---|---|---|
gatewayUrl | string | required | Your Unbound gateway URL (e.g., https://api.getunbound.ai) |
apiKey | string | $UNBOUND_API_KEY | API key for authentication. Falls back to the UNBOUND_API_KEY environment variable |
failOpen | boolean | true | When true, tool calls proceed if the gateway is unreachable. Set to false to block all tool calls when the gateway is down |
Verification
After setup, verify the integration is working: Test 1: Safe command (should succeed)[tools] exec failed: This command is blocked by your organization's policy.
Configuring Policies
Tool policies are managed in the Unbound dashboard under Tool Policies:- Terminal Command policies: Match against classified command families (e.g.,
delete_file,git_action,network_request) - MCP Tool policies: Match against specific MCP server and tool name combinations (e.g.,
slack/send_message)

