authhero 9.20.0 → 9.21.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.
Files changed (49) hide show
  1. package/dist/assets/u/widget/authhero-widget.esm.js +1 -1
  2. package/dist/assets/u/widget/p-dc0662ad.entry.js +1 -0
  3. package/dist/authhero.cjs +115 -115
  4. package/dist/authhero.d.ts +203 -187
  5. package/dist/authhero.mjs +13154 -13072
  6. package/dist/tsconfig.types.tsbuildinfo +1 -1
  7. package/dist/types/authentication-flows/auth0-migration.d.ts +2 -2
  8. package/dist/types/authentication-flows/passwordless.d.ts +3 -3
  9. package/dist/types/generated/locale-types.d.ts +1 -0
  10. package/dist/types/helpers/request-data.d.ts +9 -0
  11. package/dist/types/helpers/reserved-claims.d.ts +2 -2
  12. package/dist/types/index.d.ts +195 -187
  13. package/dist/types/routes/auth-api/account.d.ts +2 -2
  14. package/dist/types/routes/auth-api/index.d.ts +8 -8
  15. package/dist/types/routes/auth-api/passwordless.d.ts +4 -4
  16. package/dist/types/routes/auth-api/register/index.d.ts +2 -2
  17. package/dist/types/routes/auth-api/token.d.ts +10 -10
  18. package/dist/types/routes/management-api/action-executions.d.ts +2 -2
  19. package/dist/types/routes/management-api/actions.d.ts +1 -1
  20. package/dist/types/routes/management-api/authentication-methods.d.ts +1 -1
  21. package/dist/types/routes/management-api/client-grants.d.ts +9 -9
  22. package/dist/types/routes/management-api/clients.d.ts +14 -14
  23. package/dist/types/routes/management-api/connections.d.ts +7 -7
  24. package/dist/types/routes/management-api/email-templates.d.ts +18 -18
  25. package/dist/types/routes/management-api/flows.d.ts +7 -7
  26. package/dist/types/routes/management-api/guardian.d.ts +5 -5
  27. package/dist/types/routes/management-api/helpers.d.ts +1 -1
  28. package/dist/types/routes/management-api/hook-code.d.ts +2 -2
  29. package/dist/types/routes/management-api/index.d.ts +176 -168
  30. package/dist/types/routes/management-api/keys.d.ts +12 -12
  31. package/dist/types/routes/management-api/log-streams.d.ts +6 -6
  32. package/dist/types/routes/management-api/logs.d.ts +4 -4
  33. package/dist/types/routes/management-api/migration-sources.d.ts +6 -6
  34. package/dist/types/routes/management-api/organizations.d.ts +5 -5
  35. package/dist/types/routes/management-api/prompts.d.ts +4 -4
  36. package/dist/types/routes/management-api/roles.d.ts +10 -2
  37. package/dist/types/routes/management-api/tenant-operations.d.ts +1 -1
  38. package/dist/types/routes/management-api/tenants.d.ts +5 -5
  39. package/dist/types/routes/management-api/themes.d.ts +6 -6
  40. package/dist/types/routes/management-api/users.d.ts +12 -12
  41. package/dist/types/routes/universal-login/common.d.ts +12 -12
  42. package/dist/types/routes/universal-login/flow-api.d.ts +4 -4
  43. package/dist/types/routes/universal-login/identifier.d.ts +2 -2
  44. package/dist/types/routes/universal-login/u2-index.d.ts +5 -5
  45. package/dist/types/routes/universal-login/u2-routes.d.ts +5 -5
  46. package/dist/types/types/AuthError.d.ts +1 -1
  47. package/dist/types/types/Variables.d.ts +8 -0
  48. package/package.json +6 -6
  49. package/dist/assets/u/widget/p-36898e2d.entry.js +0 -1
@@ -43,8 +43,8 @@ interface AttemptUpstreamPasswordParams {
43
43
  * via the password-realm grant. On success, creates the local user (if
44
44
  * missing), stores the bcrypt hash of the password locally, and returns the
45
45
  * user. On any failure, returns null — the caller surfaces the existing
46
- * INVALID_PASSWORD/USER_NOT_FOUND error so the upstream's existence is not
47
- * leaked to clients.
46
+ * INVALID_CREDENTIALS error so the upstream's existence is not leaked to
47
+ * clients.
48
48
  *
49
49
  * Subsequent logins are served entirely locally because the password row now
50
50
  * exists on our side.
@@ -475,7 +475,7 @@ export declare function passwordlessGrantUser(ctx: Context<{
475
475
  custom_login_page_preview?: string | undefined;
476
476
  form_template?: string | undefined;
477
477
  addons?: Record<string, any> | undefined;
478
- token_endpoint_auth_method?: "none" | "client_secret_post" | "client_secret_basic" | "client_secret_jwt" | "private_key_jwt" | undefined;
478
+ token_endpoint_auth_method?: "client_secret_post" | "client_secret_basic" | "none" | "client_secret_jwt" | "private_key_jwt" | undefined;
479
479
  client_metadata?: Record<string, string> | undefined;
480
480
  hide_sign_up_disabled_error?: boolean | undefined;
481
481
  mobile?: Record<string, any> | undefined;
@@ -561,8 +561,8 @@ export declare function passwordlessGrantUser(ctx: Context<{
561
561
  } | undefined;
562
562
  authenticated_at?: string | undefined;
563
563
  };
564
- connectionType: "username" | "sms" | "email";
565
- authConnection: "username" | "sms" | "email";
564
+ connectionType: "email" | "username" | "sms";
565
+ authConnection: "email" | "username" | "sms";
566
566
  session_id: string | undefined;
567
567
  authParams: {
568
568
  audience?: string | undefined;
@@ -2,6 +2,7 @@ export type Locale = "cs" | "da" | "en" | "fi" | "it" | "nb" | "pl" | "sv";
2
2
  export interface CommonScreen {
3
3
  alertListTitle: () => string;
4
4
  backText: () => string;
5
+ backToLoginText: () => string;
5
6
  cancelText: () => string;
6
7
  closeText: () => string;
7
8
  contactSupportText: () => string;
@@ -13,3 +13,12 @@ export declare function setRequestData(ctx: Context<{
13
13
  Bindings: Bindings;
14
14
  Variables: Variables;
15
15
  }>, data: DataAdapters): void;
16
+ /**
17
+ * The raw adapter a route group composes its per-request stack on: the base
18
+ * an earlier middleware installed on `ctx.var.baseData` (per-tenant database
19
+ * isolation), or `fallback`, the startup adapter from the config.
20
+ */
21
+ export declare function getBaseData(ctx: Context<{
22
+ Bindings: Bindings;
23
+ Variables: Variables;
24
+ }>, fallback: DataAdapters): DataAdapters;
@@ -14,9 +14,9 @@ export declare const USERINFO_RESERVED_CLAIMS: readonly ["iss", "sub", "aud", "e
14
14
  * vendor/tenant for downstream APIs while `sub` stays `auth-service`.
15
15
  * Client-bound mints keep `azp` locked (see below).
16
16
  */
17
- export declare const SERVICE_TOKEN_RESERVED_CLAIMS: ("tenant_id" | "client_id" | "org_name" | "sub" | "sid" | "scope" | "permissions" | "iat" | "org_id" | "aud" | "auth_time" | "exp" | "iss" | "acr" | "amr" | "nbf" | "jti" | "act" | "requested_userinfo_claims" | "gty")[];
17
+ export declare const SERVICE_TOKEN_RESERVED_CLAIMS: ("sub" | "permissions" | "tenant_id" | "client_id" | "org_name" | "scope" | "sid" | "exp" | "iat" | "org_id" | "iss" | "aud" | "auth_time" | "acr" | "amr" | "nbf" | "jti" | "act" | "requested_userinfo_claims" | "gty")[];
18
18
  /** Client-bound mints: `azp` must stay the registered client id. */
19
- export declare const CLIENT_SERVICE_TOKEN_RESERVED_CLAIMS: ("tenant_id" | "client_id" | "org_name" | "sub" | "sid" | "scope" | "permissions" | "iat" | "org_id" | "aud" | "auth_time" | "exp" | "iss" | "acr" | "amr" | "azp" | "nbf" | "jti" | "act" | "requested_userinfo_claims" | "gty")[];
19
+ export declare const CLIENT_SERVICE_TOKEN_RESERVED_CLAIMS: ("sub" | "permissions" | "tenant_id" | "client_id" | "org_name" | "scope" | "sid" | "exp" | "iat" | "org_id" | "iss" | "aud" | "auth_time" | "acr" | "amr" | "azp" | "nbf" | "jti" | "act" | "requested_userinfo_claims" | "gty")[];
20
20
  export type AccessTokenReservedClaim = (typeof ACCESS_TOKEN_RESERVED_CLAIMS)[number];
21
21
  export type IdTokenReservedClaim = (typeof ID_TOKEN_RESERVED_CLAIMS)[number];
22
22
  /**