@authhero/kysely-adapter 7.0.0 → 8.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/kysely-adapter.cjs +1 -1
- package/dist/kysely-adapter.d.ts +180 -42
- package/dist/kysely-adapter.mjs +349 -297
- package/package.json +2 -2
package/dist/kysely-adapter.d.ts
CHANGED
|
@@ -1933,7 +1933,6 @@ declare const passwordSchema: z.ZodObject<{
|
|
|
1933
1933
|
export type Password = z.infer<typeof passwordSchema>;
|
|
1934
1934
|
declare const sessionInsertSchema: z.ZodObject<{
|
|
1935
1935
|
id: z.ZodString;
|
|
1936
|
-
session_id: z.ZodOptional<z.ZodString>;
|
|
1937
1936
|
client_id: z.ZodString;
|
|
1938
1937
|
revoked_at: z.ZodOptional<z.ZodString>;
|
|
1939
1938
|
used_at: z.ZodString;
|
|
@@ -1978,7 +1977,6 @@ declare const sessionInsertSchema: z.ZodObject<{
|
|
|
1978
1977
|
};
|
|
1979
1978
|
clients: string[];
|
|
1980
1979
|
expires_at?: string | undefined;
|
|
1981
|
-
session_id?: string | undefined;
|
|
1982
1980
|
revoked_at?: string | undefined;
|
|
1983
1981
|
idle_expires_at?: string | undefined;
|
|
1984
1982
|
}, {
|
|
@@ -1996,14 +1994,12 @@ declare const sessionInsertSchema: z.ZodObject<{
|
|
|
1996
1994
|
};
|
|
1997
1995
|
clients: string[];
|
|
1998
1996
|
expires_at?: string | undefined;
|
|
1999
|
-
session_id?: string | undefined;
|
|
2000
1997
|
revoked_at?: string | undefined;
|
|
2001
1998
|
idle_expires_at?: string | undefined;
|
|
2002
1999
|
}>;
|
|
2003
2000
|
export type SessionInsert = z.infer<typeof sessionInsertSchema>;
|
|
2004
2001
|
declare const sessionSchema: z.ZodObject<{
|
|
2005
2002
|
id: z.ZodString;
|
|
2006
|
-
session_id: z.ZodOptional<z.ZodString>;
|
|
2007
2003
|
client_id: z.ZodString;
|
|
2008
2004
|
revoked_at: z.ZodOptional<z.ZodString>;
|
|
2009
2005
|
used_at: z.ZodString;
|
|
@@ -2056,7 +2052,6 @@ declare const sessionSchema: z.ZodObject<{
|
|
|
2056
2052
|
authenticated_at: string;
|
|
2057
2053
|
last_interaction_at: string;
|
|
2058
2054
|
expires_at?: string | undefined;
|
|
2059
|
-
session_id?: string | undefined;
|
|
2060
2055
|
revoked_at?: string | undefined;
|
|
2061
2056
|
idle_expires_at?: string | undefined;
|
|
2062
2057
|
}, {
|
|
@@ -2078,7 +2073,6 @@ declare const sessionSchema: z.ZodObject<{
|
|
|
2078
2073
|
authenticated_at: string;
|
|
2079
2074
|
last_interaction_at: string;
|
|
2080
2075
|
expires_at?: string | undefined;
|
|
2081
|
-
session_id?: string | undefined;
|
|
2082
2076
|
revoked_at?: string | undefined;
|
|
2083
2077
|
idle_expires_at?: string | undefined;
|
|
2084
2078
|
}>;
|
|
@@ -3138,56 +3132,168 @@ export type EmailProvider = z.infer<typeof emailProviderSchema>;
|
|
|
3138
3132
|
declare const refreshTokenInsertSchema: z.ZodObject<{
|
|
3139
3133
|
token: z.ZodString;
|
|
3140
3134
|
session_id: z.ZodString;
|
|
3141
|
-
|
|
3142
|
-
|
|
3143
|
-
|
|
3144
|
-
|
|
3145
|
-
|
|
3135
|
+
user_id: z.ZodString;
|
|
3136
|
+
expires_at: z.ZodOptional<z.ZodString>;
|
|
3137
|
+
idle_expires_at: z.ZodOptional<z.ZodString>;
|
|
3138
|
+
last_exchanged_at: z.ZodOptional<z.ZodString>;
|
|
3139
|
+
device: z.ZodOptional<z.ZodObject<{
|
|
3140
|
+
initial_user_agent: z.ZodString;
|
|
3141
|
+
initial_ip: z.ZodString;
|
|
3142
|
+
initial_asn: z.ZodString;
|
|
3143
|
+
last_user_agent: z.ZodString;
|
|
3144
|
+
last_ip: z.ZodString;
|
|
3145
|
+
last_asn: z.ZodString;
|
|
3146
|
+
}, "strip", z.ZodTypeAny, {
|
|
3147
|
+
last_ip: string;
|
|
3148
|
+
initial_user_agent: string;
|
|
3149
|
+
initial_ip: string;
|
|
3150
|
+
initial_asn: string;
|
|
3151
|
+
last_user_agent: string;
|
|
3152
|
+
last_asn: string;
|
|
3153
|
+
}, {
|
|
3154
|
+
last_ip: string;
|
|
3155
|
+
initial_user_agent: string;
|
|
3156
|
+
initial_ip: string;
|
|
3157
|
+
initial_asn: string;
|
|
3158
|
+
last_user_agent: string;
|
|
3159
|
+
last_asn: string;
|
|
3160
|
+
}>>;
|
|
3161
|
+
resource_servers: z.ZodArray<z.ZodObject<{
|
|
3162
|
+
audience: z.ZodString;
|
|
3163
|
+
scopes: z.ZodString;
|
|
3164
|
+
}, "strip", z.ZodTypeAny, {
|
|
3165
|
+
audience: string;
|
|
3166
|
+
scopes: string;
|
|
3167
|
+
}, {
|
|
3168
|
+
audience: string;
|
|
3169
|
+
scopes: string;
|
|
3170
|
+
}>, "many">;
|
|
3171
|
+
rotating: z.ZodBoolean;
|
|
3146
3172
|
}, "strip", z.ZodTypeAny, {
|
|
3147
|
-
|
|
3173
|
+
user_id: string;
|
|
3148
3174
|
token: string;
|
|
3149
|
-
scope: string;
|
|
3150
|
-
expires_at: string;
|
|
3151
3175
|
session_id: string;
|
|
3152
|
-
|
|
3153
|
-
|
|
3176
|
+
resource_servers: {
|
|
3177
|
+
audience: string;
|
|
3178
|
+
scopes: string;
|
|
3179
|
+
}[];
|
|
3180
|
+
rotating: boolean;
|
|
3181
|
+
expires_at?: string | undefined;
|
|
3182
|
+
idle_expires_at?: string | undefined;
|
|
3183
|
+
device?: {
|
|
3184
|
+
last_ip: string;
|
|
3185
|
+
initial_user_agent: string;
|
|
3186
|
+
initial_ip: string;
|
|
3187
|
+
initial_asn: string;
|
|
3188
|
+
last_user_agent: string;
|
|
3189
|
+
last_asn: string;
|
|
3190
|
+
} | undefined;
|
|
3191
|
+
last_exchanged_at?: string | undefined;
|
|
3154
3192
|
}, {
|
|
3155
|
-
|
|
3193
|
+
user_id: string;
|
|
3156
3194
|
token: string;
|
|
3157
|
-
scope: string;
|
|
3158
|
-
expires_at: string;
|
|
3159
3195
|
session_id: string;
|
|
3160
|
-
|
|
3161
|
-
|
|
3196
|
+
resource_servers: {
|
|
3197
|
+
audience: string;
|
|
3198
|
+
scopes: string;
|
|
3199
|
+
}[];
|
|
3200
|
+
rotating: boolean;
|
|
3201
|
+
expires_at?: string | undefined;
|
|
3202
|
+
idle_expires_at?: string | undefined;
|
|
3203
|
+
device?: {
|
|
3204
|
+
last_ip: string;
|
|
3205
|
+
initial_user_agent: string;
|
|
3206
|
+
initial_ip: string;
|
|
3207
|
+
initial_asn: string;
|
|
3208
|
+
last_user_agent: string;
|
|
3209
|
+
last_asn: string;
|
|
3210
|
+
} | undefined;
|
|
3211
|
+
last_exchanged_at?: string | undefined;
|
|
3162
3212
|
}>;
|
|
3163
3213
|
export type RefreshTokenInsert = z.infer<typeof refreshTokenInsertSchema>;
|
|
3164
3214
|
declare const refreshTokenSchema: z.ZodObject<{
|
|
3165
3215
|
token: z.ZodString;
|
|
3166
3216
|
session_id: z.ZodString;
|
|
3167
|
-
|
|
3168
|
-
|
|
3169
|
-
|
|
3170
|
-
|
|
3171
|
-
|
|
3217
|
+
user_id: z.ZodString;
|
|
3218
|
+
expires_at: z.ZodOptional<z.ZodString>;
|
|
3219
|
+
idle_expires_at: z.ZodOptional<z.ZodString>;
|
|
3220
|
+
last_exchanged_at: z.ZodOptional<z.ZodString>;
|
|
3221
|
+
device: z.ZodOptional<z.ZodObject<{
|
|
3222
|
+
initial_user_agent: z.ZodString;
|
|
3223
|
+
initial_ip: z.ZodString;
|
|
3224
|
+
initial_asn: z.ZodString;
|
|
3225
|
+
last_user_agent: z.ZodString;
|
|
3226
|
+
last_ip: z.ZodString;
|
|
3227
|
+
last_asn: z.ZodString;
|
|
3228
|
+
}, "strip", z.ZodTypeAny, {
|
|
3229
|
+
last_ip: string;
|
|
3230
|
+
initial_user_agent: string;
|
|
3231
|
+
initial_ip: string;
|
|
3232
|
+
initial_asn: string;
|
|
3233
|
+
last_user_agent: string;
|
|
3234
|
+
last_asn: string;
|
|
3235
|
+
}, {
|
|
3236
|
+
last_ip: string;
|
|
3237
|
+
initial_user_agent: string;
|
|
3238
|
+
initial_ip: string;
|
|
3239
|
+
initial_asn: string;
|
|
3240
|
+
last_user_agent: string;
|
|
3241
|
+
last_asn: string;
|
|
3242
|
+
}>>;
|
|
3243
|
+
resource_servers: z.ZodArray<z.ZodObject<{
|
|
3244
|
+
audience: z.ZodString;
|
|
3245
|
+
scopes: z.ZodString;
|
|
3246
|
+
}, "strip", z.ZodTypeAny, {
|
|
3247
|
+
audience: string;
|
|
3248
|
+
scopes: string;
|
|
3249
|
+
}, {
|
|
3250
|
+
audience: string;
|
|
3251
|
+
scopes: string;
|
|
3252
|
+
}>, "many">;
|
|
3253
|
+
rotating: z.ZodBoolean;
|
|
3172
3254
|
created_at: z.ZodString;
|
|
3173
3255
|
}, "strip", z.ZodTypeAny, {
|
|
3174
3256
|
created_at: string;
|
|
3175
|
-
|
|
3257
|
+
user_id: string;
|
|
3176
3258
|
token: string;
|
|
3177
|
-
scope: string;
|
|
3178
|
-
expires_at: string;
|
|
3179
3259
|
session_id: string;
|
|
3180
|
-
|
|
3181
|
-
|
|
3260
|
+
resource_servers: {
|
|
3261
|
+
audience: string;
|
|
3262
|
+
scopes: string;
|
|
3263
|
+
}[];
|
|
3264
|
+
rotating: boolean;
|
|
3265
|
+
expires_at?: string | undefined;
|
|
3266
|
+
idle_expires_at?: string | undefined;
|
|
3267
|
+
device?: {
|
|
3268
|
+
last_ip: string;
|
|
3269
|
+
initial_user_agent: string;
|
|
3270
|
+
initial_ip: string;
|
|
3271
|
+
initial_asn: string;
|
|
3272
|
+
last_user_agent: string;
|
|
3273
|
+
last_asn: string;
|
|
3274
|
+
} | undefined;
|
|
3275
|
+
last_exchanged_at?: string | undefined;
|
|
3182
3276
|
}, {
|
|
3183
3277
|
created_at: string;
|
|
3184
|
-
|
|
3278
|
+
user_id: string;
|
|
3185
3279
|
token: string;
|
|
3186
|
-
scope: string;
|
|
3187
|
-
expires_at: string;
|
|
3188
3280
|
session_id: string;
|
|
3189
|
-
|
|
3190
|
-
|
|
3281
|
+
resource_servers: {
|
|
3282
|
+
audience: string;
|
|
3283
|
+
scopes: string;
|
|
3284
|
+
}[];
|
|
3285
|
+
rotating: boolean;
|
|
3286
|
+
expires_at?: string | undefined;
|
|
3287
|
+
idle_expires_at?: string | undefined;
|
|
3288
|
+
device?: {
|
|
3289
|
+
last_ip: string;
|
|
3290
|
+
initial_user_agent: string;
|
|
3291
|
+
initial_ip: string;
|
|
3292
|
+
initial_asn: string;
|
|
3293
|
+
last_user_agent: string;
|
|
3294
|
+
last_asn: string;
|
|
3295
|
+
} | undefined;
|
|
3296
|
+
last_exchanged_at?: string | undefined;
|
|
3191
3297
|
}>;
|
|
3192
3298
|
export type RefreshToken = z.infer<typeof refreshTokenSchema>;
|
|
3193
3299
|
export interface ListCodesResponse extends Totals {
|
|
@@ -3738,7 +3844,6 @@ declare const sqlSessionSchema: z.ZodObject<{
|
|
|
3738
3844
|
device: z.ZodString;
|
|
3739
3845
|
clients: z.ZodString;
|
|
3740
3846
|
id: z.ZodString;
|
|
3741
|
-
session_id: z.ZodOptional<z.ZodString>;
|
|
3742
3847
|
client_id: z.ZodString;
|
|
3743
3848
|
revoked_at: z.ZodOptional<z.ZodString>;
|
|
3744
3849
|
used_at: z.ZodString;
|
|
@@ -3761,7 +3866,6 @@ declare const sqlSessionSchema: z.ZodObject<{
|
|
|
3761
3866
|
used_at: string;
|
|
3762
3867
|
authenticated_at: string;
|
|
3763
3868
|
last_interaction_at: string;
|
|
3764
|
-
session_id?: string | undefined;
|
|
3765
3869
|
revoked_at?: string | undefined;
|
|
3766
3870
|
expires_at?: string | undefined;
|
|
3767
3871
|
idle_expires_at?: string | undefined;
|
|
@@ -3777,11 +3881,47 @@ declare const sqlSessionSchema: z.ZodObject<{
|
|
|
3777
3881
|
used_at: string;
|
|
3778
3882
|
authenticated_at: string;
|
|
3779
3883
|
last_interaction_at: string;
|
|
3780
|
-
session_id?: string | undefined;
|
|
3781
3884
|
revoked_at?: string | undefined;
|
|
3782
3885
|
expires_at?: string | undefined;
|
|
3783
3886
|
idle_expires_at?: string | undefined;
|
|
3784
3887
|
}>;
|
|
3888
|
+
declare const sqlRefreshTokensSchema: z.ZodObject<{
|
|
3889
|
+
tenant_id: z.ZodString;
|
|
3890
|
+
device: z.ZodString;
|
|
3891
|
+
resource_servers: z.ZodString;
|
|
3892
|
+
rotating: z.ZodNumber;
|
|
3893
|
+
token: z.ZodString;
|
|
3894
|
+
session_id: z.ZodString;
|
|
3895
|
+
user_id: z.ZodString;
|
|
3896
|
+
expires_at: z.ZodOptional<z.ZodString>;
|
|
3897
|
+
idle_expires_at: z.ZodOptional<z.ZodString>;
|
|
3898
|
+
last_exchanged_at: z.ZodOptional<z.ZodString>;
|
|
3899
|
+
created_at: z.ZodString;
|
|
3900
|
+
}, "strip", z.ZodTypeAny, {
|
|
3901
|
+
tenant_id: string;
|
|
3902
|
+
created_at: string;
|
|
3903
|
+
user_id: string;
|
|
3904
|
+
device: string;
|
|
3905
|
+
resource_servers: string;
|
|
3906
|
+
rotating: number;
|
|
3907
|
+
token: string;
|
|
3908
|
+
session_id: string;
|
|
3909
|
+
expires_at?: string | undefined;
|
|
3910
|
+
idle_expires_at?: string | undefined;
|
|
3911
|
+
last_exchanged_at?: string | undefined;
|
|
3912
|
+
}, {
|
|
3913
|
+
tenant_id: string;
|
|
3914
|
+
created_at: string;
|
|
3915
|
+
user_id: string;
|
|
3916
|
+
device: string;
|
|
3917
|
+
resource_servers: string;
|
|
3918
|
+
rotating: number;
|
|
3919
|
+
token: string;
|
|
3920
|
+
session_id: string;
|
|
3921
|
+
expires_at?: string | undefined;
|
|
3922
|
+
idle_expires_at?: string | undefined;
|
|
3923
|
+
last_exchanged_at?: string | undefined;
|
|
3924
|
+
}>;
|
|
3785
3925
|
export interface Database {
|
|
3786
3926
|
applications: z.infer<typeof sqlApplicationSchema>;
|
|
3787
3927
|
branding: z.infer<typeof sqlBrandingSchema>;
|
|
@@ -3803,9 +3943,7 @@ export interface Database {
|
|
|
3803
3943
|
tenant_id: string;
|
|
3804
3944
|
};
|
|
3805
3945
|
prompt_settings: z.infer<typeof sqlPromptSettingSchema>;
|
|
3806
|
-
refresh_tokens:
|
|
3807
|
-
tenant_id: string;
|
|
3808
|
-
};
|
|
3946
|
+
refresh_tokens: z.infer<typeof sqlRefreshTokensSchema>;
|
|
3809
3947
|
users: z.infer<typeof sqlUserSchema>;
|
|
3810
3948
|
sessions: z.infer<typeof sqlSessionSchema>;
|
|
3811
3949
|
tenants: Tenant;
|