{
  "$schema": "./schemas/permission-mode.schema.json",
  "defaultMode": "default",
  "cycleOrder": ["default", "plan", "build", "yolo"],
  "modes": {
    "default": {
      "label": "Default",
      "color": "muted",
      "sandbox": {
        "enabled": true,
        "writable": true,
        "allowWrite": [".", "/tmp"],
        "denyWrite": [],
        "denyRead": ["~/.ssh", "~/.aws", "~/.gnupg"],
        "network": {
          "allowedDomains": [
            "npmjs.org",
            "*.npmjs.org",
            "registry.npmjs.org",
            "registry.yarnpkg.com",
            "pypi.org",
            "*.pypi.org",
            "github.com",
            "*.github.com",
            "api.github.com",
            "raw.githubusercontent.com"
          ],
          "deniedDomains": []
        }
      },
      "permission": {
        "path": { "*": "allow" },
        "external_directory": "ask",
        "read": "allow",
        "grep": "allow",
        "find": "allow",
        "ls": "allow",
        "write": "ask",
        "edit": "ask",
        "bash": { "*": "ask" },
        "web_search": "ask",
        "tool": "ask",
        "skill": "ask"
      }
    },
    "plan": {
      "label": "Plan Mode",
      "color": "mdLink",
      "systemPrompt": "@plan",
      "sandbox": {
        "enabled": true,
        "writable": false,
        "allowWrite": [".", "/tmp"],
        "denyWrite": [],
        "denyRead": ["~/.ssh", "~/.aws", "~/.gnupg"],
        "network": {
          "allowedDomains": [
            "npmjs.org",
            "*.npmjs.org",
            "registry.npmjs.org",
            "registry.yarnpkg.com",
            "pypi.org",
            "*.pypi.org",
            "github.com",
            "*.github.com",
            "api.github.com",
            "raw.githubusercontent.com"
          ],
          "deniedDomains": []
        }
      },
      "permission": {
        "path": { "*": "allow" },
        "external_directory": "ask",
        "read": "allow",
        "grep": "allow",
        "find": "allow",
        "ls": "allow",
        "write": { "*": "deny", "*.md": "allow", "*.markdown": "allow" },
        "edit": { "*": "deny", "*.md": "allow", "*.markdown": "allow" },
        "bash": { "*": "allow" },
        "web_search": "allow",
        "tool": "ask",
        "skill": "ask"
      }
    },
    "build": {
      "label": "Build",
      "color": "accent",
      "sandbox": {
        "enabled": true,
        "writable": true,
        "allowWrite": [".", "/tmp"],
        "denyWrite": [],
        "denyRead": ["~/.ssh", "~/.aws", "~/.gnupg"],
        "network": {
          "allowedDomains": [
            "npmjs.org",
            "*.npmjs.org",
            "registry.npmjs.org",
            "registry.yarnpkg.com",
            "pypi.org",
            "*.pypi.org",
            "github.com",
            "*.github.com",
            "api.github.com",
            "raw.githubusercontent.com"
          ],
          "deniedDomains": []
        }
      },
      "permission": {
        "path": { "*": "allow" },
        "external_directory": "ask",
        "read": "allow",
        "grep": "allow",
        "find": "allow",
        "ls": "allow",
        "write": "allow",
        "edit": "allow",
        "bash": { "*": "allow" },
        "web_search": "allow",
        "tool": "allow",
        "skill": "allow"
      }
    },
    "yolo": {
      "label": "YOLO",
      "color": "error",
      "sandbox": { "enabled": false, "writable": true },
      "bypassProtectedPaths": true,
      "permission": {
        "path": { "*": "allow" },
        "external_directory": "allow",
        "read": "allow",
        "write": "allow",
        "edit": "allow",
        "grep": "allow",
        "find": "allow",
        "ls": "allow",
        "bash": { "*": "allow" },
        "web_search": "allow",
        "tool": "allow",
        "skill": "allow"
      }
    }
  }
}
