home / mcp / danger zone mcp server
Executes safe and dangerous commands from config with optional confirmation and easy npx-based execution.
Configuration
View docs{
"mcpServers": {
"koinunopochi-danger-zone-mcp": {
"command": "npx",
"args": [
"@koinunopochi/danger-zone-mcp"
]
}
}
}Danger Zone MCP is a server that lets you run predefined commands in a controlled way, providing safety checks for potentially risky actions. It supports safe commands, dangerous commands with optional native confirmation, and easy adoption through npx. It helps you automate common tasks while protecting your system from unintended operations.
To use Danger Zone MCP, connect a client that can invoke MCP servers. You can run safe commands directly from the configuration, and you can run dangerous commands with a confirmation prompt by default. If you need to bypass the confirmation for trusted commands, you can configure those commands as pre-authorized. The system supports JSONC (JSON with comments) and plain JSON configuration files and will fall back to a global config in your home directory if a project config isn’t found.
Prerequisites: ensure you have Node.js and npm installed on your machine.
Install the MCP server globally so you can run it from anywhere.
Or run the MCP server inline with npx for a quick start.
Create a configuration to define which commands are safe and which are dangerous. Safe commands execute without confirmation, while dangerous commands show a native macOS confirmation dialog by default. You can mark specific dangerous commands as pre-authorized to skip the confirmation step.
Project configuration (highest priority) should be placed in the project root under the Claude config path. Global configuration is used as a fallback when no project config exists.
The following example demonstrates the structure for a configuration that includes both safe and dangerous commands. Save this as a project-wide or global .jsonc/.json file as appropriate.
{
// Safe commands that can be executed without confirmation
"commands": [
{
"name": "build_project",
"description": "Build the project",
"command": "npm",
"args": ["run", "build"]
},
{
"name": "check_chrome_mcp",
"description": "Check if MCP Chrome profile instances are running",
"command": "ps aux | grep -E '(Google Chrome.*mcp-chrome-profile)' | grep -v grep | wc -l"
}
],
// Dangerous commands that require confirmation
"dangerZone": [
{
"name": "clean_build",
"description": "Clean all build artifacts",
"command": "rm -rf dist"
// Will show confirmation dialog (default behavior)
},
{
"name": "kill_chrome_mcp",
"description": "Kill all Chrome instances with MCP profile",
"command": "pkill -f 'Google Chrome.*mcp-chrome-profile'",
"preAuthorized": true // Skip confirmation dialog
}
]
}Add the MCP server configuration under your Claude settings to enable command execution from Claude. When using Claude Code, the working directory is automatically set to your current project directory.
{
"mcpServers": {
"danger_zone": {
"command": "npx",
"args": ["@koinunopochi/danger-zone-mcp"]
}
}
}The server is implemented in TypeScript and can be extended or rebuilt as needed. Use npm to install dependencies, build, and run in development mode if you are contributing.
Executes predefined safe commands from configuration without user confirmation.
Executes dangerous commands from configuration and shows a native macOS confirmation dialog by default; supports preAuthorized commands to skip confirmation.