BrowserSwitchClient

Client that manages the logic for browser switching.

Constructors

Link copied to clipboard
constructor()
Construct a client that manages browser switching with Chrome Custom Tabs fallback only.
constructor(@NonNull caller: ActivityResultCaller)
Construct a client that manages the logic for browser switching and automatically initializes the Auth Tab launcher.

Functions

Link copied to clipboard
open fun assertCanPerformBrowserSwitch(activity: Activity, browserSwitchOptions: BrowserSwitchOptions)
Throws a BrowserSwitchException when a browser switch flow cannot be started.
Link copied to clipboard
open fun completeRequest(@NonNull intent: Intent, @NonNull pendingRequest: String): BrowserSwitchFinalResult
Completes the browser switch flow for both Auth Tab and Custom Tabs fallback scenarios.
Link copied to clipboard
open fun restorePendingRequest(@NonNull pendingRequest: String)
Restores a pending request after process kill or app restart.
Link copied to clipboard
open fun start(@NonNull activity: Activity, @NonNull browserSwitchOptions: BrowserSwitchOptions): BrowserSwitchStartResult
Open a browser or Auth Tab with a given set of BrowserSwitchOptions from an Android activity.