KeyWayProvider includes the complete email OTP flow. Your application opens it with login() or KeyWayLoginButton.
Login lifecycle
1
Send a one-time code
The SDK requests an OTP from the managed KeyWay API. Backend email credentials never enter the browser.
2
Create a KeyWay session
A valid code returns a KeyWay session tied to a stable backend user ID.
3
Recover the account
The user ID maps to the same Lit PKP and CKB address on future logins.
4
Start Fiber
With
autoConnect enabled, the SDK recovers the device’s Fiber identity and starts the browser node.Session state
The SDK stores the KeyWay session in browserlocalStorage and validates it when the provider mounts. Use ready before reading authentication state.
| Value | Meaning |
|---|---|
ready | Stored session validation has completed. |
authenticated | A valid KeyWay session exists. |
user.id | Stable backend identity for the email account. |
status | Current authentication or connection lifecycle state. |
Device behavior
Channel state belongs to the browser profile that opened the channel. KeyWay permits one active Fiber device lease per account and fails closed if another device takes the lease.Branding
appName changes the name shown in KeyWay’s modal. theme selects the built-in light or dark appearance.
appName does not currently change the email itself.