{"version":"2.1.98","anchor":"claude-code-script-caps-environment-variable","canonical_anchor":"claude-code-script-caps-environment-variable","heading":"CLAUDE_CODE_SCRIPT_CAPS Environment Variable","tier":null,"area":null,"scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.98\/e\/claude-code-script-caps-environment-variable","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.98","markdown":"### `CLAUDE_CODE_SCRIPT_CAPS` Environment Variable\n\n**What**\n\nEnforces per-script call limits in subprocess-scrubbed environments to prevent data exfiltration via repeated write operations.\n\n**Usage**\n\n`export CLAUDE_CODE_SCRIPT_CAPS='{\"curl\": 10, \"wget\": 5}'` **Details** - JSON object mapping script\/command name substrings to maximum call counts - Tracks cumulative usage across the session - Throws an error when a cap is exceeded: \"Script call limit exceeded: X has been called N times (cap: M)\" - Only active when `CLAUDE_CODE_SUBPROCESS_ENV_SCRUB` is enabled - Designed for untrusted-input workflows where exfiltration prevention is critical **Evidence** Script caps (search for `\"CLAUDE_CODE_SCRIPT_CAPS\"` and `\"Script call limit exceeded\"`)"}