I
InsightNexus

AzureADGraphClient (Azure SDK for Java Reference Documentation)

Author

Rachel Davis

Published Feb 17, 2026

AzureADGraphClient (Azure SDK for Java Reference Documentation)

  • public class AzureADGraphClientextends Object

    Microsoft Graph client encapsulation.

    • Constructor Detail

    • Method Detail

      • acquireTokenForGraphApi

        public com.microsoft.aad.msal4j.IAuthenticationResult acquireTokenForGraphApi(String idToken, String tenantId) throws ServiceUnavailableException

        Acquire access token for calling Graph API.

        Parameters:
        idToken - The token used to perform an OBO request.
        tenantId - The tenant id.
        Returns:
        The access token for Graph service.
        Throws:
        ServiceUnavailableException - If fail to acquire the token.
        com.microsoft.aad.msal4j.MsalServiceException - If MsalServiceException has occurred.

Copyright © 2020 Microsoft Corporation. All rights reserved.