• Returns a jwt bearer token that can be used to call the given service. The token is fetched via a JWT bearer token grant using the user token + client credentials.

    Throws an error if there is no instance of the given service type or the XSUAA service, or if the request to the XSUAA service fails.

    Parameters

    • jwt: string

      The JWT of the user for whom the access token should be fetched.

    • service: string | Service

      The type of the service or an instance of Service.

    Returns Promise<string>

    A jwt bearer token.

    Copyright Ⓒ 2024 SAP SE or an SAP affiliate company. All rights reserved.