The properties related to the email link generated
Type declaration
action_link: string
The email link to send to the user.
The action_link follows the following format: auth/v1/verify?type={verification_type}&token={hashed_token}&redirect_to={redirect_to}
email_otp: string
The raw email OTP.
You should send this in the email if you want your users to verify using an OTP instead of the action link.
Provide your own global lock implementation instead of the default
implementation. The function should acquire a lock for the duration of the
fn async function, such that no other client instances will be able to
hold it at the same time.
experimental
Type Parameters
R
Parameters
name: string
Name of the lock to be acquired.
acquireTimeout: number
If negative, no timeout should occur. If positive it
should throw an Error with an isAcquireTimeout
property set to true if the operation fails to be
acquired after this much time (ms).
fn: (() => Promise<R>)
The operation to execute when the lock is acquired.
Provider name or OIDC iss value identifying which provider should be used to verify the provided token. Supported names: google, apple, azure, facebook, kakao, keycloak (deprecated).
token: string
OIDC ID token issued by the specified provider. The iss claim in the ID token must match the supplied provider. Some ID tokens contain an at_hash which require that you provide an access_token value to be accepted properly. If the token contains a nonce claim you must supply the nonce used to obtain the ID token.
Determines which sessions should be
logged out. Global means all
sessions by this account. Local
means only this session. Others
means all other sessions except the
current one. When using others,
there is no sign-out event fired on
the current session!
Implements a global exclusive lock using the Navigator LockManager API. It
is available on all browsers released after 2022-03-15 with Safari being the
last one to release support. If the API is not available, this function will
throw. Make sure you check availablility before configuring GoTrueClient.
You can turn on debugging by setting the supabase.gotrue-js.locks.debug
local storage item to true.
Internals:
Since the LockManager API does not preserve stack traces for the async
function passed in the request method, a trick is used where acquiring the
lock releases a previously started promise to run the operation in the fn
function. The lock waits for that promise to finish (with or without error),
while the function will finally wait for the result anyway.
Type Parameters
R
Parameters
name: string
Name of the lock to be acquired.
acquireTimeout: number
If negative, no timeout. If 0 an error is thrown if
the lock can't be acquired without waiting. If positive, the lock acquire
will time out after so many milliseconds. An error is
a timeout if it has isAcquireTimeout set to true.