@dakkitor/api-contracts 1.1.135 → 1.1.137

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.
Files changed (42) hide show
  1. package/dist/abilities/abilities.contract.d.ts +13 -19
  2. package/dist/abilities/abilities.contract.d.ts.map +1 -1
  3. package/dist/abilities/abilities.contract.js +18 -33
  4. package/dist/abilities/admin.abilities.json +10 -0
  5. package/dist/abilities/first-agent.abilities.json +17 -2
  6. package/dist/abilities/second-agent.abilities.json +9 -1
  7. package/dist/actives/actives.contract.d.ts +6986 -6296
  8. package/dist/actives/actives.contract.d.ts.map +1 -1
  9. package/dist/agent-client-links/agent-client-links.contract.d.ts +2151 -702
  10. package/dist/agent-client-links/agent-client-links.contract.d.ts.map +1 -1
  11. package/dist/agent-client-links/agent-client-links.contract.js +56 -2
  12. package/dist/bookings/bookings.contract.d.ts +26279 -22681
  13. package/dist/bookings/bookings.contract.d.ts.map +1 -1
  14. package/dist/bookings/bookings.contract.js +169 -36
  15. package/dist/client-contacts/client-contacts.contract.d.ts +460 -460
  16. package/dist/clients/clients.contract.d.ts +263 -197
  17. package/dist/clients/clients.contract.d.ts.map +1 -1
  18. package/dist/clients/clients.contract.js +50 -6
  19. package/dist/collaboration-checkings/collaboration-checkings.contract.d.ts +1620 -1620
  20. package/dist/collaborations/collaborations.contract.d.ts +1456 -1456
  21. package/dist/collaborations/collaborations.contract.js +2 -2
  22. package/dist/cron-executions/cron-executions.contract.d.ts +163 -39
  23. package/dist/cron-executions/cron-executions.contract.d.ts.map +1 -1
  24. package/dist/cron-executions/cron-executions.contract.js +14 -0
  25. package/dist/dashboards/agent-daily-metrics.contract.d.ts +173 -803
  26. package/dist/dashboards/agent-daily-metrics.contract.d.ts.map +1 -1
  27. package/dist/dashboards/agent-daily-metrics.contract.js +45 -108
  28. package/dist/dashboards/dashboard-widgets.contract.d.ts +388 -282
  29. package/dist/dashboards/dashboard-widgets.contract.d.ts.map +1 -1
  30. package/dist/dashboards/dashboard-widgets.contract.js +77 -32
  31. package/dist/dashboards/dashboard.contract.d.ts +215 -305
  32. package/dist/index.d.ts +3 -0
  33. package/dist/index.d.ts.map +1 -1
  34. package/dist/index.js +3 -0
  35. package/dist/jobs/jobs.contract.d.ts +2885 -2885
  36. package/dist/kpi-impersonation/kpi-impersonation.contract.d.ts +1340 -0
  37. package/dist/kpi-impersonation/kpi-impersonation.contract.d.ts.map +1 -0
  38. package/dist/kpi-impersonation/kpi-impersonation.contract.js +146 -0
  39. package/dist/lead-distribution/agent-lead-distribution.contract.d.ts +535 -139
  40. package/dist/lead-distribution/agent-lead-distribution.contract.d.ts.map +1 -1
  41. package/dist/lead-distribution/agent-lead-distribution.contract.js +57 -1
  42. package/package.json +1 -1
@@ -9,21 +9,21 @@ export declare const ClientUserSchema: z.ZodObject<{
9
9
  lastName: z.ZodString;
10
10
  email: z.ZodString;
11
11
  }, "strip", z.ZodTypeAny, {
12
- email: string;
13
12
  id: string;
14
13
  firstName: string;
15
14
  lastName: string;
16
- }, {
17
15
  email: string;
16
+ }, {
18
17
  id: string;
19
18
  firstName: string;
20
19
  lastName: string;
20
+ email: string;
21
21
  }>;
22
22
  export declare const ClientSchema: z.ZodObject<{
23
23
  id: z.ZodString;
24
24
  name: z.ZodString;
25
25
  crn: z.ZodNullable<z.ZodString>;
26
- govLink: z.ZodString;
26
+ govLink: z.ZodNullable<z.ZodString>;
27
27
  soleTrader: z.ZodBoolean;
28
28
  status: z.ZodEnum<["APPROVED", "PENDING_VERIFICATION", "BLACKLISTED"]>;
29
29
  director: z.ZodString;
@@ -34,15 +34,15 @@ export declare const ClientSchema: z.ZodObject<{
34
34
  lastName: z.ZodString;
35
35
  email: z.ZodString;
36
36
  }, "strip", z.ZodTypeAny, {
37
- email: string;
38
37
  id: string;
39
38
  firstName: string;
40
39
  lastName: string;
41
- }, {
42
40
  email: string;
41
+ }, {
43
42
  id: string;
44
43
  firstName: string;
45
44
  lastName: string;
45
+ email: string;
46
46
  }>>>;
47
47
  createdAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
48
48
  updatedAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
@@ -54,60 +54,115 @@ export declare const ClientSchema: z.ZodObject<{
54
54
  agentId: string;
55
55
  }>>>;
56
56
  }, "strip", z.ZodTypeAny, {
57
- name: string;
58
57
  id: string;
59
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
60
- createdAt: string;
61
- updatedAt: string;
58
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
59
+ name: string;
62
60
  crn: string | null;
63
- govLink: string;
61
+ govLink: string | null;
64
62
  soleTrader: boolean;
65
63
  director: string;
64
+ createdAt: string;
65
+ updatedAt: string;
66
66
  blacklistReason?: string | null | undefined;
67
67
  lastUpdatedBy?: {
68
- email: string;
69
68
  id: string;
70
69
  firstName: string;
71
70
  lastName: string;
71
+ email: string;
72
72
  } | null | undefined;
73
73
  agentClientLinks?: {
74
74
  agentId: string;
75
75
  } | null | undefined;
76
76
  }, {
77
- name: string;
78
77
  id: string;
79
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
80
- createdAt: string | Date;
81
- updatedAt: string | Date;
78
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
79
+ name: string;
82
80
  crn: string | null;
83
- govLink: string;
81
+ govLink: string | null;
84
82
  soleTrader: boolean;
85
83
  director: string;
84
+ createdAt: string | Date;
85
+ updatedAt: string | Date;
86
86
  blacklistReason?: string | null | undefined;
87
87
  lastUpdatedBy?: {
88
- email: string;
89
88
  id: string;
90
89
  firstName: string;
91
90
  lastName: string;
91
+ email: string;
92
92
  } | null | undefined;
93
93
  agentClientLinks?: {
94
94
  agentId: string;
95
95
  } | null | undefined;
96
96
  }>;
97
- export declare const CreateClientSchema: z.ZodObject<{
97
+ /**
98
+ * Base schema for CreateClient without refinements.
99
+ * Use this for form field introspection on the frontend.
100
+ */
101
+ export declare const CreateClientBaseSchema: z.ZodObject<{
102
+ name: z.ZodString;
103
+ govLink: z.ZodOptional<z.ZodNullable<z.ZodString>>;
104
+ soleTrader: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
105
+ director: z.ZodString;
106
+ }, "strip", z.ZodTypeAny, {
107
+ name: string;
108
+ soleTrader: boolean;
109
+ director: string;
110
+ govLink?: string | null | undefined;
111
+ }, {
112
+ name: string;
113
+ director: string;
114
+ govLink?: string | null | undefined;
115
+ soleTrader?: boolean | undefined;
116
+ }>;
117
+ /**
118
+ * Conditional validation rules for CreateClient.
119
+ * Export these so the frontend can apply them based on context.
120
+ */
121
+ export declare const CreateClientRefinements: {
122
+ readonly govLinkRequiredForNonSoleTrader: {
123
+ /** Fields that trigger this refinement */
124
+ readonly dependsOn: readonly ["soleTrader"];
125
+ /** Field that this refinement validates */
126
+ readonly validates: "govLink";
127
+ /** Condition description for UI hints */
128
+ readonly condition: "soleTrader !== true";
129
+ /** Error message when validation fails */
130
+ readonly message: "Government Registration Link is required for non-sole trader clients";
131
+ /** The actual refinement function */
132
+ readonly check: (data: {
133
+ soleTrader?: boolean;
134
+ govLink?: string | null;
135
+ }) => boolean;
136
+ };
137
+ };
138
+ /**
139
+ * Full CreateClient schema with all refinements applied.
140
+ * Use this for API validation.
141
+ */
142
+ export declare const CreateClientSchema: z.ZodEffects<z.ZodObject<{
98
143
  name: z.ZodString;
99
- govLink: z.ZodString;
144
+ govLink: z.ZodOptional<z.ZodNullable<z.ZodString>>;
100
145
  soleTrader: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
101
146
  director: z.ZodString;
102
147
  }, "strip", z.ZodTypeAny, {
103
148
  name: string;
104
- govLink: string;
105
149
  soleTrader: boolean;
106
150
  director: string;
151
+ govLink?: string | null | undefined;
152
+ }, {
153
+ name: string;
154
+ director: string;
155
+ govLink?: string | null | undefined;
156
+ soleTrader?: boolean | undefined;
157
+ }>, {
158
+ name: string;
159
+ soleTrader: boolean;
160
+ director: string;
161
+ govLink?: string | null | undefined;
107
162
  }, {
108
163
  name: string;
109
- govLink: string;
110
164
  director: string;
165
+ govLink?: string | null | undefined;
111
166
  soleTrader?: boolean | undefined;
112
167
  }>;
113
168
  /**
@@ -116,22 +171,22 @@ export declare const CreateClientSchema: z.ZodObject<{
116
171
  */
117
172
  export declare const UpdateClientBaseSchema: z.ZodObject<{
118
173
  name: z.ZodOptional<z.ZodString>;
119
- govLink: z.ZodOptional<z.ZodString>;
174
+ govLink: z.ZodOptional<z.ZodNullable<z.ZodString>>;
120
175
  director: z.ZodOptional<z.ZodString>;
121
176
  status: z.ZodOptional<z.ZodEnum<["APPROVED", "PENDING_VERIFICATION", "BLACKLISTED"]>>;
122
177
  blacklistReason: z.ZodOptional<z.ZodNullable<z.ZodString>>;
123
178
  }, "strip", z.ZodTypeAny, {
179
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | undefined;
124
180
  name?: string | undefined;
125
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | undefined;
126
- blacklistReason?: string | null | undefined;
127
- govLink?: string | undefined;
181
+ govLink?: string | null | undefined;
128
182
  director?: string | undefined;
183
+ blacklistReason?: string | null | undefined;
129
184
  }, {
185
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | undefined;
130
186
  name?: string | undefined;
131
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | undefined;
132
- blacklistReason?: string | null | undefined;
133
- govLink?: string | undefined;
187
+ govLink?: string | null | undefined;
134
188
  director?: string | undefined;
189
+ blacklistReason?: string | null | undefined;
135
190
  }>;
136
191
  /**
137
192
  * Conditional validation rules for UpdateClient.
@@ -160,34 +215,34 @@ export declare const UpdateClientRefinements: {
160
215
  */
161
216
  export declare const UpdateClientSchema: z.ZodEffects<z.ZodObject<{
162
217
  name: z.ZodOptional<z.ZodString>;
163
- govLink: z.ZodOptional<z.ZodString>;
218
+ govLink: z.ZodOptional<z.ZodNullable<z.ZodString>>;
164
219
  director: z.ZodOptional<z.ZodString>;
165
220
  status: z.ZodOptional<z.ZodEnum<["APPROVED", "PENDING_VERIFICATION", "BLACKLISTED"]>>;
166
221
  blacklistReason: z.ZodOptional<z.ZodNullable<z.ZodString>>;
167
222
  }, "strip", z.ZodTypeAny, {
223
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | undefined;
168
224
  name?: string | undefined;
169
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | undefined;
170
- blacklistReason?: string | null | undefined;
171
- govLink?: string | undefined;
225
+ govLink?: string | null | undefined;
172
226
  director?: string | undefined;
227
+ blacklistReason?: string | null | undefined;
173
228
  }, {
229
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | undefined;
174
230
  name?: string | undefined;
175
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | undefined;
176
- blacklistReason?: string | null | undefined;
177
- govLink?: string | undefined;
231
+ govLink?: string | null | undefined;
178
232
  director?: string | undefined;
233
+ blacklistReason?: string | null | undefined;
179
234
  }>, {
235
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | undefined;
180
236
  name?: string | undefined;
181
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | undefined;
182
- blacklistReason?: string | null | undefined;
183
- govLink?: string | undefined;
237
+ govLink?: string | null | undefined;
184
238
  director?: string | undefined;
239
+ blacklistReason?: string | null | undefined;
185
240
  }, {
241
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | undefined;
186
242
  name?: string | undefined;
187
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | undefined;
188
- blacklistReason?: string | null | undefined;
189
- govLink?: string | undefined;
243
+ govLink?: string | null | undefined;
190
244
  director?: string | undefined;
245
+ blacklistReason?: string | null | undefined;
191
246
  }>;
192
247
  export declare const FilterClientSchema: z.ZodObject<{
193
248
  limit: z.ZodDefault<z.ZodNumber>;
@@ -219,12 +274,11 @@ export declare const FilterClientSchema: z.ZodObject<{
219
274
  sortBy: z.ZodNullable<z.ZodOptional<z.ZodEnum<["name", "director", "createdAt", "updatedAt"]>>>;
220
275
  sortOrder: z.ZodNullable<z.ZodOptional<z.ZodEnum<["ASC", "DESC"]>>>;
221
276
  }, "strip", z.ZodTypeAny, {
222
- page: number;
223
277
  limit: number;
278
+ page: number;
279
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | null | undefined;
224
280
  name?: string | null | undefined;
225
- sortBy?: "name" | "createdAt" | "updatedAt" | "director" | null | undefined;
226
- sortOrder?: "ASC" | "DESC" | null | undefined;
227
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | null | undefined;
281
+ director?: string | null | undefined;
228
282
  createdAt?: {
229
283
  from?: string | null | undefined;
230
284
  to?: string | null | undefined;
@@ -233,14 +287,12 @@ export declare const FilterClientSchema: z.ZodObject<{
233
287
  from?: string | null | undefined;
234
288
  to?: string | null | undefined;
235
289
  } | null | undefined;
236
- director?: string | null | undefined;
290
+ sortBy?: "name" | "director" | "createdAt" | "updatedAt" | null | undefined;
291
+ sortOrder?: "ASC" | "DESC" | null | undefined;
237
292
  }, {
293
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | null | undefined;
238
294
  name?: string | null | undefined;
239
- sortBy?: "name" | "createdAt" | "updatedAt" | "director" | null | undefined;
240
- sortOrder?: "ASC" | "DESC" | null | undefined;
241
- page?: number | undefined;
242
- limit?: number | undefined;
243
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | null | undefined;
295
+ director?: string | null | undefined;
244
296
  createdAt?: {
245
297
  from?: string | null | undefined;
246
298
  to?: string | null | undefined;
@@ -249,34 +301,37 @@ export declare const FilterClientSchema: z.ZodObject<{
249
301
  from?: string | null | undefined;
250
302
  to?: string | null | undefined;
251
303
  } | null | undefined;
252
- director?: string | null | undefined;
304
+ limit?: number | undefined;
305
+ page?: number | undefined;
306
+ sortBy?: "name" | "director" | "createdAt" | "updatedAt" | null | undefined;
307
+ sortOrder?: "ASC" | "DESC" | null | undefined;
253
308
  }>;
254
309
  export declare const ClientAutocompleteResponseSchema: z.ZodObject<{
255
310
  id: z.ZodString;
256
311
  name: z.ZodString;
257
312
  }, "strip", z.ZodTypeAny, {
258
- name: string;
259
313
  id: string;
260
- }, {
261
314
  name: string;
315
+ }, {
262
316
  id: string;
317
+ name: string;
263
318
  }>;
264
319
  export declare const ClientAutocompleteArraySchema: z.ZodArray<z.ZodObject<{
265
320
  id: z.ZodString;
266
321
  name: z.ZodString;
267
322
  }, "strip", z.ZodTypeAny, {
268
- name: string;
269
323
  id: string;
270
- }, {
271
324
  name: string;
325
+ }, {
272
326
  id: string;
327
+ name: string;
273
328
  }>, "many">;
274
329
  export declare const PaginatedClientResponseSchema: z.ZodObject<{
275
330
  items: z.ZodArray<z.ZodObject<{
276
331
  id: z.ZodString;
277
332
  name: z.ZodString;
278
333
  crn: z.ZodNullable<z.ZodString>;
279
- govLink: z.ZodString;
334
+ govLink: z.ZodNullable<z.ZodString>;
280
335
  soleTrader: z.ZodBoolean;
281
336
  status: z.ZodEnum<["APPROVED", "PENDING_VERIFICATION", "BLACKLISTED"]>;
282
337
  director: z.ZodString;
@@ -287,15 +342,15 @@ export declare const PaginatedClientResponseSchema: z.ZodObject<{
287
342
  lastName: z.ZodString;
288
343
  email: z.ZodString;
289
344
  }, "strip", z.ZodTypeAny, {
290
- email: string;
291
345
  id: string;
292
346
  firstName: string;
293
347
  lastName: string;
294
- }, {
295
348
  email: string;
349
+ }, {
296
350
  id: string;
297
351
  firstName: string;
298
352
  lastName: string;
353
+ email: string;
299
354
  }>>>;
300
355
  createdAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
301
356
  updatedAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
@@ -307,41 +362,41 @@ export declare const PaginatedClientResponseSchema: z.ZodObject<{
307
362
  agentId: string;
308
363
  }>>>;
309
364
  }, "strip", z.ZodTypeAny, {
310
- name: string;
311
365
  id: string;
312
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
313
- createdAt: string;
314
- updatedAt: string;
366
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
367
+ name: string;
315
368
  crn: string | null;
316
- govLink: string;
369
+ govLink: string | null;
317
370
  soleTrader: boolean;
318
371
  director: string;
372
+ createdAt: string;
373
+ updatedAt: string;
319
374
  blacklistReason?: string | null | undefined;
320
375
  lastUpdatedBy?: {
321
- email: string;
322
376
  id: string;
323
377
  firstName: string;
324
378
  lastName: string;
379
+ email: string;
325
380
  } | null | undefined;
326
381
  agentClientLinks?: {
327
382
  agentId: string;
328
383
  } | null | undefined;
329
384
  }, {
330
- name: string;
331
385
  id: string;
332
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
333
- createdAt: string | Date;
334
- updatedAt: string | Date;
386
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
387
+ name: string;
335
388
  crn: string | null;
336
- govLink: string;
389
+ govLink: string | null;
337
390
  soleTrader: boolean;
338
391
  director: string;
392
+ createdAt: string | Date;
393
+ updatedAt: string | Date;
339
394
  blacklistReason?: string | null | undefined;
340
395
  lastUpdatedBy?: {
341
- email: string;
342
396
  id: string;
343
397
  firstName: string;
344
398
  lastName: string;
399
+ email: string;
345
400
  } | null | undefined;
346
401
  agentClientLinks?: {
347
402
  agentId: string;
@@ -355,21 +410,21 @@ export declare const PaginatedClientResponseSchema: z.ZodObject<{
355
410
  }, "strip", z.ZodTypeAny, {
356
411
  limit: number;
357
412
  items: {
358
- name: string;
359
413
  id: string;
360
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
361
- createdAt: string;
362
- updatedAt: string;
414
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
415
+ name: string;
363
416
  crn: string | null;
364
- govLink: string;
417
+ govLink: string | null;
365
418
  soleTrader: boolean;
366
419
  director: string;
420
+ createdAt: string;
421
+ updatedAt: string;
367
422
  blacklistReason?: string | null | undefined;
368
423
  lastUpdatedBy?: {
369
- email: string;
370
424
  id: string;
371
425
  firstName: string;
372
426
  lastName: string;
427
+ email: string;
373
428
  } | null | undefined;
374
429
  agentClientLinks?: {
375
430
  agentId: string;
@@ -382,21 +437,21 @@ export declare const PaginatedClientResponseSchema: z.ZodObject<{
382
437
  }, {
383
438
  limit: number;
384
439
  items: {
385
- name: string;
386
440
  id: string;
387
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
388
- createdAt: string | Date;
389
- updatedAt: string | Date;
441
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
442
+ name: string;
390
443
  crn: string | null;
391
- govLink: string;
444
+ govLink: string | null;
392
445
  soleTrader: boolean;
393
446
  director: string;
447
+ createdAt: string | Date;
448
+ updatedAt: string | Date;
394
449
  blacklistReason?: string | null | undefined;
395
450
  lastUpdatedBy?: {
396
- email: string;
397
451
  id: string;
398
452
  firstName: string;
399
453
  lastName: string;
454
+ email: string;
400
455
  } | null | undefined;
401
456
  agentClientLinks?: {
402
457
  agentId: string;
@@ -409,6 +464,7 @@ export declare const PaginatedClientResponseSchema: z.ZodObject<{
409
464
  }>;
410
465
  export type Client = z.infer<typeof ClientSchema>;
411
466
  export type CreateClient = z.infer<typeof CreateClientSchema>;
467
+ export type CreateClientBase = z.infer<typeof CreateClientBaseSchema>;
412
468
  export type UpdateClientBase = z.infer<typeof UpdateClientBaseSchema>;
413
469
  export type UpdateClient = z.infer<typeof UpdateClientSchema>;
414
470
  export type FilterClient = z.infer<typeof FilterClientSchema>;
@@ -426,20 +482,30 @@ export declare const clientsContractRouter: {
426
482
  };
427
483
  summary: "Create a new client";
428
484
  method: "POST";
429
- body: z.ZodObject<{
485
+ body: z.ZodEffects<z.ZodObject<{
430
486
  name: z.ZodString;
431
- govLink: z.ZodString;
487
+ govLink: z.ZodOptional<z.ZodNullable<z.ZodString>>;
432
488
  soleTrader: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
433
489
  director: z.ZodString;
434
490
  }, "strip", z.ZodTypeAny, {
435
491
  name: string;
436
- govLink: string;
437
492
  soleTrader: boolean;
438
493
  director: string;
494
+ govLink?: string | null | undefined;
439
495
  }, {
440
496
  name: string;
441
- govLink: string;
442
497
  director: string;
498
+ govLink?: string | null | undefined;
499
+ soleTrader?: boolean | undefined;
500
+ }>, {
501
+ name: string;
502
+ soleTrader: boolean;
503
+ director: string;
504
+ govLink?: string | null | undefined;
505
+ }, {
506
+ name: string;
507
+ director: string;
508
+ govLink?: string | null | undefined;
443
509
  soleTrader?: boolean | undefined;
444
510
  }>;
445
511
  path: "/v2/clients";
@@ -548,7 +614,7 @@ export declare const clientsContractRouter: {
548
614
  id: z.ZodString;
549
615
  name: z.ZodString;
550
616
  crn: z.ZodNullable<z.ZodString>;
551
- govLink: z.ZodString;
617
+ govLink: z.ZodNullable<z.ZodString>;
552
618
  soleTrader: z.ZodBoolean;
553
619
  status: z.ZodEnum<["APPROVED", "PENDING_VERIFICATION", "BLACKLISTED"]>;
554
620
  director: z.ZodString;
@@ -559,15 +625,15 @@ export declare const clientsContractRouter: {
559
625
  lastName: z.ZodString;
560
626
  email: z.ZodString;
561
627
  }, "strip", z.ZodTypeAny, {
562
- email: string;
563
628
  id: string;
564
629
  firstName: string;
565
630
  lastName: string;
566
- }, {
567
631
  email: string;
632
+ }, {
568
633
  id: string;
569
634
  firstName: string;
570
635
  lastName: string;
636
+ email: string;
571
637
  }>>>;
572
638
  createdAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
573
639
  updatedAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
@@ -579,41 +645,41 @@ export declare const clientsContractRouter: {
579
645
  agentId: string;
580
646
  }>>>;
581
647
  }, "strip", z.ZodTypeAny, {
582
- name: string;
583
648
  id: string;
584
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
585
- createdAt: string;
586
- updatedAt: string;
649
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
650
+ name: string;
587
651
  crn: string | null;
588
- govLink: string;
652
+ govLink: string | null;
589
653
  soleTrader: boolean;
590
654
  director: string;
655
+ createdAt: string;
656
+ updatedAt: string;
591
657
  blacklistReason?: string | null | undefined;
592
658
  lastUpdatedBy?: {
593
- email: string;
594
659
  id: string;
595
660
  firstName: string;
596
661
  lastName: string;
662
+ email: string;
597
663
  } | null | undefined;
598
664
  agentClientLinks?: {
599
665
  agentId: string;
600
666
  } | null | undefined;
601
667
  }, {
602
- name: string;
603
668
  id: string;
604
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
605
- createdAt: string | Date;
606
- updatedAt: string | Date;
669
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
670
+ name: string;
607
671
  crn: string | null;
608
- govLink: string;
672
+ govLink: string | null;
609
673
  soleTrader: boolean;
610
674
  director: string;
675
+ createdAt: string | Date;
676
+ updatedAt: string | Date;
611
677
  blacklistReason?: string | null | undefined;
612
678
  lastUpdatedBy?: {
613
- email: string;
614
679
  id: string;
615
680
  firstName: string;
616
681
  lastName: string;
682
+ email: string;
617
683
  } | null | undefined;
618
684
  agentClientLinks?: {
619
685
  agentId: string;
@@ -647,6 +713,12 @@ export declare const clientsContractRouter: {
647
713
  };
648
714
  };
649
715
  findAll: {
716
+ metadata: {
717
+ tags: string[];
718
+ openApi: {
719
+ operationId: string;
720
+ };
721
+ };
650
722
  query: z.ZodObject<{
651
723
  limit: z.ZodDefault<z.ZodNumber>;
652
724
  page: z.ZodDefault<z.ZodNumber>;
@@ -677,12 +749,11 @@ export declare const clientsContractRouter: {
677
749
  sortBy: z.ZodNullable<z.ZodOptional<z.ZodEnum<["name", "director", "createdAt", "updatedAt"]>>>;
678
750
  sortOrder: z.ZodNullable<z.ZodOptional<z.ZodEnum<["ASC", "DESC"]>>>;
679
751
  }, "strip", z.ZodTypeAny, {
680
- page: number;
681
752
  limit: number;
753
+ page: number;
754
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | null | undefined;
682
755
  name?: string | null | undefined;
683
- sortBy?: "name" | "createdAt" | "updatedAt" | "director" | null | undefined;
684
- sortOrder?: "ASC" | "DESC" | null | undefined;
685
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | null | undefined;
756
+ director?: string | null | undefined;
686
757
  createdAt?: {
687
758
  from?: string | null | undefined;
688
759
  to?: string | null | undefined;
@@ -691,14 +762,12 @@ export declare const clientsContractRouter: {
691
762
  from?: string | null | undefined;
692
763
  to?: string | null | undefined;
693
764
  } | null | undefined;
694
- director?: string | null | undefined;
765
+ sortBy?: "name" | "director" | "createdAt" | "updatedAt" | null | undefined;
766
+ sortOrder?: "ASC" | "DESC" | null | undefined;
695
767
  }, {
768
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | null | undefined;
696
769
  name?: string | null | undefined;
697
- sortBy?: "name" | "createdAt" | "updatedAt" | "director" | null | undefined;
698
- sortOrder?: "ASC" | "DESC" | null | undefined;
699
- page?: number | undefined;
700
- limit?: number | undefined;
701
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | null | undefined;
770
+ director?: string | null | undefined;
702
771
  createdAt?: {
703
772
  from?: string | null | undefined;
704
773
  to?: string | null | undefined;
@@ -707,14 +776,11 @@ export declare const clientsContractRouter: {
707
776
  from?: string | null | undefined;
708
777
  to?: string | null | undefined;
709
778
  } | null | undefined;
710
- director?: string | null | undefined;
779
+ limit?: number | undefined;
780
+ page?: number | undefined;
781
+ sortBy?: "name" | "director" | "createdAt" | "updatedAt" | null | undefined;
782
+ sortOrder?: "ASC" | "DESC" | null | undefined;
711
783
  }>;
712
- metadata: {
713
- tags: string[];
714
- openApi: {
715
- operationId: string;
716
- };
717
- };
718
784
  summary: "Get all clients";
719
785
  method: "GET";
720
786
  path: "/v2/clients";
@@ -824,7 +890,7 @@ export declare const clientsContractRouter: {
824
890
  id: z.ZodString;
825
891
  name: z.ZodString;
826
892
  crn: z.ZodNullable<z.ZodString>;
827
- govLink: z.ZodString;
893
+ govLink: z.ZodNullable<z.ZodString>;
828
894
  soleTrader: z.ZodBoolean;
829
895
  status: z.ZodEnum<["APPROVED", "PENDING_VERIFICATION", "BLACKLISTED"]>;
830
896
  director: z.ZodString;
@@ -835,15 +901,15 @@ export declare const clientsContractRouter: {
835
901
  lastName: z.ZodString;
836
902
  email: z.ZodString;
837
903
  }, "strip", z.ZodTypeAny, {
838
- email: string;
839
904
  id: string;
840
905
  firstName: string;
841
906
  lastName: string;
842
- }, {
843
907
  email: string;
908
+ }, {
844
909
  id: string;
845
910
  firstName: string;
846
911
  lastName: string;
912
+ email: string;
847
913
  }>>>;
848
914
  createdAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
849
915
  updatedAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
@@ -855,41 +921,41 @@ export declare const clientsContractRouter: {
855
921
  agentId: string;
856
922
  }>>>;
857
923
  }, "strip", z.ZodTypeAny, {
858
- name: string;
859
924
  id: string;
860
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
861
- createdAt: string;
862
- updatedAt: string;
925
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
926
+ name: string;
863
927
  crn: string | null;
864
- govLink: string;
928
+ govLink: string | null;
865
929
  soleTrader: boolean;
866
930
  director: string;
931
+ createdAt: string;
932
+ updatedAt: string;
867
933
  blacklistReason?: string | null | undefined;
868
934
  lastUpdatedBy?: {
869
- email: string;
870
935
  id: string;
871
936
  firstName: string;
872
937
  lastName: string;
938
+ email: string;
873
939
  } | null | undefined;
874
940
  agentClientLinks?: {
875
941
  agentId: string;
876
942
  } | null | undefined;
877
943
  }, {
878
- name: string;
879
944
  id: string;
880
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
881
- createdAt: string | Date;
882
- updatedAt: string | Date;
945
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
946
+ name: string;
883
947
  crn: string | null;
884
- govLink: string;
948
+ govLink: string | null;
885
949
  soleTrader: boolean;
886
950
  director: string;
951
+ createdAt: string | Date;
952
+ updatedAt: string | Date;
887
953
  blacklistReason?: string | null | undefined;
888
954
  lastUpdatedBy?: {
889
- email: string;
890
955
  id: string;
891
956
  firstName: string;
892
957
  lastName: string;
958
+ email: string;
893
959
  } | null | undefined;
894
960
  agentClientLinks?: {
895
961
  agentId: string;
@@ -903,21 +969,21 @@ export declare const clientsContractRouter: {
903
969
  }, "strip", z.ZodTypeAny, {
904
970
  limit: number;
905
971
  items: {
906
- name: string;
907
972
  id: string;
908
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
909
- createdAt: string;
910
- updatedAt: string;
973
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
974
+ name: string;
911
975
  crn: string | null;
912
- govLink: string;
976
+ govLink: string | null;
913
977
  soleTrader: boolean;
914
978
  director: string;
979
+ createdAt: string;
980
+ updatedAt: string;
915
981
  blacklistReason?: string | null | undefined;
916
982
  lastUpdatedBy?: {
917
- email: string;
918
983
  id: string;
919
984
  firstName: string;
920
985
  lastName: string;
986
+ email: string;
921
987
  } | null | undefined;
922
988
  agentClientLinks?: {
923
989
  agentId: string;
@@ -930,21 +996,21 @@ export declare const clientsContractRouter: {
930
996
  }, {
931
997
  limit: number;
932
998
  items: {
933
- name: string;
934
999
  id: string;
935
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
936
- createdAt: string | Date;
937
- updatedAt: string | Date;
1000
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
1001
+ name: string;
938
1002
  crn: string | null;
939
- govLink: string;
1003
+ govLink: string | null;
940
1004
  soleTrader: boolean;
941
1005
  director: string;
1006
+ createdAt: string | Date;
1007
+ updatedAt: string | Date;
942
1008
  blacklistReason?: string | null | undefined;
943
1009
  lastUpdatedBy?: {
944
- email: string;
945
1010
  id: string;
946
1011
  firstName: string;
947
1012
  lastName: string;
1013
+ email: string;
948
1014
  } | null | undefined;
949
1015
  agentClientLinks?: {
950
1016
  agentId: string;
@@ -958,6 +1024,12 @@ export declare const clientsContractRouter: {
958
1024
  };
959
1025
  };
960
1026
  autocomplete: {
1027
+ metadata: {
1028
+ tags: string[];
1029
+ openApi: {
1030
+ operationId: string;
1031
+ };
1032
+ };
961
1033
  query: z.ZodObject<{
962
1034
  query: z.ZodOptional<z.ZodString>;
963
1035
  id: z.ZodOptional<z.ZodString>;
@@ -968,12 +1040,6 @@ export declare const clientsContractRouter: {
968
1040
  id?: string | undefined;
969
1041
  query?: string | undefined;
970
1042
  }>;
971
- metadata: {
972
- tags: string[];
973
- openApi: {
974
- operationId: string;
975
- };
976
- };
977
1043
  summary: "Get clients for autocomplete";
978
1044
  method: "GET";
979
1045
  path: "/v2/clients/autocomplete";
@@ -1082,11 +1148,11 @@ export declare const clientsContractRouter: {
1082
1148
  id: z.ZodString;
1083
1149
  name: z.ZodString;
1084
1150
  }, "strip", z.ZodTypeAny, {
1085
- name: string;
1086
1151
  id: string;
1087
- }, {
1088
1152
  name: string;
1153
+ }, {
1089
1154
  id: string;
1155
+ name: string;
1090
1156
  }>, "many">;
1091
1157
  };
1092
1158
  };
@@ -1212,7 +1278,7 @@ export declare const clientsContractRouter: {
1212
1278
  id: z.ZodString;
1213
1279
  name: z.ZodString;
1214
1280
  crn: z.ZodNullable<z.ZodString>;
1215
- govLink: z.ZodString;
1281
+ govLink: z.ZodNullable<z.ZodString>;
1216
1282
  soleTrader: z.ZodBoolean;
1217
1283
  status: z.ZodEnum<["APPROVED", "PENDING_VERIFICATION", "BLACKLISTED"]>;
1218
1284
  director: z.ZodString;
@@ -1223,15 +1289,15 @@ export declare const clientsContractRouter: {
1223
1289
  lastName: z.ZodString;
1224
1290
  email: z.ZodString;
1225
1291
  }, "strip", z.ZodTypeAny, {
1226
- email: string;
1227
1292
  id: string;
1228
1293
  firstName: string;
1229
1294
  lastName: string;
1230
- }, {
1231
1295
  email: string;
1296
+ }, {
1232
1297
  id: string;
1233
1298
  firstName: string;
1234
1299
  lastName: string;
1300
+ email: string;
1235
1301
  }>>>;
1236
1302
  createdAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
1237
1303
  updatedAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
@@ -1243,41 +1309,41 @@ export declare const clientsContractRouter: {
1243
1309
  agentId: string;
1244
1310
  }>>>;
1245
1311
  }, "strip", z.ZodTypeAny, {
1246
- name: string;
1247
1312
  id: string;
1248
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
1249
- createdAt: string;
1250
- updatedAt: string;
1313
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
1314
+ name: string;
1251
1315
  crn: string | null;
1252
- govLink: string;
1316
+ govLink: string | null;
1253
1317
  soleTrader: boolean;
1254
1318
  director: string;
1319
+ createdAt: string;
1320
+ updatedAt: string;
1255
1321
  blacklistReason?: string | null | undefined;
1256
1322
  lastUpdatedBy?: {
1257
- email: string;
1258
1323
  id: string;
1259
1324
  firstName: string;
1260
1325
  lastName: string;
1326
+ email: string;
1261
1327
  } | null | undefined;
1262
1328
  agentClientLinks?: {
1263
1329
  agentId: string;
1264
1330
  } | null | undefined;
1265
1331
  }, {
1266
- name: string;
1267
1332
  id: string;
1268
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
1269
- createdAt: string | Date;
1270
- updatedAt: string | Date;
1333
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
1334
+ name: string;
1271
1335
  crn: string | null;
1272
- govLink: string;
1336
+ govLink: string | null;
1273
1337
  soleTrader: boolean;
1274
1338
  director: string;
1339
+ createdAt: string | Date;
1340
+ updatedAt: string | Date;
1275
1341
  blacklistReason?: string | null | undefined;
1276
1342
  lastUpdatedBy?: {
1277
- email: string;
1278
1343
  id: string;
1279
1344
  firstName: string;
1280
1345
  lastName: string;
1346
+ email: string;
1281
1347
  } | null | undefined;
1282
1348
  agentClientLinks?: {
1283
1349
  agentId: string;
@@ -1328,34 +1394,34 @@ export declare const clientsContractRouter: {
1328
1394
  method: "PATCH";
1329
1395
  body: z.ZodEffects<z.ZodObject<{
1330
1396
  name: z.ZodOptional<z.ZodString>;
1331
- govLink: z.ZodOptional<z.ZodString>;
1397
+ govLink: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1332
1398
  director: z.ZodOptional<z.ZodString>;
1333
1399
  status: z.ZodOptional<z.ZodEnum<["APPROVED", "PENDING_VERIFICATION", "BLACKLISTED"]>>;
1334
1400
  blacklistReason: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1335
1401
  }, "strip", z.ZodTypeAny, {
1402
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | undefined;
1336
1403
  name?: string | undefined;
1337
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | undefined;
1338
- blacklistReason?: string | null | undefined;
1339
- govLink?: string | undefined;
1404
+ govLink?: string | null | undefined;
1340
1405
  director?: string | undefined;
1406
+ blacklistReason?: string | null | undefined;
1341
1407
  }, {
1408
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | undefined;
1342
1409
  name?: string | undefined;
1343
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | undefined;
1344
- blacklistReason?: string | null | undefined;
1345
- govLink?: string | undefined;
1410
+ govLink?: string | null | undefined;
1346
1411
  director?: string | undefined;
1412
+ blacklistReason?: string | null | undefined;
1347
1413
  }>, {
1414
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | undefined;
1348
1415
  name?: string | undefined;
1349
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | undefined;
1350
- blacklistReason?: string | null | undefined;
1351
- govLink?: string | undefined;
1416
+ govLink?: string | null | undefined;
1352
1417
  director?: string | undefined;
1418
+ blacklistReason?: string | null | undefined;
1353
1419
  }, {
1420
+ status?: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED" | undefined;
1354
1421
  name?: string | undefined;
1355
- status?: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION" | undefined;
1356
- blacklistReason?: string | null | undefined;
1357
- govLink?: string | undefined;
1422
+ govLink?: string | null | undefined;
1358
1423
  director?: string | undefined;
1424
+ blacklistReason?: string | null | undefined;
1359
1425
  }>;
1360
1426
  path: "/v2/clients/:id";
1361
1427
  responses: {
@@ -1463,7 +1529,7 @@ export declare const clientsContractRouter: {
1463
1529
  id: z.ZodString;
1464
1530
  name: z.ZodString;
1465
1531
  crn: z.ZodNullable<z.ZodString>;
1466
- govLink: z.ZodString;
1532
+ govLink: z.ZodNullable<z.ZodString>;
1467
1533
  soleTrader: z.ZodBoolean;
1468
1534
  status: z.ZodEnum<["APPROVED", "PENDING_VERIFICATION", "BLACKLISTED"]>;
1469
1535
  director: z.ZodString;
@@ -1474,15 +1540,15 @@ export declare const clientsContractRouter: {
1474
1540
  lastName: z.ZodString;
1475
1541
  email: z.ZodString;
1476
1542
  }, "strip", z.ZodTypeAny, {
1477
- email: string;
1478
1543
  id: string;
1479
1544
  firstName: string;
1480
1545
  lastName: string;
1481
- }, {
1482
1546
  email: string;
1547
+ }, {
1483
1548
  id: string;
1484
1549
  firstName: string;
1485
1550
  lastName: string;
1551
+ email: string;
1486
1552
  }>>>;
1487
1553
  createdAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
1488
1554
  updatedAt: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodDate]>, string, string | Date>;
@@ -1494,41 +1560,41 @@ export declare const clientsContractRouter: {
1494
1560
  agentId: string;
1495
1561
  }>>>;
1496
1562
  }, "strip", z.ZodTypeAny, {
1497
- name: string;
1498
1563
  id: string;
1499
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
1500
- createdAt: string;
1501
- updatedAt: string;
1564
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
1565
+ name: string;
1502
1566
  crn: string | null;
1503
- govLink: string;
1567
+ govLink: string | null;
1504
1568
  soleTrader: boolean;
1505
1569
  director: string;
1570
+ createdAt: string;
1571
+ updatedAt: string;
1506
1572
  blacklistReason?: string | null | undefined;
1507
1573
  lastUpdatedBy?: {
1508
- email: string;
1509
1574
  id: string;
1510
1575
  firstName: string;
1511
1576
  lastName: string;
1577
+ email: string;
1512
1578
  } | null | undefined;
1513
1579
  agentClientLinks?: {
1514
1580
  agentId: string;
1515
1581
  } | null | undefined;
1516
1582
  }, {
1517
- name: string;
1518
1583
  id: string;
1519
- status: "BLACKLISTED" | "APPROVED" | "PENDING_VERIFICATION";
1520
- createdAt: string | Date;
1521
- updatedAt: string | Date;
1584
+ status: "APPROVED" | "PENDING_VERIFICATION" | "BLACKLISTED";
1585
+ name: string;
1522
1586
  crn: string | null;
1523
- govLink: string;
1587
+ govLink: string | null;
1524
1588
  soleTrader: boolean;
1525
1589
  director: string;
1590
+ createdAt: string | Date;
1591
+ updatedAt: string | Date;
1526
1592
  blacklistReason?: string | null | undefined;
1527
1593
  lastUpdatedBy?: {
1528
- email: string;
1529
1594
  id: string;
1530
1595
  firstName: string;
1531
1596
  lastName: string;
1597
+ email: string;
1532
1598
  } | null | undefined;
1533
1599
  agentClientLinks?: {
1534
1600
  agentId: string;