plugins/claude-code-expert/skills/auto-mode/SKILL.md
Auto mode permission handling — classifier-based approvals, PermissionDenied hook, defer permissionDecision, and autonomy profiles for hands-off Claude Code usage
npx skillsauth add markus41/claude auto-modeInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Auto mode is the middle ground between approving every tool call and running with --dangerously-skip-permissions. A classifier evaluates each permission prompt and either approves safe operations silently or blocks and surfaces suspicious ones.
Available since v2.1.83 (research preview).
Cycle with Shift+Tab in the terminal:
| Mode | Behavior |
|------|----------|
| default | Claude asks for approval on every sensitive action |
| auto | Classifier auto-approves safe actions; blocks/surfaces suspicious ones |
| bypassPermissions | All actions run without prompting (dangerous — only in trusted environments) |
Press Shift+Tab until you see auto mode on in the footer.
{
"permissions": {
"defaultMode": "auto"
}
}
claude --permission-mode auto
The classifier scores each tool call against a risk model. For each action:
You see the same UI as a manual block, so you can review and override when needed.
When the classifier blocks an action, a PermissionDenied hook fires before Claude has a chance to respond. Use it to:
retry: true to let Claude try a different approach instead of failing{
"hooks": {
"PermissionDenied": [{
"hooks": [{
"type": "command",
"command": ".claude/hooks/permission-denied.sh"
}]
}]
}
}
#!/usr/bin/env bash
# permission-denied.sh
set -euo pipefail
INPUT=$(cat)
TOOL=$(echo "$INPUT" | jq -r '.tool_name // "unknown"')
REASON=$(echo "$INPUT" | jq -r '.reason // "no reason"')
# Log to audit file
printf '%s\t%s\t%s\n' "$(date -u +%Y-%m-%dT%H:%M:%SZ)" "$TOOL" "$REASON" \
>> .claude/logs/permission-denied.log
# Return retry: true so Claude tries an alternative approach
echo '{"retry": true}'
Alternatively, retry manually from the /permissions → Recent tab using r.
For SDK apps and custom UIs that run Claude in -p (print/pipe) mode, use defer on a PreToolUse hook to pause Claude at a tool call and hand the decision to your application:
{
"hooks": {
"PreToolUse": [{
"hooks": [{
"type": "command",
"command": ".claude/hooks/pause-for-review.sh"
}]
}]
}
}
#!/usr/bin/env bash
# pause-for-review.sh — returns defer for sensitive tools
set -euo pipefail
INPUT=$(cat)
TOOL=$(echo "$INPUT" | jq -r '.tool_name // ""')
case "$TOOL" in
Bash|Write|Edit)
echo '{"permissionDecision": "defer"}'
;;
*)
echo '{"decision": "approve"}'
;;
esac
When Claude hits a defer:
deferred_tool_use payloadclaude --resume <session-id> --permission-decision approve| | Manual | Auto | bypassPermissions | |--|--------|------|-------------------| | File reads | Prompt | ✅ Silent | ✅ Silent | | File writes | Prompt | ✅ Usually silent | ✅ Silent | | git push | Prompt | ⚠️ Surfaced | ✅ Silent | | rm -rf | Prompt | 🚫 Blocked | ✅ Silent | | Network calls | Prompt | ⚠️ Surfaced | ✅ Silent | | Effort | High friction | Low friction | Zero friction / high risk |
Recommended for most workflows: auto mode.
Only use bypassPermissions: In locked-down CI containers where you control the entire environment.
Auto mode pairs well with the autonomy profiles from skills/autonomy-profiles/SKILL.md. Set defaultMode: "auto" and then configure the appropriate autonomy profile (conservative, balanced, aggressive) to control task scope and self-correction behavior independently of permission approval.
/status # shows current permission mode in the footer
/permissions # opens the full permissions panel
development
Enhanced plan-authoring skill with Pre-Writing context gathering, task metadata, non-TDD templates, Red Flags, telemetry, and an automated plan linter. Use when you have a spec or requirements for a multi-step task, before touching code.
tools
Documentation intelligence engine with graph-based API docs, algorithm library, and drift detection
tools
Ultraplan cloud planning — kick off a plan in the cloud from your terminal, review and revise in the browser, then execute remotely or send back to CLI
tools
--- name: mcp description: Configure MCP servers for Claude Code — stdio vs HTTP, authentication, Tools/Resources/Prompts distinction, channels (CI webhook, mobile relay, Discord bridge, fakechat), and cost of always-loaded tools. Use this skill whenever adding an MCP server, debugging connection issues, choosing between MCP Tools vs Prompts vs Resources, installing channel servers, or managing .mcp.json. Triggers on: "MCP server", "mcp config", "add Obsidian MCP", "install context7", "channels"