{"name":"CLAUDE_CODE_FORWARD_SUBAGENT_TEXT","slug":"claude-code-forward-subagent-text","family":"env","title":"Environment variables","noun":"environment variable","description":"Set to `1` to emit [subagent](\/docs\/en\/sub-agents) text and thinking blocks in `claude -p --output-format stream-json` output, the same behavior as the [`--forward-subagent-text`](\/docs\/en\/cli-reference#cli-flags) flag. Use the variable when a harness invokes `claude` and can't pass the flag itself. Unlike the flag, which exits with an error outside non-interactive mode with stream-json output, the variable is ignored there so that nested invocations keep working when it's set process-wide. Requires Claude Code v2.1.211 or later","description_source":"docs","described_by":{"doc":"claude-code\/env-vars","title":"Environment variables"},"presence":{"first_seen":"2.1.211","removed_in":null,"in_current_build":true,"newest_mined":"2.1.309","builds":87,"mined_builds":150,"first_cited":null},"aliases":[],"entries":[],"entries_total":0,"docs":[{"source":"claude-code","path":"env-vars","title":"Environment variables","documented":true},{"source":"claude-code","path":"cli-reference","title":"CLI reference","documented":false},{"source":"claude-code","path":"headless","title":"Run Claude Code programmatically","documented":false},{"source":"claude-code","path":"whats-new\/2026-w29","title":"Week 29 \u00b7 July 13\u201317, 2026","documented":false}],"docs_total":4,"gates":[],"related":[{"name":"CLAUDE_CODE_FORWARD_USER_INTENT","slug":"claude-code-forward-user-intent","description":"Two new env vars were added to internal forwarding and auth-token handling lists."}],"url":"https:\/\/changelogs.core-directive.com\/reference\/env\/claude-code-forward-subagent-text","family_url":"https:\/\/changelogs.core-directive.com\/reference\/env.json"}