@logto/schemas 1.30.0 → 1.31.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/alterations/1.31.0-1753689065-add-forgot-password-methods-to-sie-table.ts +20 -0
- package/alterations-js/1.31.0-1753689065-add-forgot-password-methods-to-sie-table.js +16 -0
- package/lib/consts/subscriptions.d.ts +8 -2
- package/lib/consts/subscriptions.js +7 -1
- package/lib/db-entries/sign-in-experience.d.ts +4 -2
- package/lib/db-entries/sign-in-experience.js +5 -1
- package/lib/foundations/jsonb-types/custom-profile-fields.d.ts +73 -50
- package/lib/foundations/jsonb-types/custom-profile-fields.js +3 -2
- package/lib/foundations/jsonb-types/sign-in-experience.d.ts +6 -0
- package/lib/foundations/jsonb-types/sign-in-experience.js +6 -0
- package/lib/foundations/jsonb-types/users.d.ts +0 -94
- package/lib/foundations/jsonb-types/users.js +0 -11
- package/lib/types/consent.d.ts +0 -40
- package/lib/types/custom-profile-fields.d.ts +389 -376
- package/lib/types/custom-profile-fields.js +42 -23
- package/lib/types/interactions.d.ts +0 -120
- package/lib/types/interactions.js +0 -31
- package/lib/types/logto-config/jwt-customizer.d.ts +0 -20
- package/lib/types/sign-in-experience.d.ts +7 -6
- package/lib/types/sign-in-experience.js +4 -3
- package/lib/types/user.d.ts +0 -60
- package/lib/types/verification-records/code-verification.d.ts +73 -1
- package/lib/types/verification-records/code-verification.js +14 -0
- package/lib/types/verification-records/verification-type.d.ts +2 -0
- package/lib/types/verification-records/verification-type.js +2 -0
- package/package.json +6 -6
- package/tables/sign_in_experiences.sql +1 -0
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { sql } from '@silverhand/slonik';
|
|
2
|
+
|
|
3
|
+
import type { AlterationScript } from '../lib/types/alteration.js';
|
|
4
|
+
|
|
5
|
+
const alteration: AlterationScript = {
|
|
6
|
+
up: async (pool) => {
|
|
7
|
+
await pool.query(sql`
|
|
8
|
+
alter table sign_in_experiences
|
|
9
|
+
add column forgot_password_methods jsonb;
|
|
10
|
+
`);
|
|
11
|
+
},
|
|
12
|
+
down: async (pool) => {
|
|
13
|
+
await pool.query(sql`
|
|
14
|
+
alter table sign_in_experiences
|
|
15
|
+
drop column forgot_password_methods;
|
|
16
|
+
`);
|
|
17
|
+
},
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export default alteration;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { sql } from '@silverhand/slonik';
|
|
2
|
+
const alteration = {
|
|
3
|
+
up: async (pool) => {
|
|
4
|
+
await pool.query(sql `
|
|
5
|
+
alter table sign_in_experiences
|
|
6
|
+
add column forgot_password_methods jsonb;
|
|
7
|
+
`);
|
|
8
|
+
},
|
|
9
|
+
down: async (pool) => {
|
|
10
|
+
await pool.query(sql `
|
|
11
|
+
alter table sign_in_experiences
|
|
12
|
+
drop column forgot_password_methods;
|
|
13
|
+
`);
|
|
14
|
+
},
|
|
15
|
+
};
|
|
16
|
+
export default alteration;
|
|
@@ -19,9 +19,15 @@ export declare enum ReservedPlanId {
|
|
|
19
19
|
*/
|
|
20
20
|
Admin = "admin",
|
|
21
21
|
/**
|
|
22
|
-
*
|
|
22
|
+
* @deprecated
|
|
23
|
+
* Grandfathered Pro plan ID deprecated from 2025-09.
|
|
24
|
+
* Use {@link Pro202509} instead.
|
|
25
|
+
*/
|
|
26
|
+
Pro202411 = "pro-202411",
|
|
27
|
+
/**
|
|
28
|
+
* Latest Pro plan ID applied from 2025-09.
|
|
23
29
|
*/
|
|
24
|
-
|
|
30
|
+
Pro202509 = "pro-202509"
|
|
25
31
|
}
|
|
26
32
|
/**
|
|
27
33
|
* Tenant subscription related Redis cache keys.
|
|
@@ -20,9 +20,15 @@ export var ReservedPlanId;
|
|
|
20
20
|
*/
|
|
21
21
|
ReservedPlanId["Admin"] = "admin";
|
|
22
22
|
/**
|
|
23
|
-
*
|
|
23
|
+
* @deprecated
|
|
24
|
+
* Grandfathered Pro plan ID deprecated from 2025-09.
|
|
25
|
+
* Use {@link Pro202509} instead.
|
|
24
26
|
*/
|
|
25
27
|
ReservedPlanId["Pro202411"] = "pro-202411";
|
|
28
|
+
/**
|
|
29
|
+
* Latest Pro plan ID applied from 2025-09.
|
|
30
|
+
*/
|
|
31
|
+
ReservedPlanId["Pro202509"] = "pro-202509";
|
|
26
32
|
})(ReservedPlanId || (ReservedPlanId = {}));
|
|
27
33
|
/**
|
|
28
34
|
* Tenant subscription related Redis cache keys.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Color, Branding, LanguageInfo, SignIn, SignUp, SocialSignIn, ConnectorTargets, CustomContent, CustomUiAssets, PartialPasswordPolicy, Mfa, CaptchaPolicy, SentinelPolicy, EmailBlocklistPolicy, GeneratedSchema } from './../foundations/index.js';
|
|
1
|
+
import { Color, Branding, LanguageInfo, SignIn, SignUp, SocialSignIn, ConnectorTargets, CustomContent, CustomUiAssets, PartialPasswordPolicy, Mfa, CaptchaPolicy, SentinelPolicy, EmailBlocklistPolicy, ForgotPasswordMethods, GeneratedSchema } from './../foundations/index.js';
|
|
2
2
|
import { AgreeToTermsPolicy, SignInMode } from './custom-types.js';
|
|
3
3
|
/**
|
|
4
4
|
*
|
|
@@ -32,6 +32,7 @@ export type CreateSignInExperience = {
|
|
|
32
32
|
captchaPolicy?: CaptchaPolicy;
|
|
33
33
|
sentinelPolicy?: SentinelPolicy;
|
|
34
34
|
emailBlocklistPolicy?: EmailBlocklistPolicy;
|
|
35
|
+
forgotPasswordMethods?: ForgotPasswordMethods | null;
|
|
35
36
|
};
|
|
36
37
|
export type SignInExperience = {
|
|
37
38
|
tenantId: string;
|
|
@@ -60,6 +61,7 @@ export type SignInExperience = {
|
|
|
60
61
|
captchaPolicy: CaptchaPolicy;
|
|
61
62
|
sentinelPolicy: SentinelPolicy;
|
|
62
63
|
emailBlocklistPolicy: EmailBlocklistPolicy;
|
|
64
|
+
forgotPasswordMethods: ForgotPasswordMethods | null;
|
|
63
65
|
};
|
|
64
|
-
export type SignInExperienceKeys = 'tenantId' | 'id' | 'color' | 'branding' | 'languageInfo' | 'termsOfUseUrl' | 'privacyPolicyUrl' | 'agreeToTermsPolicy' | 'signIn' | 'signUp' | 'socialSignIn' | 'socialSignInConnectorTargets' | 'signInMode' | 'customCss' | 'customContent' | 'customUiAssets' | 'passwordPolicy' | 'mfa' | 'singleSignOnEnabled' | 'supportEmail' | 'supportWebsiteUrl' | 'unknownSessionRedirectUrl' | 'captchaPolicy' | 'sentinelPolicy' | 'emailBlocklistPolicy';
|
|
66
|
+
export type SignInExperienceKeys = 'tenantId' | 'id' | 'color' | 'branding' | 'languageInfo' | 'termsOfUseUrl' | 'privacyPolicyUrl' | 'agreeToTermsPolicy' | 'signIn' | 'signUp' | 'socialSignIn' | 'socialSignInConnectorTargets' | 'signInMode' | 'customCss' | 'customContent' | 'customUiAssets' | 'passwordPolicy' | 'mfa' | 'singleSignOnEnabled' | 'supportEmail' | 'supportWebsiteUrl' | 'unknownSessionRedirectUrl' | 'captchaPolicy' | 'sentinelPolicy' | 'emailBlocklistPolicy' | 'forgotPasswordMethods';
|
|
65
67
|
export declare const SignInExperiences: GeneratedSchema<SignInExperienceKeys, CreateSignInExperience, SignInExperience, 'sign_in_experiences', 'sign_in_experience'>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
2
2
|
import { z } from 'zod';
|
|
3
|
-
import { colorGuard, brandingGuard, languageInfoGuard, signInGuard, signUpGuard, socialSignInGuard, connectorTargetsGuard, customContentGuard, customUiAssetsGuard, partialPasswordPolicyGuard, mfaGuard, captchaPolicyGuard, sentinelPolicyGuard, emailBlocklistPolicyGuard } from './../foundations/index.js';
|
|
3
|
+
import { colorGuard, brandingGuard, languageInfoGuard, signInGuard, signUpGuard, socialSignInGuard, connectorTargetsGuard, customContentGuard, customUiAssetsGuard, partialPasswordPolicyGuard, mfaGuard, captchaPolicyGuard, sentinelPolicyGuard, emailBlocklistPolicyGuard, forgotPasswordMethodsGuard } from './../foundations/index.js';
|
|
4
4
|
import { AgreeToTermsPolicy, SignInMode } from './custom-types.js';
|
|
5
5
|
const createGuard = z.object({
|
|
6
6
|
tenantId: z.string().max(21).optional(),
|
|
@@ -28,6 +28,7 @@ const createGuard = z.object({
|
|
|
28
28
|
captchaPolicy: captchaPolicyGuard.optional(),
|
|
29
29
|
sentinelPolicy: sentinelPolicyGuard.optional(),
|
|
30
30
|
emailBlocklistPolicy: emailBlocklistPolicyGuard.optional(),
|
|
31
|
+
forgotPasswordMethods: forgotPasswordMethodsGuard.nullable().optional(),
|
|
31
32
|
});
|
|
32
33
|
const guard = z.object({
|
|
33
34
|
tenantId: z.string().max(21),
|
|
@@ -55,6 +56,7 @@ const guard = z.object({
|
|
|
55
56
|
captchaPolicy: captchaPolicyGuard,
|
|
56
57
|
sentinelPolicy: sentinelPolicyGuard,
|
|
57
58
|
emailBlocklistPolicy: emailBlocklistPolicyGuard,
|
|
59
|
+
forgotPasswordMethods: forgotPasswordMethodsGuard.nullable(),
|
|
58
60
|
});
|
|
59
61
|
export const SignInExperiences = Object.freeze({
|
|
60
62
|
table: 'sign_in_experiences',
|
|
@@ -85,6 +87,7 @@ export const SignInExperiences = Object.freeze({
|
|
|
85
87
|
captchaPolicy: 'captcha_policy',
|
|
86
88
|
sentinelPolicy: 'sentinel_policy',
|
|
87
89
|
emailBlocklistPolicy: 'email_blocklist_policy',
|
|
90
|
+
forgotPasswordMethods: 'forgot_password_methods',
|
|
88
91
|
},
|
|
89
92
|
fieldKeys: [
|
|
90
93
|
'tenantId',
|
|
@@ -112,6 +115,7 @@ export const SignInExperiences = Object.freeze({
|
|
|
112
115
|
'captchaPolicy',
|
|
113
116
|
'sentinelPolicy',
|
|
114
117
|
'emailBlocklistPolicy',
|
|
118
|
+
'forgotPasswordMethods',
|
|
115
119
|
],
|
|
116
120
|
createGuard,
|
|
117
121
|
guard,
|
|
@@ -12,25 +12,25 @@ export declare enum CustomProfileFieldType {
|
|
|
12
12
|
}
|
|
13
13
|
export declare const customProfileFieldTypeGuard: z.ZodNativeEnum<typeof CustomProfileFieldType>;
|
|
14
14
|
export declare const fieldOptionGuard: z.ZodObject<{
|
|
15
|
-
label: z.ZodString
|
|
15
|
+
label: z.ZodOptional<z.ZodString>;
|
|
16
16
|
value: z.ZodString;
|
|
17
17
|
}, "strip", z.ZodTypeAny, {
|
|
18
18
|
value: string;
|
|
19
|
-
label
|
|
19
|
+
label?: string | undefined;
|
|
20
20
|
}, {
|
|
21
21
|
value: string;
|
|
22
|
-
label
|
|
22
|
+
label?: string | undefined;
|
|
23
23
|
}>;
|
|
24
24
|
export type FieldOption = z.infer<typeof fieldOptionGuard>;
|
|
25
25
|
export declare const fieldOptionsGuard: z.ZodArray<z.ZodObject<{
|
|
26
|
-
label: z.ZodString
|
|
26
|
+
label: z.ZodOptional<z.ZodString>;
|
|
27
27
|
value: z.ZodString;
|
|
28
28
|
}, "strip", z.ZodTypeAny, {
|
|
29
29
|
value: string;
|
|
30
|
-
label
|
|
30
|
+
label?: string | undefined;
|
|
31
31
|
}, {
|
|
32
32
|
value: string;
|
|
33
|
-
label
|
|
33
|
+
label?: string | undefined;
|
|
34
34
|
}>, "many">;
|
|
35
35
|
export type FieldOptions = z.infer<typeof fieldOptionsGuard>;
|
|
36
36
|
export declare const baseConfigGuard: z.ZodObject<{
|
|
@@ -42,19 +42,20 @@ export declare const baseConfigGuard: z.ZodObject<{
|
|
|
42
42
|
format: z.ZodOptional<z.ZodString>;
|
|
43
43
|
customFormat: z.ZodOptional<z.ZodString>;
|
|
44
44
|
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
45
|
-
label: z.ZodString
|
|
45
|
+
label: z.ZodOptional<z.ZodString>;
|
|
46
46
|
value: z.ZodString;
|
|
47
47
|
}, "strip", z.ZodTypeAny, {
|
|
48
48
|
value: string;
|
|
49
|
-
label
|
|
49
|
+
label?: string | undefined;
|
|
50
50
|
}, {
|
|
51
51
|
value: string;
|
|
52
|
-
label
|
|
52
|
+
label?: string | undefined;
|
|
53
53
|
}>, "many">>;
|
|
54
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
54
55
|
}, "strip", z.ZodTypeAny, {
|
|
55
56
|
options?: {
|
|
56
57
|
value: string;
|
|
57
|
-
label
|
|
58
|
+
label?: string | undefined;
|
|
58
59
|
}[] | undefined;
|
|
59
60
|
minLength?: number | undefined;
|
|
60
61
|
maxLength?: number | undefined;
|
|
@@ -63,10 +64,11 @@ export declare const baseConfigGuard: z.ZodObject<{
|
|
|
63
64
|
maxValue?: number | undefined;
|
|
64
65
|
format?: string | undefined;
|
|
65
66
|
customFormat?: string | undefined;
|
|
67
|
+
defaultValue?: string | undefined;
|
|
66
68
|
}, {
|
|
67
69
|
options?: {
|
|
68
70
|
value: string;
|
|
69
|
-
label
|
|
71
|
+
label?: string | undefined;
|
|
70
72
|
}[] | undefined;
|
|
71
73
|
minLength?: number | undefined;
|
|
72
74
|
maxLength?: number | undefined;
|
|
@@ -75,12 +77,13 @@ export declare const baseConfigGuard: z.ZodObject<{
|
|
|
75
77
|
maxValue?: number | undefined;
|
|
76
78
|
format?: string | undefined;
|
|
77
79
|
customFormat?: string | undefined;
|
|
80
|
+
defaultValue?: string | undefined;
|
|
78
81
|
}>;
|
|
79
82
|
export declare const fieldPartGuard: z.ZodObject<{
|
|
80
83
|
enabled: z.ZodBoolean;
|
|
81
84
|
name: z.ZodString;
|
|
82
85
|
type: z.ZodNativeEnum<typeof CustomProfileFieldType>;
|
|
83
|
-
label: z.ZodString
|
|
86
|
+
label: z.ZodOptional<z.ZodString>;
|
|
84
87
|
description: z.ZodOptional<z.ZodString>;
|
|
85
88
|
required: z.ZodBoolean;
|
|
86
89
|
config: z.ZodOptional<z.ZodObject<{
|
|
@@ -92,19 +95,20 @@ export declare const fieldPartGuard: z.ZodObject<{
|
|
|
92
95
|
format: z.ZodOptional<z.ZodString>;
|
|
93
96
|
customFormat: z.ZodOptional<z.ZodString>;
|
|
94
97
|
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
95
|
-
label: z.ZodString
|
|
98
|
+
label: z.ZodOptional<z.ZodString>;
|
|
96
99
|
value: z.ZodString;
|
|
97
100
|
}, "strip", z.ZodTypeAny, {
|
|
98
101
|
value: string;
|
|
99
|
-
label
|
|
102
|
+
label?: string | undefined;
|
|
100
103
|
}, {
|
|
101
104
|
value: string;
|
|
102
|
-
label
|
|
105
|
+
label?: string | undefined;
|
|
103
106
|
}>, "many">>;
|
|
107
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
104
108
|
}, "strip", z.ZodTypeAny, {
|
|
105
109
|
options?: {
|
|
106
110
|
value: string;
|
|
107
|
-
label
|
|
111
|
+
label?: string | undefined;
|
|
108
112
|
}[] | undefined;
|
|
109
113
|
minLength?: number | undefined;
|
|
110
114
|
maxLength?: number | undefined;
|
|
@@ -113,10 +117,11 @@ export declare const fieldPartGuard: z.ZodObject<{
|
|
|
113
117
|
maxValue?: number | undefined;
|
|
114
118
|
format?: string | undefined;
|
|
115
119
|
customFormat?: string | undefined;
|
|
120
|
+
defaultValue?: string | undefined;
|
|
116
121
|
}, {
|
|
117
122
|
options?: {
|
|
118
123
|
value: string;
|
|
119
|
-
label
|
|
124
|
+
label?: string | undefined;
|
|
120
125
|
}[] | undefined;
|
|
121
126
|
minLength?: number | undefined;
|
|
122
127
|
maxLength?: number | undefined;
|
|
@@ -125,18 +130,19 @@ export declare const fieldPartGuard: z.ZodObject<{
|
|
|
125
130
|
maxValue?: number | undefined;
|
|
126
131
|
format?: string | undefined;
|
|
127
132
|
customFormat?: string | undefined;
|
|
133
|
+
defaultValue?: string | undefined;
|
|
128
134
|
}>>;
|
|
129
135
|
}, "strip", z.ZodTypeAny, {
|
|
130
136
|
type: CustomProfileFieldType;
|
|
131
137
|
name: string;
|
|
132
138
|
enabled: boolean;
|
|
133
|
-
label: string;
|
|
134
139
|
required: boolean;
|
|
140
|
+
label?: string | undefined;
|
|
135
141
|
description?: string | undefined;
|
|
136
142
|
config?: {
|
|
137
143
|
options?: {
|
|
138
144
|
value: string;
|
|
139
|
-
label
|
|
145
|
+
label?: string | undefined;
|
|
140
146
|
}[] | undefined;
|
|
141
147
|
minLength?: number | undefined;
|
|
142
148
|
maxLength?: number | undefined;
|
|
@@ -145,18 +151,19 @@ export declare const fieldPartGuard: z.ZodObject<{
|
|
|
145
151
|
maxValue?: number | undefined;
|
|
146
152
|
format?: string | undefined;
|
|
147
153
|
customFormat?: string | undefined;
|
|
154
|
+
defaultValue?: string | undefined;
|
|
148
155
|
} | undefined;
|
|
149
156
|
}, {
|
|
150
157
|
type: CustomProfileFieldType;
|
|
151
158
|
name: string;
|
|
152
159
|
enabled: boolean;
|
|
153
|
-
label: string;
|
|
154
160
|
required: boolean;
|
|
161
|
+
label?: string | undefined;
|
|
155
162
|
description?: string | undefined;
|
|
156
163
|
config?: {
|
|
157
164
|
options?: {
|
|
158
165
|
value: string;
|
|
159
|
-
label
|
|
166
|
+
label?: string | undefined;
|
|
160
167
|
}[] | undefined;
|
|
161
168
|
minLength?: number | undefined;
|
|
162
169
|
maxLength?: number | undefined;
|
|
@@ -165,6 +172,7 @@ export declare const fieldPartGuard: z.ZodObject<{
|
|
|
165
172
|
maxValue?: number | undefined;
|
|
166
173
|
format?: string | undefined;
|
|
167
174
|
customFormat?: string | undefined;
|
|
175
|
+
defaultValue?: string | undefined;
|
|
168
176
|
} | undefined;
|
|
169
177
|
}>;
|
|
170
178
|
export type FieldPart = z.infer<typeof fieldPartGuard>;
|
|
@@ -172,7 +180,7 @@ export declare const fieldPartsGuard: z.ZodArray<z.ZodObject<{
|
|
|
172
180
|
enabled: z.ZodBoolean;
|
|
173
181
|
name: z.ZodString;
|
|
174
182
|
type: z.ZodNativeEnum<typeof CustomProfileFieldType>;
|
|
175
|
-
label: z.ZodString
|
|
183
|
+
label: z.ZodOptional<z.ZodString>;
|
|
176
184
|
description: z.ZodOptional<z.ZodString>;
|
|
177
185
|
required: z.ZodBoolean;
|
|
178
186
|
config: z.ZodOptional<z.ZodObject<{
|
|
@@ -184,19 +192,20 @@ export declare const fieldPartsGuard: z.ZodArray<z.ZodObject<{
|
|
|
184
192
|
format: z.ZodOptional<z.ZodString>;
|
|
185
193
|
customFormat: z.ZodOptional<z.ZodString>;
|
|
186
194
|
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
187
|
-
label: z.ZodString
|
|
195
|
+
label: z.ZodOptional<z.ZodString>;
|
|
188
196
|
value: z.ZodString;
|
|
189
197
|
}, "strip", z.ZodTypeAny, {
|
|
190
198
|
value: string;
|
|
191
|
-
label
|
|
199
|
+
label?: string | undefined;
|
|
192
200
|
}, {
|
|
193
201
|
value: string;
|
|
194
|
-
label
|
|
202
|
+
label?: string | undefined;
|
|
195
203
|
}>, "many">>;
|
|
204
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
196
205
|
}, "strip", z.ZodTypeAny, {
|
|
197
206
|
options?: {
|
|
198
207
|
value: string;
|
|
199
|
-
label
|
|
208
|
+
label?: string | undefined;
|
|
200
209
|
}[] | undefined;
|
|
201
210
|
minLength?: number | undefined;
|
|
202
211
|
maxLength?: number | undefined;
|
|
@@ -205,10 +214,11 @@ export declare const fieldPartsGuard: z.ZodArray<z.ZodObject<{
|
|
|
205
214
|
maxValue?: number | undefined;
|
|
206
215
|
format?: string | undefined;
|
|
207
216
|
customFormat?: string | undefined;
|
|
217
|
+
defaultValue?: string | undefined;
|
|
208
218
|
}, {
|
|
209
219
|
options?: {
|
|
210
220
|
value: string;
|
|
211
|
-
label
|
|
221
|
+
label?: string | undefined;
|
|
212
222
|
}[] | undefined;
|
|
213
223
|
minLength?: number | undefined;
|
|
214
224
|
maxLength?: number | undefined;
|
|
@@ -217,18 +227,19 @@ export declare const fieldPartsGuard: z.ZodArray<z.ZodObject<{
|
|
|
217
227
|
maxValue?: number | undefined;
|
|
218
228
|
format?: string | undefined;
|
|
219
229
|
customFormat?: string | undefined;
|
|
230
|
+
defaultValue?: string | undefined;
|
|
220
231
|
}>>;
|
|
221
232
|
}, "strip", z.ZodTypeAny, {
|
|
222
233
|
type: CustomProfileFieldType;
|
|
223
234
|
name: string;
|
|
224
235
|
enabled: boolean;
|
|
225
|
-
label: string;
|
|
226
236
|
required: boolean;
|
|
237
|
+
label?: string | undefined;
|
|
227
238
|
description?: string | undefined;
|
|
228
239
|
config?: {
|
|
229
240
|
options?: {
|
|
230
241
|
value: string;
|
|
231
|
-
label
|
|
242
|
+
label?: string | undefined;
|
|
232
243
|
}[] | undefined;
|
|
233
244
|
minLength?: number | undefined;
|
|
234
245
|
maxLength?: number | undefined;
|
|
@@ -237,18 +248,19 @@ export declare const fieldPartsGuard: z.ZodArray<z.ZodObject<{
|
|
|
237
248
|
maxValue?: number | undefined;
|
|
238
249
|
format?: string | undefined;
|
|
239
250
|
customFormat?: string | undefined;
|
|
251
|
+
defaultValue?: string | undefined;
|
|
240
252
|
} | undefined;
|
|
241
253
|
}, {
|
|
242
254
|
type: CustomProfileFieldType;
|
|
243
255
|
name: string;
|
|
244
256
|
enabled: boolean;
|
|
245
|
-
label: string;
|
|
246
257
|
required: boolean;
|
|
258
|
+
label?: string | undefined;
|
|
247
259
|
description?: string | undefined;
|
|
248
260
|
config?: {
|
|
249
261
|
options?: {
|
|
250
262
|
value: string;
|
|
251
|
-
label
|
|
263
|
+
label?: string | undefined;
|
|
252
264
|
}[] | undefined;
|
|
253
265
|
minLength?: number | undefined;
|
|
254
266
|
maxLength?: number | undefined;
|
|
@@ -257,6 +269,7 @@ export declare const fieldPartsGuard: z.ZodArray<z.ZodObject<{
|
|
|
257
269
|
maxValue?: number | undefined;
|
|
258
270
|
format?: string | undefined;
|
|
259
271
|
customFormat?: string | undefined;
|
|
272
|
+
defaultValue?: string | undefined;
|
|
260
273
|
} | undefined;
|
|
261
274
|
}>, "many">;
|
|
262
275
|
export type FieldParts = z.infer<typeof fieldPartsGuard>;
|
|
@@ -269,21 +282,22 @@ export declare const customProfileFieldConfigGuard: z.ZodObject<{
|
|
|
269
282
|
format: z.ZodOptional<z.ZodString>;
|
|
270
283
|
customFormat: z.ZodOptional<z.ZodString>;
|
|
271
284
|
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
272
|
-
label: z.ZodString
|
|
285
|
+
label: z.ZodOptional<z.ZodString>;
|
|
273
286
|
value: z.ZodString;
|
|
274
287
|
}, "strip", z.ZodTypeAny, {
|
|
275
288
|
value: string;
|
|
276
|
-
label
|
|
289
|
+
label?: string | undefined;
|
|
277
290
|
}, {
|
|
278
291
|
value: string;
|
|
279
|
-
label
|
|
292
|
+
label?: string | undefined;
|
|
280
293
|
}>, "many">>;
|
|
294
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
281
295
|
} & {
|
|
282
296
|
parts: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
283
297
|
enabled: z.ZodBoolean;
|
|
284
298
|
name: z.ZodString;
|
|
285
299
|
type: z.ZodNativeEnum<typeof CustomProfileFieldType>;
|
|
286
|
-
label: z.ZodString
|
|
300
|
+
label: z.ZodOptional<z.ZodString>;
|
|
287
301
|
description: z.ZodOptional<z.ZodString>;
|
|
288
302
|
required: z.ZodBoolean;
|
|
289
303
|
config: z.ZodOptional<z.ZodObject<{
|
|
@@ -295,19 +309,20 @@ export declare const customProfileFieldConfigGuard: z.ZodObject<{
|
|
|
295
309
|
format: z.ZodOptional<z.ZodString>;
|
|
296
310
|
customFormat: z.ZodOptional<z.ZodString>;
|
|
297
311
|
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
298
|
-
label: z.ZodString
|
|
312
|
+
label: z.ZodOptional<z.ZodString>;
|
|
299
313
|
value: z.ZodString;
|
|
300
314
|
}, "strip", z.ZodTypeAny, {
|
|
301
315
|
value: string;
|
|
302
|
-
label
|
|
316
|
+
label?: string | undefined;
|
|
303
317
|
}, {
|
|
304
318
|
value: string;
|
|
305
|
-
label
|
|
319
|
+
label?: string | undefined;
|
|
306
320
|
}>, "many">>;
|
|
321
|
+
defaultValue: z.ZodOptional<z.ZodString>;
|
|
307
322
|
}, "strip", z.ZodTypeAny, {
|
|
308
323
|
options?: {
|
|
309
324
|
value: string;
|
|
310
|
-
label
|
|
325
|
+
label?: string | undefined;
|
|
311
326
|
}[] | undefined;
|
|
312
327
|
minLength?: number | undefined;
|
|
313
328
|
maxLength?: number | undefined;
|
|
@@ -316,10 +331,11 @@ export declare const customProfileFieldConfigGuard: z.ZodObject<{
|
|
|
316
331
|
maxValue?: number | undefined;
|
|
317
332
|
format?: string | undefined;
|
|
318
333
|
customFormat?: string | undefined;
|
|
334
|
+
defaultValue?: string | undefined;
|
|
319
335
|
}, {
|
|
320
336
|
options?: {
|
|
321
337
|
value: string;
|
|
322
|
-
label
|
|
338
|
+
label?: string | undefined;
|
|
323
339
|
}[] | undefined;
|
|
324
340
|
minLength?: number | undefined;
|
|
325
341
|
maxLength?: number | undefined;
|
|
@@ -328,18 +344,19 @@ export declare const customProfileFieldConfigGuard: z.ZodObject<{
|
|
|
328
344
|
maxValue?: number | undefined;
|
|
329
345
|
format?: string | undefined;
|
|
330
346
|
customFormat?: string | undefined;
|
|
347
|
+
defaultValue?: string | undefined;
|
|
331
348
|
}>>;
|
|
332
349
|
}, "strip", z.ZodTypeAny, {
|
|
333
350
|
type: CustomProfileFieldType;
|
|
334
351
|
name: string;
|
|
335
352
|
enabled: boolean;
|
|
336
|
-
label: string;
|
|
337
353
|
required: boolean;
|
|
354
|
+
label?: string | undefined;
|
|
338
355
|
description?: string | undefined;
|
|
339
356
|
config?: {
|
|
340
357
|
options?: {
|
|
341
358
|
value: string;
|
|
342
|
-
label
|
|
359
|
+
label?: string | undefined;
|
|
343
360
|
}[] | undefined;
|
|
344
361
|
minLength?: number | undefined;
|
|
345
362
|
maxLength?: number | undefined;
|
|
@@ -348,18 +365,19 @@ export declare const customProfileFieldConfigGuard: z.ZodObject<{
|
|
|
348
365
|
maxValue?: number | undefined;
|
|
349
366
|
format?: string | undefined;
|
|
350
367
|
customFormat?: string | undefined;
|
|
368
|
+
defaultValue?: string | undefined;
|
|
351
369
|
} | undefined;
|
|
352
370
|
}, {
|
|
353
371
|
type: CustomProfileFieldType;
|
|
354
372
|
name: string;
|
|
355
373
|
enabled: boolean;
|
|
356
|
-
label: string;
|
|
357
374
|
required: boolean;
|
|
375
|
+
label?: string | undefined;
|
|
358
376
|
description?: string | undefined;
|
|
359
377
|
config?: {
|
|
360
378
|
options?: {
|
|
361
379
|
value: string;
|
|
362
|
-
label
|
|
380
|
+
label?: string | undefined;
|
|
363
381
|
}[] | undefined;
|
|
364
382
|
minLength?: number | undefined;
|
|
365
383
|
maxLength?: number | undefined;
|
|
@@ -368,12 +386,13 @@ export declare const customProfileFieldConfigGuard: z.ZodObject<{
|
|
|
368
386
|
maxValue?: number | undefined;
|
|
369
387
|
format?: string | undefined;
|
|
370
388
|
customFormat?: string | undefined;
|
|
389
|
+
defaultValue?: string | undefined;
|
|
371
390
|
} | undefined;
|
|
372
391
|
}>, "many">>;
|
|
373
392
|
}, "strip", z.ZodTypeAny, {
|
|
374
393
|
options?: {
|
|
375
394
|
value: string;
|
|
376
|
-
label
|
|
395
|
+
label?: string | undefined;
|
|
377
396
|
}[] | undefined;
|
|
378
397
|
minLength?: number | undefined;
|
|
379
398
|
maxLength?: number | undefined;
|
|
@@ -382,17 +401,18 @@ export declare const customProfileFieldConfigGuard: z.ZodObject<{
|
|
|
382
401
|
maxValue?: number | undefined;
|
|
383
402
|
format?: string | undefined;
|
|
384
403
|
customFormat?: string | undefined;
|
|
404
|
+
defaultValue?: string | undefined;
|
|
385
405
|
parts?: {
|
|
386
406
|
type: CustomProfileFieldType;
|
|
387
407
|
name: string;
|
|
388
408
|
enabled: boolean;
|
|
389
|
-
label: string;
|
|
390
409
|
required: boolean;
|
|
410
|
+
label?: string | undefined;
|
|
391
411
|
description?: string | undefined;
|
|
392
412
|
config?: {
|
|
393
413
|
options?: {
|
|
394
414
|
value: string;
|
|
395
|
-
label
|
|
415
|
+
label?: string | undefined;
|
|
396
416
|
}[] | undefined;
|
|
397
417
|
minLength?: number | undefined;
|
|
398
418
|
maxLength?: number | undefined;
|
|
@@ -401,12 +421,13 @@ export declare const customProfileFieldConfigGuard: z.ZodObject<{
|
|
|
401
421
|
maxValue?: number | undefined;
|
|
402
422
|
format?: string | undefined;
|
|
403
423
|
customFormat?: string | undefined;
|
|
424
|
+
defaultValue?: string | undefined;
|
|
404
425
|
} | undefined;
|
|
405
426
|
}[] | undefined;
|
|
406
427
|
}, {
|
|
407
428
|
options?: {
|
|
408
429
|
value: string;
|
|
409
|
-
label
|
|
430
|
+
label?: string | undefined;
|
|
410
431
|
}[] | undefined;
|
|
411
432
|
minLength?: number | undefined;
|
|
412
433
|
maxLength?: number | undefined;
|
|
@@ -415,17 +436,18 @@ export declare const customProfileFieldConfigGuard: z.ZodObject<{
|
|
|
415
436
|
maxValue?: number | undefined;
|
|
416
437
|
format?: string | undefined;
|
|
417
438
|
customFormat?: string | undefined;
|
|
439
|
+
defaultValue?: string | undefined;
|
|
418
440
|
parts?: {
|
|
419
441
|
type: CustomProfileFieldType;
|
|
420
442
|
name: string;
|
|
421
443
|
enabled: boolean;
|
|
422
|
-
label: string;
|
|
423
444
|
required: boolean;
|
|
445
|
+
label?: string | undefined;
|
|
424
446
|
description?: string | undefined;
|
|
425
447
|
config?: {
|
|
426
448
|
options?: {
|
|
427
449
|
value: string;
|
|
428
|
-
label
|
|
450
|
+
label?: string | undefined;
|
|
429
451
|
}[] | undefined;
|
|
430
452
|
minLength?: number | undefined;
|
|
431
453
|
maxLength?: number | undefined;
|
|
@@ -434,6 +456,7 @@ export declare const customProfileFieldConfigGuard: z.ZodObject<{
|
|
|
434
456
|
maxValue?: number | undefined;
|
|
435
457
|
format?: string | undefined;
|
|
436
458
|
customFormat?: string | undefined;
|
|
459
|
+
defaultValue?: string | undefined;
|
|
437
460
|
} | undefined;
|
|
438
461
|
}[] | undefined;
|
|
439
462
|
}>;
|
|
@@ -15,7 +15,7 @@ export var CustomProfileFieldType;
|
|
|
15
15
|
})(CustomProfileFieldType || (CustomProfileFieldType = {}));
|
|
16
16
|
export const customProfileFieldTypeGuard = z.nativeEnum(CustomProfileFieldType);
|
|
17
17
|
export const fieldOptionGuard = z.object({
|
|
18
|
-
label: z.string(),
|
|
18
|
+
label: z.string().optional(),
|
|
19
19
|
value: z.string(),
|
|
20
20
|
});
|
|
21
21
|
export const fieldOptionsGuard = fieldOptionGuard.array();
|
|
@@ -28,12 +28,13 @@ export const baseConfigGuard = z.object({
|
|
|
28
28
|
format: z.string().max(128).optional(),
|
|
29
29
|
customFormat: z.string().max(128).optional(),
|
|
30
30
|
options: fieldOptionsGuard.optional(),
|
|
31
|
+
defaultValue: z.string().optional(),
|
|
31
32
|
});
|
|
32
33
|
export const fieldPartGuard = z.object({
|
|
33
34
|
enabled: z.boolean(),
|
|
34
35
|
name: z.string(),
|
|
35
36
|
type: customProfileFieldTypeGuard,
|
|
36
|
-
label: z.string(),
|
|
37
|
+
label: z.string().min(1).optional(),
|
|
37
38
|
description: z.string().optional(),
|
|
38
39
|
required: z.boolean(),
|
|
39
40
|
config: baseConfigGuard.optional(),
|
|
@@ -346,4 +346,10 @@ export declare const emailBlocklistPolicyGuard: z.ZodObject<{
|
|
|
346
346
|
blockSubaddressing?: boolean | undefined;
|
|
347
347
|
customBlocklist?: string[] | undefined;
|
|
348
348
|
}>;
|
|
349
|
+
export declare enum ForgotPasswordMethod {
|
|
350
|
+
EmailVerificationCode = "EmailVerificationCode",
|
|
351
|
+
PhoneVerificationCode = "PhoneVerificationCode"
|
|
352
|
+
}
|
|
353
|
+
export declare const forgotPasswordMethodsGuard: z.ZodArray<z.ZodNativeEnum<typeof ForgotPasswordMethod>, "many">;
|
|
354
|
+
export type ForgotPasswordMethods = z.infer<typeof forgotPasswordMethodsGuard>;
|
|
349
355
|
export {};
|
|
@@ -117,3 +117,9 @@ export const emailBlocklistPolicyGuard = z.object({
|
|
|
117
117
|
blockSubaddressing: z.boolean().optional(),
|
|
118
118
|
customBlocklist: z.string().array().optional(),
|
|
119
119
|
});
|
|
120
|
+
export var ForgotPasswordMethod;
|
|
121
|
+
(function (ForgotPasswordMethod) {
|
|
122
|
+
ForgotPasswordMethod["EmailVerificationCode"] = "EmailVerificationCode";
|
|
123
|
+
ForgotPasswordMethod["PhoneVerificationCode"] = "PhoneVerificationCode";
|
|
124
|
+
})(ForgotPasswordMethod || (ForgotPasswordMethod = {}));
|
|
125
|
+
export const forgotPasswordMethodsGuard = z.nativeEnum(ForgotPasswordMethod).array();
|