BrowserAuthorizationClient Class

Implements

Methods

Name Description
constructor(configuration: BrowserAuthorizationClientConfiguration): BrowserAuthorizationClient    
_onAccessTokenExpired(): void Protected Raised after the access token has expired.  
_onAccessTokenExpiring(): Promise<void> Protected Raised prior to the access token expiring  
_onSilentRenewError(): void Protected Raised when the automatic silent renew has failed.  
_onUserLoaded(user: User): void Protected Raised when a user session has been established (or re-established).  
_onUserSignedOut(): void Protected Raised when the user's sign-in status at the OP has changed.  
_onUserStateChanged(user: User): void Protected    
_onUserUnloaded(): void Protected Raised when a user session has been terminated.  
checkSessionStatus(): Promise<boolean> Checks the current local user session against that of the identity provider.  
createUserManager(settings: UserManagerSettings): UserManager Protected Creates the internal user manager and binds all relevant events to their respective callback function.  
dispose(): void Disposes the resources held by this client  
getAccessToken(): Promise<string> Returns a promise that resolves to the AccessToken of the currently authorized user.  
getUserManager(): Promise<UserManager> Protected    
getUserManagerSettings(basicSettings: BrowserAuthorizationClientConfiguration, advancedSettings?: UserManagerSettings): Promise<UserManagerSettings> Protected Merges the basic and advanced settings into a single configuration object consumable by the internal userManager.  
handleSigninCallback(): Promise<void> Attempts to parse an OIDC token from the current window URL  
initAccessToken(user: User): void Protected    
loadUser(): Promise<undefined | User> Protected Gets the user from storage  
nonInteractiveSignIn(args?: BrowserAuthorizationClientRequestOptions): Promise<undefined | User> Protected Attempts a non-interactive signIn  
Alias for signInRedirect  
signInPopup(args?: BrowserAuthorizationClientRequestOptions): Promise<void> Attempts a sign-in via popup with the authorization provider  
signInRedirect(successRedirectUrl?: string, args?: BrowserAuthorizationClientRequestOptions): Promise<void> Attempts a sign-in via redirection with the authorization provider.  
signInSilent(): Promise<void> Attempts a silent sign in with the authorization provider  
signOut(): Promise<void> Alias for signOutRedirect  
signOutPopup(): Promise<void>    
signOutRedirect(): Promise<void>    
handleSignInCallback(store: Storagewindow.localStorage): Promise<void> Static Configuration-less sign in callback.  

Properties

Name Type Description
_accessToken Protected string    
_advancedSettings Protected UserManagerSettings | undefined    
_basicSettings Protected BrowserAuthorizationClientConfigurationOptions    
_expiresAt Protected Date | undefined    
_userManager Protected UserManager | undefined    
authorityUrl Accessor ReadOnly string    
hasExpired Accessor ReadOnly boolean    
hasSignedIn Accessor ReadOnly boolean    
isAuthorized Accessor ReadOnly boolean    
onAccessTokenChanged Readonly BeEvent<(token: string) => void>    

Defined in

Last Updated: 06 November, 2024