docs: clarify auth in Codex CLI instructions#2549
Open
RossTarrant wants to merge 2 commits into
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the Codex installation guide to ensure the Codex CLI example produces an authenticated remote MCP server configuration for the hosted GitHub MCP server, avoiding confusing 401 failures.
Changes:
- Updated the
codex mcp addexample to include--bearer-token-env-var GITHUB_PAT_TOKEN. - Added a brief note explaining that the bearer token env var is required for PAT-authenticated access.
Show a summary per file
| File | Description |
|---|---|
| docs/installation-guides/install-codex.md | Fixes the Codex CLI example to include bearer token env var configuration and clarifies the auth requirement. |
Copilot's findings
- Files reviewed: 1/1 changed files
- Comments generated: 1
Co-authored-by: Copilot Autofix powered by AI <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Updates the Codex installation guide so the CLI setup command configures the required bearer token environment variable for the hosted GitHub MCP server.
Why
Fixes #2421
The existing Codex CLI example only stored the remote MCP server URL, which produced an unauthenticated config and could leave users in a confusing 401 state.
What changed
docs/installation-guides/install-codex.mdto add--bearer-token-env-var GITHUB_PAT_TOKENto thecodex mcp addexample.MCP impact
Prompts tested (tool changes only)
Security / limits
The docs now direct users to configure Codex to read the PAT from
GITHUB_PAT_TOKENinstead of creating an unauthenticated remote server entry.Tool renaming
deprecated_tool_aliases.goLint & tests
./script/lint./script/testipt/test`Docs-only change. Validated the documented
codex mcp add github --url https://api.githubcopilot.com/mcp/ --bearer-token-env-var GITHUB_PAT_TOKENcommand writesbearer_token_env_var = "GITHUB_PAT_TOKEN"to~/.codex/config.toml.Docs