Members
# constant clearStoredCodeVerifier
Removes the PKCE code verifier from sessionStorage.
# constant generateCodeVerifier
Generates a high-entropy, cryptographically strong random string for use as a PKCE code verifier.
It uses rejection sampling to eliminate modulo bias, ensuring a perfectly uniform distribution
across the character set recommended by RFC 7636.
# constant getStoredCodeVerifier
Retrieves the PKCE code verifier from sessionStorage.
# constant setStoredCodeVerifier
Stores the PKCE code verifier in sessionStorage.
Type Definitions
object
# ActionInfo
Identifies an action that was (or can be) run, and the state it is associated with.
Properties:
# AutoStep(state)
A handler that automatically runs a follow-up action for a given state, without requiring
explicit user interaction. See
State#autoStep.
Parameters:
| Name | Type | Description |
|---|---|---|
state |
State.<TState>
|
Array
|
"all"
# AutoStepExclusion
Controls which
AutoSteppedStates should be skipped when initializing a State
(`"all"` to skip every automatic step).
object
# Claims
Custom claims can be added via the `TCustomClaims` generic parameter, which will be merged
with the standard claims properties. These custom claims must follow the `Record` pattern.
Properties:
| Name | Type | Attributes | Description |
|---|---|---|---|
subject |
string
|
The subject or identifier of the claims. | |
issued_at |
string
|
<optional> |
The timestamp when the claims were issued (optional). |
expiration |
string
|
The timestamp when the claims expire. | |
audience |
Array.<string>
|
<optional> |
The intended audience(s) for the claims (optional). |
issuer |
string
|
<optional> |
The entity that issued the claims (optional). |
email |
Pick.<Email, ("address"|"is_primary"|"is_verified")>
|
<optional> |
Email information associated with the subject (optional). |
username |
string
|
<optional> |
The subject's username (optional). |
session_id |
string
|
The session identifier linked to the claims. | |
subject |
string
|
||
issued_at |
string
|
<optional> |
|
expiration |
string
|
||
audience |
Array
|
<optional> |
|
issuer |
string
|
<optional> |
|
email |
Pick.<Email, ("address"|"is_primary"|"is_verified")>
|
<optional> |
|
username |
string
|
<optional> |
|
session_id |
string
|
"login"
|
"registration"
|
"profile"
|
"token_exchange"
# FlowName
The name of a top-level flow exposed by the flow API. Each flow is a self-contained state
machine (e.g. logging in, registering, or managing a profile).
"password"
|
"passkey"
|
"passcode"
|
"third_party"
# LoginMethod
The method used to complete a login.
# PasskeyAutofillActivationHandler(state)
A handler that activates WebAuthn passkey autofill (conditional mediation) for a given state.
See
State#passkeyAutofillActivation.
Parameters:
| Name | Type | Description |
|---|---|---|
state |
State.<TState>
|
object
# StateCreateConfig
Configuration options accepted when creating the initial
State of a flow.
Properties:
| Name | Type | Attributes | Description |
|---|---|---|---|
loadFromCache |
boolean
|
<optional> |
Whether to attempt loading a previously cached state instead of fetching a fresh one. |
loadFromCache |
boolean
|
<optional> |
"account_deleted"
|
"credential_onboarding_chooser"
|
"device_trust"
|
"error"
|
"login_init"
|
"login_method_chooser"
|
"login_otp"
|
"login_passkey"
|
"login_password"
|
"login_password_recovery"
|
"login_security_key"
|
"mfa_method_chooser"
|
"mfa_otp_secret_creation"
|
"mfa_security_key_creation"
|
"onboarding_create_passkey"
|
"onboarding_email"
|
"onboarding_username"
|
"onboarding_verify_passkey_attestation"
|
"passcode_confirmation"
|
"password_creation"
|
"preflight"
|
"profile_init"
|
"registration_init"
|
"success"
|
"thirdparty"
|
"webauthn_credential_verification"
# StateName
object
# UserMetadata
A user's custom metadata, split into a `public_metadata` portion (readable by any client) and an
`unsafe_metadata` portion (writable by any authenticated client).
Properties:
| Name | Type | Attributes | Description |
|---|---|---|---|
public_metadata |
PublicMetadata
|
<optional> |
Metadata visible to any client. |
unsafe_metadata |
UnsafeMetadata
|
<optional> |
Metadata that any authenticated client may write. |
public_metadata |
PublicMetadata
|
<optional> |
|
unsafe_metadata |
UnsafeMetadata
|
<optional> |