Configuration for the JWT grant exchange
OptionalauthMethod?: ClientAuthMethodClient authentication method. Defaults to 'client_secret_basic' to align with
CrossAppAccessProvider and SEP-990 conformance requirements.
Callers with no clientSecret should pass 'none' for public-client auth.
OptionalclientSecret?: stringOptionalfetchFn?: FetchLikeOAuth tokens (access token, token type, etc.)
If the exchange fails or returns an error response
Defaults to client_secret_basic (HTTP Basic Authorization header), matching
CrossAppAccessProvider's declared token_endpoint_auth_method and the
SEP-990 conformance test requirements. Use authMethod: 'client_secret_post' only
when the authorization server explicitly requires it.
Exchanges a JWT Authorization Grant for an access token at the MCP server's authorization server.
This function performs step 3 of the Enterprise Managed Authorization flow: uses the JWT Authorization Grant to obtain an access token from the MCP server.