Unclear It is not clear what turns on the gh stand-in mode.
What
gh is GitHub's command-line tool. When a session finds no GitHub CLI at startup, Claude Code now provides its own stand-in:
- What it does: it handles only
gh api <REST endpoint>, sending the request through the session's GitHub proxy without a token. - Supported options:
--method,--field,--raw-field,--header,--input,--paginate,--jq,--includeand--hostname. - Placeholders:
{owner},{repo}and{branch}are filled fromGH_REPOor the git remotes. - Refusals: it refuses GraphQL, unsupported options and headers that are not on its allowed list.
- Off switch: it is disabled when
CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFICis set. - How it runs: it is a per-session script that calls Claude Code with a hidden
--gh-standinargument, and a newghStandinMainentry handles it. - Which gh wins: when the stand-in is in use and a PATH is set, its folder is added after the PATH instead of before it, so a real
ghruns if one is there. - Claude is told: the instructions about the session proxy now say no GitHub CLI was found and that
ghhere is a built-in stand-in that supports onlygh api <REST endpoint>.
The --daemon-worker, remote-control and agents startup paths also now call a setup step for global agents, and a new startup check was added at entry.
Why
Sessions without gh installed can still make GitHub REST calls. Other gh commands will not work there, and Claude is told so.
Something disagreesSomething we can check disagrees with this entry, or the writer said they could not settle it.
The writer flagged doubt
It is not clear what turns on the gh stand-in mode.