@authhero/kysely-adapter 0.5.1 → 0.5.2

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.
@@ -297,94 +297,6 @@ declare enum CodeChallengeMethod {
297
297
  S265 = "S256",
298
298
  plain = "plain"
299
299
  }
300
- declare const authenticationCodeSchema: z.ZodObject<{
301
- created_at: z.ZodString;
302
- authParams: z.ZodObject<{
303
- client_id: z.ZodString;
304
- vendor_id: z.ZodOptional<z.ZodString>;
305
- response_type: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseType>>;
306
- response_mode: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseMode>>;
307
- redirect_uri: z.ZodOptional<z.ZodString>;
308
- audience: z.ZodOptional<z.ZodString>;
309
- state: z.ZodOptional<z.ZodString>;
310
- nonce: z.ZodOptional<z.ZodString>;
311
- scope: z.ZodOptional<z.ZodString>;
312
- code_challenge_method: z.ZodOptional<z.ZodNativeEnum<typeof CodeChallengeMethod>>;
313
- code_challenge: z.ZodOptional<z.ZodString>;
314
- username: z.ZodOptional<z.ZodString>;
315
- }, "strip", z.ZodTypeAny, {
316
- client_id: string;
317
- username?: string | undefined;
318
- vendor_id?: string | undefined;
319
- response_type?: AuthorizationResponseType | undefined;
320
- response_mode?: AuthorizationResponseMode | undefined;
321
- redirect_uri?: string | undefined;
322
- audience?: string | undefined;
323
- state?: string | undefined;
324
- nonce?: string | undefined;
325
- scope?: string | undefined;
326
- code_challenge_method?: CodeChallengeMethod | undefined;
327
- code_challenge?: string | undefined;
328
- }, {
329
- client_id: string;
330
- username?: string | undefined;
331
- vendor_id?: string | undefined;
332
- response_type?: AuthorizationResponseType | undefined;
333
- response_mode?: AuthorizationResponseMode | undefined;
334
- redirect_uri?: string | undefined;
335
- audience?: string | undefined;
336
- state?: string | undefined;
337
- nonce?: string | undefined;
338
- scope?: string | undefined;
339
- code_challenge_method?: CodeChallengeMethod | undefined;
340
- code_challenge?: string | undefined;
341
- }>;
342
- code: z.ZodString;
343
- user_id: z.ZodString;
344
- expires_at: z.ZodString;
345
- used_at: z.ZodOptional<z.ZodString>;
346
- }, "strip", z.ZodTypeAny, {
347
- code: string;
348
- created_at: string;
349
- user_id: string;
350
- authParams: {
351
- client_id: string;
352
- username?: string | undefined;
353
- vendor_id?: string | undefined;
354
- response_type?: AuthorizationResponseType | undefined;
355
- response_mode?: AuthorizationResponseMode | undefined;
356
- redirect_uri?: string | undefined;
357
- audience?: string | undefined;
358
- state?: string | undefined;
359
- nonce?: string | undefined;
360
- scope?: string | undefined;
361
- code_challenge_method?: CodeChallengeMethod | undefined;
362
- code_challenge?: string | undefined;
363
- };
364
- expires_at: string;
365
- used_at?: string | undefined;
366
- }, {
367
- code: string;
368
- created_at: string;
369
- user_id: string;
370
- authParams: {
371
- client_id: string;
372
- username?: string | undefined;
373
- vendor_id?: string | undefined;
374
- response_type?: AuthorizationResponseType | undefined;
375
- response_mode?: AuthorizationResponseMode | undefined;
376
- redirect_uri?: string | undefined;
377
- audience?: string | undefined;
378
- state?: string | undefined;
379
- nonce?: string | undefined;
380
- scope?: string | undefined;
381
- code_challenge_method?: CodeChallengeMethod | undefined;
382
- code_challenge?: string | undefined;
383
- };
384
- expires_at: string;
385
- used_at?: string | undefined;
386
- }>;
387
- export type AuthenticationCode = z.infer<typeof authenticationCodeSchema>;
388
300
  declare const brandingSchema: z.ZodObject<{
389
301
  colors: z.ZodOptional<z.ZodObject<{
390
302
  primary: z.ZodString;
@@ -462,15 +374,45 @@ declare const brandingSchema: z.ZodObject<{
462
374
  } | undefined;
463
375
  }>;
464
376
  export type Branding = z.infer<typeof brandingSchema>;
465
- export interface Code {
466
- id: string;
467
- code: string;
468
- type: "password_reset" | "validation";
377
+ declare const codeTypeSchema: z.ZodEnum<[
378
+ "password_reset",
379
+ "email_verification",
380
+ "otp",
381
+ "oauth2",
382
+ "oauth2_state",
383
+ "ticket"
384
+ ]>;
385
+ export type CodeType = z.infer<typeof codeTypeSchema>;
386
+ declare const codeSchema: z.ZodObject<{
387
+ code_id: z.ZodString;
388
+ login_id: z.ZodString;
389
+ code_type: z.ZodEnum<[
390
+ "password_reset",
391
+ "email_verification",
392
+ "otp",
393
+ "oauth2",
394
+ "oauth2_state",
395
+ "ticket"
396
+ ]>;
397
+ created_at: z.ZodString;
398
+ expires_at: z.ZodString;
399
+ used_at: z.ZodOptional<z.ZodString>;
400
+ }, "strip", z.ZodTypeAny, {
469
401
  created_at: string;
402
+ code_id: string;
403
+ login_id: string;
404
+ code_type: "password_reset" | "email_verification" | "otp" | "oauth2" | "oauth2_state" | "ticket";
470
405
  expires_at: string;
471
- used_at?: string;
472
- user_id: string;
473
- }
406
+ used_at?: string | undefined;
407
+ }, {
408
+ created_at: string;
409
+ code_id: string;
410
+ login_id: string;
411
+ code_type: "password_reset" | "email_verification" | "otp" | "oauth2" | "oauth2_state" | "ticket";
412
+ expires_at: string;
413
+ used_at?: string | undefined;
414
+ }>;
415
+ export type Code = z.infer<typeof codeSchema>;
474
416
  declare const connectionInsertSchema: z.ZodObject<{
475
417
  id: z.ZodOptional<z.ZodString>;
476
418
  name: z.ZodString;
@@ -796,258 +738,67 @@ export type LogsResponse = Log & {
796
738
  log_id: string;
797
739
  _id: string;
798
740
  };
799
- declare const otpInsertSchema: z.ZodObject<{
800
- id: z.ZodString;
801
- email: z.ZodString;
802
- code: z.ZodString;
803
- ip: z.ZodOptional<z.ZodString>;
804
- send: z.ZodEnum<[
805
- "code",
806
- "link"
807
- ]>;
808
- authParams: z.ZodObject<{
809
- client_id: z.ZodString;
810
- vendor_id: z.ZodOptional<z.ZodString>;
811
- response_type: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseType>>;
812
- response_mode: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseMode>>;
813
- redirect_uri: z.ZodOptional<z.ZodString>;
814
- audience: z.ZodOptional<z.ZodString>;
815
- state: z.ZodOptional<z.ZodString>;
816
- nonce: z.ZodOptional<z.ZodString>;
817
- scope: z.ZodOptional<z.ZodString>;
818
- code_challenge_method: z.ZodOptional<z.ZodNativeEnum<typeof CodeChallengeMethod>>;
819
- code_challenge: z.ZodOptional<z.ZodString>;
820
- username: z.ZodOptional<z.ZodString>;
821
- }, "strip", z.ZodTypeAny, {
822
- client_id: string;
823
- username?: string | undefined;
824
- vendor_id?: string | undefined;
825
- response_type?: AuthorizationResponseType | undefined;
826
- response_mode?: AuthorizationResponseMode | undefined;
827
- redirect_uri?: string | undefined;
828
- audience?: string | undefined;
829
- state?: string | undefined;
830
- nonce?: string | undefined;
831
- scope?: string | undefined;
832
- code_challenge_method?: CodeChallengeMethod | undefined;
833
- code_challenge?: string | undefined;
834
- }, {
835
- client_id: string;
836
- username?: string | undefined;
837
- vendor_id?: string | undefined;
838
- response_type?: AuthorizationResponseType | undefined;
839
- response_mode?: AuthorizationResponseMode | undefined;
840
- redirect_uri?: string | undefined;
841
- audience?: string | undefined;
842
- state?: string | undefined;
843
- nonce?: string | undefined;
844
- scope?: string | undefined;
845
- code_challenge_method?: CodeChallengeMethod | undefined;
846
- code_challenge?: string | undefined;
847
- }>;
741
+ declare const passwordInsertSchema: z.ZodObject<{
742
+ user_id: z.ZodString;
743
+ password: z.ZodString;
744
+ algorithm: z.ZodDefault<z.ZodEnum<[
745
+ "bcrypt",
746
+ "argon2id"
747
+ ]>>;
748
+ }, "strip", z.ZodTypeAny, {
749
+ password: string;
750
+ user_id: string;
751
+ algorithm: "bcrypt" | "argon2id";
752
+ }, {
753
+ password: string;
754
+ user_id: string;
755
+ algorithm?: "bcrypt" | "argon2id" | undefined;
756
+ }>;
757
+ export type PasswordInsert = z.infer<typeof passwordInsertSchema>;
758
+ declare const passwordSchema: z.ZodObject<{
759
+ created_at: z.ZodString;
760
+ updated_at: z.ZodString;
761
+ user_id: z.ZodString;
762
+ password: z.ZodString;
763
+ algorithm: z.ZodDefault<z.ZodEnum<[
764
+ "bcrypt",
765
+ "argon2id"
766
+ ]>>;
767
+ }, "strip", z.ZodTypeAny, {
768
+ password: string;
769
+ created_at: string;
770
+ updated_at: string;
771
+ user_id: string;
772
+ algorithm: "bcrypt" | "argon2id";
773
+ }, {
774
+ password: string;
775
+ created_at: string;
776
+ updated_at: string;
777
+ user_id: string;
778
+ algorithm?: "bcrypt" | "argon2id" | undefined;
779
+ }>;
780
+ export type Password = z.infer<typeof passwordSchema>;
781
+ declare const sessionInsertSchema: z.ZodObject<{
782
+ session_id: z.ZodString;
783
+ client_id: z.ZodString;
848
784
  expires_at: z.ZodString;
849
- used_at: z.ZodOptional<z.ZodString>;
850
- user_id: z.ZodOptional<z.ZodString>;
785
+ used_at: z.ZodString;
786
+ deleted_at: z.ZodOptional<z.ZodString>;
787
+ user_id: z.ZodString;
851
788
  }, "strip", z.ZodTypeAny, {
852
- code: string;
853
- email: string;
854
- id: string;
855
- authParams: {
856
- client_id: string;
857
- username?: string | undefined;
858
- vendor_id?: string | undefined;
859
- response_type?: AuthorizationResponseType | undefined;
860
- response_mode?: AuthorizationResponseMode | undefined;
861
- redirect_uri?: string | undefined;
862
- audience?: string | undefined;
863
- state?: string | undefined;
864
- nonce?: string | undefined;
865
- scope?: string | undefined;
866
- code_challenge_method?: CodeChallengeMethod | undefined;
867
- code_challenge?: string | undefined;
868
- };
789
+ user_id: string;
790
+ client_id: string;
869
791
  expires_at: string;
870
- send: "code" | "link";
871
- user_id?: string | undefined;
872
- used_at?: string | undefined;
873
- ip?: string | undefined;
792
+ used_at: string;
793
+ session_id: string;
794
+ deleted_at?: string | undefined;
874
795
  }, {
875
- code: string;
876
- email: string;
877
- id: string;
878
- authParams: {
879
- client_id: string;
880
- username?: string | undefined;
881
- vendor_id?: string | undefined;
882
- response_type?: AuthorizationResponseType | undefined;
883
- response_mode?: AuthorizationResponseMode | undefined;
884
- redirect_uri?: string | undefined;
885
- audience?: string | undefined;
886
- state?: string | undefined;
887
- nonce?: string | undefined;
888
- scope?: string | undefined;
889
- code_challenge_method?: CodeChallengeMethod | undefined;
890
- code_challenge?: string | undefined;
891
- };
796
+ user_id: string;
797
+ client_id: string;
892
798
  expires_at: string;
893
- send: "code" | "link";
894
- user_id?: string | undefined;
895
- used_at?: string | undefined;
896
- ip?: string | undefined;
897
- }>;
898
- export type OTPInsert = z.infer<typeof otpInsertSchema>;
899
- declare const otpSchema: z.ZodObject<{
900
- id: z.ZodString;
901
- email: z.ZodString;
902
- code: z.ZodString;
903
- ip: z.ZodOptional<z.ZodString>;
904
- send: z.ZodEnum<[
905
- "code",
906
- "link"
907
- ]>;
908
- authParams: z.ZodObject<{
909
- client_id: z.ZodString;
910
- vendor_id: z.ZodOptional<z.ZodString>;
911
- response_type: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseType>>;
912
- response_mode: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseMode>>;
913
- redirect_uri: z.ZodOptional<z.ZodString>;
914
- audience: z.ZodOptional<z.ZodString>;
915
- state: z.ZodOptional<z.ZodString>;
916
- nonce: z.ZodOptional<z.ZodString>;
917
- scope: z.ZodOptional<z.ZodString>;
918
- code_challenge_method: z.ZodOptional<z.ZodNativeEnum<typeof CodeChallengeMethod>>;
919
- code_challenge: z.ZodOptional<z.ZodString>;
920
- username: z.ZodOptional<z.ZodString>;
921
- }, "strip", z.ZodTypeAny, {
922
- client_id: string;
923
- username?: string | undefined;
924
- vendor_id?: string | undefined;
925
- response_type?: AuthorizationResponseType | undefined;
926
- response_mode?: AuthorizationResponseMode | undefined;
927
- redirect_uri?: string | undefined;
928
- audience?: string | undefined;
929
- state?: string | undefined;
930
- nonce?: string | undefined;
931
- scope?: string | undefined;
932
- code_challenge_method?: CodeChallengeMethod | undefined;
933
- code_challenge?: string | undefined;
934
- }, {
935
- client_id: string;
936
- username?: string | undefined;
937
- vendor_id?: string | undefined;
938
- response_type?: AuthorizationResponseType | undefined;
939
- response_mode?: AuthorizationResponseMode | undefined;
940
- redirect_uri?: string | undefined;
941
- audience?: string | undefined;
942
- state?: string | undefined;
943
- nonce?: string | undefined;
944
- scope?: string | undefined;
945
- code_challenge_method?: CodeChallengeMethod | undefined;
946
- code_challenge?: string | undefined;
947
- }>;
948
- expires_at: z.ZodString;
949
- used_at: z.ZodOptional<z.ZodString>;
950
- user_id: z.ZodOptional<z.ZodString>;
951
- created_at: z.ZodString;
952
- }, "strip", z.ZodTypeAny, {
953
- code: string;
954
- created_at: string;
955
- email: string;
956
- id: string;
957
- authParams: {
958
- client_id: string;
959
- username?: string | undefined;
960
- vendor_id?: string | undefined;
961
- response_type?: AuthorizationResponseType | undefined;
962
- response_mode?: AuthorizationResponseMode | undefined;
963
- redirect_uri?: string | undefined;
964
- audience?: string | undefined;
965
- state?: string | undefined;
966
- nonce?: string | undefined;
967
- scope?: string | undefined;
968
- code_challenge_method?: CodeChallengeMethod | undefined;
969
- code_challenge?: string | undefined;
970
- };
971
- expires_at: string;
972
- send: "code" | "link";
973
- user_id?: string | undefined;
974
- used_at?: string | undefined;
975
- ip?: string | undefined;
976
- }, {
977
- code: string;
978
- created_at: string;
979
- email: string;
980
- id: string;
981
- authParams: {
982
- client_id: string;
983
- username?: string | undefined;
984
- vendor_id?: string | undefined;
985
- response_type?: AuthorizationResponseType | undefined;
986
- response_mode?: AuthorizationResponseMode | undefined;
987
- redirect_uri?: string | undefined;
988
- audience?: string | undefined;
989
- state?: string | undefined;
990
- nonce?: string | undefined;
991
- scope?: string | undefined;
992
- code_challenge_method?: CodeChallengeMethod | undefined;
993
- code_challenge?: string | undefined;
994
- };
995
- expires_at: string;
996
- send: "code" | "link";
997
- user_id?: string | undefined;
998
- used_at?: string | undefined;
999
- ip?: string | undefined;
1000
- }>;
1001
- export type OTP = z.infer<typeof otpSchema>;
1002
- declare const passwordInsertSchema: z.ZodObject<{
1003
- user_id: z.ZodString;
1004
- password: z.ZodString;
1005
- }, "strip", z.ZodTypeAny, {
1006
- password: string;
1007
- user_id: string;
1008
- }, {
1009
- password: string;
1010
- user_id: string;
1011
- }>;
1012
- export type PasswordInsert = z.infer<typeof passwordInsertSchema>;
1013
- declare const passwordSchema: z.ZodObject<{
1014
- created_at: z.ZodString;
1015
- updated_at: z.ZodString;
1016
- user_id: z.ZodString;
1017
- password: z.ZodString;
1018
- }, "strip", z.ZodTypeAny, {
1019
- password: string;
1020
- created_at: string;
1021
- updated_at: string;
1022
- user_id: string;
1023
- }, {
1024
- password: string;
1025
- created_at: string;
1026
- updated_at: string;
1027
- user_id: string;
1028
- }>;
1029
- export type Password = z.infer<typeof passwordSchema>;
1030
- declare const sessionInsertSchema: z.ZodObject<{
1031
- session_id: z.ZodString;
1032
- client_id: z.ZodString;
1033
- expires_at: z.ZodString;
1034
- used_at: z.ZodString;
1035
- deleted_at: z.ZodOptional<z.ZodString>;
1036
- user_id: z.ZodString;
1037
- }, "strip", z.ZodTypeAny, {
1038
- user_id: string;
1039
- client_id: string;
1040
- expires_at: string;
1041
- used_at: string;
1042
- session_id: string;
1043
- deleted_at?: string | undefined;
1044
- }, {
1045
- user_id: string;
1046
- client_id: string;
1047
- expires_at: string;
1048
- used_at: string;
1049
- session_id: string;
1050
- deleted_at?: string | undefined;
799
+ used_at: string;
800
+ session_id: string;
801
+ deleted_at?: string | undefined;
1051
802
  }>;
1052
803
  export type SessionInsert = z.infer<typeof sessionInsertSchema>;
1053
804
  declare const sessionSchema: z.ZodObject<{
@@ -1097,228 +848,41 @@ export interface Tenant {
1097
848
  created_at: string;
1098
849
  updated_at: string;
1099
850
  }
1100
- export interface Ticket {
1101
- id: string;
1102
- tenant_id: string;
1103
- client_id: string;
1104
- email: string;
1105
- authParams?: {
1106
- nonce?: string;
1107
- state?: string;
1108
- scope?: string;
1109
- response_type?: AuthorizationResponseType;
1110
- response_mode?: AuthorizationResponseMode;
1111
- redirect_uri?: string;
1112
- };
1113
- created_at: Date;
1114
- expires_at: Date;
1115
- used_at?: Date;
1116
- }
1117
- declare const universalLoginSessionInsertSchema: z.ZodObject<{
1118
- id: z.ZodString;
1119
- expires_at: z.ZodString;
1120
- auth0Client: z.ZodOptional<z.ZodString>;
1121
- authParams: z.ZodObject<{
1122
- client_id: z.ZodString;
1123
- vendor_id: z.ZodOptional<z.ZodString>;
1124
- response_type: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseType>>;
1125
- response_mode: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseMode>>;
1126
- redirect_uri: z.ZodOptional<z.ZodString>;
1127
- audience: z.ZodOptional<z.ZodString>;
1128
- state: z.ZodOptional<z.ZodString>;
1129
- nonce: z.ZodOptional<z.ZodString>;
1130
- scope: z.ZodOptional<z.ZodString>;
1131
- code_challenge_method: z.ZodOptional<z.ZodNativeEnum<typeof CodeChallengeMethod>>;
1132
- code_challenge: z.ZodOptional<z.ZodString>;
1133
- username: z.ZodOptional<z.ZodString>;
851
+ declare const themeInsertSchema: z.ZodObject<{
852
+ borders: z.ZodObject<{
853
+ button_border_radius: z.ZodNumber;
854
+ button_border_weight: z.ZodNumber;
855
+ buttons_style: z.ZodEnum<[
856
+ "pill"
857
+ ]>;
858
+ input_border_radius: z.ZodNumber;
859
+ input_border_weight: z.ZodNumber;
860
+ inputs_style: z.ZodEnum<[
861
+ "pill"
862
+ ]>;
863
+ show_widget_shadow: z.ZodBoolean;
864
+ widget_border_weight: z.ZodNumber;
865
+ widget_corner_radius: z.ZodNumber;
1134
866
  }, "strip", z.ZodTypeAny, {
1135
- client_id: string;
1136
- username?: string | undefined;
1137
- vendor_id?: string | undefined;
1138
- response_type?: AuthorizationResponseType | undefined;
1139
- response_mode?: AuthorizationResponseMode | undefined;
1140
- redirect_uri?: string | undefined;
1141
- audience?: string | undefined;
1142
- state?: string | undefined;
1143
- nonce?: string | undefined;
1144
- scope?: string | undefined;
1145
- code_challenge_method?: CodeChallengeMethod | undefined;
1146
- code_challenge?: string | undefined;
867
+ button_border_radius: number;
868
+ button_border_weight: number;
869
+ buttons_style: "pill";
870
+ input_border_radius: number;
871
+ input_border_weight: number;
872
+ inputs_style: "pill";
873
+ show_widget_shadow: boolean;
874
+ widget_border_weight: number;
875
+ widget_corner_radius: number;
1147
876
  }, {
1148
- client_id: string;
1149
- username?: string | undefined;
1150
- vendor_id?: string | undefined;
1151
- response_type?: AuthorizationResponseType | undefined;
1152
- response_mode?: AuthorizationResponseMode | undefined;
1153
- redirect_uri?: string | undefined;
1154
- audience?: string | undefined;
1155
- state?: string | undefined;
1156
- nonce?: string | undefined;
1157
- scope?: string | undefined;
1158
- code_challenge_method?: CodeChallengeMethod | undefined;
1159
- code_challenge?: string | undefined;
1160
- }>;
1161
- }, "strip", z.ZodTypeAny, {
1162
- id: string;
1163
- authParams: {
1164
- client_id: string;
1165
- username?: string | undefined;
1166
- vendor_id?: string | undefined;
1167
- response_type?: AuthorizationResponseType | undefined;
1168
- response_mode?: AuthorizationResponseMode | undefined;
1169
- redirect_uri?: string | undefined;
1170
- audience?: string | undefined;
1171
- state?: string | undefined;
1172
- nonce?: string | undefined;
1173
- scope?: string | undefined;
1174
- code_challenge_method?: CodeChallengeMethod | undefined;
1175
- code_challenge?: string | undefined;
1176
- };
1177
- expires_at: string;
1178
- auth0Client?: string | undefined;
1179
- }, {
1180
- id: string;
1181
- authParams: {
1182
- client_id: string;
1183
- username?: string | undefined;
1184
- vendor_id?: string | undefined;
1185
- response_type?: AuthorizationResponseType | undefined;
1186
- response_mode?: AuthorizationResponseMode | undefined;
1187
- redirect_uri?: string | undefined;
1188
- audience?: string | undefined;
1189
- state?: string | undefined;
1190
- nonce?: string | undefined;
1191
- scope?: string | undefined;
1192
- code_challenge_method?: CodeChallengeMethod | undefined;
1193
- code_challenge?: string | undefined;
1194
- };
1195
- expires_at: string;
1196
- auth0Client?: string | undefined;
1197
- }>;
1198
- export type UniversalLoginSessionInsert = z.infer<typeof universalLoginSessionInsertSchema>;
1199
- declare const universalLoginSessionSchema: z.ZodObject<{
1200
- created_at: z.ZodString;
1201
- updated_at: z.ZodString;
1202
- id: z.ZodString;
1203
- expires_at: z.ZodString;
1204
- auth0Client: z.ZodOptional<z.ZodString>;
1205
- authParams: z.ZodObject<{
1206
- client_id: z.ZodString;
1207
- vendor_id: z.ZodOptional<z.ZodString>;
1208
- response_type: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseType>>;
1209
- response_mode: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseMode>>;
1210
- redirect_uri: z.ZodOptional<z.ZodString>;
1211
- audience: z.ZodOptional<z.ZodString>;
1212
- state: z.ZodOptional<z.ZodString>;
1213
- nonce: z.ZodOptional<z.ZodString>;
1214
- scope: z.ZodOptional<z.ZodString>;
1215
- code_challenge_method: z.ZodOptional<z.ZodNativeEnum<typeof CodeChallengeMethod>>;
1216
- code_challenge: z.ZodOptional<z.ZodString>;
1217
- username: z.ZodOptional<z.ZodString>;
1218
- }, "strip", z.ZodTypeAny, {
1219
- client_id: string;
1220
- username?: string | undefined;
1221
- vendor_id?: string | undefined;
1222
- response_type?: AuthorizationResponseType | undefined;
1223
- response_mode?: AuthorizationResponseMode | undefined;
1224
- redirect_uri?: string | undefined;
1225
- audience?: string | undefined;
1226
- state?: string | undefined;
1227
- nonce?: string | undefined;
1228
- scope?: string | undefined;
1229
- code_challenge_method?: CodeChallengeMethod | undefined;
1230
- code_challenge?: string | undefined;
1231
- }, {
1232
- client_id: string;
1233
- username?: string | undefined;
1234
- vendor_id?: string | undefined;
1235
- response_type?: AuthorizationResponseType | undefined;
1236
- response_mode?: AuthorizationResponseMode | undefined;
1237
- redirect_uri?: string | undefined;
1238
- audience?: string | undefined;
1239
- state?: string | undefined;
1240
- nonce?: string | undefined;
1241
- scope?: string | undefined;
1242
- code_challenge_method?: CodeChallengeMethod | undefined;
1243
- code_challenge?: string | undefined;
1244
- }>;
1245
- }, "strip", z.ZodTypeAny, {
1246
- created_at: string;
1247
- updated_at: string;
1248
- id: string;
1249
- authParams: {
1250
- client_id: string;
1251
- username?: string | undefined;
1252
- vendor_id?: string | undefined;
1253
- response_type?: AuthorizationResponseType | undefined;
1254
- response_mode?: AuthorizationResponseMode | undefined;
1255
- redirect_uri?: string | undefined;
1256
- audience?: string | undefined;
1257
- state?: string | undefined;
1258
- nonce?: string | undefined;
1259
- scope?: string | undefined;
1260
- code_challenge_method?: CodeChallengeMethod | undefined;
1261
- code_challenge?: string | undefined;
1262
- };
1263
- expires_at: string;
1264
- auth0Client?: string | undefined;
1265
- }, {
1266
- created_at: string;
1267
- updated_at: string;
1268
- id: string;
1269
- authParams: {
1270
- client_id: string;
1271
- username?: string | undefined;
1272
- vendor_id?: string | undefined;
1273
- response_type?: AuthorizationResponseType | undefined;
1274
- response_mode?: AuthorizationResponseMode | undefined;
1275
- redirect_uri?: string | undefined;
1276
- audience?: string | undefined;
1277
- state?: string | undefined;
1278
- nonce?: string | undefined;
1279
- scope?: string | undefined;
1280
- code_challenge_method?: CodeChallengeMethod | undefined;
1281
- code_challenge?: string | undefined;
1282
- };
1283
- expires_at: string;
1284
- auth0Client?: string | undefined;
1285
- }>;
1286
- export type UniversalLoginSession = z.infer<typeof universalLoginSessionSchema>;
1287
- declare const themeInsertSchema: z.ZodObject<{
1288
- borders: z.ZodObject<{
1289
- button_border_radius: z.ZodNumber;
1290
- button_border_weight: z.ZodNumber;
1291
- buttons_style: z.ZodEnum<[
1292
- "pill"
1293
- ]>;
1294
- input_border_radius: z.ZodNumber;
1295
- input_border_weight: z.ZodNumber;
1296
- inputs_style: z.ZodEnum<[
1297
- "pill"
1298
- ]>;
1299
- show_widget_shadow: z.ZodBoolean;
1300
- widget_border_weight: z.ZodNumber;
1301
- widget_corner_radius: z.ZodNumber;
1302
- }, "strip", z.ZodTypeAny, {
1303
- button_border_radius: number;
1304
- button_border_weight: number;
1305
- buttons_style: "pill";
1306
- input_border_radius: number;
1307
- input_border_weight: number;
1308
- inputs_style: "pill";
1309
- show_widget_shadow: boolean;
1310
- widget_border_weight: number;
1311
- widget_corner_radius: number;
1312
- }, {
1313
- button_border_radius: number;
1314
- button_border_weight: number;
1315
- buttons_style: "pill";
1316
- input_border_radius: number;
1317
- input_border_weight: number;
1318
- inputs_style: "pill";
1319
- show_widget_shadow: boolean;
1320
- widget_border_weight: number;
1321
- widget_corner_radius: number;
877
+ button_border_radius: number;
878
+ button_border_weight: number;
879
+ buttons_style: "pill";
880
+ input_border_radius: number;
881
+ input_border_weight: number;
882
+ inputs_style: "pill";
883
+ show_widget_shadow: boolean;
884
+ widget_border_weight: number;
885
+ widget_corner_radius: number;
1322
886
  }>;
1323
887
  colors: z.ZodObject<{
1324
888
  base_focus_color: z.ZodString;
@@ -2039,88 +1603,581 @@ declare const themeSchema: z.ZodObject<z.objectUtil.extendShape<{
2039
1603
  logo_position: "center";
2040
1604
  social_buttons_layout: "bottom";
2041
1605
  };
2042
- themeId: string;
1606
+ themeId: string;
1607
+ }, {
1608
+ page_background: {
1609
+ background_color: string;
1610
+ background_image_url: string;
1611
+ page_layout: "center";
1612
+ };
1613
+ colors: {
1614
+ base_focus_color: string;
1615
+ base_hover_color: string;
1616
+ body_text: string;
1617
+ captcha_widget_theme: "auto";
1618
+ error: string;
1619
+ header: string;
1620
+ icons: string;
1621
+ input_background: string;
1622
+ input_border: string;
1623
+ input_filled_text: string;
1624
+ input_labels_placeholders: string;
1625
+ links_focused_components: string;
1626
+ primary_button: string;
1627
+ primary_button_label: string;
1628
+ secondary_button_border: string;
1629
+ secondary_button_label: string;
1630
+ success: string;
1631
+ widget_background: string;
1632
+ widget_border: string;
1633
+ };
1634
+ borders: {
1635
+ button_border_radius: number;
1636
+ button_border_weight: number;
1637
+ buttons_style: "pill";
1638
+ input_border_radius: number;
1639
+ input_border_weight: number;
1640
+ inputs_style: "pill";
1641
+ show_widget_shadow: boolean;
1642
+ widget_border_weight: number;
1643
+ widget_corner_radius: number;
1644
+ };
1645
+ displayName: string;
1646
+ fonts: {
1647
+ title: {
1648
+ bold: boolean;
1649
+ size: number;
1650
+ };
1651
+ body_text: {
1652
+ bold: boolean;
1653
+ size: number;
1654
+ };
1655
+ buttons_text: {
1656
+ bold: boolean;
1657
+ size: number;
1658
+ };
1659
+ font_url: string;
1660
+ input_labels: {
1661
+ bold: boolean;
1662
+ size: number;
1663
+ };
1664
+ links: {
1665
+ bold: boolean;
1666
+ size: number;
1667
+ };
1668
+ links_style: "normal";
1669
+ reference_text_size: number;
1670
+ subtitle: {
1671
+ bold: boolean;
1672
+ size: number;
1673
+ };
1674
+ };
1675
+ widget: {
1676
+ logo_url: string;
1677
+ header_text_alignment: "center";
1678
+ logo_height: number;
1679
+ logo_position: "center";
1680
+ social_buttons_layout: "bottom";
1681
+ };
1682
+ themeId: string;
1683
+ }>;
1684
+ export type Theme = z.infer<typeof themeSchema>;
1685
+ export interface Ticket {
1686
+ id: string;
1687
+ tenant_id: string;
1688
+ client_id: string;
1689
+ email: string;
1690
+ authParams?: {
1691
+ nonce?: string;
1692
+ state?: string;
1693
+ scope?: string;
1694
+ response_type?: AuthorizationResponseType;
1695
+ response_mode?: AuthorizationResponseMode;
1696
+ redirect_uri?: string;
1697
+ };
1698
+ created_at: Date;
1699
+ expires_at: Date;
1700
+ used_at?: Date;
1701
+ }
1702
+ declare const universalLoginSessionInsertSchema: z.ZodObject<{
1703
+ id: z.ZodString;
1704
+ expires_at: z.ZodString;
1705
+ auth0Client: z.ZodOptional<z.ZodString>;
1706
+ authParams: z.ZodObject<{
1707
+ client_id: z.ZodString;
1708
+ vendor_id: z.ZodOptional<z.ZodString>;
1709
+ response_type: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseType>>;
1710
+ response_mode: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseMode>>;
1711
+ redirect_uri: z.ZodOptional<z.ZodString>;
1712
+ audience: z.ZodOptional<z.ZodString>;
1713
+ state: z.ZodOptional<z.ZodString>;
1714
+ nonce: z.ZodOptional<z.ZodString>;
1715
+ scope: z.ZodOptional<z.ZodString>;
1716
+ code_challenge_method: z.ZodOptional<z.ZodNativeEnum<typeof CodeChallengeMethod>>;
1717
+ code_challenge: z.ZodOptional<z.ZodString>;
1718
+ username: z.ZodOptional<z.ZodString>;
1719
+ }, "strip", z.ZodTypeAny, {
1720
+ client_id: string;
1721
+ username?: string | undefined;
1722
+ vendor_id?: string | undefined;
1723
+ response_type?: AuthorizationResponseType | undefined;
1724
+ response_mode?: AuthorizationResponseMode | undefined;
1725
+ redirect_uri?: string | undefined;
1726
+ audience?: string | undefined;
1727
+ state?: string | undefined;
1728
+ nonce?: string | undefined;
1729
+ scope?: string | undefined;
1730
+ code_challenge_method?: CodeChallengeMethod | undefined;
1731
+ code_challenge?: string | undefined;
1732
+ }, {
1733
+ client_id: string;
1734
+ username?: string | undefined;
1735
+ vendor_id?: string | undefined;
1736
+ response_type?: AuthorizationResponseType | undefined;
1737
+ response_mode?: AuthorizationResponseMode | undefined;
1738
+ redirect_uri?: string | undefined;
1739
+ audience?: string | undefined;
1740
+ state?: string | undefined;
1741
+ nonce?: string | undefined;
1742
+ scope?: string | undefined;
1743
+ code_challenge_method?: CodeChallengeMethod | undefined;
1744
+ code_challenge?: string | undefined;
1745
+ }>;
1746
+ }, "strip", z.ZodTypeAny, {
1747
+ id: string;
1748
+ expires_at: string;
1749
+ authParams: {
1750
+ client_id: string;
1751
+ username?: string | undefined;
1752
+ vendor_id?: string | undefined;
1753
+ response_type?: AuthorizationResponseType | undefined;
1754
+ response_mode?: AuthorizationResponseMode | undefined;
1755
+ redirect_uri?: string | undefined;
1756
+ audience?: string | undefined;
1757
+ state?: string | undefined;
1758
+ nonce?: string | undefined;
1759
+ scope?: string | undefined;
1760
+ code_challenge_method?: CodeChallengeMethod | undefined;
1761
+ code_challenge?: string | undefined;
1762
+ };
1763
+ auth0Client?: string | undefined;
1764
+ }, {
1765
+ id: string;
1766
+ expires_at: string;
1767
+ authParams: {
1768
+ client_id: string;
1769
+ username?: string | undefined;
1770
+ vendor_id?: string | undefined;
1771
+ response_type?: AuthorizationResponseType | undefined;
1772
+ response_mode?: AuthorizationResponseMode | undefined;
1773
+ redirect_uri?: string | undefined;
1774
+ audience?: string | undefined;
1775
+ state?: string | undefined;
1776
+ nonce?: string | undefined;
1777
+ scope?: string | undefined;
1778
+ code_challenge_method?: CodeChallengeMethod | undefined;
1779
+ code_challenge?: string | undefined;
1780
+ };
1781
+ auth0Client?: string | undefined;
1782
+ }>;
1783
+ export type UniversalLoginSessionInsert = z.infer<typeof universalLoginSessionInsertSchema>;
1784
+ declare const universalLoginSessionSchema: z.ZodObject<{
1785
+ created_at: z.ZodString;
1786
+ updated_at: z.ZodString;
1787
+ id: z.ZodString;
1788
+ expires_at: z.ZodString;
1789
+ auth0Client: z.ZodOptional<z.ZodString>;
1790
+ authParams: z.ZodObject<{
1791
+ client_id: z.ZodString;
1792
+ vendor_id: z.ZodOptional<z.ZodString>;
1793
+ response_type: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseType>>;
1794
+ response_mode: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseMode>>;
1795
+ redirect_uri: z.ZodOptional<z.ZodString>;
1796
+ audience: z.ZodOptional<z.ZodString>;
1797
+ state: z.ZodOptional<z.ZodString>;
1798
+ nonce: z.ZodOptional<z.ZodString>;
1799
+ scope: z.ZodOptional<z.ZodString>;
1800
+ code_challenge_method: z.ZodOptional<z.ZodNativeEnum<typeof CodeChallengeMethod>>;
1801
+ code_challenge: z.ZodOptional<z.ZodString>;
1802
+ username: z.ZodOptional<z.ZodString>;
1803
+ }, "strip", z.ZodTypeAny, {
1804
+ client_id: string;
1805
+ username?: string | undefined;
1806
+ vendor_id?: string | undefined;
1807
+ response_type?: AuthorizationResponseType | undefined;
1808
+ response_mode?: AuthorizationResponseMode | undefined;
1809
+ redirect_uri?: string | undefined;
1810
+ audience?: string | undefined;
1811
+ state?: string | undefined;
1812
+ nonce?: string | undefined;
1813
+ scope?: string | undefined;
1814
+ code_challenge_method?: CodeChallengeMethod | undefined;
1815
+ code_challenge?: string | undefined;
1816
+ }, {
1817
+ client_id: string;
1818
+ username?: string | undefined;
1819
+ vendor_id?: string | undefined;
1820
+ response_type?: AuthorizationResponseType | undefined;
1821
+ response_mode?: AuthorizationResponseMode | undefined;
1822
+ redirect_uri?: string | undefined;
1823
+ audience?: string | undefined;
1824
+ state?: string | undefined;
1825
+ nonce?: string | undefined;
1826
+ scope?: string | undefined;
1827
+ code_challenge_method?: CodeChallengeMethod | undefined;
1828
+ code_challenge?: string | undefined;
1829
+ }>;
1830
+ }, "strip", z.ZodTypeAny, {
1831
+ created_at: string;
1832
+ updated_at: string;
1833
+ id: string;
1834
+ expires_at: string;
1835
+ authParams: {
1836
+ client_id: string;
1837
+ username?: string | undefined;
1838
+ vendor_id?: string | undefined;
1839
+ response_type?: AuthorizationResponseType | undefined;
1840
+ response_mode?: AuthorizationResponseMode | undefined;
1841
+ redirect_uri?: string | undefined;
1842
+ audience?: string | undefined;
1843
+ state?: string | undefined;
1844
+ nonce?: string | undefined;
1845
+ scope?: string | undefined;
1846
+ code_challenge_method?: CodeChallengeMethod | undefined;
1847
+ code_challenge?: string | undefined;
1848
+ };
1849
+ auth0Client?: string | undefined;
1850
+ }, {
1851
+ created_at: string;
1852
+ updated_at: string;
1853
+ id: string;
1854
+ expires_at: string;
1855
+ authParams: {
1856
+ client_id: string;
1857
+ username?: string | undefined;
1858
+ vendor_id?: string | undefined;
1859
+ response_type?: AuthorizationResponseType | undefined;
1860
+ response_mode?: AuthorizationResponseMode | undefined;
1861
+ redirect_uri?: string | undefined;
1862
+ audience?: string | undefined;
1863
+ state?: string | undefined;
1864
+ nonce?: string | undefined;
1865
+ scope?: string | undefined;
1866
+ code_challenge_method?: CodeChallengeMethod | undefined;
1867
+ code_challenge?: string | undefined;
1868
+ };
1869
+ auth0Client?: string | undefined;
1870
+ }>;
1871
+ export type UniversalLoginSession = z.infer<typeof universalLoginSessionSchema>;
1872
+ declare const otpInsertSchema: z.ZodObject<{
1873
+ id: z.ZodString;
1874
+ email: z.ZodString;
1875
+ code: z.ZodString;
1876
+ ip: z.ZodOptional<z.ZodString>;
1877
+ send: z.ZodEnum<[
1878
+ "code",
1879
+ "link"
1880
+ ]>;
1881
+ authParams: z.ZodObject<{
1882
+ client_id: z.ZodString;
1883
+ vendor_id: z.ZodOptional<z.ZodString>;
1884
+ response_type: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseType>>;
1885
+ response_mode: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseMode>>;
1886
+ redirect_uri: z.ZodOptional<z.ZodString>;
1887
+ audience: z.ZodOptional<z.ZodString>;
1888
+ state: z.ZodOptional<z.ZodString>;
1889
+ nonce: z.ZodOptional<z.ZodString>;
1890
+ scope: z.ZodOptional<z.ZodString>;
1891
+ code_challenge_method: z.ZodOptional<z.ZodNativeEnum<typeof CodeChallengeMethod>>;
1892
+ code_challenge: z.ZodOptional<z.ZodString>;
1893
+ username: z.ZodOptional<z.ZodString>;
1894
+ }, "strip", z.ZodTypeAny, {
1895
+ client_id: string;
1896
+ username?: string | undefined;
1897
+ vendor_id?: string | undefined;
1898
+ response_type?: AuthorizationResponseType | undefined;
1899
+ response_mode?: AuthorizationResponseMode | undefined;
1900
+ redirect_uri?: string | undefined;
1901
+ audience?: string | undefined;
1902
+ state?: string | undefined;
1903
+ nonce?: string | undefined;
1904
+ scope?: string | undefined;
1905
+ code_challenge_method?: CodeChallengeMethod | undefined;
1906
+ code_challenge?: string | undefined;
1907
+ }, {
1908
+ client_id: string;
1909
+ username?: string | undefined;
1910
+ vendor_id?: string | undefined;
1911
+ response_type?: AuthorizationResponseType | undefined;
1912
+ response_mode?: AuthorizationResponseMode | undefined;
1913
+ redirect_uri?: string | undefined;
1914
+ audience?: string | undefined;
1915
+ state?: string | undefined;
1916
+ nonce?: string | undefined;
1917
+ scope?: string | undefined;
1918
+ code_challenge_method?: CodeChallengeMethod | undefined;
1919
+ code_challenge?: string | undefined;
1920
+ }>;
1921
+ expires_at: z.ZodString;
1922
+ used_at: z.ZodOptional<z.ZodString>;
1923
+ user_id: z.ZodOptional<z.ZodString>;
1924
+ }, "strip", z.ZodTypeAny, {
1925
+ code: string;
1926
+ email: string;
1927
+ id: string;
1928
+ expires_at: string;
1929
+ authParams: {
1930
+ client_id: string;
1931
+ username?: string | undefined;
1932
+ vendor_id?: string | undefined;
1933
+ response_type?: AuthorizationResponseType | undefined;
1934
+ response_mode?: AuthorizationResponseMode | undefined;
1935
+ redirect_uri?: string | undefined;
1936
+ audience?: string | undefined;
1937
+ state?: string | undefined;
1938
+ nonce?: string | undefined;
1939
+ scope?: string | undefined;
1940
+ code_challenge_method?: CodeChallengeMethod | undefined;
1941
+ code_challenge?: string | undefined;
1942
+ };
1943
+ send: "code" | "link";
1944
+ user_id?: string | undefined;
1945
+ used_at?: string | undefined;
1946
+ ip?: string | undefined;
1947
+ }, {
1948
+ code: string;
1949
+ email: string;
1950
+ id: string;
1951
+ expires_at: string;
1952
+ authParams: {
1953
+ client_id: string;
1954
+ username?: string | undefined;
1955
+ vendor_id?: string | undefined;
1956
+ response_type?: AuthorizationResponseType | undefined;
1957
+ response_mode?: AuthorizationResponseMode | undefined;
1958
+ redirect_uri?: string | undefined;
1959
+ audience?: string | undefined;
1960
+ state?: string | undefined;
1961
+ nonce?: string | undefined;
1962
+ scope?: string | undefined;
1963
+ code_challenge_method?: CodeChallengeMethod | undefined;
1964
+ code_challenge?: string | undefined;
1965
+ };
1966
+ send: "code" | "link";
1967
+ user_id?: string | undefined;
1968
+ used_at?: string | undefined;
1969
+ ip?: string | undefined;
1970
+ }>;
1971
+ export type OTPInsert = z.infer<typeof otpInsertSchema>;
1972
+ declare const otpSchema: z.ZodObject<{
1973
+ id: z.ZodString;
1974
+ email: z.ZodString;
1975
+ code: z.ZodString;
1976
+ ip: z.ZodOptional<z.ZodString>;
1977
+ send: z.ZodEnum<[
1978
+ "code",
1979
+ "link"
1980
+ ]>;
1981
+ authParams: z.ZodObject<{
1982
+ client_id: z.ZodString;
1983
+ vendor_id: z.ZodOptional<z.ZodString>;
1984
+ response_type: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseType>>;
1985
+ response_mode: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseMode>>;
1986
+ redirect_uri: z.ZodOptional<z.ZodString>;
1987
+ audience: z.ZodOptional<z.ZodString>;
1988
+ state: z.ZodOptional<z.ZodString>;
1989
+ nonce: z.ZodOptional<z.ZodString>;
1990
+ scope: z.ZodOptional<z.ZodString>;
1991
+ code_challenge_method: z.ZodOptional<z.ZodNativeEnum<typeof CodeChallengeMethod>>;
1992
+ code_challenge: z.ZodOptional<z.ZodString>;
1993
+ username: z.ZodOptional<z.ZodString>;
1994
+ }, "strip", z.ZodTypeAny, {
1995
+ client_id: string;
1996
+ username?: string | undefined;
1997
+ vendor_id?: string | undefined;
1998
+ response_type?: AuthorizationResponseType | undefined;
1999
+ response_mode?: AuthorizationResponseMode | undefined;
2000
+ redirect_uri?: string | undefined;
2001
+ audience?: string | undefined;
2002
+ state?: string | undefined;
2003
+ nonce?: string | undefined;
2004
+ scope?: string | undefined;
2005
+ code_challenge_method?: CodeChallengeMethod | undefined;
2006
+ code_challenge?: string | undefined;
2007
+ }, {
2008
+ client_id: string;
2009
+ username?: string | undefined;
2010
+ vendor_id?: string | undefined;
2011
+ response_type?: AuthorizationResponseType | undefined;
2012
+ response_mode?: AuthorizationResponseMode | undefined;
2013
+ redirect_uri?: string | undefined;
2014
+ audience?: string | undefined;
2015
+ state?: string | undefined;
2016
+ nonce?: string | undefined;
2017
+ scope?: string | undefined;
2018
+ code_challenge_method?: CodeChallengeMethod | undefined;
2019
+ code_challenge?: string | undefined;
2020
+ }>;
2021
+ expires_at: z.ZodString;
2022
+ used_at: z.ZodOptional<z.ZodString>;
2023
+ user_id: z.ZodOptional<z.ZodString>;
2024
+ created_at: z.ZodString;
2025
+ }, "strip", z.ZodTypeAny, {
2026
+ code: string;
2027
+ created_at: string;
2028
+ email: string;
2029
+ id: string;
2030
+ expires_at: string;
2031
+ authParams: {
2032
+ client_id: string;
2033
+ username?: string | undefined;
2034
+ vendor_id?: string | undefined;
2035
+ response_type?: AuthorizationResponseType | undefined;
2036
+ response_mode?: AuthorizationResponseMode | undefined;
2037
+ redirect_uri?: string | undefined;
2038
+ audience?: string | undefined;
2039
+ state?: string | undefined;
2040
+ nonce?: string | undefined;
2041
+ scope?: string | undefined;
2042
+ code_challenge_method?: CodeChallengeMethod | undefined;
2043
+ code_challenge?: string | undefined;
2044
+ };
2045
+ send: "code" | "link";
2046
+ user_id?: string | undefined;
2047
+ used_at?: string | undefined;
2048
+ ip?: string | undefined;
2043
2049
  }, {
2044
- page_background: {
2045
- background_color: string;
2046
- background_image_url: string;
2047
- page_layout: "center";
2048
- };
2049
- colors: {
2050
- base_focus_color: string;
2051
- base_hover_color: string;
2052
- body_text: string;
2053
- captcha_widget_theme: "auto";
2054
- error: string;
2055
- header: string;
2056
- icons: string;
2057
- input_background: string;
2058
- input_border: string;
2059
- input_filled_text: string;
2060
- input_labels_placeholders: string;
2061
- links_focused_components: string;
2062
- primary_button: string;
2063
- primary_button_label: string;
2064
- secondary_button_border: string;
2065
- secondary_button_label: string;
2066
- success: string;
2067
- widget_background: string;
2068
- widget_border: string;
2069
- };
2070
- borders: {
2071
- button_border_radius: number;
2072
- button_border_weight: number;
2073
- buttons_style: "pill";
2074
- input_border_radius: number;
2075
- input_border_weight: number;
2076
- inputs_style: "pill";
2077
- show_widget_shadow: boolean;
2078
- widget_border_weight: number;
2079
- widget_corner_radius: number;
2050
+ code: string;
2051
+ created_at: string;
2052
+ email: string;
2053
+ id: string;
2054
+ expires_at: string;
2055
+ authParams: {
2056
+ client_id: string;
2057
+ username?: string | undefined;
2058
+ vendor_id?: string | undefined;
2059
+ response_type?: AuthorizationResponseType | undefined;
2060
+ response_mode?: AuthorizationResponseMode | undefined;
2061
+ redirect_uri?: string | undefined;
2062
+ audience?: string | undefined;
2063
+ state?: string | undefined;
2064
+ nonce?: string | undefined;
2065
+ scope?: string | undefined;
2066
+ code_challenge_method?: CodeChallengeMethod | undefined;
2067
+ code_challenge?: string | undefined;
2080
2068
  };
2081
- displayName: string;
2082
- fonts: {
2083
- title: {
2084
- bold: boolean;
2085
- size: number;
2086
- };
2087
- body_text: {
2088
- bold: boolean;
2089
- size: number;
2090
- };
2091
- buttons_text: {
2092
- bold: boolean;
2093
- size: number;
2094
- };
2095
- font_url: string;
2096
- input_labels: {
2097
- bold: boolean;
2098
- size: number;
2099
- };
2100
- links: {
2101
- bold: boolean;
2102
- size: number;
2103
- };
2104
- links_style: "normal";
2105
- reference_text_size: number;
2106
- subtitle: {
2107
- bold: boolean;
2108
- size: number;
2109
- };
2069
+ send: "code" | "link";
2070
+ user_id?: string | undefined;
2071
+ used_at?: string | undefined;
2072
+ ip?: string | undefined;
2073
+ }>;
2074
+ export type OTP = z.infer<typeof otpSchema>;
2075
+ declare const authenticationCodeSchema: z.ZodObject<{
2076
+ created_at: z.ZodString;
2077
+ authParams: z.ZodObject<{
2078
+ client_id: z.ZodString;
2079
+ vendor_id: z.ZodOptional<z.ZodString>;
2080
+ response_type: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseType>>;
2081
+ response_mode: z.ZodOptional<z.ZodNativeEnum<typeof AuthorizationResponseMode>>;
2082
+ redirect_uri: z.ZodOptional<z.ZodString>;
2083
+ audience: z.ZodOptional<z.ZodString>;
2084
+ state: z.ZodOptional<z.ZodString>;
2085
+ nonce: z.ZodOptional<z.ZodString>;
2086
+ scope: z.ZodOptional<z.ZodString>;
2087
+ code_challenge_method: z.ZodOptional<z.ZodNativeEnum<typeof CodeChallengeMethod>>;
2088
+ code_challenge: z.ZodOptional<z.ZodString>;
2089
+ username: z.ZodOptional<z.ZodString>;
2090
+ }, "strip", z.ZodTypeAny, {
2091
+ client_id: string;
2092
+ username?: string | undefined;
2093
+ vendor_id?: string | undefined;
2094
+ response_type?: AuthorizationResponseType | undefined;
2095
+ response_mode?: AuthorizationResponseMode | undefined;
2096
+ redirect_uri?: string | undefined;
2097
+ audience?: string | undefined;
2098
+ state?: string | undefined;
2099
+ nonce?: string | undefined;
2100
+ scope?: string | undefined;
2101
+ code_challenge_method?: CodeChallengeMethod | undefined;
2102
+ code_challenge?: string | undefined;
2103
+ }, {
2104
+ client_id: string;
2105
+ username?: string | undefined;
2106
+ vendor_id?: string | undefined;
2107
+ response_type?: AuthorizationResponseType | undefined;
2108
+ response_mode?: AuthorizationResponseMode | undefined;
2109
+ redirect_uri?: string | undefined;
2110
+ audience?: string | undefined;
2111
+ state?: string | undefined;
2112
+ nonce?: string | undefined;
2113
+ scope?: string | undefined;
2114
+ code_challenge_method?: CodeChallengeMethod | undefined;
2115
+ code_challenge?: string | undefined;
2116
+ }>;
2117
+ code: z.ZodString;
2118
+ user_id: z.ZodString;
2119
+ expires_at: z.ZodString;
2120
+ used_at: z.ZodOptional<z.ZodString>;
2121
+ }, "strip", z.ZodTypeAny, {
2122
+ code: string;
2123
+ created_at: string;
2124
+ user_id: string;
2125
+ expires_at: string;
2126
+ authParams: {
2127
+ client_id: string;
2128
+ username?: string | undefined;
2129
+ vendor_id?: string | undefined;
2130
+ response_type?: AuthorizationResponseType | undefined;
2131
+ response_mode?: AuthorizationResponseMode | undefined;
2132
+ redirect_uri?: string | undefined;
2133
+ audience?: string | undefined;
2134
+ state?: string | undefined;
2135
+ nonce?: string | undefined;
2136
+ scope?: string | undefined;
2137
+ code_challenge_method?: CodeChallengeMethod | undefined;
2138
+ code_challenge?: string | undefined;
2110
2139
  };
2111
- widget: {
2112
- logo_url: string;
2113
- header_text_alignment: "center";
2114
- logo_height: number;
2115
- logo_position: "center";
2116
- social_buttons_layout: "bottom";
2140
+ used_at?: string | undefined;
2141
+ }, {
2142
+ code: string;
2143
+ created_at: string;
2144
+ user_id: string;
2145
+ expires_at: string;
2146
+ authParams: {
2147
+ client_id: string;
2148
+ username?: string | undefined;
2149
+ vendor_id?: string | undefined;
2150
+ response_type?: AuthorizationResponseType | undefined;
2151
+ response_mode?: AuthorizationResponseMode | undefined;
2152
+ redirect_uri?: string | undefined;
2153
+ audience?: string | undefined;
2154
+ state?: string | undefined;
2155
+ nonce?: string | undefined;
2156
+ scope?: string | undefined;
2157
+ code_challenge_method?: CodeChallengeMethod | undefined;
2158
+ code_challenge?: string | undefined;
2117
2159
  };
2118
- themeId: string;
2160
+ used_at?: string | undefined;
2119
2161
  }>;
2120
- export type Theme = z.infer<typeof themeSchema>;
2162
+ export type AuthenticationCode = z.infer<typeof authenticationCodeSchema>;
2163
+ export interface ListParams {
2164
+ page: number;
2165
+ per_page: number;
2166
+ include_totals: boolean;
2167
+ q?: string;
2168
+ sort?: {
2169
+ sort_by: string;
2170
+ sort_order: "asc" | "desc";
2171
+ };
2172
+ }
2173
+ export interface ListCodesResponse extends Totals {
2174
+ codes: Code[];
2175
+ }
2121
2176
  export interface CodesAdapter {
2122
- create: (tenant_id: string, authCode: Code) => Promise<void>;
2123
- list: (tenant_id: string, user_id: string) => Promise<Code[]>;
2177
+ create: (tenant_id: string, authCode: Code) => Promise<Code>;
2178
+ get: (tenant_id: string, code_id: string, type: CodeType) => Promise<Code | null>;
2179
+ list: (tenant_id: string, params: ListParams) => Promise<ListCodesResponse>;
2180
+ remove: (tenant_id: string, code: string) => Promise<boolean>;
2124
2181
  }
2125
2182
  export interface OTPAdapter {
2126
2183
  create: (tenant_id: string, authCode: OTPInsert) => Promise<void>;
@@ -2132,16 +2189,6 @@ export interface PasswordsAdapter {
2132
2189
  update: (tenant_id: string, params: PasswordInsert) => Promise<boolean>;
2133
2190
  get: (tenant_id: string, user_id: string) => Promise<Password>;
2134
2191
  }
2135
- export interface ListParams {
2136
- page: number;
2137
- per_page: number;
2138
- include_totals: boolean;
2139
- q?: string;
2140
- sort?: {
2141
- sort_by: string;
2142
- sort_order: "asc" | "desc";
2143
- };
2144
- }
2145
2192
  export interface ListSesssionsResponse extends Totals {
2146
2193
  sessions: Session[];
2147
2194
  }
@@ -2380,6 +2427,16 @@ declare const sqlThemeSchema: z.ZodObject<z.objectUtil.extendShape<any, {
2380
2427
  tenant_id?: unknown;
2381
2428
  }>;
2382
2429
  export type SqlTheme = z.infer<typeof sqlThemeSchema>;
2430
+ declare const sqlLoginSchema: z.ZodObject<z.objectUtil.extendShape<any, {
2431
+ tenant_id: z.ZodString;
2432
+ }>, "strip", z.ZodTypeAny, {
2433
+ [x: string]: any;
2434
+ tenant_id?: unknown;
2435
+ }, {
2436
+ [x: string]: any;
2437
+ tenant_id?: unknown;
2438
+ }>;
2439
+ export type SqlLogin = z.infer<typeof sqlLoginSchema>;
2383
2440
  export interface Database {
2384
2441
  applications: Application & {
2385
2442
  tenant_id: string;
@@ -2399,6 +2456,7 @@ export interface Database {
2399
2456
  tenant_id: string;
2400
2457
  };
2401
2458
  keys: Certificate;
2459
+ logins: SqlLogin;
2402
2460
  logs: SqlLog;
2403
2461
  otps: SqlOTP;
2404
2462
  passwords: Password & {