@softistx/janus 0.0.0-stage → 0.74.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +2929 -2
- package/dist/auth/api-keys/authenticate-key.d.ts +21 -0
- package/dist/auth/api-keys/authenticate-key.d.ts.map +1 -0
- package/dist/auth/api-keys/bound.d.ts +11 -0
- package/dist/auth/api-keys/bound.d.ts.map +1 -0
- package/dist/auth/api-keys/count.d.ts +8 -0
- package/dist/auth/api-keys/count.d.ts.map +1 -0
- package/dist/auth/api-keys/create/checks.d.ts +42 -0
- package/dist/auth/api-keys/create/checks.d.ts.map +1 -0
- package/dist/auth/api-keys/create/index.d.ts +10 -0
- package/dist/auth/api-keys/create/index.d.ts.map +1 -0
- package/dist/auth/api-keys/events.d.ts +22 -0
- package/dist/auth/api-keys/events.d.ts.map +1 -0
- package/dist/auth/api-keys/expiry.d.ts +11 -0
- package/dist/auth/api-keys/expiry.d.ts.map +1 -0
- package/dist/auth/api-keys/flows.d.ts +13 -0
- package/dist/auth/api-keys/flows.d.ts.map +1 -0
- package/dist/auth/api-keys/index.d.ts +11 -0
- package/dist/auth/api-keys/index.d.ts.map +1 -0
- package/dist/auth/api-keys/read.d.ts +10 -0
- package/dist/auth/api-keys/read.d.ts.map +1 -0
- package/dist/auth/api-keys/shape.d.ts +24 -0
- package/dist/auth/api-keys/shape.d.ts.map +1 -0
- package/dist/auth/api-keys/to-api-key.d.ts +8 -0
- package/dist/auth/api-keys/to-api-key.d.ts.map +1 -0
- package/dist/auth/api-keys/token.d.ts +23 -0
- package/dist/auth/api-keys/token.d.ts.map +1 -0
- package/dist/auth/api-keys/user-bound.d.ts +10 -0
- package/dist/auth/api-keys/user-bound.d.ts.map +1 -0
- package/dist/auth/at.d.ts +9 -0
- package/dist/auth/at.d.ts.map +1 -0
- package/dist/auth/avatar/any-type.d.ts +13 -0
- package/dist/auth/avatar/any-type.d.ts.map +1 -0
- package/dist/auth/avatar/flows.d.ts +7 -0
- package/dist/auth/avatar/flows.d.ts.map +1 -0
- package/dist/auth/avatar/id.d.ts +10 -0
- package/dist/auth/avatar/id.d.ts.map +1 -0
- package/dist/auth/avatar/index.d.ts +7 -0
- package/dist/auth/avatar/index.d.ts.map +1 -0
- package/dist/auth/avatar/remove.d.ts +10 -0
- package/dist/auth/avatar/remove.d.ts.map +1 -0
- package/dist/auth/avatar/set.d.ts +12 -0
- package/dist/auth/avatar/set.d.ts.map +1 -0
- package/dist/auth/concurrency-limit.d.ts +13 -0
- package/dist/auth/concurrency-limit.d.ts.map +1 -0
- package/dist/auth/config/api-keys-config.d.ts +33 -0
- package/dist/auth/config/api-keys-config.d.ts.map +1 -0
- package/dist/auth/config/hasher.d.ts +22 -0
- package/dist/auth/config/hasher.d.ts.map +1 -0
- package/dist/auth/config/index.d.ts +24 -0
- package/dist/auth/config/index.d.ts.map +1 -0
- package/dist/auth/config/invitations-config.d.ts +74 -0
- package/dist/auth/config/invitations-config.d.ts.map +1 -0
- package/dist/auth/config/janus-config.d.ts +233 -0
- package/dist/auth/config/janus-config.d.ts.map +1 -0
- package/dist/auth/config/magic-link-config.d.ts +6 -0
- package/dist/auth/config/magic-link-config.d.ts.map +1 -0
- package/dist/auth/config/names.d.ts +9 -0
- package/dist/auth/config/names.d.ts.map +1 -0
- package/dist/auth/config/normalize.d.ts +26 -0
- package/dist/auth/config/normalize.d.ts.map +1 -0
- package/dist/auth/config/passkeys-config.d.ts +49 -0
- package/dist/auth/config/passkeys-config.d.ts.map +1 -0
- package/dist/auth/config/password-config.d.ts +22 -0
- package/dist/auth/config/password-config.d.ts.map +1 -0
- package/dist/auth/config/reserved.d.ts +14 -0
- package/dist/auth/config/reserved.d.ts.map +1 -0
- package/dist/auth/config/resolve-api-keys.d.ts +5 -0
- package/dist/auth/config/resolve-api-keys.d.ts.map +1 -0
- package/dist/auth/config/resolve-config.d.ts +9 -0
- package/dist/auth/config/resolve-config.d.ts.map +1 -0
- package/dist/auth/config/resolve-cookie.d.ts +5 -0
- package/dist/auth/config/resolve-cookie.d.ts.map +1 -0
- package/dist/auth/config/resolve-devices.d.ts +5 -0
- package/dist/auth/config/resolve-devices.d.ts.map +1 -0
- package/dist/auth/config/resolve-invitation-types.d.ts +5 -0
- package/dist/auth/config/resolve-invitation-types.d.ts.map +1 -0
- package/dist/auth/config/resolve-invitations.d.ts +5 -0
- package/dist/auth/config/resolve-invitations.d.ts.map +1 -0
- package/dist/auth/config/resolve-magic-link.d.ts +4 -0
- package/dist/auth/config/resolve-magic-link.d.ts.map +1 -0
- package/dist/auth/config/resolve-passkeys.d.ts +5 -0
- package/dist/auth/config/resolve-passkeys.d.ts.map +1 -0
- package/dist/auth/config/resolve-second-factor.d.ts +5 -0
- package/dist/auth/config/resolve-second-factor.d.ts.map +1 -0
- package/dist/auth/config/resolve-social.d.ts +17 -0
- package/dist/auth/config/resolve-social.d.ts.map +1 -0
- package/dist/auth/config/resolve-throttle.d.ts +37 -0
- package/dist/auth/config/resolve-throttle.d.ts.map +1 -0
- package/dist/auth/config/resolve-type.d.ts +6 -0
- package/dist/auth/config/resolve-type.d.ts.map +1 -0
- package/dist/auth/config/resolved-config.d.ts +126 -0
- package/dist/auth/config/resolved-config.d.ts.map +1 -0
- package/dist/auth/config/social-config.d.ts +154 -0
- package/dist/auth/config/social-config.d.ts.map +1 -0
- package/dist/auth/config/user-type.d.ts +79 -0
- package/dist/auth/config/user-type.d.ts.map +1 -0
- package/dist/auth/config/warn-throttle-window.d.ts +14 -0
- package/dist/auth/config/warn-throttle-window.d.ts.map +1 -0
- package/dist/auth/context/create-context.d.ts +31 -0
- package/dist/auth/context/create-context.d.ts.map +1 -0
- package/dist/auth/context/index.d.ts +17 -0
- package/dist/auth/context/index.d.ts.map +1 -0
- package/dist/auth/context/logins.d.ts +28 -0
- package/dist/auth/context/logins.d.ts.map +1 -0
- package/dist/auth/context/password.d.ts +34 -0
- package/dist/auth/context/password.d.ts.map +1 -0
- package/dist/auth/context/records.d.ts +27 -0
- package/dist/auth/context/records.d.ts.map +1 -0
- package/dist/auth/context/user.d.ts +21 -0
- package/dist/auth/context/user.d.ts.map +1 -0
- package/dist/auth/context/validate-fields.d.ts +12 -0
- package/dist/auth/context/validate-fields.d.ts.map +1 -0
- package/dist/auth/counter-key.d.ts +20 -0
- package/dist/auth/counter-key.d.ts.map +1 -0
- package/dist/auth/derived-keys.d.ts +9 -0
- package/dist/auth/derived-keys.d.ts.map +1 -0
- package/dist/auth/devices/cookie.d.ts +56 -0
- package/dist/auth/devices/cookie.d.ts.map +1 -0
- package/dist/auth/devices/hint.d.ts +42 -0
- package/dist/auth/devices/hint.d.ts.map +1 -0
- package/dist/auth/devices/index.d.ts +11 -0
- package/dist/auth/devices/index.d.ts.map +1 -0
- package/dist/auth/devices/report.d.ts +11 -0
- package/dist/auth/devices/report.d.ts.map +1 -0
- package/dist/auth/devices/token.d.ts +13 -0
- package/dist/auth/devices/token.d.ts.map +1 -0
- package/dist/auth/email-flows/any-type-change-email.d.ts +18 -0
- package/dist/auth/email-flows/any-type-change-email.d.ts.map +1 -0
- package/dist/auth/email-flows/any-type-reset-password.d.ts +19 -0
- package/dist/auth/email-flows/any-type-reset-password.d.ts.map +1 -0
- package/dist/auth/email-flows/any-type-verify-email.d.ts +18 -0
- package/dist/auth/email-flows/any-type-verify-email.d.ts.map +1 -0
- package/dist/auth/email-flows/change-email-token.d.ts +47 -0
- package/dist/auth/email-flows/change-email-token.d.ts.map +1 -0
- package/dist/auth/email-flows/change-email.d.ts +17 -0
- package/dist/auth/email-flows/change-email.d.ts.map +1 -0
- package/dist/auth/email-flows/confirm-reset.d.ts +16 -0
- package/dist/auth/email-flows/confirm-reset.d.ts.map +1 -0
- package/dist/auth/email-flows/email-token.d.ts +30 -0
- package/dist/auth/email-flows/email-token.d.ts.map +1 -0
- package/dist/auth/email-flows/flows.d.ts +13 -0
- package/dist/auth/email-flows/flows.d.ts.map +1 -0
- package/dist/auth/email-flows/index.d.ts +10 -0
- package/dist/auth/email-flows/index.d.ts.map +1 -0
- package/dist/auth/email-flows/owner-of.d.ts +17 -0
- package/dist/auth/email-flows/owner-of.d.ts.map +1 -0
- package/dist/auth/email-flows/prove-first.d.ts +45 -0
- package/dist/auth/email-flows/prove-first.d.ts.map +1 -0
- package/dist/auth/email-flows/reset-password.d.ts +17 -0
- package/dist/auth/email-flows/reset-password.d.ts.map +1 -0
- package/dist/auth/email-flows/set-email-verified.d.ts +19 -0
- package/dist/auth/email-flows/set-email-verified.d.ts.map +1 -0
- package/dist/auth/email-flows/verify-email.d.ts +25 -0
- package/dist/auth/email-flows/verify-email.d.ts.map +1 -0
- package/dist/auth/email-sign-in.d.ts +51 -0
- package/dist/auth/email-sign-in.d.ts.map +1 -0
- package/dist/auth/events.d.ts +166 -0
- package/dist/auth/events.d.ts.map +1 -0
- package/dist/auth/first-proof.d.ts +43 -0
- package/dist/auth/first-proof.d.ts.map +1 -0
- package/dist/auth/hashers.d.ts +52 -0
- package/dist/auth/hashers.d.ts.map +1 -0
- package/dist/auth/index.d.ts +22 -0
- package/dist/auth/index.d.ts.map +1 -0
- package/dist/auth/invitations/accept.d.ts +10 -0
- package/dist/auth/invitations/accept.d.ts.map +1 -0
- package/dist/auth/invitations/change-pending.d.ts +17 -0
- package/dist/auth/invitations/change-pending.d.ts.map +1 -0
- package/dist/auth/invitations/claim.d.ts +31 -0
- package/dist/auth/invitations/claim.d.ts.map +1 -0
- package/dist/auth/invitations/events.d.ts +46 -0
- package/dist/auth/invitations/events.d.ts.map +1 -0
- package/dist/auth/invitations/find-invitee.d.ts +20 -0
- package/dist/auth/invitations/find-invitee.d.ts.map +1 -0
- package/dist/auth/invitations/find-pending.d.ts +5 -0
- package/dist/auth/invitations/find-pending.d.ts.map +1 -0
- package/dist/auth/invitations/flows.d.ts +7 -0
- package/dist/auth/invitations/flows.d.ts.map +1 -0
- package/dist/auth/invitations/history-input.d.ts +29 -0
- package/dist/auth/invitations/history-input.d.ts.map +1 -0
- package/dist/auth/invitations/history.d.ts +10 -0
- package/dist/auth/invitations/history.d.ts.map +1 -0
- package/dist/auth/invitations/index.d.ts +11 -0
- package/dist/auth/invitations/index.d.ts.map +1 -0
- package/dist/auth/invitations/input.d.ts +30 -0
- package/dist/auth/invitations/input.d.ts.map +1 -0
- package/dist/auth/invitations/invited-type.d.ts +22 -0
- package/dist/auth/invitations/invited-type.d.ts.map +1 -0
- package/dist/auth/invitations/invitee.d.ts +11 -0
- package/dist/auth/invitations/invitee.d.ts.map +1 -0
- package/dist/auth/invitations/issue.d.ts +9 -0
- package/dist/auth/invitations/issue.d.ts.map +1 -0
- package/dist/auth/invitations/limit.d.ts +7 -0
- package/dist/auth/invitations/limit.d.ts.map +1 -0
- package/dist/auth/invitations/password-invitee.d.ts +18 -0
- package/dist/auth/invitations/password-invitee.d.ts.map +1 -0
- package/dist/auth/invitations/passwordless-invitee.d.ts +13 -0
- package/dist/auth/invitations/passwordless-invitee.d.ts.map +1 -0
- package/dist/auth/invitations/preview.d.ts +8 -0
- package/dist/auth/invitations/preview.d.ts.map +1 -0
- package/dist/auth/invitations/read.d.ts +10 -0
- package/dist/auth/invitations/read.d.ts.map +1 -0
- package/dist/auth/invitations/resend.d.ts +12 -0
- package/dist/auth/invitations/resend.d.ts.map +1 -0
- package/dist/auth/invitations/to-invitation.d.ts +11 -0
- package/dist/auth/invitations/to-invitation.d.ts.map +1 -0
- package/dist/auth/invitations/write.d.ts +17 -0
- package/dist/auth/invitations/write.d.ts.map +1 -0
- package/dist/auth/issuers/cache.d.ts +21 -0
- package/dist/auth/issuers/cache.d.ts.map +1 -0
- package/dist/auth/issuers/create.d.ts +18 -0
- package/dist/auth/issuers/create.d.ts.map +1 -0
- package/dist/auth/issuers/index.d.ts +3 -0
- package/dist/auth/issuers/index.d.ts.map +1 -0
- package/dist/auth/issuers/types.d.ts +45 -0
- package/dist/auth/issuers/types.d.ts.map +1 -0
- package/dist/auth/janus.d.ts +39 -0
- package/dist/auth/janus.d.ts.map +1 -0
- package/dist/auth/magic-link.d.ts +25 -0
- package/dist/auth/magic-link.d.ts.map +1 -0
- package/dist/auth/mail-requests.d.ts +55 -0
- package/dist/auth/mail-requests.d.ts.map +1 -0
- package/dist/auth/one-time/codes.d.ts +46 -0
- package/dist/auth/one-time/codes.d.ts.map +1 -0
- package/dist/auth/one-time/index.d.ts +15 -0
- package/dist/auth/one-time/index.d.ts.map +1 -0
- package/dist/auth/one-time/issue.d.ts +45 -0
- package/dist/auth/one-time/issue.d.ts.map +1 -0
- package/dist/auth/one-time/refusals.d.ts +26 -0
- package/dist/auth/one-time/refusals.d.ts.map +1 -0
- package/dist/auth/one-time/spend.d.ts +24 -0
- package/dist/auth/one-time/spend.d.ts.map +1 -0
- package/dist/auth/one-time/window.d.ts +50 -0
- package/dist/auth/one-time/window.d.ts.map +1 -0
- package/dist/auth/outage.d.ts +66 -0
- package/dist/auth/outage.d.ts.map +1 -0
- package/dist/auth/parse-sealing-keys.d.ts +26 -0
- package/dist/auth/parse-sealing-keys.d.ts.map +1 -0
- package/dist/auth/passkeys/assert.d.ts +51 -0
- package/dist/auth/passkeys/assert.d.ts.map +1 -0
- package/dist/auth/passkeys/assertion-options.d.ts +9 -0
- package/dist/auth/passkeys/assertion-options.d.ts.map +1 -0
- package/dist/auth/passkeys/challenge.d.ts +19 -0
- package/dist/auth/passkeys/challenge.d.ts.map +1 -0
- package/dist/auth/passkeys/commit.d.ts +33 -0
- package/dist/auth/passkeys/commit.d.ts.map +1 -0
- package/dist/auth/passkeys/flows.d.ts +13 -0
- package/dist/auth/passkeys/flows.d.ts.map +1 -0
- package/dist/auth/passkeys/index.d.ts +12 -0
- package/dist/auth/passkeys/index.d.ts.map +1 -0
- package/dist/auth/passkeys/manage.d.ts +11 -0
- package/dist/auth/passkeys/manage.d.ts.map +1 -0
- package/dist/auth/passkeys/name.d.ts +4 -0
- package/dist/auth/passkeys/name.d.ts.map +1 -0
- package/dist/auth/passkeys/register.d.ts +20 -0
- package/dist/auth/passkeys/register.d.ts.map +1 -0
- package/dist/auth/passkeys/registration-options.d.ts +22 -0
- package/dist/auth/passkeys/registration-options.d.ts.map +1 -0
- package/dist/auth/passkeys/remove-all.d.ts +26 -0
- package/dist/auth/passkeys/remove-all.d.ts.map +1 -0
- package/dist/auth/passkeys/sign-in-options.d.ts +12 -0
- package/dist/auth/passkeys/sign-in-options.d.ts.map +1 -0
- package/dist/auth/passkeys/sign-in.d.ts +21 -0
- package/dist/auth/passkeys/sign-in.d.ts.map +1 -0
- package/dist/auth/passkeys/verifier.d.ts +113 -0
- package/dist/auth/passkeys/verifier.d.ts.map +1 -0
- package/dist/auth/passkeys/view.d.ts +5 -0
- package/dist/auth/passkeys/view.d.ts.map +1 -0
- package/dist/auth/passkeys/wiring.d.ts +24 -0
- package/dist/auth/passkeys/wiring.d.ts.map +1 -0
- package/dist/auth/password-written.d.ts +55 -0
- package/dist/auth/password-written.d.ts.map +1 -0
- package/dist/auth/port/assert-api-keys.d.ts +21 -0
- package/dist/auth/port/assert-api-keys.d.ts.map +1 -0
- package/dist/auth/port/assert-invitations.d.ts +15 -0
- package/dist/auth/port/assert-invitations.d.ts.map +1 -0
- package/dist/auth/port/assert-stores.d.ts +16 -0
- package/dist/auth/port/assert-stores.d.ts.map +1 -0
- package/dist/auth/port/memory/api-keys/capabilities.d.ts +8 -0
- package/dist/auth/port/memory/api-keys/capabilities.d.ts.map +1 -0
- package/dist/auth/port/memory/api-keys/index.d.ts +13 -0
- package/dist/auth/port/memory/api-keys/index.d.ts.map +1 -0
- package/dist/auth/port/memory/api-keys/pages.d.ts +7 -0
- package/dist/auth/port/memory/api-keys/pages.d.ts.map +1 -0
- package/dist/auth/port/memory/copy.d.ts +6 -0
- package/dist/auth/port/memory/copy.d.ts.map +1 -0
- package/dist/auth/port/memory/index.d.ts +10 -0
- package/dist/auth/port/memory/index.d.ts.map +1 -0
- package/dist/auth/port/memory/invitations-pending.d.ts +6 -0
- package/dist/auth/port/memory/invitations-pending.d.ts.map +1 -0
- package/dist/auth/port/memory/invitations.d.ts +12 -0
- package/dist/auth/port/memory/invitations.d.ts.map +1 -0
- package/dist/auth/port/memory/passkeys.d.ts +9 -0
- package/dist/auth/port/memory/passkeys.d.ts.map +1 -0
- package/dist/auth/port/memory/sessions.d.ts +4 -0
- package/dist/auth/port/memory/sessions.d.ts.map +1 -0
- package/dist/auth/port/memory/social-links.d.ts +10 -0
- package/dist/auth/port/memory/social-links.d.ts.map +1 -0
- package/dist/auth/port/memory/stores.d.ts +26 -0
- package/dist/auth/port/memory/stores.d.ts.map +1 -0
- package/dist/auth/port/memory/tokens.d.ts +4 -0
- package/dist/auth/port/memory/tokens.d.ts.map +1 -0
- package/dist/auth/port/memory/user-index.d.ts +20 -0
- package/dist/auth/port/memory/user-index.d.ts.map +1 -0
- package/dist/auth/port/memory/user-update.d.ts +10 -0
- package/dist/auth/port/memory/user-update.d.ts.map +1 -0
- package/dist/auth/port/memory/users.d.ts +4 -0
- package/dist/auth/port/memory/users.d.ts.map +1 -0
- package/dist/auth/port/types/api-keys.d.ts +199 -0
- package/dist/auth/port/types/api-keys.d.ts.map +1 -0
- package/dist/auth/port/types/credentials.d.ts +46 -0
- package/dist/auth/port/types/credentials.d.ts.map +1 -0
- package/dist/auth/port/types/index.d.ts +75 -0
- package/dist/auth/port/types/index.d.ts.map +1 -0
- package/dist/auth/port/types/invitations/index.d.ts +15 -0
- package/dist/auth/port/types/invitations/index.d.ts.map +1 -0
- package/dist/auth/port/types/invitations/page.d.ts +52 -0
- package/dist/auth/port/types/invitations/page.d.ts.map +1 -0
- package/dist/auth/port/types/invitations/records.d.ts +101 -0
- package/dist/auth/port/types/invitations/records.d.ts.map +1 -0
- package/dist/auth/port/types/invitations/store.d.ts +82 -0
- package/dist/auth/port/types/invitations/store.d.ts.map +1 -0
- package/dist/auth/port/types/json.d.ts +27 -0
- package/dist/auth/port/types/json.d.ts.map +1 -0
- package/dist/auth/port/types/passkeys.d.ts +94 -0
- package/dist/auth/port/types/passkeys.d.ts.map +1 -0
- package/dist/auth/port/types/sessions.d.ts +142 -0
- package/dist/auth/port/types/sessions.d.ts.map +1 -0
- package/dist/auth/port/types/social-links.d.ts +72 -0
- package/dist/auth/port/types/social-links.d.ts.map +1 -0
- package/dist/auth/port/types/stores.d.ts +48 -0
- package/dist/auth/port/types/stores.d.ts.map +1 -0
- package/dist/auth/port/types/tokens.d.ts +168 -0
- package/dist/auth/port/types/tokens.d.ts.map +1 -0
- package/dist/auth/port/types/users.d.ts +260 -0
- package/dist/auth/port/types/users.d.ts.map +1 -0
- package/dist/auth/prepared.d.ts +21 -0
- package/dist/auth/prepared.d.ts.map +1 -0
- package/dist/auth/proven-sign-in.d.ts +22 -0
- package/dist/auth/proven-sign-in.d.ts.map +1 -0
- package/dist/auth/sealer-for.d.ts +44 -0
- package/dist/auth/sealer-for.d.ts.map +1 -0
- package/dist/auth/sealing.d.ts +36 -0
- package/dist/auth/sealing.d.ts.map +1 -0
- package/dist/auth/second-factor/activate.d.ts +9 -0
- package/dist/auth/second-factor/activate.d.ts.map +1 -0
- package/dist/auth/second-factor/app-code-attempts.d.ts +47 -0
- package/dist/auth/second-factor/app-code-attempts.d.ts.map +1 -0
- package/dist/auth/second-factor/challenge.d.ts +15 -0
- package/dist/auth/second-factor/challenge.d.ts.map +1 -0
- package/dist/auth/second-factor/codes-left.d.ts +14 -0
- package/dist/auth/second-factor/codes-left.d.ts.map +1 -0
- package/dist/auth/second-factor/disable.d.ts +10 -0
- package/dist/auth/second-factor/disable.d.ts.map +1 -0
- package/dist/auth/second-factor/enroll.d.ts +6 -0
- package/dist/auth/second-factor/enroll.d.ts.map +1 -0
- package/dist/auth/second-factor/factor.d.ts +33 -0
- package/dist/auth/second-factor/factor.d.ts.map +1 -0
- package/dist/auth/second-factor/flows.d.ts +36 -0
- package/dist/auth/second-factor/flows.d.ts.map +1 -0
- package/dist/auth/second-factor/lifecycle.d.ts +14 -0
- package/dist/auth/second-factor/lifecycle.d.ts.map +1 -0
- package/dist/auth/second-factor/passkey-confirm.d.ts +21 -0
- package/dist/auth/second-factor/passkey-confirm.d.ts.map +1 -0
- package/dist/auth/second-factor/recovery-codes.d.ts +36 -0
- package/dist/auth/second-factor/recovery-codes.d.ts.map +1 -0
- package/dist/auth/second-factor/recovery.d.ts +20 -0
- package/dist/auth/second-factor/recovery.d.ts.map +1 -0
- package/dist/auth/second-factor/redeem.d.ts +42 -0
- package/dist/auth/second-factor/redeem.d.ts.map +1 -0
- package/dist/auth/second-factor/refusal.d.ts +6 -0
- package/dist/auth/second-factor/refusal.d.ts.map +1 -0
- package/dist/auth/second-factor/regenerate.d.ts +12 -0
- package/dist/auth/second-factor/regenerate.d.ts.map +1 -0
- package/dist/auth/second-factor/reseal.d.ts +17 -0
- package/dist/auth/second-factor/reseal.d.ts.map +1 -0
- package/dist/auth/second-factor/spend-recovery-code.d.ts +15 -0
- package/dist/auth/second-factor/spend-recovery-code.d.ts.map +1 -0
- package/dist/auth/secrets.d.ts +17 -0
- package/dist/auth/secrets.d.ts.map +1 -0
- package/dist/auth/sessions/amr.d.ts +36 -0
- package/dist/auth/sessions/amr.d.ts.map +1 -0
- package/dist/auth/sessions/authenticate.d.ts +12 -0
- package/dist/auth/sessions/authenticate.d.ts.map +1 -0
- package/dist/auth/sessions/collect-expired.d.ts +15 -0
- package/dist/auth/sessions/collect-expired.d.ts.map +1 -0
- package/dist/auth/sessions/cookie.d.ts +9 -0
- package/dist/auth/sessions/cookie.d.ts.map +1 -0
- package/dist/auth/sessions/fresh.d.ts +35 -0
- package/dist/auth/sessions/fresh.d.ts.map +1 -0
- package/dist/auth/sessions/index.d.ts +12 -0
- package/dist/auth/sessions/index.d.ts.map +1 -0
- package/dist/auth/sessions/open-session.d.ts +22 -0
- package/dist/auth/sessions/open-session.d.ts.map +1 -0
- package/dist/auth/sessions/presented-token.d.ts +25 -0
- package/dist/auth/sessions/presented-token.d.ts.map +1 -0
- package/dist/auth/sessions/shared-api.d.ts +17 -0
- package/dist/auth/sessions/shared-api.d.ts.map +1 -0
- package/dist/auth/sessions/standing.d.ts +32 -0
- package/dist/auth/sessions/standing.d.ts.map +1 -0
- package/dist/auth/shared-api.d.ts +142 -0
- package/dist/auth/shared-api.d.ts.map +1 -0
- package/dist/auth/sign-in-attempts.d.ts +45 -0
- package/dist/auth/sign-in-attempts.d.ts.map +1 -0
- package/dist/auth/sign-in-code.d.ts +26 -0
- package/dist/auth/sign-in-code.d.ts.map +1 -0
- package/dist/auth/social/attach.d.ts +31 -0
- package/dist/auth/social/attach.d.ts.map +1 -0
- package/dist/auth/social/begin.d.ts +30 -0
- package/dist/auth/social/begin.d.ts.map +1 -0
- package/dist/auth/social/complete-link.d.ts +17 -0
- package/dist/auth/social/complete-link.d.ts.map +1 -0
- package/dist/auth/social/complete.d.ts +54 -0
- package/dist/auth/social/complete.d.ts.map +1 -0
- package/dist/auth/social/cookie.d.ts +16 -0
- package/dist/auth/social/cookie.d.ts.map +1 -0
- package/dist/auth/social/find-provider.d.ts +23 -0
- package/dist/auth/social/find-provider.d.ts.map +1 -0
- package/dist/auth/social/finish.d.ts +60 -0
- package/dist/auth/social/finish.d.ts.map +1 -0
- package/dist/auth/social/flow-cookie-value.d.ts +26 -0
- package/dist/auth/social/flow-cookie-value.d.ts.map +1 -0
- package/dist/auth/social/flow-secret.d.ts +40 -0
- package/dist/auth/social/flow-secret.d.ts.map +1 -0
- package/dist/auth/social/index.d.ts +19 -0
- package/dist/auth/social/index.d.ts.map +1 -0
- package/dist/auth/social/link-holder.d.ts +33 -0
- package/dist/auth/social/link-holder.d.ts.map +1 -0
- package/dist/auth/social/provider-call.d.ts +31 -0
- package/dist/auth/social/provider-call.d.ts.map +1 -0
- package/dist/auth/social/redeem.d.ts +45 -0
- package/dist/auth/social/redeem.d.ts.map +1 -0
- package/dist/auth/social/return-to.d.ts +18 -0
- package/dist/auth/social/return-to.d.ts.map +1 -0
- package/dist/auth/social/sign-in.d.ts +41 -0
- package/dist/auth/social/sign-in.d.ts.map +1 -0
- package/dist/auth/social/sign-up.d.ts +37 -0
- package/dist/auth/social/sign-up.d.ts.map +1 -0
- package/dist/auth/social/start.d.ts +21 -0
- package/dist/auth/social/start.d.ts.map +1 -0
- package/dist/auth/social/step-up-proof.d.ts +26 -0
- package/dist/auth/social/step-up-proof.d.ts.map +1 -0
- package/dist/auth/social/step-up-request.d.ts +28 -0
- package/dist/auth/social/step-up-request.d.ts.map +1 -0
- package/dist/auth/social/step-up.d.ts +19 -0
- package/dist/auth/social/step-up.d.ts.map +1 -0
- package/dist/auth/social/types-of.d.ts +12 -0
- package/dist/auth/social/types-of.d.ts.map +1 -0
- package/dist/auth/social/unlink.d.ts +23 -0
- package/dist/auth/social/unlink.d.ts.map +1 -0
- package/dist/auth/social/wiring.d.ts +10 -0
- package/dist/auth/social/wiring.d.ts.map +1 -0
- package/dist/auth/standard-schema.d.ts +41 -0
- package/dist/auth/standard-schema.d.ts.map +1 -0
- package/dist/auth/step-up/codes.d.ts +35 -0
- package/dist/auth/step-up/codes.d.ts.map +1 -0
- package/dist/auth/step-up/flows.d.ts +18 -0
- package/dist/auth/step-up/flows.d.ts.map +1 -0
- package/dist/auth/step-up/open.d.ts +23 -0
- package/dist/auth/step-up/open.d.ts.map +1 -0
- package/dist/auth/step-up/passkey.d.ts +31 -0
- package/dist/auth/step-up/passkey.d.ts.map +1 -0
- package/dist/auth/step-up/request.d.ts +15 -0
- package/dist/auth/step-up/request.d.ts.map +1 -0
- package/dist/auth/step-up/spend.d.ts +4 -0
- package/dist/auth/step-up/spend.d.ts.map +1 -0
- package/dist/auth/totp.d.ts +36 -0
- package/dist/auth/totp.d.ts.map +1 -0
- package/dist/auth/types/api-keys-of.d.ts +19 -0
- package/dist/auth/types/api-keys-of.d.ts.map +1 -0
- package/dist/auth/types/api-keys.d.ts +164 -0
- package/dist/auth/types/api-keys.d.ts.map +1 -0
- package/dist/auth/types/avatar.d.ts +72 -0
- package/dist/auth/types/avatar.d.ts.map +1 -0
- package/dist/auth/types/change-email.d.ts +82 -0
- package/dist/auth/types/change-email.d.ts.map +1 -0
- package/dist/auth/types/checks.d.ts +147 -0
- package/dist/auth/types/checks.d.ts.map +1 -0
- package/dist/auth/types/email-flows.d.ts +117 -0
- package/dist/auth/types/email-flows.d.ts.map +1 -0
- package/dist/auth/types/find-by-email.d.ts +31 -0
- package/dist/auth/types/find-by-email.d.ts.map +1 -0
- package/dist/auth/types/find-or-create.d.ts +59 -0
- package/dist/auth/types/find-or-create.d.ts.map +1 -0
- package/dist/auth/types/index.d.ts +38 -0
- package/dist/auth/types/index.d.ts.map +1 -0
- package/dist/auth/types/inference.d.ts +62 -0
- package/dist/auth/types/inference.d.ts.map +1 -0
- package/dist/auth/types/invitations/api.d.ts +203 -0
- package/dist/auth/types/invitations/api.d.ts.map +1 -0
- package/dist/auth/types/invitations/history.d.ts +87 -0
- package/dist/auth/types/invitations/history.d.ts.map +1 -0
- package/dist/auth/types/invitations/index.d.ts +10 -0
- package/dist/auth/types/invitations/index.d.ts.map +1 -0
- package/dist/auth/types/invitations/invitation.d.ts +76 -0
- package/dist/auth/types/invitations/invitation.d.ts.map +1 -0
- package/dist/auth/types/invitations/issue-type.d.ts +15 -0
- package/dist/auth/types/invitations/issue-type.d.ts.map +1 -0
- package/dist/auth/types/invitations-of.d.ts +26 -0
- package/dist/auth/types/invitations-of.d.ts.map +1 -0
- package/dist/auth/types/janus.d.ts +51 -0
- package/dist/auth/types/janus.d.ts.map +1 -0
- package/dist/auth/types/magic-link.d.ts +69 -0
- package/dist/auth/types/magic-link.d.ts.map +1 -0
- package/dist/auth/types/passkeys.d.ts +183 -0
- package/dist/auth/types/passkeys.d.ts.map +1 -0
- package/dist/auth/types/password.d.ts +113 -0
- package/dist/auth/types/password.d.ts.map +1 -0
- package/dist/auth/types/prepared.d.ts +68 -0
- package/dist/auth/types/prepared.d.ts.map +1 -0
- package/dist/auth/types/proven-sign-in.d.ts +43 -0
- package/dist/auth/types/proven-sign-in.d.ts.map +1 -0
- package/dist/auth/types/reset-password.d.ts +46 -0
- package/dist/auth/types/reset-password.d.ts.map +1 -0
- package/dist/auth/types/second-factor.d.ts +164 -0
- package/dist/auth/types/second-factor.d.ts.map +1 -0
- package/dist/auth/types/session.d.ts +68 -0
- package/dist/auth/types/session.d.ts.map +1 -0
- package/dist/auth/types/shared-api.d.ts +96 -0
- package/dist/auth/types/shared-api.d.ts.map +1 -0
- package/dist/auth/types/sign-in.d.ts +102 -0
- package/dist/auth/types/sign-in.d.ts.map +1 -0
- package/dist/auth/types/social-flow.d.ts +28 -0
- package/dist/auth/types/social-flow.d.ts.map +1 -0
- package/dist/auth/types/social-step-up.d.ts +38 -0
- package/dist/auth/types/social-step-up.d.ts.map +1 -0
- package/dist/auth/types/social.d.ts +201 -0
- package/dist/auth/types/social.d.ts.map +1 -0
- package/dist/auth/types/step-up.d.ts +133 -0
- package/dist/auth/types/step-up.d.ts.map +1 -0
- package/dist/auth/types/type-api.d.ts +29 -0
- package/dist/auth/types/type-api.d.ts.map +1 -0
- package/dist/auth/types/user-type.d.ts +106 -0
- package/dist/auth/types/user-type.d.ts.map +1 -0
- package/dist/auth/types/user.d.ts +62 -0
- package/dist/auth/types/user.d.ts.map +1 -0
- package/dist/auth/types/verify-email.d.ts +190 -0
- package/dist/auth/types/verify-email.d.ts.map +1 -0
- package/dist/auth/users/any-type-api.d.ts +6 -0
- package/dist/auth/users/any-type-api.d.ts.map +1 -0
- package/dist/auth/users/by-login.d.ts +10 -0
- package/dist/auth/users/by-login.d.ts.map +1 -0
- package/dist/auth/users/change-password.d.ts +26 -0
- package/dist/auth/users/change-password.d.ts.map +1 -0
- package/dist/auth/users/delete.d.ts +10 -0
- package/dist/auth/users/delete.d.ts.map +1 -0
- package/dist/auth/users/email-move-guard.d.ts +20 -0
- package/dist/auth/users/email-move-guard.d.ts.map +1 -0
- package/dist/auth/users/email-prefix.d.ts +23 -0
- package/dist/auth/users/email-prefix.d.ts.map +1 -0
- package/dist/auth/users/fields-patch.d.ts +21 -0
- package/dist/auth/users/fields-patch.d.ts.map +1 -0
- package/dist/auth/users/find-by-email.d.ts +11 -0
- package/dist/auth/users/find-by-email.d.ts.map +1 -0
- package/dist/auth/users/find-many.d.ts +29 -0
- package/dist/auth/users/find-many.d.ts.map +1 -0
- package/dist/auth/users/find-or-create.d.ts +12 -0
- package/dist/auth/users/find-or-create.d.ts.map +1 -0
- package/dist/auth/users/flow-types.d.ts +15 -0
- package/dist/auth/users/flow-types.d.ts.map +1 -0
- package/dist/auth/users/index.d.ts +9 -0
- package/dist/auth/users/index.d.ts.map +1 -0
- package/dist/auth/users/insert.d.ts +15 -0
- package/dist/auth/users/insert.d.ts.map +1 -0
- package/dist/auth/users/name-prefix.d.ts +19 -0
- package/dist/auth/users/name-prefix.d.ts.map +1 -0
- package/dist/auth/users/password-flows.d.ts +11 -0
- package/dist/auth/users/password-flows.d.ts.map +1 -0
- package/dist/auth/users/record-flows.d.ts +11 -0
- package/dist/auth/users/record-flows.d.ts.map +1 -0
- package/dist/auth/users/sign-in.d.ts +24 -0
- package/dist/auth/users/sign-in.d.ts.map +1 -0
- package/dist/auth/users/sign-up.d.ts +13 -0
- package/dist/auth/users/sign-up.d.ts.map +1 -0
- package/dist/auth/users/type-api.d.ts +10 -0
- package/dist/auth/users/type-api.d.ts.map +1 -0
- package/dist/auth/users/update.d.ts +16 -0
- package/dist/auth/users/update.d.ts.map +1 -0
- package/dist/background/background.d.ts +22 -0
- package/dist/background/background.d.ts.map +1 -0
- package/dist/chunks/index-2ttdcz7n.js +354 -0
- package/dist/chunks/index-2ttdcz7n.js.map +16 -0
- package/dist/chunks/index-5dxynm32.js +85 -0
- package/dist/chunks/index-5dxynm32.js.map +10 -0
- package/dist/chunks/index-7h34nqrm.js +732 -0
- package/dist/chunks/index-7h34nqrm.js.map +24 -0
- package/dist/chunks/index-ftz0ne6j.js +127 -0
- package/dist/chunks/index-ftz0ne6j.js.map +11 -0
- package/dist/chunks/index-n8jxmxeg.js +64 -0
- package/dist/chunks/index-n8jxmxeg.js.map +11 -0
- package/dist/conformance/api-keys/cases/bound.d.ts +3 -0
- package/dist/conformance/api-keys/cases/bound.d.ts.map +1 -0
- package/dist/conformance/api-keys/cases/expiry.d.ts +3 -0
- package/dist/conformance/api-keys/cases/expiry.d.ts.map +1 -0
- package/dist/conformance/api-keys/cases/index.d.ts +4 -0
- package/dist/conformance/api-keys/cases/index.d.ts.map +1 -0
- package/dist/conformance/api-keys/cases/insert.d.ts +3 -0
- package/dist/conformance/api-keys/cases/insert.d.ts.map +1 -0
- package/dist/conformance/api-keys/cases/outage.d.ts +3 -0
- package/dist/conformance/api-keys/cases/outage.d.ts.map +1 -0
- package/dist/conformance/api-keys/cases/revoke.d.ts +3 -0
- package/dist/conformance/api-keys/cases/revoke.d.ts.map +1 -0
- package/dist/conformance/api-keys/cases/touch.d.ts +3 -0
- package/dist/conformance/api-keys/cases/touch.d.ts.map +1 -0
- package/dist/conformance/api-keys/cases/user-bound.d.ts +3 -0
- package/dist/conformance/api-keys/cases/user-bound.d.ts.map +1 -0
- package/dist/conformance/api-keys/describe.d.ts +20 -0
- package/dist/conformance/api-keys/describe.d.ts.map +1 -0
- package/dist/conformance/api-keys/fixtures.d.ts +4 -0
- package/dist/conformance/api-keys/fixtures.d.ts.map +1 -0
- package/dist/conformance/api-keys/index.d.ts +18 -0
- package/dist/conformance/api-keys/index.d.ts.map +1 -0
- package/dist/conformance/api-keys/reference.d.ts +4 -0
- package/dist/conformance/api-keys/reference.d.ts.map +1 -0
- package/dist/conformance/api-keys/types.d.ts +42 -0
- package/dist/conformance/api-keys/types.d.ts.map +1 -0
- package/dist/conformance/assert.d.ts +40 -0
- package/dist/conformance/assert.d.ts.map +1 -0
- package/dist/conformance/cases/outage.d.ts +3 -0
- package/dist/conformance/cases/outage.d.ts.map +1 -0
- package/dist/conformance/cases/outage.passkeys.d.ts +12 -0
- package/dist/conformance/cases/outage.passkeys.d.ts.map +1 -0
- package/dist/conformance/cases/passkeys/deletion.d.ts +4 -0
- package/dist/conformance/cases/passkeys/deletion.d.ts.map +1 -0
- package/dist/conformance/cases/passkeys/index.d.ts +8 -0
- package/dist/conformance/cases/passkeys/index.d.ts.map +1 -0
- package/dist/conformance/cases/passkeys/inserts.d.ts +4 -0
- package/dist/conformance/cases/passkeys/inserts.d.ts.map +1 -0
- package/dist/conformance/cases/passkeys/reads.d.ts +4 -0
- package/dist/conformance/cases/passkeys/reads.d.ts.map +1 -0
- package/dist/conformance/cases/passkeys/uses.d.ts +4 -0
- package/dist/conformance/cases/passkeys/uses.d.ts.map +1 -0
- package/dist/conformance/cases/sessions/deletion.d.ts +4 -0
- package/dist/conformance/cases/sessions/deletion.d.ts.map +1 -0
- package/dist/conformance/cases/sessions/extension.d.ts +4 -0
- package/dist/conformance/cases/sessions/extension.d.ts.map +1 -0
- package/dist/conformance/cases/sessions/index.d.ts +4 -0
- package/dist/conformance/cases/sessions/index.d.ts.map +1 -0
- package/dist/conformance/cases/sessions/inserts.d.ts +4 -0
- package/dist/conformance/cases/sessions/inserts.d.ts.map +1 -0
- package/dist/conformance/cases/sessions/list.d.ts +4 -0
- package/dist/conformance/cases/sessions/list.d.ts.map +1 -0
- package/dist/conformance/cases/sessions/reads.d.ts +4 -0
- package/dist/conformance/cases/sessions/reads.d.ts.map +1 -0
- package/dist/conformance/cases/sessions/reauthentication.d.ts +4 -0
- package/dist/conformance/cases/sessions/reauthentication.d.ts.map +1 -0
- package/dist/conformance/cases/sessions/revocation.d.ts +4 -0
- package/dist/conformance/cases/sessions/revocation.d.ts.map +1 -0
- package/dist/conformance/cases/social-links/deletion.d.ts +4 -0
- package/dist/conformance/cases/social-links/deletion.d.ts.map +1 -0
- package/dist/conformance/cases/social-links/index.d.ts +8 -0
- package/dist/conformance/cases/social-links/index.d.ts.map +1 -0
- package/dist/conformance/cases/social-links/inserts.d.ts +4 -0
- package/dist/conformance/cases/social-links/inserts.d.ts.map +1 -0
- package/dist/conformance/cases/social-links/reads.d.ts +4 -0
- package/dist/conformance/cases/social-links/reads.d.ts.map +1 -0
- package/dist/conformance/cases/tokens/attempts.d.ts +7 -0
- package/dist/conformance/cases/tokens/attempts.d.ts.map +1 -0
- package/dist/conformance/cases/tokens/change-email.d.ts +8 -0
- package/dist/conformance/cases/tokens/change-email.d.ts.map +1 -0
- package/dist/conformance/cases/tokens/deletion.d.ts +4 -0
- package/dist/conformance/cases/tokens/deletion.d.ts.map +1 -0
- package/dist/conformance/cases/tokens/index.d.ts +4 -0
- package/dist/conformance/cases/tokens/index.d.ts.map +1 -0
- package/dist/conformance/cases/tokens/inserts.d.ts +7 -0
- package/dist/conformance/cases/tokens/inserts.d.ts.map +1 -0
- package/dist/conformance/cases/tokens/kinds.d.ts +7 -0
- package/dist/conformance/cases/tokens/kinds.d.ts.map +1 -0
- package/dist/conformance/cases/tokens/redemption.d.ts +7 -0
- package/dist/conformance/cases/tokens/redemption.d.ts.map +1 -0
- package/dist/conformance/cases/tokens/social-flow.d.ts +8 -0
- package/dist/conformance/cases/tokens/social-flow.d.ts.map +1 -0
- package/dist/conformance/cases/tokens/spending.d.ts +7 -0
- package/dist/conformance/cases/tokens/spending.d.ts.map +1 -0
- package/dist/conformance/cases/users/avatar.d.ts +8 -0
- package/dist/conformance/cases/users/avatar.d.ts.map +1 -0
- package/dist/conformance/cases/users/batch.d.ts +8 -0
- package/dist/conformance/cases/users/batch.d.ts.map +1 -0
- package/dist/conformance/cases/users/deletion.d.ts +4 -0
- package/dist/conformance/cases/users/deletion.d.ts.map +1 -0
- package/dist/conformance/cases/users/index.d.ts +4 -0
- package/dist/conformance/cases/users/index.d.ts.map +1 -0
- package/dist/conformance/cases/users/inserts.d.ts +4 -0
- package/dist/conformance/cases/users/inserts.d.ts.map +1 -0
- package/dist/conformance/cases/users/listing.d.ts +4 -0
- package/dist/conformance/cases/users/listing.d.ts.map +1 -0
- package/dist/conformance/cases/users/patches.d.ts +7 -0
- package/dist/conformance/cases/users/patches.d.ts.map +1 -0
- package/dist/conformance/cases/users/reads.d.ts +7 -0
- package/dist/conformance/cases/users/reads.d.ts.map +1 -0
- package/dist/conformance/cases/users/second-factor.d.ts +16 -0
- package/dist/conformance/cases/users/second-factor.d.ts.map +1 -0
- package/dist/conformance/cases/users/versions.d.ts +7 -0
- package/dist/conformance/cases/users/versions.d.ts.map +1 -0
- package/dist/conformance/describe.d.ts +82 -0
- package/dist/conformance/describe.d.ts.map +1 -0
- package/dist/conformance/fixtures.d.ts +31 -0
- package/dist/conformance/fixtures.d.ts.map +1 -0
- package/dist/conformance/index.d.ts +46 -0
- package/dist/conformance/index.d.ts.map +1 -0
- package/dist/conformance/index.js +4442 -0
- package/dist/conformance/index.js.map +86 -0
- package/dist/conformance/invitations/cases/actors.d.ts +3 -0
- package/dist/conformance/invitations/cases/actors.d.ts.map +1 -0
- package/dist/conformance/invitations/cases/find-pending.d.ts +3 -0
- package/dist/conformance/invitations/cases/find-pending.d.ts.map +1 -0
- package/dist/conformance/invitations/cases/imported.d.ts +3 -0
- package/dist/conformance/invitations/cases/imported.d.ts.map +1 -0
- package/dist/conformance/invitations/cases/index.d.ts +4 -0
- package/dist/conformance/invitations/cases/index.d.ts.map +1 -0
- package/dist/conformance/invitations/cases/insert.d.ts +3 -0
- package/dist/conformance/invitations/cases/insert.d.ts.map +1 -0
- package/dist/conformance/invitations/cases/list-lapsed.d.ts +3 -0
- package/dist/conformance/invitations/cases/list-lapsed.d.ts.map +1 -0
- package/dist/conformance/invitations/cases/list-status.d.ts +3 -0
- package/dist/conformance/invitations/cases/list-status.d.ts.map +1 -0
- package/dist/conformance/invitations/cases/list.d.ts +3 -0
- package/dist/conformance/invitations/cases/list.d.ts.map +1 -0
- package/dist/conformance/invitations/cases/outage.d.ts +3 -0
- package/dist/conformance/invitations/cases/outage.d.ts.map +1 -0
- package/dist/conformance/invitations/cases/scope.d.ts +3 -0
- package/dist/conformance/invitations/cases/scope.d.ts.map +1 -0
- package/dist/conformance/invitations/cases/update.d.ts +3 -0
- package/dist/conformance/invitations/cases/update.d.ts.map +1 -0
- package/dist/conformance/invitations/describe.d.ts +20 -0
- package/dist/conformance/invitations/describe.d.ts.map +1 -0
- package/dist/conformance/invitations/fixtures.d.ts +4 -0
- package/dist/conformance/invitations/fixtures.d.ts.map +1 -0
- package/dist/conformance/invitations/index.d.ts +18 -0
- package/dist/conformance/invitations/index.d.ts.map +1 -0
- package/dist/conformance/invitations/reference.d.ts +4 -0
- package/dist/conformance/invitations/reference.d.ts.map +1 -0
- package/dist/conformance/invitations/types.d.ts +34 -0
- package/dist/conformance/invitations/types.d.ts.map +1 -0
- package/dist/conformance/reference.d.ts +13 -0
- package/dist/conformance/reference.d.ts.map +1 -0
- package/dist/conformance/relations/cases/deletion.d.ts +4 -0
- package/dist/conformance/relations/cases/deletion.d.ts.map +1 -0
- package/dist/conformance/relations/cases/holders.d.ts +9 -0
- package/dist/conformance/relations/cases/holders.d.ts.map +1 -0
- package/dist/conformance/relations/cases/index.d.ts +4 -0
- package/dist/conformance/relations/cases/index.d.ts.map +1 -0
- package/dist/conformance/relations/cases/outage.d.ts +3 -0
- package/dist/conformance/relations/cases/outage.d.ts.map +1 -0
- package/dist/conformance/relations/cases/reads.d.ts +8 -0
- package/dist/conformance/relations/cases/reads.d.ts.map +1 -0
- package/dist/conformance/relations/cases/traversal.d.ts +7 -0
- package/dist/conformance/relations/cases/traversal.d.ts.map +1 -0
- package/dist/conformance/relations/cases/writes.d.ts +4 -0
- package/dist/conformance/relations/cases/writes.d.ts.map +1 -0
- package/dist/conformance/relations/describe.d.ts +20 -0
- package/dist/conformance/relations/describe.d.ts.map +1 -0
- package/dist/conformance/relations/fixtures.d.ts +8 -0
- package/dist/conformance/relations/fixtures.d.ts.map +1 -0
- package/dist/conformance/relations/index.d.ts +18 -0
- package/dist/conformance/relations/index.d.ts.map +1 -0
- package/dist/conformance/relations/reference.d.ts +4 -0
- package/dist/conformance/relations/reference.d.ts.map +1 -0
- package/dist/conformance/relations/types.d.ts +34 -0
- package/dist/conformance/relations/types.d.ts.map +1 -0
- package/dist/conformance/types.d.ts +79 -0
- package/dist/conformance/types.d.ts.map +1 -0
- package/dist/errors/janus-error/base.d.ts +47 -0
- package/dist/errors/janus-error/base.d.ts.map +1 -0
- package/dist/errors/janus-error/codes.credentials.d.ts +36 -0
- package/dist/errors/janus-error/codes.credentials.d.ts.map +1 -0
- package/dist/errors/janus-error/codes.d.ts +23 -0
- package/dist/errors/janus-error/codes.d.ts.map +1 -0
- package/dist/errors/janus-error/codes.invitations.d.ts +52 -0
- package/dist/errors/janus-error/codes.invitations.d.ts.map +1 -0
- package/dist/errors/janus-error/codes.one-time.d.ts +63 -0
- package/dist/errors/janus-error/codes.one-time.d.ts.map +1 -0
- package/dist/errors/janus-error/codes.records.d.ts +86 -0
- package/dist/errors/janus-error/codes.records.d.ts.map +1 -0
- package/dist/errors/janus-error/codes.social.d.ts +88 -0
- package/dist/errors/janus-error/codes.social.d.ts.map +1 -0
- package/dist/errors/janus-error/index.d.ts +17 -0
- package/dist/errors/janus-error/index.d.ts.map +1 -0
- package/dist/errors/janus-error/options.d.ts +105 -0
- package/dist/errors/janus-error/options.d.ts.map +1 -0
- package/dist/errors/janus-error/refusals.d.ts +151 -0
- package/dist/errors/janus-error/refusals.d.ts.map +1 -0
- package/dist/errors/janus-error/status.d.ts +21 -0
- package/dist/errors/janus-error/status.d.ts.map +1 -0
- package/dist/errors/janus-error/store.d.ts +36 -0
- package/dist/errors/janus-error/store.d.ts.map +1 -0
- package/dist/ids/derived.d.ts +25 -0
- package/dist/ids/derived.d.ts.map +1 -0
- package/dist/ids/id.d.ts +55 -0
- package/dist/ids/id.d.ts.map +1 -0
- package/dist/index.d.ts +32 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +6948 -0
- package/dist/index.js.map +208 -0
- package/dist/pagination/cursor-page.d.ts +53 -0
- package/dist/pagination/cursor-page.d.ts.map +1 -0
- package/dist/permissions/bound-model.d.ts +10 -0
- package/dist/permissions/bound-model.d.ts.map +1 -0
- package/dist/permissions/can.d.ts +13 -0
- package/dist/permissions/can.d.ts.map +1 -0
- package/dist/permissions/engine.d.ts +49 -0
- package/dist/permissions/engine.d.ts.map +1 -0
- package/dist/permissions/holders.d.ts +12 -0
- package/dist/permissions/holders.d.ts.map +1 -0
- package/dist/permissions/index.d.ts +36 -0
- package/dist/permissions/index.d.ts.map +1 -0
- package/dist/permissions/index.js +924 -0
- package/dist/permissions/index.js.map +28 -0
- package/dist/permissions/input.d.ts +43 -0
- package/dist/permissions/input.d.ts.map +1 -0
- package/dist/permissions/list.d.ts +16 -0
- package/dist/permissions/list.d.ts.map +1 -0
- package/dist/permissions/model/can.d.ts +41 -0
- package/dist/permissions/model/can.d.ts.map +1 -0
- package/dist/permissions/model/config.d.ts +36 -0
- package/dist/permissions/model/config.d.ts.map +1 -0
- package/dist/permissions/model/constraint.d.ts +37 -0
- package/dist/permissions/model/constraint.d.ts.map +1 -0
- package/dist/permissions/model/ctx.d.ts +23 -0
- package/dist/permissions/model/ctx.d.ts.map +1 -0
- package/dist/permissions/model/define.d.ts +78 -0
- package/dist/permissions/model/define.d.ts.map +1 -0
- package/dist/permissions/model/from-field.d.ts +31 -0
- package/dist/permissions/model/from-field.d.ts.map +1 -0
- package/dist/permissions/model/grant.d.ts +81 -0
- package/dist/permissions/model/grant.d.ts.map +1 -0
- package/dist/permissions/model/list.d.ts +48 -0
- package/dist/permissions/model/list.d.ts.map +1 -0
- package/dist/permissions/model/names.d.ts +51 -0
- package/dist/permissions/model/names.d.ts.map +1 -0
- package/dist/permissions/model/permissions.d.ts +48 -0
- package/dist/permissions/model/permissions.d.ts.map +1 -0
- package/dist/permissions/model/refs.d.ts +36 -0
- package/dist/permissions/model/refs.d.ts.map +1 -0
- package/dist/permissions/model/refusal.d.ts +13 -0
- package/dist/permissions/model/refusal.d.ts.map +1 -0
- package/dist/permissions/model/unions.d.ts +3 -0
- package/dist/permissions/model/unions.d.ts.map +1 -0
- package/dist/permissions/model/when.d.ts +16 -0
- package/dist/permissions/model/when.d.ts.map +1 -0
- package/dist/permissions/port/holders.d.ts +38 -0
- package/dist/permissions/port/holders.d.ts.map +1 -0
- package/dist/permissions/port/memory.d.ts +17 -0
- package/dist/permissions/port/memory.d.ts.map +1 -0
- package/dist/permissions/port/types.d.ts +101 -0
- package/dist/permissions/port/types.d.ts.map +1 -0
- package/dist/permissions/replace.d.ts +25 -0
- package/dist/permissions/replace.d.ts.map +1 -0
- package/dist/permissions/resolve/declared-names.d.ts +24 -0
- package/dist/permissions/resolve/declared-names.d.ts.map +1 -0
- package/dist/permissions/resolve/refuse-data-beyond-root.d.ts +11 -0
- package/dist/permissions/resolve/refuse-data-beyond-root.d.ts.map +1 -0
- package/dist/permissions/resolve/refuse-loops.d.ts +10 -0
- package/dist/permissions/resolve/refuse-loops.d.ts.map +1 -0
- package/dist/permissions/resolve/resolve-model.d.ts +13 -0
- package/dist/permissions/resolve/resolve-model.d.ts.map +1 -0
- package/dist/permissions/resolve/resolve-relation.d.ts +9 -0
- package/dist/permissions/resolve/resolve-relation.d.ts.map +1 -0
- package/dist/permissions/resolve/resolve-rule.d.ts +12 -0
- package/dist/permissions/resolve/resolve-rule.d.ts.map +1 -0
- package/dist/permissions/resolve/resolved.d.ts +52 -0
- package/dist/permissions/resolve/resolved.d.ts.map +1 -0
- package/dist/permissions/resolve/step.d.ts +4 -0
- package/dist/permissions/resolve/step.d.ts.map +1 -0
- package/dist/permissions/reverse.d.ts +53 -0
- package/dist/permissions/reverse.d.ts.map +1 -0
- package/dist/permissions/walk.d.ts +29 -0
- package/dist/permissions/walk.d.ts.map +1 -0
- package/dist/stores/guard.d.ts +24 -0
- package/dist/stores/guard.d.ts.map +1 -0
- package/dist/stores/storable.d.ts +15 -0
- package/dist/stores/storable.d.ts.map +1 -0
- package/dist/subjects/notation.d.ts +39 -0
- package/dist/subjects/notation.d.ts.map +1 -0
- package/dist/subjects/subject.d.ts +128 -0
- package/dist/subjects/subject.d.ts.map +1 -0
- package/dist/testing/index.d.ts +12 -0
- package/dist/testing/index.d.ts.map +1 -0
- package/dist/testing/index.js +26 -0
- package/dist/testing/index.js.map +10 -0
- package/dist/time/clock.d.ts +31 -0
- package/dist/time/clock.d.ts.map +1 -0
- package/dist/time/duration.d.ts +23 -0
- package/dist/time/duration.d.ts.map +1 -0
- package/docs/README.md +46 -0
- package/docs/guide/adapters.md +861 -0
- package/docs/guide/api-keys.md +316 -0
- package/docs/guide/avatars.md +334 -0
- package/docs/guide/devices.md +441 -0
- package/docs/guide/email-flows.md +880 -0
- package/docs/guide/errors.md +180 -0
- package/docs/guide/events.md +467 -0
- package/docs/guide/invitations.md +465 -0
- package/docs/guide/issuers.md +107 -0
- package/docs/guide/magic-link.md +580 -0
- package/docs/guide/migrating-invitations.md +142 -0
- package/docs/guide/passkeys.md +425 -0
- package/docs/guide/passwords.md +325 -0
- package/docs/guide/permissions.md +719 -0
- package/docs/guide/second-factor.md +1124 -0
- package/docs/guide/sessions.md +521 -0
- package/docs/guide/sign-in-code.md +631 -0
- package/docs/guide/social.md +648 -0
- package/docs/guide/step-up.md +262 -0
- package/docs/guide/users.md +557 -0
- package/docs/guide/vocabulary.md +316 -0
- package/docs/roadmap.md +102 -0
- package/docs/troubleshooting.md +3318 -0
- package/package.json +77 -5
|
@@ -0,0 +1,580 @@
|
|
|
1
|
+
# Signing in with an e-mailed link
|
|
2
|
+
|
|
3
|
+
This page is for signing a user in with a link sent to their e-mail — a
|
|
4
|
+
"magic link": no password, nothing to type, and the link proves the address.
|
|
5
|
+
`janus` issues and redeems the link's token; **building the link, sending the
|
|
6
|
+
e-mail and the page it opens are yours**.
|
|
7
|
+
|
|
8
|
+
```ts
|
|
9
|
+
import { z } from 'zod';
|
|
10
|
+
import { createMemoryStores, janus, scryptHasher } from '@softistx/janus';
|
|
11
|
+
|
|
12
|
+
async function sendMail(to: string, subject: string, text: string): Promise<void> {
|
|
13
|
+
// your mailer
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
const auth = janus({
|
|
17
|
+
user: z.object({ email: z.email() }),
|
|
18
|
+
password: { login: 'email' },
|
|
19
|
+
store: createMemoryStores(),
|
|
20
|
+
hasher: scryptHasher(),
|
|
21
|
+
});
|
|
22
|
+
|
|
23
|
+
const issued = await auth.magicLink.request('ada@example.com'); // { token, email, expiresAt, user } | null
|
|
24
|
+
if (issued !== null) {
|
|
25
|
+
const link = `https://app.example/sign-in/link?token=${issued.token}`;
|
|
26
|
+
await sendMail(issued.email, 'Your sign-in link', `${link}\nIt expires in 15 minutes.`);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
// the link opens a page of yours, whose button POSTs the token back:
|
|
30
|
+
const signedIn = await auth.magicLink.confirm(token);
|
|
31
|
+
signedIn.token; // a session, as signIn opens one
|
|
32
|
+
signedIn.user.emailVerified; // true: the link reached the inbox
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
It is the [sign-in code](sign-in-code.md) with the code folded into a link:
|
|
36
|
+
the same users have it, the same refusals, the same second factor. What
|
|
37
|
+
differs is what a link is — something anybody holding the e-mail can open,
|
|
38
|
+
on any device, **and that a mail scanner opens too**. The words — **sign-in
|
|
39
|
+
link**, **one-time token**, **spent**, **issued** — are defined in
|
|
40
|
+
[the vocabulary](vocabulary.md#identities).
|
|
41
|
+
|
|
42
|
+
## Which types have it
|
|
43
|
+
|
|
44
|
+
`magicLink` exists on every user type with an e-mail — the field `email`
|
|
45
|
+
names, or a required string field called `email` — **with or without a
|
|
46
|
+
password**, exactly as `signInCode` does. A type with no e-mail has no
|
|
47
|
+
`magicLink`: it is absent from its type, not failing at run time.
|
|
48
|
+
|
|
49
|
+
```ts
|
|
50
|
+
clinic.patient.magicLink.request; // exists
|
|
51
|
+
clinic.member.magicLink.request; // exists: a passwordless type signs in by link or code
|
|
52
|
+
// @ts-expect-error — staff have no e-mail to send a link to
|
|
53
|
+
clinic.staff.magicLink;
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
**Accepting an invitation? Use `signInProven` instead of `request` +
|
|
57
|
+
`confirm`.** When your server already verified the person — the invitation
|
|
58
|
+
token it issued and they followed — call
|
|
59
|
+
[`auth.signInProven(userId)`](sessions.md#signing-in-on-your-own-proof--signinproven):
|
|
60
|
+
the same sign-in, second factor included, with no e-mail sent, no mail
|
|
61
|
+
throttle counted and no earlier link spent. Call
|
|
62
|
+
[`verifyEmail.proveFirst`](email-flows.md#proving-an-e-mail-on-your-own-proof--provefirst)
|
|
63
|
+
before it (or `verifyEmail.confirm(token, { firstProof: true })` when your own verification link is the proof): the invitation reached the inbox, and a first proof drops what
|
|
64
|
+
somebody who signed up with the address left on it, as a link does. A `request` made only to be
|
|
65
|
+
confirmed at once is counted per address, so five anonymous requests for the
|
|
66
|
+
invitee's address would make the acceptance answer `MAIL_THROTTLED`.
|
|
67
|
+
|
|
68
|
+
## Requesting a link
|
|
69
|
+
|
|
70
|
+
```ts
|
|
71
|
+
const issued = await auth.magicLink.request(email);
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
`request` looks up the user of this type holding that e-mail — trimmed and
|
|
75
|
+
lowercased first — and issues a token for them:
|
|
76
|
+
|
|
77
|
+
```ts
|
|
78
|
+
interface IssuedToken {
|
|
79
|
+
readonly token: string; // 32 random bytes, base64url: for the link, and nowhere else
|
|
80
|
+
readonly email: string; // the address to send it to, as the user's field holds it
|
|
81
|
+
readonly expiresAt: Date; // fifteen minutes from now, by default
|
|
82
|
+
}
|
|
83
|
+
// request answers IssuedToken & { readonly user: U } — or null
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
It answers **`null`** when nobody of this type holds that e-mail, when the
|
|
87
|
+
user is inactive, and when the value matches a login that only looks like an
|
|
88
|
+
e-mail. Nothing is issued, nothing is written.
|
|
89
|
+
|
|
90
|
+
**Never tell the visitor which.** Answer the same page, with the same
|
|
91
|
+
headers — "if an account uses that address, we sent it a link". Unlike a
|
|
92
|
+
sign-in code, there is **no decoy to forge**: nothing of a link reaches the
|
|
93
|
+
visitor, so the same `202` with no body and no cookie is already the same
|
|
94
|
+
answer. Send the e-mail **after** answering, from a queue, so the time the
|
|
95
|
+
answer takes does not tell either; the store's one write for a link issued,
|
|
96
|
+
and none for `null`, still tells a patient observer.
|
|
97
|
+
|
|
98
|
+
**At most one link is live per user.** A `request` issues its token, then
|
|
99
|
+
spends every other link of the user, so the link in an earlier e-mail
|
|
100
|
+
answers `TOKEN_SPENT` — only the last one works. Requests that arrive at
|
|
101
|
+
once cannot each keep a link: at most one survives, sometimes none, and the
|
|
102
|
+
visitor asks again. A link and a [sign-in code](sign-in-code.md) are
|
|
103
|
+
separate kinds: asking for one leaves the other live.
|
|
104
|
+
|
|
105
|
+
**`request` is throttled per address**: every call sends an e-mail and
|
|
106
|
+
cancels the link before it, so past five requests for one address in a
|
|
107
|
+
10-minute window, `request` throws `MailThrottledError` (`MAIL_THROTTLED`)
|
|
108
|
+
and issues nothing: **a refused request spends and rotates nothing, so the
|
|
109
|
+
link last sent still works** until it expires, even when somebody else's
|
|
110
|
+
request caused it. The address is counted
|
|
111
|
+
before anything is looked up, so an address nobody holds is counted and
|
|
112
|
+
refused alike, and under the limit it still answers `null`. Sign-in codes and
|
|
113
|
+
password resets count on their own: a loop on this route never shuts them.
|
|
114
|
+
Answer it with a 429 and `Retry-After`:
|
|
115
|
+
|
|
116
|
+
```ts
|
|
117
|
+
import { MailThrottledError } from '@softistx/janus';
|
|
118
|
+
|
|
119
|
+
try {
|
|
120
|
+
const issued = await auth.magicLink.request(email);
|
|
121
|
+
// …send the e-mail from `issued`, whether or not there is one to send
|
|
122
|
+
} catch (error) {
|
|
123
|
+
if (error instanceof MailThrottledError) {
|
|
124
|
+
return Response.json(
|
|
125
|
+
{
|
|
126
|
+
error: 'too many e-mails — the last one we sent still works; use it, or wait',
|
|
127
|
+
retryAfter: error.retryAfter,
|
|
128
|
+
},
|
|
129
|
+
{ status: 429, headers: { 'retry-after': String(error.retryAfter) } },
|
|
130
|
+
);
|
|
131
|
+
}
|
|
132
|
+
throw error;
|
|
133
|
+
}
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
Tell the visitor to use the last e-mail they received, or to wait
|
|
137
|
+
`retryAfter` seconds: "Check your inbox: the last e-mail we sent still works.
|
|
138
|
+
You can ask for a new one in N minutes." The throttle is per address, not per
|
|
139
|
+
client: `janus` never sees IP addresses, so one client asking for many
|
|
140
|
+
addresses is not counted. Add a per-IP ceiling with `@softistx/redis` rate limits
|
|
141
|
+
([example](email-flows.md#requests-that-send-e-mail-are-throttled)). See
|
|
142
|
+
[the mail throttle](email-flows.md#requests-that-send-e-mail-are-throttled)
|
|
143
|
+
for the options.
|
|
144
|
+
|
|
145
|
+
## Requesting a link in two steps
|
|
146
|
+
|
|
147
|
+
`request` takes longer for an address with an account — a lookup, a token
|
|
148
|
+
written, the earlier ones spent — than for one nobody holds. Run it off the
|
|
149
|
+
visitor's request to hide that, and its `MAIL_THROTTLED` reaches nobody.
|
|
150
|
+
`prepare` keeps the count in the visitor's request and moves the rest off
|
|
151
|
+
it:
|
|
152
|
+
|
|
153
|
+
```ts
|
|
154
|
+
// in the visitor's request: validated and counted, nobody looked up
|
|
155
|
+
const pending = await auth.magicLink.prepare(email); // MAIL_THROTTLED past the limit: answer 429
|
|
156
|
+
|
|
157
|
+
// off it — a queue, or a promise you do not await
|
|
158
|
+
void pending
|
|
159
|
+
.send() // what request answers: IssuedToken & { user } | null — and it counts nothing
|
|
160
|
+
.then((issued) => {
|
|
161
|
+
// ORIGIN as in As routes, below
|
|
162
|
+
if (issued !== null) return sendMail(issued.email, 'Your sign-in link', `${ORIGIN}/sign-in/link?token=${issued.token}`);
|
|
163
|
+
})
|
|
164
|
+
.catch(reportError);
|
|
165
|
+
|
|
166
|
+
return new Response(null, { status: 202 }); // the same answer either way
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
`prepare` makes the same store calls whoever holds the address — the
|
|
170
|
+
count's, none with the throttle off — so its time tells nothing. `send()`
|
|
171
|
+
runs **once**: a second call, or one after a `send()` that failed, is a
|
|
172
|
+
`TypeError` (`magicLink.prepare(…).send: already called — …`); prepare
|
|
173
|
+
again, which counts again. The details, shared with sign-in codes and
|
|
174
|
+
password resets, are in
|
|
175
|
+
[the e-mail flows guide](email-flows.md#requests-in-two-steps).
|
|
176
|
+
|
|
177
|
+
## Building the link
|
|
178
|
+
|
|
179
|
+
The token is base64url — safe in a URL without escaping — and goes in a
|
|
180
|
+
link to **a page of yours**, never to the route that signs in:
|
|
181
|
+
|
|
182
|
+
```ts
|
|
183
|
+
const link = `https://app.example/sign-in/link?token=${issued.token}`;
|
|
184
|
+
```
|
|
185
|
+
|
|
186
|
+
Put the token **in the e-mail and nowhere else**: not in a log, not in an
|
|
187
|
+
analytics event. A query string reaches your server's access log, so leave
|
|
188
|
+
the query out of the log line on that path. Only the token's hash is
|
|
189
|
+
stored, like a session token's, so the store cannot give it back.
|
|
190
|
+
|
|
191
|
+
Send it to `issued.email`, not to what the visitor typed: it is the address
|
|
192
|
+
the user's field holds, as they registered it.
|
|
193
|
+
|
|
194
|
+
[`@softistx/janus-mail`](https://github.com/softistx/nxgt-janus/tree/develop/packages/janus-mail)
|
|
195
|
+
sends this e-mail ready-made, in English and French, over any `@softistx/mail`
|
|
196
|
+
transport: its **Sign in** button is built by `links.magicLink(token)` —
|
|
197
|
+
point it at the page below — and it says how long the link lasts, from
|
|
198
|
+
`issued.expiresAt`.
|
|
199
|
+
|
|
200
|
+
```ts
|
|
201
|
+
const mail = janusMail({ …, links: { …, magicLink: (token) => `https://app.example/sign-in/link?token=${token}` } });
|
|
202
|
+
if (issued !== null) await mail.magicLink(issued, { locale: 'fr-CA' }); // the recipient's locale: sent in fr
|
|
203
|
+
```
|
|
204
|
+
|
|
205
|
+
`links.magicLink` is optional there, and `mail.magicLink` throws a
|
|
206
|
+
`TypeError` without it. Its send rejects with the mailer's `MailFailure` when
|
|
207
|
+
the transport fails: hand it to a queue that awaits it and retries, rather
|
|
208
|
+
than a promise nobody awaits.
|
|
209
|
+
|
|
210
|
+
## Confirming from a `POST`, never from the link's `GET`
|
|
211
|
+
|
|
212
|
+
**Mail scanners open links.** A corporate gateway, a webmail's safe-browsing
|
|
213
|
+
check and an antivirus fetch every URL in an e-mail before the user sees
|
|
214
|
+
it, and some run its scripts. A route that signs in on `GET` would spend the
|
|
215
|
+
token for the scanner: the user clicks, and gets `TOKEN_SPENT`.
|
|
216
|
+
|
|
217
|
+
So the link lands on a **page that spends nothing**, and the user's click
|
|
218
|
+
on a button there sends the `POST` that calls `confirm`:
|
|
219
|
+
|
|
220
|
+
```ts
|
|
221
|
+
const TOKEN = /^[A-Za-z0-9_-]{43}$/;
|
|
222
|
+
|
|
223
|
+
// GET /sign-in/link?token=… — a page, and nothing else
|
|
224
|
+
export function linkPage(request: Request): Response {
|
|
225
|
+
const token = new URL(request.url).searchParams.get('token') ?? '';
|
|
226
|
+
if (!TOKEN.test(token)) return new Response('This link is not valid.', { status: 400 });
|
|
227
|
+
return new Response(
|
|
228
|
+
`<!doctype html><meta charset="utf-8"><title>Sign in</title>
|
|
229
|
+
<form method="post" action="/sign-in/link">
|
|
230
|
+
<input type="hidden" name="token" value="${token}">
|
|
231
|
+
<button>Sign in</button>
|
|
232
|
+
</form>`,
|
|
233
|
+
{
|
|
234
|
+
headers: {
|
|
235
|
+
'Content-Type': 'text/html; charset=utf-8',
|
|
236
|
+
'Referrer-Policy': 'strict-origin', // the origin only: the token's URL reaches nobody
|
|
237
|
+
'Cache-Control': 'no-store',
|
|
238
|
+
},
|
|
239
|
+
},
|
|
240
|
+
);
|
|
241
|
+
}
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+
- **Echo only a token of the token's shape** — 43 base64url characters.
|
|
245
|
+
Anything else written into the page is a cross-site scripting hole.
|
|
246
|
+
- **A button, not a script that submits by itself.** A scanner that runs
|
|
247
|
+
scripts submits the form too; one that does not click buttons does not.
|
|
248
|
+
Auto-submitting saves the user a click, at the price of every link a
|
|
249
|
+
script-running scanner opens.
|
|
250
|
+
- **`Referrer-Policy: strict-origin`** keeps the URL, and the token in it,
|
|
251
|
+
out of the `Referer` of anything the page loads: a `Referer` holds the
|
|
252
|
+
origin only — `https://app.example/` — never the path and its query, and
|
|
253
|
+
none at all from HTTPS to HTTP. Not `no-referrer`: with it the browser
|
|
254
|
+
posts the form with `Origin: null`, which a check on `Origin` alone — as
|
|
255
|
+
`confirmLink` [below](#as-routes) — refuses every time, and one that tries
|
|
256
|
+
`Sec-Fetch-Site` first refuses whenever the browser sends none: on plain
|
|
257
|
+
HTTP off `localhost`, or in an older browser.
|
|
258
|
+
- **Refuse a `POST` from another site.** The token says nothing of the
|
|
259
|
+
browser that asked for it: a page anywhere that posts a token of the
|
|
260
|
+
attacker's own account to your route signs its visitor in as the attacker,
|
|
261
|
+
and what they type next lands there. Check `Origin` against your own, or
|
|
262
|
+
that `Sec-Fetch-Site` is `same-origin`, before calling `confirm` — as the
|
|
263
|
+
route [below](#as-routes) does.
|
|
264
|
+
|
|
265
|
+
## Confirming the link
|
|
266
|
+
|
|
267
|
+
```ts
|
|
268
|
+
const signedIn = await auth.magicLink.confirm(token);
|
|
269
|
+
// { status: 'signedIn', user, session, token }: the session is open
|
|
270
|
+
```
|
|
271
|
+
|
|
272
|
+
`confirm` spends the token, marks the user's e-mail verified — the link
|
|
273
|
+
reached the inbox — and opens a session: the same `SignedIn` that `signIn`
|
|
274
|
+
answers. **The session opens in the browser that opened the link**, which
|
|
275
|
+
need not be the one that asked for it: a link asked for on a laptop and
|
|
276
|
+
opened on a phone signs the phone in. Where the sign-in must complete in
|
|
277
|
+
the browser that started it, send a [sign-in code](sign-in-code.md) instead.
|
|
278
|
+
|
|
279
|
+
The token is spent **by the first call**, in one conditional write, whether
|
|
280
|
+
that call signs in or is refused: of ten confirmations of one link at once,
|
|
281
|
+
exactly one signs in and nine answer `TOKEN_SPENT`. There is nothing to
|
|
282
|
+
guess — 256 random bits — so no attempts are counted.
|
|
283
|
+
|
|
284
|
+
### Lifetime
|
|
285
|
+
|
|
286
|
+
A link lives **fifteen minutes** unless `tokens.magicLink` says otherwise,
|
|
287
|
+
and is `TOKEN_EXPIRED` after that. Fifteen rather than a code's ten: the
|
|
288
|
+
e-mail must arrive and be opened, and a scanner may hold it a minute first.
|
|
289
|
+
No longer: whoever reads the mailbox in that window signs in.
|
|
290
|
+
|
|
291
|
+
```ts
|
|
292
|
+
janus({ ..., tokens: { magicLink: '30m' } });
|
|
293
|
+
```
|
|
294
|
+
|
|
295
|
+
### The e-mail is verified
|
|
296
|
+
|
|
297
|
+
A user whose `emailVerified` was `false` has it `true` once `confirm`
|
|
298
|
+
succeeds, and their `version` moves; a
|
|
299
|
+
[`user.emailVerified` event](events.md) is sent. A user already verified is
|
|
300
|
+
not written, and nothing is sent. The proof is written under the version
|
|
301
|
+
read: a user written meanwhile answers `VERSION_CONFLICT`, with the link
|
|
302
|
+
spent.
|
|
303
|
+
|
|
304
|
+
### An account someone else registered
|
|
305
|
+
|
|
306
|
+
The proof can land on an account its owner did not create. `signUp` does
|
|
307
|
+
not wait for the e-mail to be proved, so anyone can register
|
|
308
|
+
`ada@example.com` with a password of theirs — and enrol a second factor on
|
|
309
|
+
their own phone. When Ada later signs in by link, `confirm` proves an e-mail
|
|
310
|
+
never verified, and **drops the password, the second factor and the avatar, signs out
|
|
311
|
+
every session and revokes every API key** before it opens hers — as a
|
|
312
|
+
[password reset](email-flows.md) does. The same holds for a
|
|
313
|
+
[code](sign-in-code.md), and for
|
|
314
|
+
[`verifyEmail.proveFirst`](email-flows.md#proving-an-e-mail-on-your-own-proof--provefirst),
|
|
315
|
+
which applies this proof when the proof is your own — an invitation.
|
|
316
|
+
|
|
317
|
+
- In the write that proves the e-mail, the password is removed
|
|
318
|
+
(`hasPassword` turns `false`), and so is the second factor, active or
|
|
319
|
+
still waiting for its first code, with its recovery codes
|
|
320
|
+
(`hasSecondFactor` turns `false`), and so is the avatar (`avatar` turns
|
|
321
|
+
`null`, `user.avatarRemoved` carries the former id to delete): Ada's sign-in asks for no factor she
|
|
322
|
+
never set. Every session of the user is revoked, and
|
|
323
|
+
the reset links and second-factor challenges still waiting are spent,
|
|
324
|
+
before that write and again after it: an outage before it leaves the
|
|
325
|
+
e-mail unproved, so the next link or code runs all of it again.
|
|
326
|
+
- [`user.emailVerified`](events.md) is sent, then `user.passwordChanged`
|
|
327
|
+
when a password was dropped, then `user.secondFactorDisabled` when an
|
|
328
|
+
active factor was — even if an outage interrupts the sign-outs.
|
|
329
|
+
- **An e-mail already verified changes nothing**: the password, the second
|
|
330
|
+
factor and the sessions stay, and nothing is written or sent.
|
|
331
|
+
- An e-mail changed by `update` is unverified again: its first proof drops
|
|
332
|
+
the password, the second factor and the avatar too. `update` refuses to move
|
|
333
|
+
the e-mail of a user who holds a second factor or a passkey
|
|
334
|
+
(`EMAIL_CHANGE_NEEDS_PROOF`): use `changeEmail`, which proves the new
|
|
335
|
+
address and keeps both.
|
|
336
|
+
- **`secondFactor.enroll` and the passkey registration refuse a user whose
|
|
337
|
+
e-mail is never verified** (`EMAIL_UNVERIFIED`), so a real member's factor is
|
|
338
|
+
never dropped by a sign-in: send `verifyEmail` before offering them. `update`
|
|
339
|
+
cannot move the e-mail of a factor holder (`EMAIL_CHANGE_NEEDS_PROOF`; use
|
|
340
|
+
`changeEmail`). Only a factor stored before these rules is still dropped.
|
|
341
|
+
|
|
342
|
+
A user who signed up with a password and signs in by link before verifying
|
|
343
|
+
has **no password afterwards**: `signIn` answers `CREDENTIALS_INVALID` with
|
|
344
|
+
`reason: 'noPassword'`. Offer to set one:
|
|
345
|
+
|
|
346
|
+
```ts
|
|
347
|
+
const signedIn = await auth.magicLink.confirm(token);
|
|
348
|
+
if (signedIn.status === 'signedIn' && !signedIn.user.hasPassword) {
|
|
349
|
+
// a page of yours that calls auth.setPassword(signedIn.user, password)
|
|
350
|
+
}
|
|
351
|
+
```
|
|
352
|
+
|
|
353
|
+
### A second factor is still asked for
|
|
354
|
+
|
|
355
|
+
The link proves the e-mail, not the second factor. With
|
|
356
|
+
`janus({ secondFactor })`, a user whose e-mail was already verified and
|
|
357
|
+
whose factor is active gets **no session from the link**: `confirm` answers
|
|
358
|
+
a challenge, exactly as `signIn` does, and
|
|
359
|
+
[`secondFactor.confirm`](second-factor.md#confirming-the-code-at-sign-in)
|
|
360
|
+
redeems it with their app's code.
|
|
361
|
+
|
|
362
|
+
```ts
|
|
363
|
+
const result = await auth.magicLink.confirm(token);
|
|
364
|
+
if (result.status === 'secondFactor') {
|
|
365
|
+
// result.challenge: for secondFactor.confirm — keep it as a sign-in keeps it
|
|
366
|
+
} else {
|
|
367
|
+
// result.token, result.session: set the cookie
|
|
368
|
+
}
|
|
369
|
+
```
|
|
370
|
+
|
|
371
|
+
`confirm` answers `SignInResult` on a type with a password or an e-mail, in an
|
|
372
|
+
instance given a `secondFactor`, and reading `token` before narrowing on
|
|
373
|
+
`status` is a compile error there. Anywhere else it answers `SignedIn`.
|
|
374
|
+
|
|
375
|
+
### The device
|
|
376
|
+
|
|
377
|
+
With [`janus({ devices })`](devices.md), `confirm` takes the device token
|
|
378
|
+
the client holds as its second argument — read from the device cookie of
|
|
379
|
+
the browser that posts the link's page, which is the one the session opens
|
|
380
|
+
in:
|
|
381
|
+
|
|
382
|
+
```ts
|
|
383
|
+
const signedIn = await auth.magicLink.confirm(token, { device: cookie ?? null });
|
|
384
|
+
// { status: 'signedIn', …, newDevice, deviceToken }: keep deviceToken in the device cookie
|
|
385
|
+
```
|
|
386
|
+
|
|
387
|
+
A new device sends `user.newDeviceSignedIn` — last, after the events a first
|
|
388
|
+
proof of the e-mail sends. A link opened on a phone the user never signed in
|
|
389
|
+
from is a new device, even when a laptop asked for it. When `confirm`
|
|
390
|
+
answers a second factor's challenge, the challenge carries no device: give
|
|
391
|
+
it again to `secondFactor.confirm`. Without `{ device }`, nothing is
|
|
392
|
+
tracked.
|
|
393
|
+
|
|
394
|
+
### What `confirm` refuses
|
|
395
|
+
|
|
396
|
+
| Rejects with | When | What to do |
|
|
397
|
+
| --- | --- | --- |
|
|
398
|
+
| `TOKEN_UNKNOWN` | no such link — a mangled URL, another user type's, a sign-in code's challenge, one whose user was deleted, or one a store's TTL already dropped. Message: `magicLink.confirm: no such token`. Another type's link is spent by the call | ask for a new link |
|
|
399
|
+
| `TOKEN_SPENT` | the link already signed someone in, a newer `request` for the same user spent it, or an earlier `confirm` of it was refused. Message: `magicLink.confirm: the token was already used` | ask for a new link, and use the latest e-mail |
|
|
400
|
+
| `TOKEN_EXPIRED` | `expiresAt` has passed. The link is spent | ask for a new link |
|
|
401
|
+
| `TOKEN_STALE` | the user changed their e-mail since the link was sent. Message: `magicLink.confirm: the token was sent to an e-mail the user no longer has`. The link is spent | ask for a new link, to the current address |
|
|
402
|
+
| `USER_INACTIVE` | the user was deactivated since the link was sent. The link is spent | answer 403 |
|
|
403
|
+
| `MAGIC_LINK_DISABLED` | `janus({ magicLink: { enabled: false } })`: refused before the token is read, so it is not spent. Message: `magicLink.confirm: magic-link sign-in is disabled`. `request` and `prepare` refuse alike | answer 404, and hide the button with `auth.magicLink.enabled` |
|
|
404
|
+
| `VERSION_CONFLICT` | rare: another write to the user landed while `confirm` marked the e-mail verified. The link is spent | ask for a new link |
|
|
405
|
+
|
|
406
|
+
Every refusal is a `TokenError` but `USER_INACTIVE`, a `UserInactiveError`, and
|
|
407
|
+
`MAGIC_LINK_DISABLED`, a `MagicLinkDisabledError`;
|
|
408
|
+
with several user types the message starts with the type:
|
|
409
|
+
`patient.magicLink.confirm: …`. Every call may also reject with
|
|
410
|
+
`STORE_FAILED` — `request` as well as `confirm`: your 503, never "no such
|
|
411
|
+
account" nor a 401. [Troubleshooting](../troubleshooting.md#sign-in-links)
|
|
412
|
+
has each message with its cause.
|
|
413
|
+
|
|
414
|
+
## Switching it off
|
|
415
|
+
|
|
416
|
+
Behind an environment flag, the application passes the flag and reads the
|
|
417
|
+
state back to hide the button; no second flag is needed:
|
|
418
|
+
|
|
419
|
+
```ts
|
|
420
|
+
const auth = janus({
|
|
421
|
+
// …
|
|
422
|
+
magicLink: { enabled: process.env.APP_MAGIC_LINK === 'true' },
|
|
423
|
+
});
|
|
424
|
+
|
|
425
|
+
// in the sign-in page's loader
|
|
426
|
+
const showMagicLink = auth.magicLink.enabled;
|
|
427
|
+
```
|
|
428
|
+
|
|
429
|
+
Off, `request`, `prepare` and `confirm` throw `MAGIC_LINK_DISABLED` (a
|
|
430
|
+
`MagicLinkDisabledError`, status 404) before any store access: nothing is
|
|
431
|
+
counted, issued, spent or sent. A link mailed earlier is not spent, and works
|
|
432
|
+
again if the switch goes back on within its fifteen minutes.
|
|
433
|
+
|
|
434
|
+
## What does not end a link
|
|
435
|
+
|
|
436
|
+
- **Writing the password.** `resetPassword.confirm`, `changePassword` and
|
|
437
|
+
`setPassword` spend the user's reset links and second-factor challenges,
|
|
438
|
+
not their sign-in links: the password proves nothing a link does, and
|
|
439
|
+
whoever holds the inbox can ask for another link anyway. The same holds
|
|
440
|
+
for sign-in codes.
|
|
441
|
+
- **Signing out everywhere.** It revokes sessions; a link opens a new one.
|
|
442
|
+
- **The sign-in throttle.** `signIn.throttle` counts passwords tried at one
|
|
443
|
+
login; a link is not a password, and its token cannot be guessed. The
|
|
444
|
+
[mail throttle](#requesting-a-link) counts its requests instead.
|
|
445
|
+
|
|
446
|
+
What does: its own redemption, a newer `request`, its fifteen minutes, an
|
|
447
|
+
e-mail changed since (`TOKEN_STALE`), the user deactivated
|
|
448
|
+
(`USER_INACTIVE`), and deleting the user, which deletes every token of
|
|
449
|
+
theirs.
|
|
450
|
+
|
|
451
|
+
## Options
|
|
452
|
+
|
|
453
|
+
| Option | Type | Default | Effect |
|
|
454
|
+
| --- | --- | --- | --- |
|
|
455
|
+
| `magicLink.enabled` (`MagicLinkConfig`) | `boolean` | `true` | `false` switches sign-in links off: `request`, `prepare` and `confirm` throw `MAGIC_LINK_DISABLED` before any store access. A value that is not `{ enabled: boolean }` is refused at wiring with a `TypeError` |
|
|
456
|
+
| `tokens.magicLink` | `Duration` | `'15m'` | How long a link can be confirmed |
|
|
457
|
+
| `email` | a field name | `'email'` | The field the link is sent to, and looked up by, per type |
|
|
458
|
+
|
|
459
|
+
A `tokens.magicLink` that is not a duration is refused when `janus()` is
|
|
460
|
+
called, with a `TypeError`: `janus: tokens.magicLink: "<value>" is not a
|
|
461
|
+
duration; …`.
|
|
462
|
+
|
|
463
|
+
## As routes
|
|
464
|
+
|
|
465
|
+
The page above, and a fetch-style pair beside it — the shape Bun and most
|
|
466
|
+
frameworks hand you;
|
|
467
|
+
[`@softistx/janus-hono`](https://github.com/softistx/nxgt-janus/blob/develop/packages/janus-hono/docs/guide/routes.md#a-link-sent-by-e-mail)
|
|
468
|
+
has the same in Hono, behind its `csrf()`:
|
|
469
|
+
|
|
470
|
+
```ts
|
|
471
|
+
import { JanusError, TokenError, UserInactiveError } from '@softistx/janus';
|
|
472
|
+
|
|
473
|
+
const ORIGIN = 'https://app.example';
|
|
474
|
+
|
|
475
|
+
// POST /sign-in/email/link — ask for a link
|
|
476
|
+
export async function requestLink(request: Request): Promise<Response> {
|
|
477
|
+
const { email } = (await request.json()) as { email: string };
|
|
478
|
+
const issued = await auth.magicLink.request(email);
|
|
479
|
+
if (issued !== null) {
|
|
480
|
+
const link = `${ORIGIN}/sign-in/link?token=${issued.token}`;
|
|
481
|
+
void sendMail(issued.email, 'Your sign-in link', link); // not awaited, so the answer's time tells nothing; in production, a queue that awaits and retries
|
|
482
|
+
}
|
|
483
|
+
return new Response(null, { status: 202 }); // the same answer either way
|
|
484
|
+
}
|
|
485
|
+
|
|
486
|
+
// POST /sign-in/link — the page's button
|
|
487
|
+
export async function confirmLink(request: Request): Promise<Response> {
|
|
488
|
+
// Only your own page posts here: another site's form would sign its visitor in.
|
|
489
|
+
if (request.headers.get('Origin') !== ORIGIN) return new Response(null, { status: 403 });
|
|
490
|
+
const token = String((await request.formData()).get('token') ?? '');
|
|
491
|
+
try {
|
|
492
|
+
const signedIn = await auth.magicLink.confirm(token);
|
|
493
|
+
return new Response(null, {
|
|
494
|
+
status: 303,
|
|
495
|
+
headers: { Location: '/', 'Set-Cookie': auth.cookie.serialize(signedIn.token, signedIn.session) },
|
|
496
|
+
});
|
|
497
|
+
} catch (error) {
|
|
498
|
+
if (error instanceof UserInactiveError) return new Response(null, { status: 403 });
|
|
499
|
+
if (error instanceof TokenError || (error instanceof JanusError && error.code === 'VERSION_CONFLICT')) {
|
|
500
|
+
return new Response(null, { status: 303, headers: { Location: '/sign-in?link=expired' } });
|
|
501
|
+
}
|
|
502
|
+
throw error; // STORE_FAILED: your 503
|
|
503
|
+
}
|
|
504
|
+
}
|
|
505
|
+
```
|
|
506
|
+
|
|
507
|
+
A refused link sends the user back to ask for another: every `TOKEN_*`, and
|
|
508
|
+
the rare `VERSION_CONFLICT`, means the same thing to them. With a
|
|
509
|
+
`secondFactor` configured, narrow `confirm`'s answer on `status` before
|
|
510
|
+
reading `token`, and hand the challenge on to
|
|
511
|
+
[the second factor's route](second-factor.md#a-sign-in-with-a-code-as-routes).
|
|
512
|
+
|
|
513
|
+
## In a test
|
|
514
|
+
|
|
515
|
+
No mailbox needed: `request` answers the token it would have sent.
|
|
516
|
+
|
|
517
|
+
```ts
|
|
518
|
+
import { expect, it } from 'bun:test';
|
|
519
|
+
import { z } from 'zod';
|
|
520
|
+
import { createMemoryStores, fixedClock, janus } from '@softistx/janus';
|
|
521
|
+
|
|
522
|
+
it('signs in with the e-mailed link, once, and not after fifteen minutes', async () => {
|
|
523
|
+
const clock = fixedClock(Date.UTC(2026, 0, 1));
|
|
524
|
+
const auth = janus({ user: z.object({ email: z.email() }), store: createMemoryStores(), clock });
|
|
525
|
+
await auth.create({ email: 'ada@example.com' });
|
|
526
|
+
|
|
527
|
+
const issued = await auth.magicLink.request('ada@example.com');
|
|
528
|
+
if (issued === null) throw new Error('expected a link');
|
|
529
|
+
expect((await auth.magicLink.confirm(issued.token)).user.emailVerified).toBe(true);
|
|
530
|
+
await expect(auth.magicLink.confirm(issued.token)).rejects.toMatchObject({ code: 'TOKEN_SPENT' });
|
|
531
|
+
|
|
532
|
+
const late = await auth.magicLink.request('ada@example.com');
|
|
533
|
+
if (late === null) throw new Error('expected a link');
|
|
534
|
+
clock.advance(15 * 60_000);
|
|
535
|
+
await expect(auth.magicLink.confirm(late.token)).rejects.toMatchObject({ code: 'TOKEN_EXPIRED' });
|
|
536
|
+
});
|
|
537
|
+
```
|
|
538
|
+
|
|
539
|
+
## Signatures
|
|
540
|
+
|
|
541
|
+
```ts
|
|
542
|
+
interface MagicLinkApi<U, Answer = SignedIn<U>> {
|
|
543
|
+
readonly magicLink: {
|
|
544
|
+
readonly enabled: boolean;
|
|
545
|
+
request(email: string): Promise<(IssuedToken & { readonly user: U }) | null>;
|
|
546
|
+
prepare(email: string): Promise<PreparedRequest<IssuedToken & { readonly user: U }>>;
|
|
547
|
+
confirm(token: string, options?: SignInOptions): Promise<Answer>;
|
|
548
|
+
};
|
|
549
|
+
}
|
|
550
|
+
|
|
551
|
+
interface PreparedRequest<Issued> {
|
|
552
|
+
send(): Promise<Issued | null>; // once: a second call is a TypeError
|
|
553
|
+
};
|
|
554
|
+
}
|
|
555
|
+
```
|
|
556
|
+
|
|
557
|
+
`Answer` is `SignInResult<U>` on a type with a password or an e-mail in an
|
|
558
|
+
instance given a `secondFactor`, and `SignedIn<U>` everywhere else. `MagicLinkApi`,
|
|
559
|
+
`IssuedToken`, `PreparedRequest` and `SignInOptions` are exported from
|
|
560
|
+
`@softistx/janus`, as types; `SignInOptions` is `{ device?: string | null }` — see
|
|
561
|
+
[devices](devices.md#giving-a-sign-in-the-device).
|
|
562
|
+
|
|
563
|
+
## For an adapter
|
|
564
|
+
|
|
565
|
+
A link is a token of kind **`magicLink`**, new in 0.15. A store that lists
|
|
566
|
+
the kinds — a `CHECK`, a validator's enum — lists it too; the conformance
|
|
567
|
+
suite's `tokens.everyKind` fails until it does, and `tokens.magicLinkKind`
|
|
568
|
+
holds that a link and a sign-in code are never redeemed as each other. See
|
|
569
|
+
[adapters](adapters.md#sessionstore-and-tokenstore).
|
|
570
|
+
|
|
571
|
+
## See also
|
|
572
|
+
|
|
573
|
+
- [Sign-in codes](sign-in-code.md) — the same sign-in with a code to type, which completes in the browser that asked
|
|
574
|
+
- [The second factor](second-factor.md) — the challenge `confirm` answers for a user whose factor is active
|
|
575
|
+
- [E-mail verification and password reset](email-flows.md) — the other flows that send a link, and `TOKEN_STALE`
|
|
576
|
+
- [Sessions](sessions.md) — the cookie the session is sent in
|
|
577
|
+
- [Devices](devices.md) — the `device` `confirm` takes, and the notice of a new one
|
|
578
|
+
- [Errors](errors.md) — every code and its status
|
|
579
|
+
- [Troubleshooting](../troubleshooting.md#sign-in-links) — by the message you see
|
|
580
|
+
- [`@softistx/janus-telemetry`](https://github.com/softistx/nxgt-janus/blob/develop/packages/janus-telemetry/docs/guide/tracing.md#a-link-sent-by-e-mail) — the events a sign-in by link writes
|