@go-mondo/identity-sdk 0.0.2-beta.68 → 0.0.2-beta.71
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/.release-please-manifest.json +1 -1
- package/.tsbuildinfo/cjs.json +1 -1
- package/.tsbuildinfo/esm.json +1 -1
- package/CHANGELOG.md +21 -0
- package/README.md +2 -0
- package/dist/cjs/action/schema/base.d.ts +0 -2
- package/dist/cjs/action/schema/base.d.ts.map +1 -1
- package/dist/cjs/action/schema/base.js +0 -2
- package/dist/cjs/action/schema/base.test.js +0 -1
- package/dist/cjs/action/schema/schema.d.ts +5 -28
- package/dist/cjs/action/schema/schema.d.ts.map +1 -1
- package/dist/cjs/action/schema/schema.js +6 -5
- package/dist/cjs/action/schema/schema.test.js +20 -46
- package/dist/cjs/association/schema.d.ts +8 -8
- package/dist/cjs/authentication/sessions/schema.d.ts +2 -5
- package/dist/cjs/authentication/sessions/schema.d.ts.map +1 -1
- package/dist/cjs/authentication/strategies/schema/base.d.ts +0 -2
- package/dist/cjs/authentication/strategies/schema/base.d.ts.map +1 -1
- package/dist/cjs/authentication/strategies/schema/base.js +0 -2
- package/dist/cjs/authentication/strategies/schema/schema.d.ts +0 -84
- package/dist/cjs/authentication/strategies/schema/schema.d.ts.map +1 -1
- package/dist/cjs/authentication/strategies/schema/schema.js +0 -6
- package/dist/cjs/oauth/authorize/schema/grants/implicit.d.ts +1 -1
- package/dist/cjs/oauth/authorize/schema/schema.d.ts +1 -1
- package/dist/esm/action/schema/base.d.ts +0 -2
- package/dist/esm/action/schema/base.d.ts.map +1 -1
- package/dist/esm/action/schema/base.js +0 -2
- package/dist/esm/action/schema/base.test.js +1 -2
- package/dist/esm/action/schema/schema.d.ts +5 -28
- package/dist/esm/action/schema/schema.d.ts.map +1 -1
- package/dist/esm/action/schema/schema.js +6 -5
- package/dist/esm/action/schema/schema.test.js +2 -28
- package/dist/esm/association/schema.d.ts +8 -8
- package/dist/esm/authentication/sessions/schema.d.ts +2 -5
- package/dist/esm/authentication/sessions/schema.d.ts.map +1 -1
- package/dist/esm/authentication/strategies/schema/base.d.ts +0 -2
- package/dist/esm/authentication/strategies/schema/base.d.ts.map +1 -1
- package/dist/esm/authentication/strategies/schema/base.js +0 -2
- package/dist/esm/authentication/strategies/schema/schema.d.ts +0 -84
- package/dist/esm/authentication/strategies/schema/schema.d.ts.map +1 -1
- package/dist/esm/authentication/strategies/schema/schema.js +0 -6
- package/dist/esm/oauth/authorize/schema/grants/implicit.d.ts +1 -1
- package/dist/esm/oauth/authorize/schema/schema.d.ts +1 -1
- package/package.json +1 -1
- package/dist/cjs/action/schema/operations/set-password.d.ts +0 -31
- package/dist/cjs/action/schema/operations/set-password.d.ts.map +0 -1
- package/dist/cjs/action/schema/operations/set-password.js +0 -52
- package/dist/cjs/action/schema/operations/set-password.test.d.ts +0 -2
- package/dist/cjs/action/schema/operations/set-password.test.d.ts.map +0 -1
- package/dist/cjs/action/schema/operations/set-password.test.js +0 -168
- package/dist/cjs/authentication/strategies/schema/types/password.d.ts +0 -139
- package/dist/cjs/authentication/strategies/schema/types/password.d.ts.map +0 -1
- package/dist/cjs/authentication/strategies/schema/types/password.js +0 -93
- package/dist/esm/action/schema/operations/set-password.d.ts +0 -31
- package/dist/esm/action/schema/operations/set-password.d.ts.map +0 -1
- package/dist/esm/action/schema/operations/set-password.js +0 -16
- package/dist/esm/action/schema/operations/set-password.test.d.ts +0 -2
- package/dist/esm/action/schema/operations/set-password.test.d.ts.map +0 -1
- package/dist/esm/action/schema/operations/set-password.test.js +0 -166
- package/dist/esm/authentication/strategies/schema/types/password.d.ts +0 -139
- package/dist/esm/authentication/strategies/schema/types/password.d.ts.map +0 -1
- package/dist/esm/authentication/strategies/schema/types/password.js +0 -57
- package/src/action/schema/base.test.ts.bak +0 -152
- package/src/action/schema/operations/set-password.test.ts.bak +0 -197
- package/src/action/schema/schema.test.ts.bak +0 -218
- package/src/authentication/strategies/schema/types/email.test.ts.bak +0 -252
|
@@ -3,25 +3,6 @@ import * as z from 'zod/v4';
|
|
|
3
3
|
* Union(s)
|
|
4
4
|
*/
|
|
5
5
|
export declare const InsertStrategyPayloadSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
6
|
-
settings: z.ZodOptional<z.ZodObject<{
|
|
7
|
-
passwordPolicy: z.ZodObject<{
|
|
8
|
-
minimumLength: z.ZodDefault<z.ZodNumber>;
|
|
9
|
-
maximumLength: z.ZodDefault<z.ZodNumber>;
|
|
10
|
-
minimumCapital: z.ZodDefault<z.ZodNumber>;
|
|
11
|
-
minimumLower: z.ZodDefault<z.ZodNumber>;
|
|
12
|
-
minimumNumber: z.ZodDefault<z.ZodNumber>;
|
|
13
|
-
minimumSpecial: z.ZodDefault<z.ZodNumber>;
|
|
14
|
-
}, z.core.$strip>;
|
|
15
|
-
}, z.core.$strip>>;
|
|
16
|
-
metadata: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Record<string, string | number | boolean> | undefined, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>>;
|
|
17
|
-
id: z.ZodOptional<z.ZodString>;
|
|
18
|
-
label: z.ZodString;
|
|
19
|
-
status: z.ZodDefault<z.ZodEnum<{
|
|
20
|
-
enabled: "enabled";
|
|
21
|
-
disabled: "disabled";
|
|
22
|
-
}>>;
|
|
23
|
-
type: z.ZodLiteral<"password">;
|
|
24
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
25
6
|
metadata: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Record<string, string | number | boolean> | undefined, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>>;
|
|
26
7
|
id: z.ZodOptional<z.ZodString>;
|
|
27
8
|
label: z.ZodString;
|
|
@@ -50,24 +31,6 @@ export declare const InsertStrategyPayloadSchema: z.ZodDiscriminatedUnion<[z.Zod
|
|
|
50
31
|
export type InsertStrategyInput = z.input<typeof InsertStrategyPayloadSchema>;
|
|
51
32
|
export type InsertStrategyPayload = z.output<typeof InsertStrategyPayloadSchema>;
|
|
52
33
|
export declare const UpdateStrategyPayloadSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
53
|
-
settings: z.ZodOptional<z.ZodObject<{
|
|
54
|
-
passwordPolicy: z.ZodObject<{
|
|
55
|
-
minimumLength: z.ZodDefault<z.ZodNumber>;
|
|
56
|
-
maximumLength: z.ZodDefault<z.ZodNumber>;
|
|
57
|
-
minimumCapital: z.ZodDefault<z.ZodNumber>;
|
|
58
|
-
minimumLower: z.ZodDefault<z.ZodNumber>;
|
|
59
|
-
minimumNumber: z.ZodDefault<z.ZodNumber>;
|
|
60
|
-
minimumSpecial: z.ZodDefault<z.ZodNumber>;
|
|
61
|
-
}, z.core.$strip>;
|
|
62
|
-
}, z.core.$strip>>;
|
|
63
|
-
metadata: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Record<string, string | number | boolean> | undefined, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>>;
|
|
64
|
-
label: z.ZodOptional<z.ZodString>;
|
|
65
|
-
status: z.ZodOptional<z.ZodEnum<{
|
|
66
|
-
enabled: "enabled";
|
|
67
|
-
disabled: "disabled";
|
|
68
|
-
}>>;
|
|
69
|
-
type: z.ZodLiteral<"password">;
|
|
70
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
71
34
|
metadata: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Record<string, string | number | boolean> | undefined, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>>;
|
|
72
35
|
label: z.ZodOptional<z.ZodString>;
|
|
73
36
|
status: z.ZodOptional<z.ZodEnum<{
|
|
@@ -94,29 +57,6 @@ export declare const UpdateStrategyPayloadSchema: z.ZodDiscriminatedUnion<[z.Zod
|
|
|
94
57
|
export type UpdateStrategyInput = z.input<typeof UpdateStrategyPayloadSchema>;
|
|
95
58
|
export type UpdateStrategyPayload = z.output<typeof UpdateStrategyPayloadSchema>;
|
|
96
59
|
export declare const StrategyPayloadSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
97
|
-
settings: z.ZodObject<{
|
|
98
|
-
passwordPolicy: z.ZodObject<{
|
|
99
|
-
minimumLength: z.ZodDefault<z.ZodNumber>;
|
|
100
|
-
maximumLength: z.ZodDefault<z.ZodNumber>;
|
|
101
|
-
minimumCapital: z.ZodDefault<z.ZodNumber>;
|
|
102
|
-
minimumLower: z.ZodDefault<z.ZodNumber>;
|
|
103
|
-
minimumNumber: z.ZodDefault<z.ZodNumber>;
|
|
104
|
-
minimumSpecial: z.ZodDefault<z.ZodNumber>;
|
|
105
|
-
}, z.core.$strip>;
|
|
106
|
-
}, z.core.$strip>;
|
|
107
|
-
type: z.ZodLiteral<"password">;
|
|
108
|
-
metadata: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Record<string, string | number | boolean> | undefined, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>>;
|
|
109
|
-
deactivatedAt: z.ZodOptional<z.ZodPipe<z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>, z.ZodTransform<string | undefined, Date | undefined>>>;
|
|
110
|
-
deletedAt: z.ZodOptional<z.ZodPipe<z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>, z.ZodTransform<string | undefined, Date | undefined>>>;
|
|
111
|
-
updatedAt: z.ZodPipe<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>, z.ZodTransform<string, Date>>;
|
|
112
|
-
createdAt: z.ZodPipe<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>, z.ZodTransform<string, Date>>;
|
|
113
|
-
id: z.ZodString;
|
|
114
|
-
status: z.ZodEnum<{
|
|
115
|
-
enabled: "enabled";
|
|
116
|
-
disabled: "disabled";
|
|
117
|
-
}>;
|
|
118
|
-
label: z.ZodString;
|
|
119
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
120
60
|
type: z.ZodLiteral<"email">;
|
|
121
61
|
metadata: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Record<string, string | number | boolean> | undefined, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>>;
|
|
122
62
|
deactivatedAt: z.ZodOptional<z.ZodPipe<z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>, z.ZodTransform<string | undefined, Date | undefined>>>;
|
|
@@ -152,29 +92,6 @@ export declare const StrategyPayloadSchema: z.ZodDiscriminatedUnion<[z.ZodObject
|
|
|
152
92
|
}, z.core.$strip>], "type">;
|
|
153
93
|
export type StrategyPayload = z.input<typeof StrategyPayloadSchema>;
|
|
154
94
|
export declare const StrategySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
155
|
-
settings: z.ZodObject<{
|
|
156
|
-
passwordPolicy: z.ZodObject<{
|
|
157
|
-
minimumLength: z.ZodDefault<z.ZodNumber>;
|
|
158
|
-
maximumLength: z.ZodDefault<z.ZodNumber>;
|
|
159
|
-
minimumCapital: z.ZodDefault<z.ZodNumber>;
|
|
160
|
-
minimumLower: z.ZodDefault<z.ZodNumber>;
|
|
161
|
-
minimumNumber: z.ZodDefault<z.ZodNumber>;
|
|
162
|
-
minimumSpecial: z.ZodDefault<z.ZodNumber>;
|
|
163
|
-
}, z.core.$strip>;
|
|
164
|
-
}, z.core.$strip>;
|
|
165
|
-
type: z.ZodLiteral<"password">;
|
|
166
|
-
metadata: z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Map<string, string | number | boolean>, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>;
|
|
167
|
-
deactivatedAt: z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>;
|
|
168
|
-
deletedAt: z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>;
|
|
169
|
-
updatedAt: z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>;
|
|
170
|
-
createdAt: z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>;
|
|
171
|
-
id: z.ZodString;
|
|
172
|
-
status: z.ZodDefault<z.ZodEnum<{
|
|
173
|
-
enabled: "enabled";
|
|
174
|
-
disabled: "disabled";
|
|
175
|
-
}>>;
|
|
176
|
-
label: z.ZodString;
|
|
177
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
178
95
|
type: z.ZodLiteral<"email">;
|
|
179
96
|
metadata: z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Map<string, string | number | boolean>, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>;
|
|
180
97
|
deactivatedAt: z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>;
|
|
@@ -212,6 +129,5 @@ export type StrategyProperties = z.input<typeof StrategySchema>;
|
|
|
212
129
|
export type Strategy = z.output<typeof StrategySchema>;
|
|
213
130
|
export { BaseInsertStrategyPayloadSchema, BaseStrategyPayloadSchema, BaseUpdateStrategyPayloadSchema, StrategyIdPropertySchema, StrategyIdSchema, StrategyLabelSchema, StrategyStatus, StrategyStatusSchema, StrategyType, type AnyStrategyStatus, type AnyStrategyType, type StrategyId, type StrategyIdProperty, } from './base.js';
|
|
214
131
|
export * from './types/email.js';
|
|
215
|
-
export * from './types/password.js';
|
|
216
132
|
export * from './types/totp.js';
|
|
217
133
|
//# sourceMappingURL=schema.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../../../src/authentication/strategies/schema/schema.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;
|
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../../../src/authentication/strategies/schema/schema.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAe5B;;GAEG;AACH,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;;;;;2BAGtC,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,2BAA2B,CAAC,CAAC;AAC9E,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAC1C,OAAO,2BAA2B,CACnC,CAAC;AAEF,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;;;2BAGtC,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,2BAA2B,CAAC,CAAC;AAC9E,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAC1C,OAAO,2BAA2B,CACnC,CAAC;AAEF,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2BAGhC,CAAC;AACH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2BAGzB,CAAC;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAChE,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,cAAc,CAAC,CAAC;AAEvD,OAAO,EACL,+BAA+B,EAC/B,yBAAyB,EACzB,+BAA+B,EAC/B,wBAAwB,EACxB,gBAAgB,EAChB,mBAAmB,EACnB,cAAc,EACd,oBAAoB,EACpB,YAAY,EACZ,KAAK,iBAAiB,EACtB,KAAK,eAAe,EACpB,KAAK,UAAU,EACf,KAAK,kBAAkB,GACxB,MAAM,WAAW,CAAC;AACnB,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC"}
|
|
@@ -1,31 +1,25 @@
|
|
|
1
1
|
import * as z from 'zod/v4';
|
|
2
2
|
import { EmailStrategyPayloadSchema, EmailStrategySchema, InsertEmailStrategyPayloadSchema, UpdateEmailStrategyPayloadSchema, } from './types/email.js';
|
|
3
|
-
import { InsertPasswordStrategyPayloadSchema, PasswordStrategyPayloadSchema, PasswordStrategySchema, UpdatePasswordStrategyPayloadSchema, } from './types/password.js';
|
|
4
3
|
import { InsertTOTPStrategyPayloadSchema, TOTPStrategyPayloadSchema, TOTPStrategySchema, UpdateTOTPStrategyPayloadSchema, } from './types/totp.js';
|
|
5
4
|
/**
|
|
6
5
|
* Union(s)
|
|
7
6
|
*/
|
|
8
7
|
export const InsertStrategyPayloadSchema = z.discriminatedUnion('type', [
|
|
9
|
-
InsertPasswordStrategyPayloadSchema,
|
|
10
8
|
InsertEmailStrategyPayloadSchema,
|
|
11
9
|
InsertTOTPStrategyPayloadSchema,
|
|
12
10
|
]);
|
|
13
11
|
export const UpdateStrategyPayloadSchema = z.discriminatedUnion('type', [
|
|
14
|
-
UpdatePasswordStrategyPayloadSchema,
|
|
15
12
|
UpdateEmailStrategyPayloadSchema,
|
|
16
13
|
UpdateTOTPStrategyPayloadSchema,
|
|
17
14
|
]);
|
|
18
15
|
export const StrategyPayloadSchema = z.discriminatedUnion('type', [
|
|
19
|
-
PasswordStrategyPayloadSchema,
|
|
20
16
|
EmailStrategyPayloadSchema,
|
|
21
17
|
TOTPStrategyPayloadSchema,
|
|
22
18
|
]);
|
|
23
19
|
export const StrategySchema = z.discriminatedUnion('type', [
|
|
24
|
-
PasswordStrategySchema,
|
|
25
20
|
EmailStrategySchema,
|
|
26
21
|
TOTPStrategySchema,
|
|
27
22
|
]);
|
|
28
23
|
export { BaseInsertStrategyPayloadSchema, BaseStrategyPayloadSchema, BaseUpdateStrategyPayloadSchema, StrategyIdPropertySchema, StrategyIdSchema, StrategyLabelSchema, StrategyStatus, StrategyStatusSchema, StrategyType, } from './base.js';
|
|
29
24
|
export * from './types/email.js';
|
|
30
|
-
export * from './types/password.js';
|
|
31
25
|
export * from './types/totp.js';
|
|
@@ -4,8 +4,8 @@ export declare const ImplicitGrantAuthorizationSchema: z.ZodObject<{
|
|
|
4
4
|
device: z.ZodOptional<z.ZodString>;
|
|
5
5
|
nonce: z.ZodOptional<z.ZodString>;
|
|
6
6
|
response_type: z.ZodEnum<{
|
|
7
|
-
token: "token";
|
|
8
7
|
id_token: "id_token";
|
|
8
|
+
token: "token";
|
|
9
9
|
"id_token token": "id_token token";
|
|
10
10
|
"token id_token": "token id_token";
|
|
11
11
|
}>;
|
|
@@ -38,8 +38,8 @@ export declare const AuthorizationGrantSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
38
38
|
device: z.ZodOptional<z.ZodString>;
|
|
39
39
|
nonce: z.ZodOptional<z.ZodString>;
|
|
40
40
|
response_type: z.ZodEnum<{
|
|
41
|
-
token: "token";
|
|
42
41
|
id_token: "id_token";
|
|
42
|
+
token: "token";
|
|
43
43
|
"id_token token": "id_token token";
|
|
44
44
|
"token id_token": "token id_token";
|
|
45
45
|
}>;
|
package/package.json
CHANGED
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import * as z from 'zod/v4';
|
|
2
|
-
export declare const SetPasswordActionPayloadSchema: z.ZodObject<{
|
|
3
|
-
operation: z.ZodLiteral<"set-password">;
|
|
4
|
-
user: z.ZodString;
|
|
5
|
-
identifier: z.ZodEnum<{
|
|
6
|
-
email: "email";
|
|
7
|
-
phoneNumber: "phoneNumber";
|
|
8
|
-
}>;
|
|
9
|
-
policy: z.ZodObject<{
|
|
10
|
-
minimumLength: z.ZodDefault<z.ZodNumber>;
|
|
11
|
-
maximumLength: z.ZodDefault<z.ZodNumber>;
|
|
12
|
-
minimumCapital: z.ZodDefault<z.ZodNumber>;
|
|
13
|
-
minimumLower: z.ZodDefault<z.ZodNumber>;
|
|
14
|
-
minimumNumber: z.ZodDefault<z.ZodNumber>;
|
|
15
|
-
minimumSpecial: z.ZodDefault<z.ZodNumber>;
|
|
16
|
-
}, z.core.$strip>;
|
|
17
|
-
metadata: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Record<string, string | number | boolean> | undefined, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>>;
|
|
18
|
-
deactivatedAt: z.ZodOptional<z.ZodPipe<z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>, z.ZodTransform<string | undefined, Date | undefined>>>;
|
|
19
|
-
deletedAt: z.ZodOptional<z.ZodPipe<z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>, z.ZodTransform<string | undefined, Date | undefined>>>;
|
|
20
|
-
updatedAt: z.ZodPipe<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>, z.ZodTransform<string, Date>>;
|
|
21
|
-
attempt: z.ZodNumber;
|
|
22
|
-
expiresAt: z.ZodPipe<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>, z.ZodTransform<string, Date>>;
|
|
23
|
-
id: z.ZodString;
|
|
24
|
-
}, z.core.$strip>;
|
|
25
|
-
export type SetPasswordActionPayload = z.output<typeof SetPasswordActionPayloadSchema>;
|
|
26
|
-
export declare const SetPasswordActionRequestSchema: z.ZodObject<{
|
|
27
|
-
code: z.ZodString;
|
|
28
|
-
password: z.ZodString;
|
|
29
|
-
}, z.core.$strip>;
|
|
30
|
-
export type SetPasswordActionRequest = z.output<typeof SetPasswordActionRequestSchema>;
|
|
31
|
-
//# sourceMappingURL=set-password.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"set-password.d.ts","sourceRoot":"","sources":["../../../../../src/action/schema/operations/set-password.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAM5B,eAAO,MAAM,8BAA8B;;;;;;;;;;;;;;;;;;;;;;iBAMzC,CAAC;AACH,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,MAAM,CAC7C,OAAO,8BAA8B,CACtC,CAAC;AAEF,eAAO,MAAM,8BAA8B;;;iBAGzC,CAAC;AACH,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,MAAM,CAC7C,OAAO,8BAA8B,CACtC,CAAC"}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
-
var ownKeys = function(o) {
|
|
20
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
-
var ar = [];
|
|
22
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
-
return ar;
|
|
24
|
-
};
|
|
25
|
-
return ownKeys(o);
|
|
26
|
-
};
|
|
27
|
-
return function (mod) {
|
|
28
|
-
if (mod && mod.__esModule) return mod;
|
|
29
|
-
var result = {};
|
|
30
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
-
__setModuleDefault(result, mod);
|
|
32
|
-
return result;
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
-
exports.SetPasswordActionRequestSchema = exports.SetPasswordActionPayloadSchema = void 0;
|
|
37
|
-
const z = __importStar(require("zod/v4"));
|
|
38
|
-
const schema_js_1 = require("../../../authentication/strategies/schema/schema.js");
|
|
39
|
-
const schema_js_2 = require("../../../customer/schema.js");
|
|
40
|
-
const schema_js_3 = require("../../../identity/schema.js");
|
|
41
|
-
const base_js_1 = require("../base.js");
|
|
42
|
-
exports.SetPasswordActionPayloadSchema = z.object({
|
|
43
|
-
...base_js_1.BasePayloadSchema.shape,
|
|
44
|
-
operation: z.literal('set-password'),
|
|
45
|
-
user: schema_js_2.UserIdSchema,
|
|
46
|
-
identifier: schema_js_3.IdentityIdentifierSchema,
|
|
47
|
-
policy: schema_js_1.PasswordPolicySchema,
|
|
48
|
-
});
|
|
49
|
-
exports.SetPasswordActionRequestSchema = z.object({
|
|
50
|
-
code: z.string(),
|
|
51
|
-
password: z.string(),
|
|
52
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"set-password.test.d.ts","sourceRoot":"","sources":["../../../../../src/action/schema/operations/set-password.test.ts"],"names":[],"mappings":""}
|
|
@@ -1,168 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const vitest_1 = require("vitest");
|
|
4
|
-
const schema_js_1 = require("../../../customer/schema.js");
|
|
5
|
-
const utils_js_1 = require("../utils.js");
|
|
6
|
-
const set_password_js_1 = require("./set-password.js");
|
|
7
|
-
(0, vitest_1.describe)('Action Schema Operations - Set Password', () => {
|
|
8
|
-
(0, vitest_1.describe)('SetPasswordActionPayloadSchema', () => {
|
|
9
|
-
(0, vitest_1.test)('should accept complete payload with email identifier', () => {
|
|
10
|
-
const payload = {
|
|
11
|
-
id: (0, utils_js_1.generateActionId)(),
|
|
12
|
-
operation: 'set-password',
|
|
13
|
-
user: (0, schema_js_1.generateUserId)(),
|
|
14
|
-
identifier: 'email',
|
|
15
|
-
policy: {},
|
|
16
|
-
attempt: 1,
|
|
17
|
-
expiresAt: new Date().toISOString(),
|
|
18
|
-
updatedAt: new Date().toISOString(),
|
|
19
|
-
metadata: { key: 'value' },
|
|
20
|
-
};
|
|
21
|
-
const result = set_password_js_1.SetPasswordActionPayloadSchema.safeParse(payload);
|
|
22
|
-
(0, vitest_1.expect)(result.success).toBe(true);
|
|
23
|
-
// Policy defaults are applied, so we don't compare exact equality
|
|
24
|
-
});
|
|
25
|
-
(0, vitest_1.test)('should accept payload with phoneNumber identifier', () => {
|
|
26
|
-
const payload = {
|
|
27
|
-
id: (0, utils_js_1.generateActionId)(),
|
|
28
|
-
operation: 'set-password',
|
|
29
|
-
user: (0, schema_js_1.generateUserId)(),
|
|
30
|
-
identifier: 'phoneNumber',
|
|
31
|
-
policy: {},
|
|
32
|
-
attempt: 1,
|
|
33
|
-
expiresAt: new Date().toISOString(),
|
|
34
|
-
updatedAt: new Date().toISOString(),
|
|
35
|
-
metadata: {},
|
|
36
|
-
};
|
|
37
|
-
const result = set_password_js_1.SetPasswordActionPayloadSchema.safeParse(payload);
|
|
38
|
-
(0, vitest_1.expect)(result.success).toBe(true);
|
|
39
|
-
// Policy defaults are applied, so we don't compare exact equality
|
|
40
|
-
});
|
|
41
|
-
(0, vitest_1.test)('should accept payload with optional dates', () => {
|
|
42
|
-
const payload = {
|
|
43
|
-
id: (0, utils_js_1.generateActionId)(),
|
|
44
|
-
operation: 'set-password',
|
|
45
|
-
user: (0, schema_js_1.generateUserId)(),
|
|
46
|
-
identifier: 'email',
|
|
47
|
-
policy: {},
|
|
48
|
-
attempt: 2,
|
|
49
|
-
expiresAt: new Date().toISOString(),
|
|
50
|
-
updatedAt: new Date().toISOString(),
|
|
51
|
-
deletedAt: new Date().toISOString(),
|
|
52
|
-
deactivatedAt: new Date().toISOString(),
|
|
53
|
-
metadata: {},
|
|
54
|
-
};
|
|
55
|
-
const result = set_password_js_1.SetPasswordActionPayloadSchema.safeParse(payload);
|
|
56
|
-
(0, vitest_1.expect)(result.success).toBe(true);
|
|
57
|
-
});
|
|
58
|
-
(0, vitest_1.test)('should reject invalid operation', () => {
|
|
59
|
-
const payload = {
|
|
60
|
-
id: (0, utils_js_1.generateActionId)(),
|
|
61
|
-
operation: 'invalid-operation',
|
|
62
|
-
user: (0, schema_js_1.generateUserId)(),
|
|
63
|
-
identifier: 'email',
|
|
64
|
-
policy: {},
|
|
65
|
-
attempt: 1,
|
|
66
|
-
expiresAt: new Date().toISOString(),
|
|
67
|
-
updatedAt: new Date().toISOString(),
|
|
68
|
-
metadata: {},
|
|
69
|
-
};
|
|
70
|
-
const result = set_password_js_1.SetPasswordActionPayloadSchema.safeParse(payload);
|
|
71
|
-
(0, vitest_1.expect)(result.success).toBe(false);
|
|
72
|
-
});
|
|
73
|
-
(0, vitest_1.test)('should reject invalid identifier', () => {
|
|
74
|
-
const payload = {
|
|
75
|
-
id: (0, utils_js_1.generateActionId)(),
|
|
76
|
-
operation: 'set-password',
|
|
77
|
-
user: (0, schema_js_1.generateUserId)(),
|
|
78
|
-
identifier: 'username',
|
|
79
|
-
policy: {},
|
|
80
|
-
attempt: 1,
|
|
81
|
-
expiresAt: new Date().toISOString(),
|
|
82
|
-
updatedAt: new Date().toISOString(),
|
|
83
|
-
metadata: {},
|
|
84
|
-
};
|
|
85
|
-
const result = set_password_js_1.SetPasswordActionPayloadSchema.safeParse(payload);
|
|
86
|
-
(0, vitest_1.expect)(result.success).toBe(false);
|
|
87
|
-
});
|
|
88
|
-
(0, vitest_1.test)('should reject missing required fields', () => {
|
|
89
|
-
const payload = {
|
|
90
|
-
id: (0, utils_js_1.generateActionId)(),
|
|
91
|
-
operation: 'set-password',
|
|
92
|
-
// missing user, identifier, policy, etc.
|
|
93
|
-
};
|
|
94
|
-
const result = set_password_js_1.SetPasswordActionPayloadSchema.safeParse(payload);
|
|
95
|
-
(0, vitest_1.expect)(result.success).toBe(false);
|
|
96
|
-
});
|
|
97
|
-
(0, vitest_1.test)('should delete undeclared keys', () => {
|
|
98
|
-
const payload = {
|
|
99
|
-
id: (0, utils_js_1.generateActionId)(),
|
|
100
|
-
operation: 'set-password',
|
|
101
|
-
user: (0, schema_js_1.generateUserId)(),
|
|
102
|
-
identifier: 'email',
|
|
103
|
-
policy: {},
|
|
104
|
-
attempt: 1,
|
|
105
|
-
expiresAt: new Date().toISOString(),
|
|
106
|
-
updatedAt: new Date().toISOString(),
|
|
107
|
-
metadata: {},
|
|
108
|
-
extraField: 'should be removed',
|
|
109
|
-
};
|
|
110
|
-
const result = set_password_js_1.SetPasswordActionPayloadSchema.safeParse(payload);
|
|
111
|
-
// Parse succeeds for valid data
|
|
112
|
-
(0, vitest_1.expect)(result.data).not.toHaveProperty('extraField');
|
|
113
|
-
});
|
|
114
|
-
});
|
|
115
|
-
(0, vitest_1.describe)('SetPasswordActionRequestSchema', () => {
|
|
116
|
-
(0, vitest_1.test)('should accept valid request', () => {
|
|
117
|
-
const request = {
|
|
118
|
-
code: 'reset_code_123',
|
|
119
|
-
password: 'NewPassword123!',
|
|
120
|
-
};
|
|
121
|
-
const result = set_password_js_1.SetPasswordActionRequestSchema.safeParse(request);
|
|
122
|
-
// Parse succeeds for valid data
|
|
123
|
-
(0, vitest_1.expect)(result.data).toEqual(request);
|
|
124
|
-
});
|
|
125
|
-
(0, vitest_1.test)('should reject missing code', () => {
|
|
126
|
-
const request = {
|
|
127
|
-
password: 'NewPassword123!',
|
|
128
|
-
};
|
|
129
|
-
const result = set_password_js_1.SetPasswordActionRequestSchema.safeParse(request);
|
|
130
|
-
(0, vitest_1.expect)(result.success).toBe(false);
|
|
131
|
-
});
|
|
132
|
-
(0, vitest_1.test)('should reject missing password', () => {
|
|
133
|
-
const request = {
|
|
134
|
-
code: 'reset_code_123',
|
|
135
|
-
};
|
|
136
|
-
const result = set_password_js_1.SetPasswordActionRequestSchema.safeParse(request);
|
|
137
|
-
(0, vitest_1.expect)(result.success).toBe(false);
|
|
138
|
-
});
|
|
139
|
-
(0, vitest_1.test)('should reject non-string values', () => {
|
|
140
|
-
const request1 = {
|
|
141
|
-
code: 123456,
|
|
142
|
-
password: 'NewPassword123!',
|
|
143
|
-
};
|
|
144
|
-
const request2 = {
|
|
145
|
-
code: 'reset_code_123',
|
|
146
|
-
password: 123456,
|
|
147
|
-
};
|
|
148
|
-
const result1 = set_password_js_1.SetPasswordActionRequestSchema.safeParse(request1);
|
|
149
|
-
(0, vitest_1.expect)(result1.success).toBe(false);
|
|
150
|
-
const result2 = set_password_js_1.SetPasswordActionRequestSchema.safeParse(request2);
|
|
151
|
-
(0, vitest_1.expect)(result2.success).toBe(false);
|
|
152
|
-
});
|
|
153
|
-
(0, vitest_1.test)('should delete undeclared keys', () => {
|
|
154
|
-
const request = {
|
|
155
|
-
code: 'reset_code_123',
|
|
156
|
-
password: 'NewPassword123!',
|
|
157
|
-
extraField: 'should be removed',
|
|
158
|
-
};
|
|
159
|
-
const result = set_password_js_1.SetPasswordActionRequestSchema.safeParse(request);
|
|
160
|
-
// Parse succeeds for valid data
|
|
161
|
-
(0, vitest_1.expect)(result.data).not.toHaveProperty('extraField');
|
|
162
|
-
(0, vitest_1.expect)(result.data).toEqual({
|
|
163
|
-
code: 'reset_code_123',
|
|
164
|
-
password: 'NewPassword123!',
|
|
165
|
-
});
|
|
166
|
-
});
|
|
167
|
-
});
|
|
168
|
-
});
|
|
@@ -1,139 +0,0 @@
|
|
|
1
|
-
import * as z from 'zod/v4';
|
|
2
|
-
export declare const PasswordPolicyDefaults: {
|
|
3
|
-
minimumLength: number;
|
|
4
|
-
maximumLength: number;
|
|
5
|
-
minimumCapital: number;
|
|
6
|
-
minimumLower: number;
|
|
7
|
-
minimumNumber: number;
|
|
8
|
-
minimumSpecial: number;
|
|
9
|
-
};
|
|
10
|
-
export declare const PasswordPolicySchema: z.ZodObject<{
|
|
11
|
-
minimumLength: z.ZodDefault<z.ZodNumber>;
|
|
12
|
-
maximumLength: z.ZodDefault<z.ZodNumber>;
|
|
13
|
-
minimumCapital: z.ZodDefault<z.ZodNumber>;
|
|
14
|
-
minimumLower: z.ZodDefault<z.ZodNumber>;
|
|
15
|
-
minimumNumber: z.ZodDefault<z.ZodNumber>;
|
|
16
|
-
minimumSpecial: z.ZodDefault<z.ZodNumber>;
|
|
17
|
-
}, z.core.$strip>;
|
|
18
|
-
export declare const PasswordStrategySettingsPropertySchema: z.ZodObject<{
|
|
19
|
-
settings: z.ZodObject<{
|
|
20
|
-
passwordPolicy: z.ZodObject<{
|
|
21
|
-
minimumLength: z.ZodDefault<z.ZodNumber>;
|
|
22
|
-
maximumLength: z.ZodDefault<z.ZodNumber>;
|
|
23
|
-
minimumCapital: z.ZodDefault<z.ZodNumber>;
|
|
24
|
-
minimumLower: z.ZodDefault<z.ZodNumber>;
|
|
25
|
-
minimumNumber: z.ZodDefault<z.ZodNumber>;
|
|
26
|
-
minimumSpecial: z.ZodDefault<z.ZodNumber>;
|
|
27
|
-
}, z.core.$strip>;
|
|
28
|
-
}, z.core.$strip>;
|
|
29
|
-
}, z.core.$strip>;
|
|
30
|
-
export declare const PasswordStrategySchema: z.ZodObject<{
|
|
31
|
-
settings: z.ZodObject<{
|
|
32
|
-
passwordPolicy: z.ZodObject<{
|
|
33
|
-
minimumLength: z.ZodDefault<z.ZodNumber>;
|
|
34
|
-
maximumLength: z.ZodDefault<z.ZodNumber>;
|
|
35
|
-
minimumCapital: z.ZodDefault<z.ZodNumber>;
|
|
36
|
-
minimumLower: z.ZodDefault<z.ZodNumber>;
|
|
37
|
-
minimumNumber: z.ZodDefault<z.ZodNumber>;
|
|
38
|
-
minimumSpecial: z.ZodDefault<z.ZodNumber>;
|
|
39
|
-
}, z.core.$strip>;
|
|
40
|
-
}, z.core.$strip>;
|
|
41
|
-
type: z.ZodLiteral<"password">;
|
|
42
|
-
metadata: z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Map<string, string | number | boolean>, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>;
|
|
43
|
-
deactivatedAt: z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>;
|
|
44
|
-
deletedAt: z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>;
|
|
45
|
-
updatedAt: z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>;
|
|
46
|
-
createdAt: z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>;
|
|
47
|
-
id: z.ZodString;
|
|
48
|
-
status: z.ZodDefault<z.ZodEnum<{
|
|
49
|
-
enabled: "enabled";
|
|
50
|
-
disabled: "disabled";
|
|
51
|
-
}>>;
|
|
52
|
-
label: z.ZodString;
|
|
53
|
-
}, z.core.$strip>;
|
|
54
|
-
export type PasswordStrategyProperties = z.input<typeof PasswordStrategySchema>;
|
|
55
|
-
export type PasswordStrategy = z.output<typeof PasswordStrategySchema>;
|
|
56
|
-
export declare const PasswordStrategyPayloadSchema: z.ZodObject<{
|
|
57
|
-
settings: z.ZodObject<{
|
|
58
|
-
passwordPolicy: z.ZodObject<{
|
|
59
|
-
minimumLength: z.ZodDefault<z.ZodNumber>;
|
|
60
|
-
maximumLength: z.ZodDefault<z.ZodNumber>;
|
|
61
|
-
minimumCapital: z.ZodDefault<z.ZodNumber>;
|
|
62
|
-
minimumLower: z.ZodDefault<z.ZodNumber>;
|
|
63
|
-
minimumNumber: z.ZodDefault<z.ZodNumber>;
|
|
64
|
-
minimumSpecial: z.ZodDefault<z.ZodNumber>;
|
|
65
|
-
}, z.core.$strip>;
|
|
66
|
-
}, z.core.$strip>;
|
|
67
|
-
type: z.ZodLiteral<"password">;
|
|
68
|
-
metadata: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Record<string, string | number | boolean> | undefined, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>>;
|
|
69
|
-
deactivatedAt: z.ZodOptional<z.ZodPipe<z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>, z.ZodTransform<string | undefined, Date | undefined>>>;
|
|
70
|
-
deletedAt: z.ZodOptional<z.ZodPipe<z.ZodOptional<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>>, z.ZodTransform<string | undefined, Date | undefined>>>;
|
|
71
|
-
updatedAt: z.ZodPipe<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>, z.ZodTransform<string, Date>>;
|
|
72
|
-
createdAt: z.ZodPipe<z.ZodUnion<readonly [z.ZodDate, z.ZodPipe<z.ZodString, z.ZodTransform<Date, string>>]>, z.ZodTransform<string, Date>>;
|
|
73
|
-
id: z.ZodString;
|
|
74
|
-
status: z.ZodEnum<{
|
|
75
|
-
enabled: "enabled";
|
|
76
|
-
disabled: "disabled";
|
|
77
|
-
}>;
|
|
78
|
-
label: z.ZodString;
|
|
79
|
-
}, z.core.$strip>;
|
|
80
|
-
export type PasswordStrategyPayload = z.output<typeof PasswordStrategyPayloadSchema>;
|
|
81
|
-
export declare const InsertPasswordStrategyPayloadSchema: z.ZodObject<{
|
|
82
|
-
settings: z.ZodOptional<z.ZodObject<{
|
|
83
|
-
passwordPolicy: z.ZodObject<{
|
|
84
|
-
minimumLength: z.ZodDefault<z.ZodNumber>;
|
|
85
|
-
maximumLength: z.ZodDefault<z.ZodNumber>;
|
|
86
|
-
minimumCapital: z.ZodDefault<z.ZodNumber>;
|
|
87
|
-
minimumLower: z.ZodDefault<z.ZodNumber>;
|
|
88
|
-
minimumNumber: z.ZodDefault<z.ZodNumber>;
|
|
89
|
-
minimumSpecial: z.ZodDefault<z.ZodNumber>;
|
|
90
|
-
}, z.core.$strip>;
|
|
91
|
-
}, z.core.$strip>>;
|
|
92
|
-
metadata: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Record<string, string | number | boolean> | undefined, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>>;
|
|
93
|
-
id: z.ZodOptional<z.ZodString>;
|
|
94
|
-
label: z.ZodString;
|
|
95
|
-
status: z.ZodDefault<z.ZodEnum<{
|
|
96
|
-
enabled: "enabled";
|
|
97
|
-
disabled: "disabled";
|
|
98
|
-
}>>;
|
|
99
|
-
type: z.ZodLiteral<"password">;
|
|
100
|
-
}, z.core.$strip>;
|
|
101
|
-
export type InsertPasswordStrategyInput = z.input<typeof InsertPasswordStrategyPayloadSchema>;
|
|
102
|
-
export type InsertPasswordStrategyPayload = z.output<typeof InsertPasswordStrategyPayloadSchema>;
|
|
103
|
-
export declare const UpdatePasswordStrategyPayloadSchema: z.ZodObject<{
|
|
104
|
-
settings: z.ZodOptional<z.ZodObject<{
|
|
105
|
-
passwordPolicy: z.ZodObject<{
|
|
106
|
-
minimumLength: z.ZodDefault<z.ZodNumber>;
|
|
107
|
-
maximumLength: z.ZodDefault<z.ZodNumber>;
|
|
108
|
-
minimumCapital: z.ZodDefault<z.ZodNumber>;
|
|
109
|
-
minimumLower: z.ZodDefault<z.ZodNumber>;
|
|
110
|
-
minimumNumber: z.ZodDefault<z.ZodNumber>;
|
|
111
|
-
minimumSpecial: z.ZodDefault<z.ZodNumber>;
|
|
112
|
-
}, z.core.$strip>;
|
|
113
|
-
}, z.core.$strip>>;
|
|
114
|
-
metadata: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodUndefined, z.ZodNull, z.ZodCustom<Map<string, string | number | boolean>, Map<string, string | number | boolean>>, z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>]>, z.ZodTransform<Record<string, string | number | boolean> | undefined, Record<string, string | number | boolean> | Map<string, string | number | boolean> | null | undefined>>>;
|
|
115
|
-
label: z.ZodOptional<z.ZodString>;
|
|
116
|
-
status: z.ZodOptional<z.ZodEnum<{
|
|
117
|
-
enabled: "enabled";
|
|
118
|
-
disabled: "disabled";
|
|
119
|
-
}>>;
|
|
120
|
-
type: z.ZodLiteral<"password">;
|
|
121
|
-
}, z.core.$strip>;
|
|
122
|
-
export type UpdatePasswordStrategyInput = z.input<typeof UpdatePasswordStrategyPayloadSchema>;
|
|
123
|
-
export type UpdatePasswordStrategyPayload = z.output<typeof UpdatePasswordStrategyPayloadSchema>;
|
|
124
|
-
export declare const ForgotPasswordSchema: z.ZodObject<{
|
|
125
|
-
identifier: z.ZodOptional<z.ZodString>;
|
|
126
|
-
identifierType: z.ZodOptional<z.ZodEnum<{
|
|
127
|
-
email: "email";
|
|
128
|
-
phoneNumber: "phoneNumber";
|
|
129
|
-
}>>;
|
|
130
|
-
}, z.core.$strip>;
|
|
131
|
-
export declare const VerifyPasswordSchema: z.ZodObject<{
|
|
132
|
-
password: z.ZodString;
|
|
133
|
-
identifier: z.ZodOptional<z.ZodString>;
|
|
134
|
-
identifierType: z.ZodOptional<z.ZodEnum<{
|
|
135
|
-
email: "email";
|
|
136
|
-
phoneNumber: "phoneNumber";
|
|
137
|
-
}>>;
|
|
138
|
-
}, z.core.$strip>;
|
|
139
|
-
//# sourceMappingURL=password.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"password.d.ts","sourceRoot":"","sources":["../../../../../../src/authentication/strategies/schema/types/password.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAU5B,eAAO,MAAM,sBAAsB;;;;;;;CAOlC,CAAC;AAMF,eAAO,MAAM,oBAAoB;;;;;;;iBAO/B,CAAC;AAMH,eAAO,MAAM,sCAAsC;;;;;;;;;;;iBAEjD,CAAC;AAEH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;iBAIjC,CAAC;AACH,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAChF,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAEvE,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;iBAIxC,CAAC;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,MAAM,CAC5C,OAAO,6BAA6B,CACrC,CAAC;AAEF,eAAO,MAAM,mCAAmC;;;;;;;;;;;;;;;;;;;iBAI9C,CAAC;AACH,MAAM,MAAM,2BAA2B,GAAG,CAAC,CAAC,KAAK,CAC/C,OAAO,mCAAmC,CAC3C,CAAC;AACF,MAAM,MAAM,6BAA6B,GAAG,CAAC,CAAC,MAAM,CAClD,OAAO,mCAAmC,CAC3C,CAAC;AAEF,eAAO,MAAM,mCAAmC;;;;;;;;;;;;;;;;;;iBAI9C,CAAC;AACH,MAAM,MAAM,2BAA2B,GAAG,CAAC,CAAC,KAAK,CAC/C,OAAO,mCAAmC,CAC3C,CAAC;AACF,MAAM,MAAM,6BAA6B,GAAG,CAAC,CAAC,MAAM,CAClD,OAAO,mCAAmC,CAC3C,CAAC;AAEF,eAAO,MAAM,oBAAoB;;;;;;iBAG/B,CAAC;AAEH,eAAO,MAAM,oBAAoB;;;;;;;iBAI/B,CAAC"}
|