BunkerWeb
v0.8.0Operate BunkerWeb, the open-source WAF, through its API: services, bans, configs, jobs.
Values you need
| Variable | What it is | |
|---|---|---|
BUNKERWEB_BASE_URL | required | Base URL of the BunkerWeb API, reachable from inside the container. |
BUNKERWEB_API_TOKEN | required secret | BunkerWeb API bearer token. The server authenticates to BunkerWeb with it. |
BUNKERWEB_WEBSOCKET_TOKEN | required secret | Token MCP clients send as Authorization: Bearer <token>. Required so /mcp/, /rpc and /ws are not open. |
MCP_ALLOWED_HOSTS | optional | Host header values accepted by the DNS rebinding protection. Change it with the published port. Default: localhost,localhost:8080,127.0.0.1,127.0.0.1:8080 |
SEARCH_MODE | optional | Documentation search. disabled keeps the server free of an external search service. Default: disabled |
PyPI (uvx) discovery passed
Requires uv (https://docs.astral.sh/uv/)
Run in a terminal
claude mcp add bunkerweb-mcp -e 'BUNKERWEB_API_TOKEN=<BUNKERWEB_API_TOKEN>' -e 'BUNKERWEB_BASE_URL=<BUNKERWEB_BASE_URL>' -e 'BUNKERWEB_WEBSOCKET_TOKEN=<BUNKERWEB_WEBSOCKET_TOKEN>' -- uvx bunkerweb-mcp==0.8.0Add to
claude_desktop_config.json{
"mcpServers": {
"bunkerweb-mcp": {
"args": [
"bunkerweb-mcp==0.8.0"
],
"command": "uvx",
"env": {
"BUNKERWEB_API_TOKEN": "<BUNKERWEB_API_TOKEN>",
"BUNKERWEB_BASE_URL": "<BUNKERWEB_BASE_URL>",
"BUNKERWEB_WEBSOCKET_TOKEN": "<BUNKERWEB_WEBSOCKET_TOKEN>"
}
}
}
}Add to
~/.cursor/mcp.json{
"mcpServers": {
"bunkerweb-mcp": {
"args": [
"bunkerweb-mcp==0.8.0"
],
"command": "uvx",
"env": {
"BUNKERWEB_API_TOKEN": "<BUNKERWEB_API_TOKEN>",
"BUNKERWEB_BASE_URL": "<BUNKERWEB_BASE_URL>",
"BUNKERWEB_WEBSOCKET_TOKEN": "<BUNKERWEB_WEBSOCKET_TOKEN>"
}
}
}
}Add to
.vscode/mcp.json{
"inputs": [
{
"description": "BUNKERWEB_API_TOKEN",
"id": "bunkerweb-api-token",
"password": true,
"type": "promptString"
},
{
"description": "BUNKERWEB_BASE_URL",
"id": "bunkerweb-base-url",
"password": true,
"type": "promptString"
},
{
"description": "BUNKERWEB_WEBSOCKET_TOKEN",
"id": "bunkerweb-websocket-token",
"password": true,
"type": "promptString"
}
],
"servers": {
"bunkerweb-mcp": {
"args": [
"bunkerweb-mcp==0.8.0"
],
"command": "uvx",
"env": {
"BUNKERWEB_API_TOKEN": "${input:bunkerweb-api-token}",
"BUNKERWEB_BASE_URL": "${input:bunkerweb-base-url}",
"BUNKERWEB_WEBSOCKET_TOKEN": "${input:bunkerweb-websocket-token}"
},
"type": "stdio"
}
}
}Add to
~/.codex/config.toml[mcp_servers.bunkerweb-mcp]
command = "uvx"
args = ["bunkerweb-mcp==0.8.0"]
env = { "BUNKERWEB_API_TOKEN" = "<BUNKERWEB_API_TOKEN>", "BUNKERWEB_BASE_URL" = "<BUNKERWEB_BASE_URL>", "BUNKERWEB_WEBSOCKET_TOKEN" = "<BUNKERWEB_WEBSOCKET_TOKEN>" }For AI agents
- Ask the user for: BUNKERWEB_BASE_URL, BUNKERWEB_API_TOKEN, BUNKERWEB_WEBSOCKET_TOKEN. Never invent or guess these values; secrets go into the client config, not into chat logs.
- Pick the user's MCP client and apply the matching config from the first install method (it is the one verified by the smoke test when available).
- Restart or reload the client so it starts the server.
- Verify: the server should expose these tools: create_api_token, ping_api, diagnose_bunkerweb, list_instances, ping_instances, stop_instances, get_instance, create_instance, ….
- If it fails, check that the required runtime is installed (uv (https://docs.astral.sh/uv/)) and that the values above are set.
Machine-readable: install.md · manifest.json