What
Stream-json is the output format programs use when they run Claude Code without a person at the keyboard. When such a run fails at startup, it can write a result explaining why. Before, that result was only written when the host set CLAUDE_CODE_STARTUP_FAILURE_RESULTS. Three reasons are now written by every stream-json run:
org_config_required_unavailableorg_config_refusedconfig_file_invalid
All other startup failures still need CLAUDE_CODE_STARTUP_FAILURE_RESULTS.
Why
Programs that run Claude Code get a structured error for these organization and configuration problems without opting in, so they can react to them rather than seeing a run end with no explanation.
Names in the bundleCLAUDE_CODE_STARTUP_FAILURE_RESULTSstream-json
Documented inclaude-code/agent-sdk/typescript