authhero 9.43.0 → 9.44.1

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.
Files changed (61) hide show
  1. package/dist/assets/u/widget/index.esm.js +1 -1
  2. package/dist/authhero.cjs +205 -164
  3. package/dist/authhero.d.ts +220 -216
  4. package/dist/authhero.mjs +10760 -10688
  5. package/dist/{mfa-C8qBEQeH.js → mfa-B0J_xOxl.js} +1 -1
  6. package/dist/{mfa-CVF4Wbdz.mjs → mfa-CX1JyNyV.mjs} +1 -1
  7. package/dist/{mfa-attempts-sV0Xs59R.mjs → mfa-attempts-BNf9KSrR.mjs} +3 -1
  8. package/dist/{mfa-attempts-CzGjIGzD.js → mfa-attempts-suDM5Cv-.js} +3 -3
  9. package/dist/{passkey-enrollment-CAb2zWEF.js → passkey-enrollment-D180Gog3.js} +1 -1
  10. package/dist/tsconfig.types.tsbuildinfo +1 -1
  11. package/dist/types/authentication-flows/passwordless.d.ts +2 -2
  12. package/dist/types/helpers/dcr/metadata-mapping.d.ts +1 -1
  13. package/dist/types/helpers/login-migration.d.ts +23 -2
  14. package/dist/types/helpers/reserved-claims.d.ts +2 -2
  15. package/dist/types/index.d.ts +220 -216
  16. package/dist/types/routes/auth-api/authorize.d.ts +13 -13
  17. package/dist/types/routes/auth-api/device.d.ts +21 -21
  18. package/dist/types/routes/auth-api/index.d.ts +81 -81
  19. package/dist/types/routes/auth-api/logout.d.ts +2 -2
  20. package/dist/types/routes/auth-api/oidc-logout.d.ts +3 -3
  21. package/dist/types/routes/auth-api/passwordless.d.ts +10 -10
  22. package/dist/types/routes/auth-api/register/index.d.ts +2 -2
  23. package/dist/types/routes/auth-api/revoke.d.ts +6 -6
  24. package/dist/types/routes/auth-api/token.d.ts +12 -12
  25. package/dist/types/routes/management-api/action-executions.d.ts +1 -1
  26. package/dist/types/routes/management-api/authentication-methods.d.ts +1 -1
  27. package/dist/types/routes/management-api/branding.d.ts +7 -3
  28. package/dist/types/routes/management-api/client-registration-tokens.d.ts +8 -8
  29. package/dist/types/routes/management-api/clients.d.ts +16 -16
  30. package/dist/types/routes/management-api/email-templates.d.ts +18 -18
  31. package/dist/types/routes/management-api/failed-events.d.ts +2 -2
  32. package/dist/types/routes/management-api/forms.d.ts +8 -8
  33. package/dist/types/routes/management-api/guardian.d.ts +5 -5
  34. package/dist/types/routes/management-api/helpers.d.ts +1 -1
  35. package/dist/types/routes/management-api/index.d.ts +112 -108
  36. package/dist/types/routes/management-api/keys.d.ts +12 -12
  37. package/dist/types/routes/management-api/log-streams.d.ts +6 -6
  38. package/dist/types/routes/management-api/logs.d.ts +4 -4
  39. package/dist/types/routes/management-api/organizations.d.ts +4 -4
  40. package/dist/types/routes/management-api/prompts.d.ts +6 -6
  41. package/dist/types/routes/management-api/rollouts.d.ts +6 -6
  42. package/dist/types/routes/management-api/self-service-profiles.d.ts +8 -8
  43. package/dist/types/routes/management-api/tenant-export-import.d.ts +5 -5
  44. package/dist/types/routes/management-api/tenant-operations.d.ts +5 -5
  45. package/dist/types/routes/management-api/tenants.d.ts +9 -9
  46. package/dist/types/routes/management-api/users.d.ts +20 -20
  47. package/dist/types/routes/saml/index.d.ts +10 -10
  48. package/dist/types/routes/saml/samlp.d.ts +10 -10
  49. package/dist/types/routes/universal-login/common.d.ts +2 -0
  50. package/dist/types/routes/universal-login/continue.d.ts +4 -4
  51. package/dist/types/routes/universal-login/dark-theme.d.ts +14 -2
  52. package/dist/types/routes/universal-login/identifier.d.ts +2 -2
  53. package/dist/types/routes/universal-login/impersonate.d.ts +4 -4
  54. package/dist/types/routes/universal-login/index.d.ts +8 -8
  55. package/dist/types/routes/universal-login/u2-index.d.ts +9 -9
  56. package/dist/types/routes/universal-login/u2-routes.d.ts +7 -7
  57. package/dist/types/routes/universal-login/u2-widget-page.d.ts +20 -2
  58. package/dist/types/routes/universal-login/universal-login-template.d.ts +8 -0
  59. package/dist/types/state-machines/login-session.d.ts +1 -1
  60. package/dist/types/strategies/apple.d.ts +1 -1
  61. package/package.json +7 -7
@@ -195,7 +195,7 @@ export default function createU2App(config: AuthHeroConfig): OpenAPIHono<{
195
195
  $get: {
196
196
  input: {
197
197
  param: {
198
- screen: "impersonate" | "signup" | "login" | "consent" | "reset-password" | "account" | "enter-password" | "try-connection-result" | "invalid-session" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "login/email-verification" | "login/email-verification-sent" | "reset-password/code" | "reset-password/request" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/change-email" | "account/change-email/verify" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
198
+ screen: "login" | "signup" | "consent" | "impersonate" | "reset-password" | "account" | "enter-password" | "invalid-session" | "reset-password/request" | "reset-password/code" | "login/email-verification" | "login/email-verification-sent" | "account/change-email" | "account/change-email/verify" | "try-connection-result" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
199
199
  };
200
200
  } & {
201
201
  query: {
@@ -211,7 +211,7 @@ export default function createU2App(config: AuthHeroConfig): OpenAPIHono<{
211
211
  } | {
212
212
  input: {
213
213
  param: {
214
- screen: "impersonate" | "signup" | "login" | "consent" | "reset-password" | "account" | "enter-password" | "try-connection-result" | "invalid-session" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "login/email-verification" | "login/email-verification-sent" | "reset-password/code" | "reset-password/request" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/change-email" | "account/change-email/verify" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
214
+ screen: "login" | "signup" | "consent" | "impersonate" | "reset-password" | "account" | "enter-password" | "invalid-session" | "reset-password/request" | "reset-password/code" | "login/email-verification" | "login/email-verification-sent" | "account/change-email" | "account/change-email/verify" | "try-connection-result" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
215
215
  };
216
216
  } & {
217
217
  query: {
@@ -223,11 +223,11 @@ export default function createU2App(config: AuthHeroConfig): OpenAPIHono<{
223
223
  };
224
224
  output: {};
225
225
  outputFormat: string;
226
- status: 400;
226
+ status: 302;
227
227
  } | {
228
228
  input: {
229
229
  param: {
230
- screen: "impersonate" | "signup" | "login" | "consent" | "reset-password" | "account" | "enter-password" | "try-connection-result" | "invalid-session" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "login/email-verification" | "login/email-verification-sent" | "reset-password/code" | "reset-password/request" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/change-email" | "account/change-email/verify" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
230
+ screen: "login" | "signup" | "consent" | "impersonate" | "reset-password" | "account" | "enter-password" | "invalid-session" | "reset-password/request" | "reset-password/code" | "login/email-verification" | "login/email-verification-sent" | "account/change-email" | "account/change-email/verify" | "try-connection-result" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
231
231
  };
232
232
  } & {
233
233
  query: {
@@ -239,7 +239,7 @@ export default function createU2App(config: AuthHeroConfig): OpenAPIHono<{
239
239
  };
240
240
  output: {};
241
241
  outputFormat: string;
242
- status: 302;
242
+ status: 400;
243
243
  };
244
244
  };
245
245
  } & {
@@ -247,7 +247,7 @@ export default function createU2App(config: AuthHeroConfig): OpenAPIHono<{
247
247
  $post: {
248
248
  input: {
249
249
  param: {
250
- screen: "impersonate" | "signup" | "login" | "consent" | "reset-password" | "enter-password" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "login/email-verification" | "login/email-verification-sent" | "reset-password/code" | "reset-password/request" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/change-email" | "account/change-email/verify" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation";
250
+ screen: "login" | "signup" | "consent" | "impersonate" | "reset-password" | "enter-password" | "reset-password/request" | "reset-password/code" | "login/email-verification" | "login/email-verification-sent" | "account/change-email" | "account/change-email/verify" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation";
251
251
  };
252
252
  } & {
253
253
  query: {
@@ -265,7 +265,7 @@ export default function createU2App(config: AuthHeroConfig): OpenAPIHono<{
265
265
  } | {
266
266
  input: {
267
267
  param: {
268
- screen: "impersonate" | "signup" | "login" | "consent" | "reset-password" | "enter-password" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "login/email-verification" | "login/email-verification-sent" | "reset-password/code" | "reset-password/request" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/change-email" | "account/change-email/verify" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation";
268
+ screen: "login" | "signup" | "consent" | "impersonate" | "reset-password" | "enter-password" | "reset-password/request" | "reset-password/code" | "login/email-verification" | "login/email-verification-sent" | "account/change-email" | "account/change-email/verify" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation";
269
269
  };
270
270
  } & {
271
271
  query: {
@@ -306,7 +306,7 @@ export default function createU2App(config: AuthHeroConfig): OpenAPIHono<{
306
306
  };
307
307
  output: {};
308
308
  outputFormat: string;
309
- status: 400;
309
+ status: 302;
310
310
  } | {
311
311
  input: {
312
312
  query: {
@@ -315,7 +315,7 @@ export default function createU2App(config: AuthHeroConfig): OpenAPIHono<{
315
315
  };
316
316
  output: {};
317
317
  outputFormat: string;
318
- status: 302;
318
+ status: 400;
319
319
  } | {
320
320
  input: {
321
321
  query: {
@@ -201,7 +201,7 @@ export declare const u2Routes: OpenAPIHono<{
201
201
  $get: {
202
202
  input: {
203
203
  param: {
204
- screen: "impersonate" | "signup" | "login" | "consent" | "reset-password" | "account" | "enter-password" | "try-connection-result" | "invalid-session" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "login/email-verification" | "login/email-verification-sent" | "reset-password/code" | "reset-password/request" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/change-email" | "account/change-email/verify" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
204
+ screen: "login" | "signup" | "consent" | "impersonate" | "reset-password" | "account" | "enter-password" | "invalid-session" | "reset-password/request" | "reset-password/code" | "login/email-verification" | "login/email-verification-sent" | "account/change-email" | "account/change-email/verify" | "try-connection-result" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
205
205
  };
206
206
  } & {
207
207
  query: {
@@ -217,7 +217,7 @@ export declare const u2Routes: OpenAPIHono<{
217
217
  } | {
218
218
  input: {
219
219
  param: {
220
- screen: "impersonate" | "signup" | "login" | "consent" | "reset-password" | "account" | "enter-password" | "try-connection-result" | "invalid-session" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "login/email-verification" | "login/email-verification-sent" | "reset-password/code" | "reset-password/request" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/change-email" | "account/change-email/verify" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
220
+ screen: "login" | "signup" | "consent" | "impersonate" | "reset-password" | "account" | "enter-password" | "invalid-session" | "reset-password/request" | "reset-password/code" | "login/email-verification" | "login/email-verification-sent" | "account/change-email" | "account/change-email/verify" | "try-connection-result" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
221
221
  };
222
222
  } & {
223
223
  query: {
@@ -229,11 +229,11 @@ export declare const u2Routes: OpenAPIHono<{
229
229
  };
230
230
  output: {};
231
231
  outputFormat: string;
232
- status: 400;
232
+ status: 302;
233
233
  } | {
234
234
  input: {
235
235
  param: {
236
- screen: "impersonate" | "signup" | "login" | "consent" | "reset-password" | "account" | "enter-password" | "try-connection-result" | "invalid-session" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "login/email-verification" | "login/email-verification-sent" | "reset-password/code" | "reset-password/request" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/change-email" | "account/change-email/verify" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
236
+ screen: "login" | "signup" | "consent" | "impersonate" | "reset-password" | "account" | "enter-password" | "invalid-session" | "reset-password/request" | "reset-password/code" | "login/email-verification" | "login/email-verification-sent" | "account/change-email" | "account/change-email/verify" | "try-connection-result" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation" | "device/complete";
237
237
  };
238
238
  } & {
239
239
  query: {
@@ -245,7 +245,7 @@ export declare const u2Routes: OpenAPIHono<{
245
245
  };
246
246
  output: {};
247
247
  outputFormat: string;
248
- status: 302;
248
+ status: 400;
249
249
  };
250
250
  };
251
251
  } & {
@@ -253,7 +253,7 @@ export declare const u2Routes: OpenAPIHono<{
253
253
  $post: {
254
254
  input: {
255
255
  param: {
256
- screen: "impersonate" | "signup" | "login" | "consent" | "reset-password" | "enter-password" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "login/email-verification" | "login/email-verification-sent" | "reset-password/code" | "reset-password/request" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/change-email" | "account/change-email/verify" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation";
256
+ screen: "login" | "signup" | "consent" | "impersonate" | "reset-password" | "enter-password" | "reset-password/request" | "reset-password/code" | "login/email-verification" | "login/email-verification-sent" | "account/change-email" | "account/change-email/verify" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation";
257
257
  };
258
258
  } & {
259
259
  query: {
@@ -271,7 +271,7 @@ export declare const u2Routes: OpenAPIHono<{
271
271
  } | {
272
272
  input: {
273
273
  param: {
274
- screen: "impersonate" | "signup" | "login" | "consent" | "reset-password" | "enter-password" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "login/email-verification" | "login/email-verification-sent" | "reset-password/code" | "reset-password/request" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/change-email" | "account/change-email/verify" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation";
274
+ screen: "login" | "signup" | "consent" | "impersonate" | "reset-password" | "enter-password" | "reset-password/request" | "reset-password/code" | "login/email-verification" | "login/email-verification-sent" | "account/change-email" | "account/change-email/verify" | "login/identifier" | "login/email-otp-challenge" | "login/sms-otp-challenge" | "login/magic-link-sent" | "login/login-passwordless-identifier" | "mfa/login-options" | "mfa/totp-challenge" | "mfa/totp-enrollment" | "mfa/phone-challenge" | "mfa/phone-enrollment" | "passkey/challenge" | "passkey/enrollment" | "passkey/enrollment-nudge" | "account/profile" | "account/security" | "account/security/totp-enrollment" | "account/security/phone-enrollment" | "account/linked" | "account/delete" | "account/passkeys" | "connect/start" | "connect/select-tenant" | "self-service/app" | "device/code" | "device/confirmation";
275
275
  };
276
276
  } & {
277
277
  query: {
@@ -36,11 +36,18 @@ export type { DarkModePreference, LogoPosition, ChipStyle, LanguageOption, } fro
36
36
  import type { Branding, Theme } from "@authhero/adapter-interfaces";
37
37
  import type { ContentfulStatusCode } from "hono/utils/http-status";
38
38
  import { type EmbedLoginContext } from "./embed";
39
+ /**
40
+ * Whether users may switch light/dark mode. Unset means yes, so existing
41
+ * tenants keep the toggle.
42
+ */
43
+ export declare function isDarkModeToggleEnabled(branding: Pick<Branding, "dark_mode_toggle"> | null | undefined): boolean;
39
44
  /**
40
45
  * Resolve the dark-mode preference for the current request.
41
46
  *
42
47
  * Priority: per-user `ah-dark-mode` cookie > tenant `branding.dark_mode` > "auto".
43
- * The cookie lets a user override the tenant default for the rest of their session.
48
+ * The cookie lets a user override the tenant default for the rest of their
49
+ * session. When the tenant turned the toggle off (`dark_mode_toggle: false`)
50
+ * the cookie is ignored, so the tenant's scheme always applies.
44
51
  */
45
52
  export declare function resolveDarkMode(ctx: any, branding: Branding | null | undefined): DarkModePreference;
46
53
  export type WidgetPageProps = {
@@ -82,6 +89,11 @@ export type WidgetPageProps = {
82
89
  termsAndConditionsUrl?: string;
83
90
  privacyUrl?: string;
84
91
  darkMode?: DarkModePreference;
92
+ /**
93
+ * Whether to render the user-facing dark-mode toggle. Defaults to true;
94
+ * false when the tenant locked the scheme (`branding.dark_mode_toggle`).
95
+ */
96
+ darkModeToggle?: boolean;
85
97
  /**
86
98
  * Where to render the tenant logo on the page.
87
99
  * - "widget" (default): inside the widget card, via the widget's own header.
@@ -142,8 +154,14 @@ export declare function buildHeadEssentials(opts: {
142
154
  clientName: string;
143
155
  branding?: WidgetPageProps["branding"];
144
156
  theme?: any;
157
+ /**
158
+ * The resolved scheme. The tenant's template owns `<html>`, so a fixed
159
+ * "light"/"dark" is applied by a script that sets the mode class before
160
+ * the dark-mode runtime reads it. "auto" (or unset) follows the OS.
161
+ */
162
+ darkMode?: DarkModePreference;
145
163
  }): string;
146
- export declare function WidgetPage({ widgetHtml, screenId, branding, theme, themePageBackground, clientName, poweredByLogo, language, availableLanguages, termsAndConditionsUrl, privacyUrl, darkMode, logoPosition, extraScript, customBodyHtml, embed, embeddedBrowser, }: WidgetPageProps): import("hono/jsx/jsx-dev-runtime").JSX.Element;
164
+ export declare function WidgetPage({ widgetHtml, screenId, branding, theme, themePageBackground, clientName, poweredByLogo, language, availableLanguages, termsAndConditionsUrl, privacyUrl, darkMode, darkModeToggle, logoPosition, extraScript, customBodyHtml, embed, embeddedBrowser, }: WidgetPageProps): import("hono/jsx/jsx-dev-runtime").JSX.Element;
147
165
  /**
148
166
  * Reads `theme.page_background.logo_placement` and returns the resolved
149
167
  * page-level `logoPosition` plus a theme variant suitable for passing to
@@ -55,12 +55,20 @@ export declare const DEFAULT_UNIVERSAL_LOGIN_TEMPLATE = "<div class=\"ah-widget-
55
55
  export type TemplateSlotOptions = {
56
56
  widgetHtml: string;
57
57
  logoUrl?: string | null;
58
+ /** Dark-scheme logo; page CSS swaps it in under the dark scheme. */
59
+ logoUrlDark?: string | null;
58
60
  clientName: string;
59
61
  darkMode: DarkModePreference;
62
+ /**
63
+ * Whether the user-facing dark-mode toggle renders. Defaults to true; false
64
+ * when the tenant locked the scheme (`branding.dark_mode_toggle`).
65
+ */
66
+ darkModeToggle?: boolean;
60
67
  language?: string;
61
68
  availableLanguages?: string[];
62
69
  poweredBy?: {
63
70
  url: string;
71
+ darkUrl?: string;
64
72
  href?: string;
65
73
  alt?: string;
66
74
  height?: number;
@@ -280,7 +280,7 @@ export declare const loginSessionMachine: import("xstate").StateMachine<LoginSes
280
280
  }, {
281
281
  type: "passwordResetRequested";
282
282
  params: unknown;
283
- }, never, "pending" | "failed" | "expired" | "completed" | "authenticated" | "awaiting_email_verification" | "awaiting_mfa" | "awaiting_consent" | "awaiting_hook" | "awaiting_continuation", string, import("xstate").NonReducibleUnknown, import("xstate").NonReducibleUnknown, import("xstate").EventObject, import("xstate").MetaObject, {
283
+ }, never, "expired" | "pending" | "failed" | "authenticated" | "awaiting_email_verification" | "awaiting_mfa" | "awaiting_consent" | "awaiting_hook" | "awaiting_continuation" | "completed", string, import("xstate").NonReducibleUnknown, import("xstate").NonReducibleUnknown, import("xstate").EventObject, import("xstate").MetaObject, {
284
284
  id: "loginSession";
285
285
  states: {
286
286
  readonly pending: {};
@@ -2,7 +2,7 @@ import { Context } from "hono";
2
2
  import { Connection } from "@authhero/adapter-interfaces";
3
3
  import { Bindings, Variables } from "../types";
4
4
  export declare const displayName = "Apple";
5
- export declare const logoDataUri = "data:image/svg+xml,%3Csvg%20width%3D%2245%22%20height%3D%2245%22%20viewBox%3D%220%200%2045%2045%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M45%200H0V45H45V0Z%22%20fill%3D%22white%22%2F%3E%3Cpath%20d%3D%22M23.5344%2010.3846C25.5313%2010.3846%2028.0344%209.01144%2029.525%207.18055C30.875%205.5213%2031.8594%203.20407%2031.8594%200.886839C31.8594%200.572154%2031.8313%200.25747%2031.775%200C29.5531%200.0858233%2026.8813%201.51621%2025.2781%203.43293C24.0125%204.89193%2022.8594%207.18055%2022.8594%209.52638C22.8594%209.86968%2022.9156%2010.213%2022.9438%2010.3274C23.0844%2010.356%2023.3094%2010.3846%2023.5344%2010.3846ZM16.5031%2045C19.2313%2045%2020.4406%2043.1405%2023.8438%2043.1405C27.3031%2043.1405%2028.0625%2044.9428%2031.1%2044.9428C34.0813%2044.9428%2036.0781%2042.1392%2037.9625%2039.3929C40.0719%2036.246%2040.9438%2033.1564%2041%2033.0134C40.8031%2032.9561%2035.0938%2030.5817%2035.0938%2023.9161C35.0938%2018.1373%2039.5938%2015.534%2039.8469%2015.3338C36.8656%2010.9854%2032.3375%2010.8709%2031.1%2010.8709C27.7531%2010.8709%2025.025%2012.9307%2023.3094%2012.9307C21.4531%2012.9307%2019.0063%2010.9854%2016.1094%2010.9854C10.5969%2010.9854%205%2015.6198%205%2024.3738C5%2029.8093%207.08125%2035.5594%209.64063%2039.2784C11.8344%2042.4253%2013.7469%2045%2016.5031%2045Z%22%20fill%3D%22black%22%2F%3E%3C%2Fsvg%3E";
5
+ export declare const logoDataUri = "data:image/svg+xml,%3Csvg%20width%3D%2245%22%20height%3D%2245%22%20viewBox%3D%220%200%2045%2045%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M23.5344%2010.3846C25.5313%2010.3846%2028.0344%209.01144%2029.525%207.18055C30.875%205.5213%2031.8594%203.20407%2031.8594%200.886839C31.8594%200.572154%2031.8313%200.25747%2031.775%200C29.5531%200.0858233%2026.8813%201.51621%2025.2781%203.43293C24.0125%204.89193%2022.8594%207.18055%2022.8594%209.52638C22.8594%209.86968%2022.9156%2010.213%2022.9438%2010.3274C23.0844%2010.356%2023.3094%2010.3846%2023.5344%2010.3846ZM16.5031%2045C19.2313%2045%2020.4406%2043.1405%2023.8438%2043.1405C27.3031%2043.1405%2028.0625%2044.9428%2031.1%2044.9428C34.0813%2044.9428%2036.0781%2042.1392%2037.9625%2039.3929C40.0719%2036.246%2040.9438%2033.1564%2041%2033.0134C40.8031%2032.9561%2035.0938%2030.5817%2035.0938%2023.9161C35.0938%2018.1373%2039.5938%2015.534%2039.8469%2015.3338C36.8656%2010.9854%2032.3375%2010.8709%2031.1%2010.8709C27.7531%2010.8709%2025.025%2012.9307%2023.3094%2012.9307C21.4531%2012.9307%2019.0063%2010.9854%2016.1094%2010.9854C10.5969%2010.9854%205%2015.6198%205%2024.3738C5%2029.8093%207.08125%2035.5594%209.64063%2039.2784C11.8344%2042.4253%2013.7469%2045%2016.5031%2045Z%22%20fill%3D%22black%22%2F%3E%3C%2Fsvg%3E";
6
6
  export declare function getRedirect(ctx: Context<{
7
7
  Bindings: Bindings;
8
8
  Variables: Variables;
package/package.json CHANGED
@@ -11,7 +11,7 @@
11
11
  "type": "git",
12
12
  "url": "https://github.com/sesamyab/authhero"
13
13
  },
14
- "version": "9.43.0",
14
+ "version": "9.44.1",
15
15
  "files": [
16
16
  "dist"
17
17
  ],
@@ -65,8 +65,8 @@
65
65
  "vite-plugin-dts": "^4.5.4",
66
66
  "vitest": "^4.1.7",
67
67
  "xml-crypto": "^6.1.2",
68
- "@authhero/kysely-adapter": "12.25.1",
69
- "@authhero/widget": "0.43.2"
68
+ "@authhero/kysely-adapter": "12.26.0",
69
+ "@authhero/widget": "0.44.1"
70
70
  },
71
71
  "dependencies": {
72
72
  "@peculiar/x509": "^1.14.3",
@@ -84,12 +84,12 @@
84
84
  "qrcode": "^1.5.4",
85
85
  "sanitize-html": "^2.17.4",
86
86
  "xstate": "^5.31.1",
87
- "@authhero/saml": "0.7.0",
88
- "@authhero/proxy": "0.11.24",
89
- "@authhero/adapter-interfaces": "4.37.0"
87
+ "@authhero/proxy": "0.11.25",
88
+ "@authhero/adapter-interfaces": "4.38.0",
89
+ "@authhero/saml": "0.7.1"
90
90
  },
91
91
  "peerDependencies": {
92
- "@authhero/widget": ">=0.38.9",
92
+ "@authhero/widget": ">=0.42.0",
93
93
  "@hono/zod-openapi": "^1.4.0",
94
94
  "hono": "^4.8.7",
95
95
  "ua-parser-js": "^2.0.0"