feat: update MCP quickstart for On-Behalf-Of Token Exchange#1053
Merged
Conversation
Updates the "Call Your API on a User's Behalf" quickstart to reflect the new On-Behalf-Of (OBO) Token Exchange implementation. JavaScript changes (PR #79): - Update sample folder: fastmcp-mcp-on-behalf-of-tokenexchange-js - Replace Custom Token Exchange with On-Behalf-Of terminology - Simplify environment variables (remove MCP_AUTH0_SUBJECT_TOKEN_TYPE) - Update token exchange: exchangeTokenOnBehalfOf() using getTokenOnBehalfOf() - Simplify MCP_AUTH0_EXCHANGE_SCOPE to "read:private" Python changes (PR #81): - Update sample folder: fastmcp-mcp-on-behalf-of-tokenexchange-python - Replace Custom Token Exchange with On-Behalf-Of terminology - Update token exchange: exchange_token_on_behalf_of() using get_token_on_behalf_of() Additional improvements: - Add rate limit note for Auth0 for AI Agents add-on - Add client grant configuration instructions - Add OBO token exchange enablement component - Update prerequisites with OBO-specific requirements Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Contributor
Summary
Redirects per inputRedirects in auth4genai/mcp/get-started/call-your-apis-on-users-behalf.mdx
|
Contributor
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Workflows to automatically generate PRs for you. |
priley86
reviewed
Apr 28, 2026
priley86
reviewed
Apr 28, 2026
priley86
reviewed
Apr 28, 2026
priley86
reviewed
Apr 28, 2026
priley86
previously approved these changes
Apr 28, 2026
Contributor
|
approved changes from this side, but please do defer until these quickstarts are merged. ty so much for this update @lrzhou25 ! 🙇 |
BcnCarlos
reviewed
Apr 30, 2026
BcnCarlos
previously approved these changes
Apr 30, 2026
This was referenced Apr 30, 2026
Merged
BcnCarlos
approved these changes
Apr 30, 2026
agiannelli-auth0
approved these changes
Apr 30, 2026
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 "Call Your API on a User's Behalf" MCP quickstart to reflect the new On-Behalf-Of (OBO) Token Exchange implementation, replacing the previous Custom Token Exchange approach.
Changes
JavaScript Updates (based on auth0-samples PR #79)
fastmcp-mcp-customtokenexchange-js→fastmcp-mcp-on-behalf-of-tokenexchange-jsMCP_AUTH0_SUBJECT_TOKEN_TYPEMCP_AUTH0_EXCHANGE_SCOPEfrom"openid offline_access read:private"to"read:private"API_BASE_URLtrailing slashexchangeCustomToken()→exchangeTokenOnBehalfOf()getTokenByExchangeProfile()→getTokenOnBehalfOf()AUTH0_AUDIENCEinstead ofAPI_AUTH0_AUDIENCEsubjectTokenTypeparameterPython Updates (based on auth0-samples PR #81)
fastmcp-mcp-customtokenexchange-python→fastmcp-mcp-on-behalf-of-tokenexchange-pythonexchange_custom_token()→exchange_token_on_behalf_of()get_token_by_exchange_profile()→get_token_on_behalf_of()AUTH0_AUDIENCEinstead ofAPI_AUTH0_AUDIENCEsubject_token_typeparameterAdditional Improvements
Files Changed
mcp/get-started/call-your-apis-on-users-behalf.mdx- Main quickstart pagesnippets/mcp/get-started/call-your-apis/create-env-file.mdx- Environment setupsnippets/mcp/get-started/call-your-apis/exchange-access-token-js.mdx- JavaScript explanationsnippets/mcp/get-started/call-your-apis/exchange-access-token-python.mdx- Python explanationsnippets/mcp/get-started/pre-reqs/enable-obo-token-exchange.mdx- New OBO enablement componentsnippets/mcp/get-started/pre-reqs/prerequisites.mdx- Updated prerequisitesTesting
🤖 Generated with Claude Code