@doist/todoist-sdk 9.5.0 → 9.6.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/cjs/types/sections/types.js +8 -6
- package/dist/cjs/types/webhooks/index.js +2 -0
- package/dist/cjs/types/webhooks/projects.js +36 -0
- package/dist/cjs/types/webhooks/sections.js +48 -0
- package/dist/cjs/types/webhooks/types.js +19 -4
- package/dist/esm/types/sections/types.js +7 -5
- package/dist/esm/types/webhooks/index.js +2 -0
- package/dist/esm/types/webhooks/projects.js +33 -0
- package/dist/esm/types/webhooks/sections.js +45 -0
- package/dist/esm/types/webhooks/types.js +19 -4
- package/dist/types/types/sections/types.d.ts +18 -0
- package/dist/types/types/webhooks/index.d.ts +2 -0
- package/dist/types/types/webhooks/projects.d.ts +345 -0
- package/dist/types/types/webhooks/sections.d.ts +335 -0
- package/dist/types/types/webhooks/types.d.ts +580 -24
- package/package.json +1 -1
|
@@ -0,0 +1,345 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/**
|
|
3
|
+
* Enum-like object of project (`project:*`) webhook event names. Single
|
|
4
|
+
* source of truth for the discriminator values — `PROJECT_WEBHOOK_EVENTS`
|
|
5
|
+
* and every `z.literal()` below derive from it.
|
|
6
|
+
*/
|
|
7
|
+
export declare const ProjectWebhookEventEnum: {
|
|
8
|
+
readonly Added: "project:added";
|
|
9
|
+
readonly Updated: "project:updated";
|
|
10
|
+
readonly Deleted: "project:deleted";
|
|
11
|
+
readonly Archived: "project:archived";
|
|
12
|
+
readonly Unarchived: "project:unarchived";
|
|
13
|
+
};
|
|
14
|
+
/** Webhook events that carry a project as their `eventData`. */
|
|
15
|
+
export declare const PROJECT_WEBHOOK_EVENTS: readonly ["project:added", "project:updated", "project:deleted", "project:archived", "project:unarchived"];
|
|
16
|
+
/**
|
|
17
|
+
* Webhook project payloads match the shape of the shared {@link Project}
|
|
18
|
+
* resource — either a personal or a workspace project. No webhook-specific
|
|
19
|
+
* schema is needed; `ProjectSchema` already dispatches on `workspaceId`.
|
|
20
|
+
*/
|
|
21
|
+
export declare const ProjectAddedPayloadSchema: z.ZodObject<{
|
|
22
|
+
eventName: z.ZodLiteral<"project:added">;
|
|
23
|
+
eventData: z.ZodPipe<z.ZodUnknown, z.ZodTransform<{
|
|
24
|
+
url: string;
|
|
25
|
+
id: string;
|
|
26
|
+
canAssignTasks: boolean;
|
|
27
|
+
childOrder: number;
|
|
28
|
+
color: string;
|
|
29
|
+
createdAt: Date | null;
|
|
30
|
+
isArchived: boolean;
|
|
31
|
+
isDeleted: boolean;
|
|
32
|
+
isFavorite: boolean;
|
|
33
|
+
isFrozen: boolean;
|
|
34
|
+
name: string;
|
|
35
|
+
updatedAt: Date | null;
|
|
36
|
+
viewStyle: string;
|
|
37
|
+
defaultOrder: number;
|
|
38
|
+
description: string;
|
|
39
|
+
isCollapsed: boolean;
|
|
40
|
+
isShared: boolean;
|
|
41
|
+
parentId: string | null;
|
|
42
|
+
inboxProject: boolean;
|
|
43
|
+
} | {
|
|
44
|
+
url: string;
|
|
45
|
+
id: string;
|
|
46
|
+
canAssignTasks: boolean;
|
|
47
|
+
childOrder: number;
|
|
48
|
+
color: string;
|
|
49
|
+
createdAt: Date | null;
|
|
50
|
+
isArchived: boolean;
|
|
51
|
+
isDeleted: boolean;
|
|
52
|
+
isFavorite: boolean;
|
|
53
|
+
isFrozen: boolean;
|
|
54
|
+
name: string;
|
|
55
|
+
updatedAt: Date | null;
|
|
56
|
+
viewStyle: string;
|
|
57
|
+
defaultOrder: number;
|
|
58
|
+
description: string;
|
|
59
|
+
isCollapsed: boolean;
|
|
60
|
+
isShared: boolean;
|
|
61
|
+
collaboratorRoleDefault: string;
|
|
62
|
+
folderId: string | null;
|
|
63
|
+
isInviteOnly: boolean | null;
|
|
64
|
+
isLinkSharingEnabled: boolean;
|
|
65
|
+
role: string | null;
|
|
66
|
+
status: string;
|
|
67
|
+
workspaceId: string;
|
|
68
|
+
access?: {
|
|
69
|
+
visibility: "restricted" | "team" | "public";
|
|
70
|
+
} | undefined;
|
|
71
|
+
}, unknown>>;
|
|
72
|
+
version: z.ZodEnum<{
|
|
73
|
+
1: "1";
|
|
74
|
+
}>;
|
|
75
|
+
userId: z.ZodString;
|
|
76
|
+
initiator: z.ZodObject<{
|
|
77
|
+
id: z.ZodString;
|
|
78
|
+
fullName: z.ZodString;
|
|
79
|
+
email: z.ZodString;
|
|
80
|
+
imageId: z.ZodNullable<z.ZodString>;
|
|
81
|
+
isPremium: z.ZodBoolean;
|
|
82
|
+
}, z.core.$strip>;
|
|
83
|
+
triggeredAt: z.ZodCoercedDate<unknown>;
|
|
84
|
+
}, z.core.$strip>;
|
|
85
|
+
export type ProjectAddedPayload = z.infer<typeof ProjectAddedPayloadSchema>;
|
|
86
|
+
export declare const ProjectUpdatedPayloadSchema: z.ZodObject<{
|
|
87
|
+
eventName: z.ZodLiteral<"project:updated">;
|
|
88
|
+
eventData: z.ZodPipe<z.ZodUnknown, z.ZodTransform<{
|
|
89
|
+
url: string;
|
|
90
|
+
id: string;
|
|
91
|
+
canAssignTasks: boolean;
|
|
92
|
+
childOrder: number;
|
|
93
|
+
color: string;
|
|
94
|
+
createdAt: Date | null;
|
|
95
|
+
isArchived: boolean;
|
|
96
|
+
isDeleted: boolean;
|
|
97
|
+
isFavorite: boolean;
|
|
98
|
+
isFrozen: boolean;
|
|
99
|
+
name: string;
|
|
100
|
+
updatedAt: Date | null;
|
|
101
|
+
viewStyle: string;
|
|
102
|
+
defaultOrder: number;
|
|
103
|
+
description: string;
|
|
104
|
+
isCollapsed: boolean;
|
|
105
|
+
isShared: boolean;
|
|
106
|
+
parentId: string | null;
|
|
107
|
+
inboxProject: boolean;
|
|
108
|
+
} | {
|
|
109
|
+
url: string;
|
|
110
|
+
id: string;
|
|
111
|
+
canAssignTasks: boolean;
|
|
112
|
+
childOrder: number;
|
|
113
|
+
color: string;
|
|
114
|
+
createdAt: Date | null;
|
|
115
|
+
isArchived: boolean;
|
|
116
|
+
isDeleted: boolean;
|
|
117
|
+
isFavorite: boolean;
|
|
118
|
+
isFrozen: boolean;
|
|
119
|
+
name: string;
|
|
120
|
+
updatedAt: Date | null;
|
|
121
|
+
viewStyle: string;
|
|
122
|
+
defaultOrder: number;
|
|
123
|
+
description: string;
|
|
124
|
+
isCollapsed: boolean;
|
|
125
|
+
isShared: boolean;
|
|
126
|
+
collaboratorRoleDefault: string;
|
|
127
|
+
folderId: string | null;
|
|
128
|
+
isInviteOnly: boolean | null;
|
|
129
|
+
isLinkSharingEnabled: boolean;
|
|
130
|
+
role: string | null;
|
|
131
|
+
status: string;
|
|
132
|
+
workspaceId: string;
|
|
133
|
+
access?: {
|
|
134
|
+
visibility: "restricted" | "team" | "public";
|
|
135
|
+
} | undefined;
|
|
136
|
+
}, unknown>>;
|
|
137
|
+
version: z.ZodEnum<{
|
|
138
|
+
1: "1";
|
|
139
|
+
}>;
|
|
140
|
+
userId: z.ZodString;
|
|
141
|
+
initiator: z.ZodObject<{
|
|
142
|
+
id: z.ZodString;
|
|
143
|
+
fullName: z.ZodString;
|
|
144
|
+
email: z.ZodString;
|
|
145
|
+
imageId: z.ZodNullable<z.ZodString>;
|
|
146
|
+
isPremium: z.ZodBoolean;
|
|
147
|
+
}, z.core.$strip>;
|
|
148
|
+
triggeredAt: z.ZodCoercedDate<unknown>;
|
|
149
|
+
}, z.core.$strip>;
|
|
150
|
+
export type ProjectUpdatedPayload = z.infer<typeof ProjectUpdatedPayloadSchema>;
|
|
151
|
+
export declare const ProjectDeletedPayloadSchema: z.ZodObject<{
|
|
152
|
+
eventName: z.ZodLiteral<"project:deleted">;
|
|
153
|
+
eventData: z.ZodPipe<z.ZodUnknown, z.ZodTransform<{
|
|
154
|
+
url: string;
|
|
155
|
+
id: string;
|
|
156
|
+
canAssignTasks: boolean;
|
|
157
|
+
childOrder: number;
|
|
158
|
+
color: string;
|
|
159
|
+
createdAt: Date | null;
|
|
160
|
+
isArchived: boolean;
|
|
161
|
+
isDeleted: boolean;
|
|
162
|
+
isFavorite: boolean;
|
|
163
|
+
isFrozen: boolean;
|
|
164
|
+
name: string;
|
|
165
|
+
updatedAt: Date | null;
|
|
166
|
+
viewStyle: string;
|
|
167
|
+
defaultOrder: number;
|
|
168
|
+
description: string;
|
|
169
|
+
isCollapsed: boolean;
|
|
170
|
+
isShared: boolean;
|
|
171
|
+
parentId: string | null;
|
|
172
|
+
inboxProject: boolean;
|
|
173
|
+
} | {
|
|
174
|
+
url: string;
|
|
175
|
+
id: string;
|
|
176
|
+
canAssignTasks: boolean;
|
|
177
|
+
childOrder: number;
|
|
178
|
+
color: string;
|
|
179
|
+
createdAt: Date | null;
|
|
180
|
+
isArchived: boolean;
|
|
181
|
+
isDeleted: boolean;
|
|
182
|
+
isFavorite: boolean;
|
|
183
|
+
isFrozen: boolean;
|
|
184
|
+
name: string;
|
|
185
|
+
updatedAt: Date | null;
|
|
186
|
+
viewStyle: string;
|
|
187
|
+
defaultOrder: number;
|
|
188
|
+
description: string;
|
|
189
|
+
isCollapsed: boolean;
|
|
190
|
+
isShared: boolean;
|
|
191
|
+
collaboratorRoleDefault: string;
|
|
192
|
+
folderId: string | null;
|
|
193
|
+
isInviteOnly: boolean | null;
|
|
194
|
+
isLinkSharingEnabled: boolean;
|
|
195
|
+
role: string | null;
|
|
196
|
+
status: string;
|
|
197
|
+
workspaceId: string;
|
|
198
|
+
access?: {
|
|
199
|
+
visibility: "restricted" | "team" | "public";
|
|
200
|
+
} | undefined;
|
|
201
|
+
}, unknown>>;
|
|
202
|
+
version: z.ZodEnum<{
|
|
203
|
+
1: "1";
|
|
204
|
+
}>;
|
|
205
|
+
userId: z.ZodString;
|
|
206
|
+
initiator: z.ZodObject<{
|
|
207
|
+
id: z.ZodString;
|
|
208
|
+
fullName: z.ZodString;
|
|
209
|
+
email: z.ZodString;
|
|
210
|
+
imageId: z.ZodNullable<z.ZodString>;
|
|
211
|
+
isPremium: z.ZodBoolean;
|
|
212
|
+
}, z.core.$strip>;
|
|
213
|
+
triggeredAt: z.ZodCoercedDate<unknown>;
|
|
214
|
+
}, z.core.$strip>;
|
|
215
|
+
export type ProjectDeletedPayload = z.infer<typeof ProjectDeletedPayloadSchema>;
|
|
216
|
+
export declare const ProjectArchivedPayloadSchema: z.ZodObject<{
|
|
217
|
+
eventName: z.ZodLiteral<"project:archived">;
|
|
218
|
+
eventData: z.ZodPipe<z.ZodUnknown, z.ZodTransform<{
|
|
219
|
+
url: string;
|
|
220
|
+
id: string;
|
|
221
|
+
canAssignTasks: boolean;
|
|
222
|
+
childOrder: number;
|
|
223
|
+
color: string;
|
|
224
|
+
createdAt: Date | null;
|
|
225
|
+
isArchived: boolean;
|
|
226
|
+
isDeleted: boolean;
|
|
227
|
+
isFavorite: boolean;
|
|
228
|
+
isFrozen: boolean;
|
|
229
|
+
name: string;
|
|
230
|
+
updatedAt: Date | null;
|
|
231
|
+
viewStyle: string;
|
|
232
|
+
defaultOrder: number;
|
|
233
|
+
description: string;
|
|
234
|
+
isCollapsed: boolean;
|
|
235
|
+
isShared: boolean;
|
|
236
|
+
parentId: string | null;
|
|
237
|
+
inboxProject: boolean;
|
|
238
|
+
} | {
|
|
239
|
+
url: string;
|
|
240
|
+
id: string;
|
|
241
|
+
canAssignTasks: boolean;
|
|
242
|
+
childOrder: number;
|
|
243
|
+
color: string;
|
|
244
|
+
createdAt: Date | null;
|
|
245
|
+
isArchived: boolean;
|
|
246
|
+
isDeleted: boolean;
|
|
247
|
+
isFavorite: boolean;
|
|
248
|
+
isFrozen: boolean;
|
|
249
|
+
name: string;
|
|
250
|
+
updatedAt: Date | null;
|
|
251
|
+
viewStyle: string;
|
|
252
|
+
defaultOrder: number;
|
|
253
|
+
description: string;
|
|
254
|
+
isCollapsed: boolean;
|
|
255
|
+
isShared: boolean;
|
|
256
|
+
collaboratorRoleDefault: string;
|
|
257
|
+
folderId: string | null;
|
|
258
|
+
isInviteOnly: boolean | null;
|
|
259
|
+
isLinkSharingEnabled: boolean;
|
|
260
|
+
role: string | null;
|
|
261
|
+
status: string;
|
|
262
|
+
workspaceId: string;
|
|
263
|
+
access?: {
|
|
264
|
+
visibility: "restricted" | "team" | "public";
|
|
265
|
+
} | undefined;
|
|
266
|
+
}, unknown>>;
|
|
267
|
+
version: z.ZodEnum<{
|
|
268
|
+
1: "1";
|
|
269
|
+
}>;
|
|
270
|
+
userId: z.ZodString;
|
|
271
|
+
initiator: z.ZodObject<{
|
|
272
|
+
id: z.ZodString;
|
|
273
|
+
fullName: z.ZodString;
|
|
274
|
+
email: z.ZodString;
|
|
275
|
+
imageId: z.ZodNullable<z.ZodString>;
|
|
276
|
+
isPremium: z.ZodBoolean;
|
|
277
|
+
}, z.core.$strip>;
|
|
278
|
+
triggeredAt: z.ZodCoercedDate<unknown>;
|
|
279
|
+
}, z.core.$strip>;
|
|
280
|
+
export type ProjectArchivedPayload = z.infer<typeof ProjectArchivedPayloadSchema>;
|
|
281
|
+
export declare const ProjectUnarchivedPayloadSchema: z.ZodObject<{
|
|
282
|
+
eventName: z.ZodLiteral<"project:unarchived">;
|
|
283
|
+
eventData: z.ZodPipe<z.ZodUnknown, z.ZodTransform<{
|
|
284
|
+
url: string;
|
|
285
|
+
id: string;
|
|
286
|
+
canAssignTasks: boolean;
|
|
287
|
+
childOrder: number;
|
|
288
|
+
color: string;
|
|
289
|
+
createdAt: Date | null;
|
|
290
|
+
isArchived: boolean;
|
|
291
|
+
isDeleted: boolean;
|
|
292
|
+
isFavorite: boolean;
|
|
293
|
+
isFrozen: boolean;
|
|
294
|
+
name: string;
|
|
295
|
+
updatedAt: Date | null;
|
|
296
|
+
viewStyle: string;
|
|
297
|
+
defaultOrder: number;
|
|
298
|
+
description: string;
|
|
299
|
+
isCollapsed: boolean;
|
|
300
|
+
isShared: boolean;
|
|
301
|
+
parentId: string | null;
|
|
302
|
+
inboxProject: boolean;
|
|
303
|
+
} | {
|
|
304
|
+
url: string;
|
|
305
|
+
id: string;
|
|
306
|
+
canAssignTasks: boolean;
|
|
307
|
+
childOrder: number;
|
|
308
|
+
color: string;
|
|
309
|
+
createdAt: Date | null;
|
|
310
|
+
isArchived: boolean;
|
|
311
|
+
isDeleted: boolean;
|
|
312
|
+
isFavorite: boolean;
|
|
313
|
+
isFrozen: boolean;
|
|
314
|
+
name: string;
|
|
315
|
+
updatedAt: Date | null;
|
|
316
|
+
viewStyle: string;
|
|
317
|
+
defaultOrder: number;
|
|
318
|
+
description: string;
|
|
319
|
+
isCollapsed: boolean;
|
|
320
|
+
isShared: boolean;
|
|
321
|
+
collaboratorRoleDefault: string;
|
|
322
|
+
folderId: string | null;
|
|
323
|
+
isInviteOnly: boolean | null;
|
|
324
|
+
isLinkSharingEnabled: boolean;
|
|
325
|
+
role: string | null;
|
|
326
|
+
status: string;
|
|
327
|
+
workspaceId: string;
|
|
328
|
+
access?: {
|
|
329
|
+
visibility: "restricted" | "team" | "public";
|
|
330
|
+
} | undefined;
|
|
331
|
+
}, unknown>>;
|
|
332
|
+
version: z.ZodEnum<{
|
|
333
|
+
1: "1";
|
|
334
|
+
}>;
|
|
335
|
+
userId: z.ZodString;
|
|
336
|
+
initiator: z.ZodObject<{
|
|
337
|
+
id: z.ZodString;
|
|
338
|
+
fullName: z.ZodString;
|
|
339
|
+
email: z.ZodString;
|
|
340
|
+
imageId: z.ZodNullable<z.ZodString>;
|
|
341
|
+
isPremium: z.ZodBoolean;
|
|
342
|
+
}, z.core.$strip>;
|
|
343
|
+
triggeredAt: z.ZodCoercedDate<unknown>;
|
|
344
|
+
}, z.core.$strip>;
|
|
345
|
+
export type ProjectUnarchivedPayload = z.infer<typeof ProjectUnarchivedPayloadSchema>;
|
|
@@ -0,0 +1,335 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/**
|
|
3
|
+
* Enum-like object of section (`section:*`) webhook event names. Single
|
|
4
|
+
* source of truth for the discriminator values — `SECTION_WEBHOOK_EVENTS`
|
|
5
|
+
* and every `z.literal()` below derive from it.
|
|
6
|
+
*/
|
|
7
|
+
export declare const SectionWebhookEventEnum: {
|
|
8
|
+
readonly Added: "section:added";
|
|
9
|
+
readonly Updated: "section:updated";
|
|
10
|
+
readonly Deleted: "section:deleted";
|
|
11
|
+
readonly Archived: "section:archived";
|
|
12
|
+
readonly Unarchived: "section:unarchived";
|
|
13
|
+
};
|
|
14
|
+
/** Webhook events that carry a section as their `eventData`. */
|
|
15
|
+
export declare const SECTION_WEBHOOK_EVENTS: readonly ["section:added", "section:updated", "section:deleted", "section:archived", "section:unarchived"];
|
|
16
|
+
/**
|
|
17
|
+
* A section as delivered in a webhook payload.
|
|
18
|
+
*
|
|
19
|
+
* Reuses {@link SectionBaseSchema} and overrides `updatedAt` to tolerate
|
|
20
|
+
* payloads that deliver it as `null` or omit the key entirely — tombstones
|
|
21
|
+
* and never-updated sections come through without an `updated_at` value.
|
|
22
|
+
* The result is normalised to `Date | null` so consumers don't have to
|
|
23
|
+
* handle three shapes. Surfaces the computed `url` so the exposed shape
|
|
24
|
+
* matches {@link Section}.
|
|
25
|
+
*/
|
|
26
|
+
export declare const WebhookSectionSchema: z.ZodPipe<z.ZodObject<{
|
|
27
|
+
id: z.ZodString;
|
|
28
|
+
userId: z.ZodString;
|
|
29
|
+
projectId: z.ZodString;
|
|
30
|
+
addedAt: z.ZodCoercedDate<unknown>;
|
|
31
|
+
archivedAt: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
32
|
+
name: z.ZodString;
|
|
33
|
+
sectionOrder: z.ZodNumber;
|
|
34
|
+
isArchived: z.ZodBoolean;
|
|
35
|
+
isDeleted: z.ZodBoolean;
|
|
36
|
+
isCollapsed: z.ZodBoolean;
|
|
37
|
+
updatedAt: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodCoercedDate<unknown>>>, z.ZodTransform<Date | null, Date | null | undefined>>;
|
|
38
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
39
|
+
url: string;
|
|
40
|
+
id: string;
|
|
41
|
+
userId: string;
|
|
42
|
+
projectId: string;
|
|
43
|
+
addedAt: Date;
|
|
44
|
+
archivedAt: Date | null;
|
|
45
|
+
name: string;
|
|
46
|
+
sectionOrder: number;
|
|
47
|
+
isArchived: boolean;
|
|
48
|
+
isDeleted: boolean;
|
|
49
|
+
isCollapsed: boolean;
|
|
50
|
+
updatedAt: Date | null;
|
|
51
|
+
}, {
|
|
52
|
+
id: string;
|
|
53
|
+
userId: string;
|
|
54
|
+
projectId: string;
|
|
55
|
+
addedAt: Date;
|
|
56
|
+
archivedAt: Date | null;
|
|
57
|
+
name: string;
|
|
58
|
+
sectionOrder: number;
|
|
59
|
+
isArchived: boolean;
|
|
60
|
+
isDeleted: boolean;
|
|
61
|
+
isCollapsed: boolean;
|
|
62
|
+
updatedAt: Date | null;
|
|
63
|
+
}>>;
|
|
64
|
+
/** A section delivered in a webhook payload. */
|
|
65
|
+
export type WebhookSection = z.infer<typeof WebhookSectionSchema>;
|
|
66
|
+
export declare const SectionAddedPayloadSchema: z.ZodObject<{
|
|
67
|
+
eventName: z.ZodLiteral<"section:added">;
|
|
68
|
+
eventData: z.ZodPipe<z.ZodObject<{
|
|
69
|
+
id: z.ZodString;
|
|
70
|
+
userId: z.ZodString;
|
|
71
|
+
projectId: z.ZodString;
|
|
72
|
+
addedAt: z.ZodCoercedDate<unknown>;
|
|
73
|
+
archivedAt: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
74
|
+
name: z.ZodString;
|
|
75
|
+
sectionOrder: z.ZodNumber;
|
|
76
|
+
isArchived: z.ZodBoolean;
|
|
77
|
+
isDeleted: z.ZodBoolean;
|
|
78
|
+
isCollapsed: z.ZodBoolean;
|
|
79
|
+
updatedAt: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodCoercedDate<unknown>>>, z.ZodTransform<Date | null, Date | null | undefined>>;
|
|
80
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
81
|
+
url: string;
|
|
82
|
+
id: string;
|
|
83
|
+
userId: string;
|
|
84
|
+
projectId: string;
|
|
85
|
+
addedAt: Date;
|
|
86
|
+
archivedAt: Date | null;
|
|
87
|
+
name: string;
|
|
88
|
+
sectionOrder: number;
|
|
89
|
+
isArchived: boolean;
|
|
90
|
+
isDeleted: boolean;
|
|
91
|
+
isCollapsed: boolean;
|
|
92
|
+
updatedAt: Date | null;
|
|
93
|
+
}, {
|
|
94
|
+
id: string;
|
|
95
|
+
userId: string;
|
|
96
|
+
projectId: string;
|
|
97
|
+
addedAt: Date;
|
|
98
|
+
archivedAt: Date | null;
|
|
99
|
+
name: string;
|
|
100
|
+
sectionOrder: number;
|
|
101
|
+
isArchived: boolean;
|
|
102
|
+
isDeleted: boolean;
|
|
103
|
+
isCollapsed: boolean;
|
|
104
|
+
updatedAt: Date | null;
|
|
105
|
+
}>>;
|
|
106
|
+
version: z.ZodEnum<{
|
|
107
|
+
1: "1";
|
|
108
|
+
}>;
|
|
109
|
+
userId: z.ZodString;
|
|
110
|
+
initiator: z.ZodObject<{
|
|
111
|
+
id: z.ZodString;
|
|
112
|
+
fullName: z.ZodString;
|
|
113
|
+
email: z.ZodString;
|
|
114
|
+
imageId: z.ZodNullable<z.ZodString>;
|
|
115
|
+
isPremium: z.ZodBoolean;
|
|
116
|
+
}, z.core.$strip>;
|
|
117
|
+
triggeredAt: z.ZodCoercedDate<unknown>;
|
|
118
|
+
}, z.core.$strip>;
|
|
119
|
+
export type SectionAddedPayload = z.infer<typeof SectionAddedPayloadSchema>;
|
|
120
|
+
export declare const SectionUpdatedPayloadSchema: z.ZodObject<{
|
|
121
|
+
eventName: z.ZodLiteral<"section:updated">;
|
|
122
|
+
eventData: z.ZodPipe<z.ZodObject<{
|
|
123
|
+
id: z.ZodString;
|
|
124
|
+
userId: z.ZodString;
|
|
125
|
+
projectId: z.ZodString;
|
|
126
|
+
addedAt: z.ZodCoercedDate<unknown>;
|
|
127
|
+
archivedAt: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
128
|
+
name: z.ZodString;
|
|
129
|
+
sectionOrder: z.ZodNumber;
|
|
130
|
+
isArchived: z.ZodBoolean;
|
|
131
|
+
isDeleted: z.ZodBoolean;
|
|
132
|
+
isCollapsed: z.ZodBoolean;
|
|
133
|
+
updatedAt: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodCoercedDate<unknown>>>, z.ZodTransform<Date | null, Date | null | undefined>>;
|
|
134
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
135
|
+
url: string;
|
|
136
|
+
id: string;
|
|
137
|
+
userId: string;
|
|
138
|
+
projectId: string;
|
|
139
|
+
addedAt: Date;
|
|
140
|
+
archivedAt: Date | null;
|
|
141
|
+
name: string;
|
|
142
|
+
sectionOrder: number;
|
|
143
|
+
isArchived: boolean;
|
|
144
|
+
isDeleted: boolean;
|
|
145
|
+
isCollapsed: boolean;
|
|
146
|
+
updatedAt: Date | null;
|
|
147
|
+
}, {
|
|
148
|
+
id: string;
|
|
149
|
+
userId: string;
|
|
150
|
+
projectId: string;
|
|
151
|
+
addedAt: Date;
|
|
152
|
+
archivedAt: Date | null;
|
|
153
|
+
name: string;
|
|
154
|
+
sectionOrder: number;
|
|
155
|
+
isArchived: boolean;
|
|
156
|
+
isDeleted: boolean;
|
|
157
|
+
isCollapsed: boolean;
|
|
158
|
+
updatedAt: Date | null;
|
|
159
|
+
}>>;
|
|
160
|
+
version: z.ZodEnum<{
|
|
161
|
+
1: "1";
|
|
162
|
+
}>;
|
|
163
|
+
userId: z.ZodString;
|
|
164
|
+
initiator: z.ZodObject<{
|
|
165
|
+
id: z.ZodString;
|
|
166
|
+
fullName: z.ZodString;
|
|
167
|
+
email: z.ZodString;
|
|
168
|
+
imageId: z.ZodNullable<z.ZodString>;
|
|
169
|
+
isPremium: z.ZodBoolean;
|
|
170
|
+
}, z.core.$strip>;
|
|
171
|
+
triggeredAt: z.ZodCoercedDate<unknown>;
|
|
172
|
+
}, z.core.$strip>;
|
|
173
|
+
export type SectionUpdatedPayload = z.infer<typeof SectionUpdatedPayloadSchema>;
|
|
174
|
+
export declare const SectionDeletedPayloadSchema: z.ZodObject<{
|
|
175
|
+
eventName: z.ZodLiteral<"section:deleted">;
|
|
176
|
+
eventData: z.ZodPipe<z.ZodObject<{
|
|
177
|
+
id: z.ZodString;
|
|
178
|
+
userId: z.ZodString;
|
|
179
|
+
projectId: z.ZodString;
|
|
180
|
+
addedAt: z.ZodCoercedDate<unknown>;
|
|
181
|
+
archivedAt: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
182
|
+
name: z.ZodString;
|
|
183
|
+
sectionOrder: z.ZodNumber;
|
|
184
|
+
isArchived: z.ZodBoolean;
|
|
185
|
+
isDeleted: z.ZodBoolean;
|
|
186
|
+
isCollapsed: z.ZodBoolean;
|
|
187
|
+
updatedAt: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodCoercedDate<unknown>>>, z.ZodTransform<Date | null, Date | null | undefined>>;
|
|
188
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
189
|
+
url: string;
|
|
190
|
+
id: string;
|
|
191
|
+
userId: string;
|
|
192
|
+
projectId: string;
|
|
193
|
+
addedAt: Date;
|
|
194
|
+
archivedAt: Date | null;
|
|
195
|
+
name: string;
|
|
196
|
+
sectionOrder: number;
|
|
197
|
+
isArchived: boolean;
|
|
198
|
+
isDeleted: boolean;
|
|
199
|
+
isCollapsed: boolean;
|
|
200
|
+
updatedAt: Date | null;
|
|
201
|
+
}, {
|
|
202
|
+
id: string;
|
|
203
|
+
userId: string;
|
|
204
|
+
projectId: string;
|
|
205
|
+
addedAt: Date;
|
|
206
|
+
archivedAt: Date | null;
|
|
207
|
+
name: string;
|
|
208
|
+
sectionOrder: number;
|
|
209
|
+
isArchived: boolean;
|
|
210
|
+
isDeleted: boolean;
|
|
211
|
+
isCollapsed: boolean;
|
|
212
|
+
updatedAt: Date | null;
|
|
213
|
+
}>>;
|
|
214
|
+
version: z.ZodEnum<{
|
|
215
|
+
1: "1";
|
|
216
|
+
}>;
|
|
217
|
+
userId: z.ZodString;
|
|
218
|
+
initiator: z.ZodObject<{
|
|
219
|
+
id: z.ZodString;
|
|
220
|
+
fullName: z.ZodString;
|
|
221
|
+
email: z.ZodString;
|
|
222
|
+
imageId: z.ZodNullable<z.ZodString>;
|
|
223
|
+
isPremium: z.ZodBoolean;
|
|
224
|
+
}, z.core.$strip>;
|
|
225
|
+
triggeredAt: z.ZodCoercedDate<unknown>;
|
|
226
|
+
}, z.core.$strip>;
|
|
227
|
+
export type SectionDeletedPayload = z.infer<typeof SectionDeletedPayloadSchema>;
|
|
228
|
+
export declare const SectionArchivedPayloadSchema: z.ZodObject<{
|
|
229
|
+
eventName: z.ZodLiteral<"section:archived">;
|
|
230
|
+
eventData: z.ZodPipe<z.ZodObject<{
|
|
231
|
+
id: z.ZodString;
|
|
232
|
+
userId: z.ZodString;
|
|
233
|
+
projectId: z.ZodString;
|
|
234
|
+
addedAt: z.ZodCoercedDate<unknown>;
|
|
235
|
+
archivedAt: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
236
|
+
name: z.ZodString;
|
|
237
|
+
sectionOrder: z.ZodNumber;
|
|
238
|
+
isArchived: z.ZodBoolean;
|
|
239
|
+
isDeleted: z.ZodBoolean;
|
|
240
|
+
isCollapsed: z.ZodBoolean;
|
|
241
|
+
updatedAt: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodCoercedDate<unknown>>>, z.ZodTransform<Date | null, Date | null | undefined>>;
|
|
242
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
243
|
+
url: string;
|
|
244
|
+
id: string;
|
|
245
|
+
userId: string;
|
|
246
|
+
projectId: string;
|
|
247
|
+
addedAt: Date;
|
|
248
|
+
archivedAt: Date | null;
|
|
249
|
+
name: string;
|
|
250
|
+
sectionOrder: number;
|
|
251
|
+
isArchived: boolean;
|
|
252
|
+
isDeleted: boolean;
|
|
253
|
+
isCollapsed: boolean;
|
|
254
|
+
updatedAt: Date | null;
|
|
255
|
+
}, {
|
|
256
|
+
id: string;
|
|
257
|
+
userId: string;
|
|
258
|
+
projectId: string;
|
|
259
|
+
addedAt: Date;
|
|
260
|
+
archivedAt: Date | null;
|
|
261
|
+
name: string;
|
|
262
|
+
sectionOrder: number;
|
|
263
|
+
isArchived: boolean;
|
|
264
|
+
isDeleted: boolean;
|
|
265
|
+
isCollapsed: boolean;
|
|
266
|
+
updatedAt: Date | null;
|
|
267
|
+
}>>;
|
|
268
|
+
version: z.ZodEnum<{
|
|
269
|
+
1: "1";
|
|
270
|
+
}>;
|
|
271
|
+
userId: z.ZodString;
|
|
272
|
+
initiator: z.ZodObject<{
|
|
273
|
+
id: z.ZodString;
|
|
274
|
+
fullName: z.ZodString;
|
|
275
|
+
email: z.ZodString;
|
|
276
|
+
imageId: z.ZodNullable<z.ZodString>;
|
|
277
|
+
isPremium: z.ZodBoolean;
|
|
278
|
+
}, z.core.$strip>;
|
|
279
|
+
triggeredAt: z.ZodCoercedDate<unknown>;
|
|
280
|
+
}, z.core.$strip>;
|
|
281
|
+
export type SectionArchivedPayload = z.infer<typeof SectionArchivedPayloadSchema>;
|
|
282
|
+
export declare const SectionUnarchivedPayloadSchema: z.ZodObject<{
|
|
283
|
+
eventName: z.ZodLiteral<"section:unarchived">;
|
|
284
|
+
eventData: z.ZodPipe<z.ZodObject<{
|
|
285
|
+
id: z.ZodString;
|
|
286
|
+
userId: z.ZodString;
|
|
287
|
+
projectId: z.ZodString;
|
|
288
|
+
addedAt: z.ZodCoercedDate<unknown>;
|
|
289
|
+
archivedAt: z.ZodNullable<z.ZodCoercedDate<unknown>>;
|
|
290
|
+
name: z.ZodString;
|
|
291
|
+
sectionOrder: z.ZodNumber;
|
|
292
|
+
isArchived: z.ZodBoolean;
|
|
293
|
+
isDeleted: z.ZodBoolean;
|
|
294
|
+
isCollapsed: z.ZodBoolean;
|
|
295
|
+
updatedAt: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodCoercedDate<unknown>>>, z.ZodTransform<Date | null, Date | null | undefined>>;
|
|
296
|
+
}, z.core.$strip>, z.ZodTransform<{
|
|
297
|
+
url: string;
|
|
298
|
+
id: string;
|
|
299
|
+
userId: string;
|
|
300
|
+
projectId: string;
|
|
301
|
+
addedAt: Date;
|
|
302
|
+
archivedAt: Date | null;
|
|
303
|
+
name: string;
|
|
304
|
+
sectionOrder: number;
|
|
305
|
+
isArchived: boolean;
|
|
306
|
+
isDeleted: boolean;
|
|
307
|
+
isCollapsed: boolean;
|
|
308
|
+
updatedAt: Date | null;
|
|
309
|
+
}, {
|
|
310
|
+
id: string;
|
|
311
|
+
userId: string;
|
|
312
|
+
projectId: string;
|
|
313
|
+
addedAt: Date;
|
|
314
|
+
archivedAt: Date | null;
|
|
315
|
+
name: string;
|
|
316
|
+
sectionOrder: number;
|
|
317
|
+
isArchived: boolean;
|
|
318
|
+
isDeleted: boolean;
|
|
319
|
+
isCollapsed: boolean;
|
|
320
|
+
updatedAt: Date | null;
|
|
321
|
+
}>>;
|
|
322
|
+
version: z.ZodEnum<{
|
|
323
|
+
1: "1";
|
|
324
|
+
}>;
|
|
325
|
+
userId: z.ZodString;
|
|
326
|
+
initiator: z.ZodObject<{
|
|
327
|
+
id: z.ZodString;
|
|
328
|
+
fullName: z.ZodString;
|
|
329
|
+
email: z.ZodString;
|
|
330
|
+
imageId: z.ZodNullable<z.ZodString>;
|
|
331
|
+
isPremium: z.ZodBoolean;
|
|
332
|
+
}, z.core.$strip>;
|
|
333
|
+
triggeredAt: z.ZodCoercedDate<unknown>;
|
|
334
|
+
}, z.core.$strip>;
|
|
335
|
+
export type SectionUnarchivedPayload = z.infer<typeof SectionUnarchivedPayloadSchema>;
|