AI Cloud Architect

ServiceNow on-behalf-of token exchange with Bedrock AgentCore Gateway

AWSHow-to by Greg Biegel, Arnab Chakraborty, Hasan Mehdi and Jose GuzmanAWS Artificial Intelligence Blog

Learn how to configure Amazon Bedrock AgentCore Gateway for an on-behalf-of (OBO) token exchange with Microsoft Entra ID, so an AI agent can call the ServiceNow REST API while preserving the calling user’s identity. AgentCore Gateway performs the exchange natively, with no interceptor Lambda or custom code.

Read the original (opens the source's page in a new tab)

AI: Summary

What it is

AgentCore Gateway now performs on-behalf-of token exchange with Microsoft Entra ID natively, so an agent's calls to the ServiceNow REST API carry the calling user's identity without a Lambda interceptor.

Who it is for

Teams running AI agents on AgentCore that call ServiceNow or other OAuth-protected REST APIs and need user-level access controls.

Key points

  • Requires MCP version 2025-11-25 on the gateway; native OBO cannot be enabled on gateways created with earlier versions.
  • Target config needs the ServiceNow connector scope (user_impersonation) and the custom parameter requested_token_use:on_behalf_of, or the call fails with an authentication error.
  • ServiceNow must map the preferred_username claim to an existing user and the inbound auth scope must be limited to the APIs the agent needs.

The same at other vendors

Timeline

Posts about Amazon Bedrock AgentCore Gateway, oldest first.

  1. Update to an existing featureAgentCore Gateway supports private TLS certificates for VPC endpoints · AWS · Announcement
  2. Blog postHow Eon built multi-cloud investigation with an MCP Gateway on Amazon Bedrock AgentCore · AWS · Blog post
  3. New featureAgentCore Gateway now supports Bedrock InvokeModel APIs and model fallback · AWS · Announcement
  4. New featureAWS Step Functions workflows now available as AI agent tools · AWS · Announcement
  5. Customer storyHow MoEngage turned over 400 APIs into agent tools with AgentCore Gateway · AWS · Customer story
  6. This postServiceNow on-behalf-of token exchange with Bedrock AgentCore Gateway
  7. How-toGovern AI agent access with Okta Cross App Access and Amazon Bedrock AgentCore – Part 2 · AWS · How-to
  8. How-toConnect Amazon Bedrock AgentCore Gateway to private APIs in a hub-and-spoke network with centralized inspection · AWS · How-to
  9. Blog postProtect agent tool calls with Skyflow and Amazon Bedrock AgentCore Gateway · AWS · Blog post
Show all 29 posts
  1. New featureAmazon Bedrock AgentCore Gateway supports AWS PrivateLink invocation and invocation logging · AWS · Announcement
  2. How-toSecure ingress connectivity to Amazon Bedrock AgentCore Gateway using interface VPC endpoints · AWS · How-to
  3. Blog postTransform your MCP architecture: Unite MCP servers through AgentCore Gateway · AWS · Blog post
  4. How-toBuild a biomedical research agent with Biomni tools and Amazon Bedrock AgentCore Gateway · AWS · How-to
  5. New featureApply fine-grained access control with Bedrock AgentCore Gateway interceptors · AWS · Announcement
  6. Blog postStreamline AI agent tool interactions: Connect API Gateway to AgentCore Gateway with MCP · AWS · Blog post
  7. How-toConnecting MCP servers to Amazon Bedrock AgentCore Gateway using Authorization Code flow · AWS · How-to
  8. How-toConfiguring Amazon Bedrock AgentCore Gateway for secure access to private resources · AWS · How-to
  9. What it explainsAmazon Bedrock AgentCore Identity now supports On-Behalf-Of (OBO) token exchange · AWS · Announcement
  10. How-toSecure AI agents with Policy and Lambda interceptors in Amazon Bedrock AgentCore gateway · AWS · How-to
  11. Blog postExtending MCP support for Amazon Bedrock AgentCore Gateway · AWS · Blog post
  12. How-toBuilding a secure auth code flow setup using AgentCore Gateway with MCP clients · AWS · How-to
  13. Generally availableIntroducing Web Search on Amazon Bedrock AgentCore · AWS · Announcement
  14. Generally availableAWS WAF adds support for Amazon Bedrock AgentCore Gateway · AWS · Announcement
  15. How-toImplement on-behalf-of token exchange for multi-tenant agents with Amazon Bedrock AgentCore Gateway · AWS · How-to
  16. Update to an existing featureHow AgentCore Gateway supports the MCP 2026-07-28 spec · AWS · Announcement
  17. How-toConfigure rate limits for AI traffic on AgentCore gateway · AWS · How-to
  18. How-toSecuring AI agents with temporal policies in Amazon Bedrock AgentCore · AWS · How-to
  19. How-toGovern AI agent tool access with Amazon Bedrock AgentCore Gateway · AWS · How-to
  20. How-toBuild a multi-account AI agent with AgentCore Gateway and MCP · AWS · How-to
  21. Update to an existing featureAgentCore Gateway supports private TLS certificates for VPC endpoints · AWS · Announcement
  22. Blog postHow Eon built multi-cloud investigation with an MCP Gateway on Amazon Bedrock AgentCore · AWS · Blog post
  23. New featureAgentCore Gateway now supports Bedrock InvokeModel APIs and model fallback · AWS · Announcement
  24. New featureAWS Step Functions workflows now available as AI agent tools · AWS · Announcement
  25. Customer storyHow MoEngage turned over 400 APIs into agent tools with AgentCore Gateway · AWS · Customer story
  26. This postServiceNow on-behalf-of token exchange with Bedrock AgentCore Gateway
  27. How-toGovern AI agent access with Okta Cross App Access and Amazon Bedrock AgentCore – Part 2 · AWS · How-to
  28. How-toConnect Amazon Bedrock AgentCore Gateway to private APIs in a hub-and-spoke network with centralized inspection · AWS · How-to
  29. Blog postProtect agent tool calls with Skyflow and Amazon Bedrock AgentCore Gateway · AWS · Blog post

Go deeper