# Tollgate Configuration
# https://github.com/dotsetlabs/tollgate
version: "1"
# Default action when no policy matches
defaults:
action: prompt # allow | deny | prompt
timeout: 60000 # Approval timeout in ms
# MCP Server configurations
servers:
# PostgreSQL database server
postgres:
command: "npx"
args: ["-y", "@modelcontextprotocol/server-postgres"]
env:
DATABASE_URL: "${DATABASE_URL}"
tools:
# Allow read-only queries
"query":
action: allow
# Prompt for write operations
"execute":
action: prompt
message: "Agent wants to execute SQL"
# Block everything else
"*":
action: deny
# Filesystem server
filesystem:
command: "npx"
args: ["-y", "@anthropic/mcp-server-filesystem", "./"]
tools:
# Allow all read operations
"read_*":
action: allow
"list_*":
action: allow
# Prompt for writes
"write_*":
action: prompt
"create_*":
action: prompt
# Block deletes
"delete_*":
action: deny
reason: "File deletion is disabled for safety"