getAccessToken Method

Returns a promise that resolves to the AccessToken if signed in.

  • The token is ensured to be valid at least for the buffer of time specified by the configuration.
  • The token is refreshed if it's possible and necessary.
  • This method must be called to refresh the token - the client does NOT automatically monitor for token expiry.
  • Getting or refreshing the token will trigger the NativeAppAuthorization.onUserStateChanged event.

getAccessToken(): Promise<AccessToken>

Returns - Promise<AccessToken>

Defined in

Last Updated: 11 June, 2024