login With Google
The Google authorize URL to open in a browser.
Returns as soon as the URL is resolved — it has no relationship to the eventual login result, which arrives as a deep link and completes through handleRedirect. Nothing here opens a browser: the host app owns that, and how it does it decides whether the login survives being backgrounded.
A Custom Tab (androidx.browser) is the recommended surface — it keeps the user in the app and shares Chrome's cookie jar, so an already-signed-in Google account needs no re-entry. A plain Intent(Intent.ACTION_VIEW, …) to the system browser works identically for the redirect. This SDK deliberately depends on neither.
val (authorizeUrl) = auth.loginWithGoogle()
startActivity(Intent(Intent.ACTION_VIEW, Uri.parse(authorizeUrl)))Fetches a fresh URL on every call, and the result must not be cached — see PortalAuthApi.getOAuthUrls for why.
Throws
when Google is not enabled for this auth environment. Not retryable — check getMethods and present the method as unavailable.