Skip to content
Latest (currently 2026.10.2) has the newest features, bug fixes, and CVE patches of Solo Enterprise for agentgateway.

For the complete documentation index, see llms.txt. Markdown versions of all docs pages are available by appending .md to any docs URL.

About Solo STS token exchange

Page as Markdown

Learn how the Solo security token service (STS) issues impersonation and delegation tokens, stores elicited credentials, and fits into the control plane.

The Solo Enterprise for agentgateway security token service (STS) exchanges a user’s identity provider (IdP) token for a token that a downstream service accepts. Unlike a proxy-side exchange at an external authorization server, the STS signs its own tokens and stores upstream credentials. Your downstream services then trust one issuer, the STS, instead of every IdP in your environment.

Why use the STS

When an agent calls an MCP server or an API on behalf of a user, the downstream service needs a token that it can verify. The user’s original IdP token is often the wrong token to forward, for the following reasons:

  • The downstream service might not trust the IdP that issued the token.
  • The token might carry an audience that the downstream service does not accept.
  • The token carries the identity of the user only, so an audit-aware service cannot tell which agent acted.
  • Raw IdP tokens that pass through an MCP stack increase the impact of a leaked token.

Which flow fits your goal

Start from what the downstream service must receive, because that decides which flow you configure.

Your goalWhat to configure
One token issuer for the backends that you ownSTS impersonation. The proxy exchanges the user’s token when it forwards a request to a protected backend.
A record of which agent acted for which userSTS delegation. Your agent calls the STS token endpoint with its own actor token.
The user’s own credential for an upstream OAuth provider, such as GitHubElicitation. The user authorizes the upstream provider once, and the STS stores the resulting credential.
A token that an external IdP issued, such as Microsoft Entra IDAn identity provider exchange instead of an STS-signed token, because the downstream service accepts tokens from its own IdP only.

Two exchange flows

The STS implements RFC 8693 token exchange, and mints a new JWT that the STS signs. Which flow you get depends on whether the exchange request carries an actor token.

FlowWho calls the STSWhat the issued token says
ImpersonationThe agentgateway proxy, when a request reaches a backend that has an impersonation policysub is the user. The token carries no act claim, so the downstream service cannot tell which agent acted.
DelegationYour agent, which sends the user’s token as the subject token and its own Kubernetes service account token as the actor tokensub is the user, and the act claim carries the identity of the agent, so the downstream service can audit both.

Elicitation is not a third exchange flow. In an elicitation, the STS does not mint a token. Instead, the STS stores the token that the upstream OAuth provider issued to the user, and returns that token to the proxy when the user calls the backend again.

How the STS fits into the gateway

For STS connections, ports, and availability requirements, see Token exchange deployment.

In Kubernetes mode, the STS runs in the Solo Enterprise for agentgateway control plane and listens on port 7777 of the control plane service. The following diagram shows an impersonation exchange.

    sequenceDiagram
    participant Agent
    participant Proxy as agentgateway proxy
    participant STS as Solo STS
    participant Backend as MCP server or API

    Agent->>Proxy: Request with IdP JWT
    Proxy->>STS: Token exchange<br/>(subject_token = IdP JWT)
    STS->>STS: Validate the subject token,<br/>mint a new JWT
    STS-->>Proxy: STS-signed JWT
    Proxy->>Backend: Request with the STS-signed JWT
    Backend-->>Proxy: Response
    Proxy-->>Agent: Response
  
  1. The agent sends a request with the user’s IdP token to the agentgateway proxy.
  2. The backend has a policy that sets backend.tokenExchange, so the proxy sends the IdP token to the STS as the subject token. The proxy finds the STS through the STS_URI environment variable in its EnterpriseAgentgatewayParameters resource.
  3. The STS validates the subject token and mints a new JWT with the same sub claim.
  4. The proxy replaces the IdP token with the STS-signed JWT and forwards the request to the backend.

The agent sends one token and does not see the second token. The backend receives a JWT that your own STS signed, and verifies it through the STS discovery endpoints, /.well-known/oauth-authorization-server and /.well-known/jwks.json.

You enable the STS and set its issuer, token lifetime, and validators with the tokenExchange Helm settings. The STS uses three validators.

ValidatorWhat it validates
subjectValidatorThe user’s IdP token, which is the subject token of the exchange. For example, set the remote type with the JWKS URL of your IdP.
actorValidatorThe actor token that the proxy or an agent presents to the STS. For example, set the k8s type to validate Kubernetes service account tokens.
apiValidatorCalls to the elicitation API, such as from the Solo UI. Set this validator even if you do not use elicitations. Without it, the STS cannot start, and the control plane goes into a CrashLoopBackOff state.

Next steps

Impersonation, delegation, and elicitation use the same STS infrastructure.

  1. Each flow guide includes the STS setup that it needs. The impersonation and delegation guides enable the STS as part of their steps. For elicitation, follow Set up interactive elicitation or Set up brokered elicitation.
  2. Configure the flow that you need: impersonation, delegation, or elicitation.