docs: add GITHUB_PERSONAL_ACCESS_TOKEN to proxy mode auth token docs#2821
docs: add GITHUB_PERSONAL_ACCESS_TOKEN to proxy mode auth token docs#2821
Conversation
Agent-Logs-Url: https://github.com/github/gh-aw-mcpg/sessions/7cf60f5e-b9d0-4f16-b2cd-8497fff9a50c Co-authored-by: lpcox <15877973+lpcox@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Updates the proxy-mode environment variable documentation so users can provide GitHub auth using GITHUB_PERSONAL_ACCESS_TOKEN in addition to GH_TOKEN and GITHUB_TOKEN, matching the proxy command’s fallback resolution behavior.
Changes:
- Document
GITHUB_PERSONAL_ACCESS_TOKENas an accepted proxy auth token env var. - Reorder token env vars to reflect checked priority order.
- Clarify the token row’s default/requirement wording (needs a small correction per inline comment).
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| | `GITHUB_API_URL` | Explicit GitHub API endpoint (e.g., `https://copilot-api.mycompany.ghe.com`); used by proxy to set upstream target | (auto-derived) | | ||
| | `GITHUB_SERVER_URL` | GitHub server URL; proxy auto-derives API endpoint: `*.ghe.com` → `copilot-api.*.ghe.com`, GHES → `<host>/api/v3`, `github.com` → `api.github.com` | (falls back to `api.github.com`) | | ||
| | `GITHUB_TOKEN` / `GH_TOKEN` | GitHub auth token for the proxy to forward requests | (required) | | ||
| | `GH_TOKEN` / `GITHUB_TOKEN` / `GITHUB_PERSONAL_ACCESS_TOKEN` | GitHub auth token for the proxy to forward requests (checked in priority order) | (required for upstream auth) | |
There was a problem hiding this comment.
The Default column says this token env var is “(required for upstream auth)”, but awmg proxy can run without any of these env vars because it forwards the client’s Authorization header by default, and only uses these as a fallback when --github-token/env is set (see internal/proxy/proxy.go where Config.GitHubToken is documented as a fallback). Please update the description/default to reflect that this env var is optional and only needed when the client isn’t providing auth headers (or when you want to override them).
| | `GH_TOKEN` / `GITHUB_TOKEN` / `GITHUB_PERSONAL_ACCESS_TOKEN` | GitHub auth token for the proxy to forward requests (checked in priority order) | (required for upstream auth) | | |
| | `GH_TOKEN` / `GITHUB_TOKEN` / `GITHUB_PERSONAL_ACCESS_TOKEN` | Optional GitHub auth token used by the proxy when the client does not provide an `Authorization` header, or when you want to override client-provided auth (checked in priority order; used as a fallback for `--github-token`) | (optional; only used when client auth is not provided or is overridden) | |
The proxy mode env var table only listed
GITHUB_TOKEN/GH_TOKEN, omittingGITHUB_PERSONAL_ACCESS_TOKEN— a commonly used token variable that the proxy already accepts as a third fallback.Changes
docs/ENVIRONMENT_VARIABLES.md: Updated the Proxy Mode Variables table to list all three supported token env vars in their checked priority order and clarify the default valuePriority order matches
internal/cmd/proxy.go:GH_TOKEN→GITHUB_TOKEN→GITHUB_PERSONAL_ACCESS_TOKEN.📍 Connect Copilot coding agent with Jira, Azure Boards or Linear to delegate work to Copilot in one click without leaving your project management tool.