@logto/schemas 1.21.0 → 1.23.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 (72) hide show
  1. package/alterations/1.22.0-1730689363-add-account-center.ts +31 -0
  2. package/alterations/1.22.0-1731054001-init-account-center.ts +43 -0
  3. package/alterations/1.22.0-1731304920-add-support-email-and-website-to-sie-table.ts +22 -0
  4. package/alterations/1.22.0-1731377260-add-unknown-session-redirect-url-to-sie.ts +20 -0
  5. package/alterations/1.22.0-1731900596-add-saml-application-type.ts +50 -0
  6. package/alterations/1.22.0-1731900631-add-saml-app-third-party-consistency-check.ts +20 -0
  7. package/alterations/1.22.0-1731901231-add-saml-application-secrets-table.ts +40 -0
  8. package/alterations/1.22.0-1731904029-add-saml-application-configs-table.ts +33 -0
  9. package/alterations/1.23.0-1732851150-rename-saml-application-constraints.ts +34 -0
  10. package/alterations/1.23.0-1733212543-add-saml-application-type-to-idp-initiated-sso-application-allow-list.ts +30 -0
  11. package/alterations/1.23.0-1735012422-add-saml-application-sessions-table.ts +37 -0
  12. package/alterations-js/1.22.0-1730689363-add-account-center.js +26 -0
  13. package/alterations-js/1.22.0-1731054001-init-account-center.js +35 -0
  14. package/alterations-js/1.22.0-1731304920-add-support-email-and-website-to-sie-table.js +18 -0
  15. package/alterations-js/1.22.0-1731377260-add-unknown-session-redirect-url-to-sie.js +16 -0
  16. package/alterations-js/1.22.0-1731900596-add-saml-application-type.js +46 -0
  17. package/alterations-js/1.22.0-1731900631-add-saml-app-third-party-consistency-check.js +16 -0
  18. package/alterations-js/1.22.0-1731901231-add-saml-application-secrets-table.js +35 -0
  19. package/alterations-js/1.22.0-1731904029-add-saml-application-configs-table.js +28 -0
  20. package/alterations-js/1.23.0-1732851150-rename-saml-application-constraints.js +28 -0
  21. package/alterations-js/1.23.0-1733212543-add-saml-application-type-to-idp-initiated-sso-application-allow-list.js +24 -0
  22. package/alterations-js/1.23.0-1735012422-add-saml-application-sessions-table.js +32 -0
  23. package/lib/consts/subscriptions.d.ts +16 -15
  24. package/lib/consts/subscriptions.js +16 -14
  25. package/lib/db-entries/account-center.d.ts +24 -0
  26. package/lib/db-entries/account-center.js +34 -0
  27. package/lib/db-entries/custom-types.d.ts +2 -1
  28. package/lib/db-entries/custom-types.js +1 -0
  29. package/lib/db-entries/index.d.ts +4 -0
  30. package/lib/db-entries/index.js +4 -0
  31. package/lib/db-entries/saml-application-config.d.ts +24 -0
  32. package/lib/db-entries/saml-application-config.js +38 -0
  33. package/lib/db-entries/saml-application-secret.d.ts +28 -0
  34. package/lib/db-entries/saml-application-secret.js +49 -0
  35. package/lib/db-entries/saml-application-session.d.ts +40 -0
  36. package/lib/db-entries/saml-application-session.js +53 -0
  37. package/lib/db-entries/sign-in-experience.d.ts +7 -1
  38. package/lib/db-entries/sign-in-experience.js +12 -0
  39. package/lib/foundations/jsonb-types/account-centers.d.ts +43 -0
  40. package/lib/foundations/jsonb-types/account-centers.js +25 -0
  41. package/lib/foundations/jsonb-types/index.d.ts +3 -0
  42. package/lib/foundations/jsonb-types/index.js +3 -0
  43. package/lib/foundations/jsonb-types/saml-application-configs.d.ts +21 -0
  44. package/lib/foundations/jsonb-types/saml-application-configs.js +11 -0
  45. package/lib/foundations/jsonb-types/saml-application-sessions.d.ts +45 -0
  46. package/lib/foundations/jsonb-types/saml-application-sessions.js +10 -0
  47. package/lib/foundations/jsonb-types/sign-in-experience.d.ts +9 -1
  48. package/lib/foundations/jsonb-types/sign-in-experience.js +8 -0
  49. package/lib/seeds/account-center.d.ts +2 -0
  50. package/lib/seeds/account-center.js +6 -0
  51. package/lib/seeds/index.d.ts +1 -0
  52. package/lib/seeds/index.js +1 -0
  53. package/lib/types/application.d.ts +6 -6
  54. package/lib/types/consent.d.ts +8 -8
  55. package/lib/types/hook.d.ts +2 -2
  56. package/lib/types/index.d.ts +1 -0
  57. package/lib/types/index.js +1 -0
  58. package/lib/types/logto-config/index.d.ts +9 -9
  59. package/lib/types/logto-config/jwt-customizer.d.ts +17 -17
  60. package/lib/types/saml-application.d.ts +493 -0
  61. package/lib/types/saml-application.js +54 -0
  62. package/lib/types/sign-in-experience.d.ts +10 -1
  63. package/lib/types/user.d.ts +7 -7
  64. package/lib/utils/application.js +2 -0
  65. package/package.json +8 -8
  66. package/tables/account_centers.sql +10 -0
  67. package/tables/applications.sql +5 -2
  68. package/tables/saml_application_configs.sql +15 -0
  69. package/tables/saml_application_secrets.sql +22 -0
  70. package/tables/saml_application_sessions.sql +23 -0
  71. package/tables/sign_in_experiences.sql +3 -0
  72. package/tables/sso_connector_idp_initiated_auth_configs.sql +1 -1
@@ -151,7 +151,7 @@ export declare const jwtCustomizerUserContextGuard: z.ZodObject<z.objectUtil.ext
151
151
  lastSignInAt: ZodType<number | null, z.ZodTypeDef, number | null>;
152
152
  createdAt: ZodType<number, z.ZodTypeDef, number>;
153
153
  updatedAt: ZodType<number, z.ZodTypeDef, number>;
154
- }, "name" | "id" | "applicationId" | "username" | "createdAt" | "profile" | "customData" | "updatedAt" | "primaryEmail" | "primaryPhone" | "avatar" | "identities" | "isSuspended" | "lastSignInAt">, {
154
+ }, "name" | "id" | "applicationId" | "username" | "createdAt" | "profile" | "avatar" | "customData" | "updatedAt" | "primaryEmail" | "primaryPhone" | "identities" | "isSuspended" | "lastSignInAt">, {
155
155
  hasPassword: z.ZodBoolean;
156
156
  ssoIdentities: z.ZodArray<z.ZodObject<Pick<{
157
157
  tenantId: ZodType<string, z.ZodTypeDef, string>;
@@ -273,6 +273,7 @@ export declare const jwtCustomizerUserContextGuard: z.ZodObject<z.objectUtil.ext
273
273
  username: string | null;
274
274
  createdAt: number;
275
275
  profile: import("../../foundations/index.js").UserProfile;
276
+ avatar: string | null;
276
277
  customData: import("@withtyped/server/lib/types.js").JsonObject;
277
278
  updatedAt: number;
278
279
  organizations: {
@@ -294,7 +295,6 @@ export declare const jwtCustomizerUserContextGuard: z.ZodObject<z.objectUtil.ext
294
295
  }[];
295
296
  primaryEmail: string | null;
296
297
  primaryPhone: string | null;
297
- avatar: string | null;
298
298
  identities: import("../../foundations/index.js").Identities;
299
299
  isSuspended: boolean;
300
300
  lastSignInAt: number | null;
@@ -317,6 +317,7 @@ export declare const jwtCustomizerUserContextGuard: z.ZodObject<z.objectUtil.ext
317
317
  username: string | null;
318
318
  createdAt: number;
319
319
  profile: import("../../foundations/index.js").UserProfile;
320
+ avatar: string | null;
320
321
  customData: import("@withtyped/server/lib/types.js").JsonObject;
321
322
  updatedAt: number;
322
323
  organizations: {
@@ -338,7 +339,6 @@ export declare const jwtCustomizerUserContextGuard: z.ZodObject<z.objectUtil.ext
338
339
  }[];
339
340
  primaryEmail: string | null;
340
341
  primaryPhone: string | null;
341
- avatar: string | null;
342
342
  identities: import("../../foundations/index.js").Identities;
343
343
  isSuspended: boolean;
344
344
  lastSignInAt: number | null;
@@ -456,11 +456,11 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
456
456
  country: string;
457
457
  }>;
458
458
  }>>>;
459
+ avatar: z.ZodOptional<ZodType<string | null, z.ZodTypeDef, string | null>>;
459
460
  customData: z.ZodOptional<ZodType<import("@withtyped/server/lib/types.js").JsonObject, z.ZodTypeDef, import("@withtyped/server/lib/types.js").JsonObject>>;
460
461
  updatedAt: z.ZodOptional<ZodType<number, z.ZodTypeDef, number>>;
461
462
  primaryEmail: z.ZodOptional<ZodType<string | null, z.ZodTypeDef, string | null>>;
462
463
  primaryPhone: z.ZodOptional<ZodType<string | null, z.ZodTypeDef, string | null>>;
463
- avatar: z.ZodOptional<ZodType<string | null, z.ZodTypeDef, string | null>>;
464
464
  identities: z.ZodOptional<ZodType<Record<string, {
465
465
  userId: string;
466
466
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -611,6 +611,7 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
611
611
  country: string;
612
612
  }>;
613
613
  }> | undefined;
614
+ avatar?: string | null | undefined;
614
615
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
615
616
  updatedAt?: number | undefined;
616
617
  organizations?: {
@@ -632,7 +633,6 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
632
633
  }[] | undefined;
633
634
  primaryEmail?: string | null | undefined;
634
635
  primaryPhone?: string | null | undefined;
635
- avatar?: string | null | undefined;
636
636
  identities?: Record<string, {
637
637
  userId: string;
638
638
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -678,6 +678,7 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
678
678
  country: string;
679
679
  }>;
680
680
  }> | undefined;
681
+ avatar?: string | null | undefined;
681
682
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
682
683
  updatedAt?: number | undefined;
683
684
  organizations?: {
@@ -699,7 +700,6 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
699
700
  }[] | undefined;
700
701
  primaryEmail?: string | null | undefined;
701
702
  primaryPhone?: string | null | undefined;
702
- avatar?: string | null | undefined;
703
703
  identities?: Record<string, {
704
704
  userId: string;
705
705
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -757,6 +757,7 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
757
757
  country: string;
758
758
  }>;
759
759
  }> | undefined;
760
+ avatar?: string | null | undefined;
760
761
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
761
762
  updatedAt?: number | undefined;
762
763
  organizations?: {
@@ -778,7 +779,6 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
778
779
  }[] | undefined;
779
780
  primaryEmail?: string | null | undefined;
780
781
  primaryPhone?: string | null | undefined;
781
- avatar?: string | null | undefined;
782
782
  identities?: Record<string, {
783
783
  userId: string;
784
784
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -830,6 +830,7 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
830
830
  country: string;
831
831
  }>;
832
832
  }> | undefined;
833
+ avatar?: string | null | undefined;
833
834
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
834
835
  updatedAt?: number | undefined;
835
836
  organizations?: {
@@ -851,7 +852,6 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
851
852
  }[] | undefined;
852
853
  primaryEmail?: string | null | undefined;
853
854
  primaryPhone?: string | null | undefined;
854
- avatar?: string | null | undefined;
855
855
  identities?: Record<string, {
856
856
  userId: string;
857
857
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -907,6 +907,7 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
907
907
  country: string;
908
908
  }>;
909
909
  }> | undefined;
910
+ avatar?: string | null | undefined;
910
911
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
911
912
  updatedAt?: number | undefined;
912
913
  organizations?: {
@@ -928,7 +929,6 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
928
929
  }[] | undefined;
929
930
  primaryEmail?: string | null | undefined;
930
931
  primaryPhone?: string | null | undefined;
931
- avatar?: string | null | undefined;
932
932
  identities?: Record<string, {
933
933
  userId: string;
934
934
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -997,6 +997,7 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
997
997
  country: string;
998
998
  }>;
999
999
  }> | undefined;
1000
+ avatar?: string | null | undefined;
1000
1001
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
1001
1002
  updatedAt?: number | undefined;
1002
1003
  organizations?: {
@@ -1018,7 +1019,6 @@ export declare const accessTokenJwtCustomizerGuard: z.ZodObject<z.objectUtil.ext
1018
1019
  }[] | undefined;
1019
1020
  primaryEmail?: string | null | undefined;
1020
1021
  primaryPhone?: string | null | undefined;
1021
- avatar?: string | null | undefined;
1022
1022
  identities?: Record<string, {
1023
1023
  userId: string;
1024
1024
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -1199,11 +1199,11 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1199
1199
  country: string;
1200
1200
  }>;
1201
1201
  }>>>;
1202
+ avatar: z.ZodOptional<ZodType<string | null, z.ZodTypeDef, string | null>>;
1202
1203
  customData: z.ZodOptional<ZodType<import("@withtyped/server/lib/types.js").JsonObject, z.ZodTypeDef, import("@withtyped/server/lib/types.js").JsonObject>>;
1203
1204
  updatedAt: z.ZodOptional<ZodType<number, z.ZodTypeDef, number>>;
1204
1205
  primaryEmail: z.ZodOptional<ZodType<string | null, z.ZodTypeDef, string | null>>;
1205
1206
  primaryPhone: z.ZodOptional<ZodType<string | null, z.ZodTypeDef, string | null>>;
1206
- avatar: z.ZodOptional<ZodType<string | null, z.ZodTypeDef, string | null>>;
1207
1207
  identities: z.ZodOptional<ZodType<Record<string, {
1208
1208
  userId: string;
1209
1209
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -1354,6 +1354,7 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1354
1354
  country: string;
1355
1355
  }>;
1356
1356
  }> | undefined;
1357
+ avatar?: string | null | undefined;
1357
1358
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
1358
1359
  updatedAt?: number | undefined;
1359
1360
  organizations?: {
@@ -1375,7 +1376,6 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1375
1376
  }[] | undefined;
1376
1377
  primaryEmail?: string | null | undefined;
1377
1378
  primaryPhone?: string | null | undefined;
1378
- avatar?: string | null | undefined;
1379
1379
  identities?: Record<string, {
1380
1380
  userId: string;
1381
1381
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -1421,6 +1421,7 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1421
1421
  country: string;
1422
1422
  }>;
1423
1423
  }> | undefined;
1424
+ avatar?: string | null | undefined;
1424
1425
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
1425
1426
  updatedAt?: number | undefined;
1426
1427
  organizations?: {
@@ -1442,7 +1443,6 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1442
1443
  }[] | undefined;
1443
1444
  primaryEmail?: string | null | undefined;
1444
1445
  primaryPhone?: string | null | undefined;
1445
- avatar?: string | null | undefined;
1446
1446
  identities?: Record<string, {
1447
1447
  userId: string;
1448
1448
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -1500,6 +1500,7 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1500
1500
  country: string;
1501
1501
  }>;
1502
1502
  }> | undefined;
1503
+ avatar?: string | null | undefined;
1503
1504
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
1504
1505
  updatedAt?: number | undefined;
1505
1506
  organizations?: {
@@ -1521,7 +1522,6 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1521
1522
  }[] | undefined;
1522
1523
  primaryEmail?: string | null | undefined;
1523
1524
  primaryPhone?: string | null | undefined;
1524
- avatar?: string | null | undefined;
1525
1525
  identities?: Record<string, {
1526
1526
  userId: string;
1527
1527
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -1573,6 +1573,7 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1573
1573
  country: string;
1574
1574
  }>;
1575
1575
  }> | undefined;
1576
+ avatar?: string | null | undefined;
1576
1577
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
1577
1578
  updatedAt?: number | undefined;
1578
1579
  organizations?: {
@@ -1594,7 +1595,6 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1594
1595
  }[] | undefined;
1595
1596
  primaryEmail?: string | null | undefined;
1596
1597
  primaryPhone?: string | null | undefined;
1597
- avatar?: string | null | undefined;
1598
1598
  identities?: Record<string, {
1599
1599
  userId: string;
1600
1600
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -1651,6 +1651,7 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1651
1651
  country: string;
1652
1652
  }>;
1653
1653
  }> | undefined;
1654
+ avatar?: string | null | undefined;
1654
1655
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
1655
1656
  updatedAt?: number | undefined;
1656
1657
  organizations?: {
@@ -1672,7 +1673,6 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1672
1673
  }[] | undefined;
1673
1674
  primaryEmail?: string | null | undefined;
1674
1675
  primaryPhone?: string | null | undefined;
1675
- avatar?: string | null | undefined;
1676
1676
  identities?: Record<string, {
1677
1677
  userId: string;
1678
1678
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;
@@ -1742,6 +1742,7 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1742
1742
  country: string;
1743
1743
  }>;
1744
1744
  }> | undefined;
1745
+ avatar?: string | null | undefined;
1745
1746
  customData?: import("@withtyped/server/lib/types.js").JsonObject | undefined;
1746
1747
  updatedAt?: number | undefined;
1747
1748
  organizations?: {
@@ -1763,7 +1764,6 @@ export declare const jwtCustomizerTestRequestBodyGuard: z.ZodDiscriminatedUnion<
1763
1764
  }[] | undefined;
1764
1765
  primaryEmail?: string | null | undefined;
1765
1766
  primaryPhone?: string | null | undefined;
1766
- avatar?: string | null | undefined;
1767
1767
  identities?: Record<string, {
1768
1768
  userId: string;
1769
1769
  details?: Record<string, import("@withtyped/server/lib/types.js").Json> | undefined;