Skip to main content

overwatch wrap

Wrap a single MCP server with a security proxy. All tool calls are intercepted and analyzed before execution.

Usage

overwatch wrap [options] <command> [args...]

Arguments

ArgumentDescription
commandThe MCP server command to run
argsArguments to pass to the MCP server

Options

OptionDescription
-c, --config <path>Path to configuration file
-n, --name <name>Server name (default: “wrapped”)
-t, --timeout <ms>Approval timeout in milliseconds (default: 60000)
--fail-mode <mode>Fail mode: open, closed, readonly (default: closed)
--no-auditDisable audit logging
--approval <method>Approval method: terminal, webhook
--approval-webhook-url <url>Webhook URL for remote approvals
--approval-webhook-secret <secret>Secret for HMAC signing webhook payloads

Examples

Basic Usage

overwatch wrap npx @modelcontextprotocol/server-postgres
Every tool call prompts for approval.

With Custom Timeout

overwatch wrap --timeout 120000 npx @anthropic/mcp-server-filesystem ./src

With Environment Variables

DATABASE_URL="postgres://localhost/mydb" overwatch wrap npx @modelcontextprotocol/server-postgres

Named Server

overwatch wrap --name production-db npx @modelcontextprotocol/server-postgres

How It Works

  1. Overwatch spawns the MCP server as a child process
  2. All JSONRPC messages pass through the proxy
  3. Tool definitions are captured and hashed for shadowing detection
  4. tools/call requests are evaluated against policies
  5. Based on policy, the call is allowed, denied, or prompts for approval
  6. Approved calls are forwarded to the upstream server
  7. All operations are logged to the audit trail

Approval Flow

When a tool call requires approval:
┌─────────────────────────────────────────────┐
│ Tool Call: query                            │
│ Server: postgres                            │
│ Risk: write                                 │
│                                             │
│ Arguments:                                  │
│   sql: INSERT INTO users (name) VALUES ('x')│
│                                             │
│ [A]llow once  [5] 5 min  [S]ession  [D]eny │
└─────────────────────────────────────────────┘

Session Grants

After approving, you can grant permissions for a duration:
GrantDurationUse Case
OnceSingle useOne-time operations
5 min5 minutesShort tasks
15 min15 minutesModerate tasks
Session24 hoursFull development session

Use with Claude Desktop

Update ~/Library/Application Support/Claude/claude_desktop_config.json:
{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": [
        "-y", "@dotsetlabs/overwatch", "wrap",
        "npx", "-y", "@anthropic/mcp-server-filesystem", "./"
      ]
    }
  }
}

Fail Modes

Control behavior when the upstream server fails:
ModeDescription
closedDeny all requests (default, safest)
openAllow requests to continue (risky)
readonlyAllow reads, deny writes