docs: document GitHub OIDC audience binding for self-hosters and CI users (#1230)

## Summary

Follow-up to #1229. Three small doc additions so the new audience
requirement is discoverable without reading the source:

- `.env.example` lists `MCP_REGISTRY_GITHUB_OIDC_AUDIENCE` alongside the
other registry env vars, with a note that the value must match the
scheme+host that publishers pass via `--registry`.
- The publisher CLI reference (`docs/reference/cli/commands.md`)
explains that the CLI derives the audience from `--registry` and that
self-hosters must set the matching env var on the registry side.
- The GitHub Actions troubleshooting table
(`docs/modelcontextprotocol-io/github-actions.mdx`) maps the new
`invalid audience` error to the user-facing fix (upgrade
`mcp-publisher`).

No code changes — docs only.

## Test plan

- [ ] CI green (markdown lint / link checks if any)
- [ ] Eyeball-render the troubleshooting table on the
modelcontextprotocol.io preview to confirm the new row formats correctly

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Radoslav Dimitrov 2026-04-29 20:56:53 -04:00 • committed by GitHub
commit db43896209
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 16 additions and 0 deletions

View file

@ -220,6 +220,7 @@ The workflow will run tests, build the package, publish the package to npm, and
| Error Message | Action |
| --- | --- |
| "Authentication failed" | Ensure `id-token: write` permission is set for OIDC, or check secrets. |
| "invalid audience" | Your `mcp-publisher` binary is too old for this registry deployment. Re-run the install step shown above so you pick up the latest release. |
| "Package validation failed" | Verify your package successfully published to the package registry (e.g., npm, PyPI), and that your package has the [necessary verification information](./package-types). |
{/* prettier-ignore-end */}

View file

@ -72,6 +72,13 @@ mcp-publisher login github-oidc [--registry=URL]
- Requires `id-token: write` permission in workflow
- No browser interaction needed
The CLI derives the OIDC `aud` claim from `--registry` (scheme + host, e.g.
`https://registry.modelcontextprotocol.io`) so tokens are bound to the specific
deployment they were minted for. Self-hosters must set
`MCP_REGISTRY_GITHUB_OIDC_AUDIENCE` on the registry to the matching value;
publishers running an older `mcp-publisher` will fail with `invalid audience`
and need to upgrade.
Also see [the guide to publishing from GitHub Actions](../../modelcontextprotocol-io/github-actions.mdx).
#### DNS Verification