@kl1/contracts 1.4.18 → 1.4.20

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.
@@ -1,6 +1,6 @@
1
1
  import z from 'zod';
2
- import { ContactContractValidationSchema } from './validation';
3
- import { ContactSchema } from './schema';
2
+ import { ContactContractValidationSchema, SendLineMessageSchema } from './validation';
3
+ import { ChannelTypeSchema, ContactSchema } from './schema';
4
4
  import { GetTagsSchema } from '../tag/validation';
5
5
  export type CreateContactRequest = z.infer<typeof ContactContractValidationSchema.create.request>;
6
6
  export type CreateContactResponse = z.infer<typeof ContactContractValidationSchema.create.response>;
@@ -11,75 +11,1388 @@ export type UpdateContactRequest = Partial<CreateContactRequest>;
11
11
  export type UpdateContactResponse = CreateContactResponse;
12
12
  export type Contact = z.infer<typeof ContactSchema>;
13
13
  export type GetAllTagsRequest = z.infer<typeof GetTagsSchema>;
14
+ export type GetSendLineRequest = z.infer<typeof SendLineMessageSchema>;
15
+ export type PublicApiChannelType = z.infer<typeof ChannelTypeSchema>;
14
16
  export declare const publicApiContract: {
15
- createContact: {
17
+ sendLineMessage: {
16
18
  body: z.ZodObject<{
17
- name: z.ZodString;
18
- email: z.ZodOptional<z.ZodArray<z.ZodObject<{
19
- email: z.ZodString;
20
- isPrimary: z.ZodBoolean;
19
+ channelId: z.ZodString;
20
+ message: z.ZodString;
21
+ contactId: z.ZodString;
22
+ }, "strip", z.ZodTypeAny, {
23
+ message: string;
24
+ channelId: string;
25
+ contactId: string;
26
+ }, {
27
+ message: string;
28
+ channelId: string;
29
+ contactId: string;
30
+ }>;
31
+ summary: "Send line message";
32
+ method: "POST";
33
+ responses: {
34
+ 201: z.ZodObject<{
35
+ status: z.ZodString;
36
+ channel: z.ZodString;
37
+ message: z.ZodString;
38
+ requestId: z.ZodString;
39
+ }, "strip", z.ZodTypeAny, {
40
+ message: string;
41
+ channel: string;
42
+ status: string;
43
+ requestId: string;
44
+ }, {
45
+ message: string;
46
+ channel: string;
47
+ status: string;
48
+ requestId: string;
49
+ }>;
50
+ 400: z.ZodObject<{
51
+ message: z.ZodString;
52
+ }, "strip", z.ZodTypeAny, {
53
+ message: string;
54
+ }, {
55
+ message: string;
56
+ }>;
57
+ 409: z.ZodObject<{
58
+ message: z.ZodString;
59
+ }, "strip", z.ZodTypeAny, {
60
+ message: string;
61
+ }, {
62
+ message: string;
63
+ }>;
64
+ 401: z.ZodObject<{
65
+ message: z.ZodString;
66
+ error: z.ZodAny;
67
+ }, "strip", z.ZodTypeAny, {
68
+ message: string;
69
+ error?: any;
70
+ }, {
71
+ message: string;
72
+ error?: any;
73
+ }>;
74
+ 404: z.ZodObject<{
75
+ message: z.ZodString;
76
+ error: z.ZodAny;
77
+ }, "strip", z.ZodTypeAny, {
78
+ message: string;
79
+ error?: any;
80
+ }, {
81
+ message: string;
82
+ error?: any;
83
+ }>;
84
+ 422: z.ZodObject<{
85
+ message: z.ZodString;
86
+ error: z.ZodAny;
87
+ }, "strip", z.ZodTypeAny, {
88
+ message: string;
89
+ error?: any;
90
+ }, {
91
+ message: string;
92
+ error?: any;
93
+ }>;
94
+ 500: z.ZodObject<{
95
+ message: z.ZodString;
96
+ error: z.ZodAny;
97
+ }, "strip", z.ZodTypeAny, {
98
+ message: string;
99
+ error?: any;
100
+ }, {
101
+ message: string;
102
+ error?: any;
103
+ }>;
104
+ };
105
+ path: "api/v1/message/line/send";
106
+ };
107
+ getAllTags: {
108
+ method: "GET";
109
+ query: z.ZodOptional<z.ZodObject<{
110
+ group: z.ZodOptional<z.ZodDefault<z.ZodUnion<[z.ZodLiteral<"general">, z.ZodLiteral<"contact">]>>>;
111
+ keyword: z.ZodOptional<z.ZodString>;
112
+ }, "strip", z.ZodTypeAny, {
113
+ group?: "general" | "contact" | undefined;
114
+ keyword?: string | undefined;
115
+ }, {
116
+ group?: "general" | "contact" | undefined;
117
+ keyword?: string | undefined;
118
+ }>>;
119
+ responses: {
120
+ 200: z.ZodObject<{
121
+ requestId: z.ZodString;
122
+ tags: z.ZodArray<z.ZodObject<{
123
+ id: z.ZodString;
124
+ createdAt: z.ZodDate;
125
+ updatedAt: z.ZodDate;
126
+ deletedAt: z.ZodNullable<z.ZodDate>;
127
+ name: z.ZodString;
128
+ }, "strip", z.ZodTypeAny, {
129
+ name: string;
130
+ id: string;
131
+ createdAt: Date;
132
+ updatedAt: Date;
133
+ deletedAt: Date | null;
134
+ }, {
135
+ name: string;
136
+ id: string;
137
+ createdAt: Date;
138
+ updatedAt: Date;
139
+ deletedAt: Date | null;
140
+ }>, "many">;
141
+ }, "strip", z.ZodTypeAny, {
142
+ requestId: string;
143
+ tags: {
144
+ name: string;
145
+ id: string;
146
+ createdAt: Date;
147
+ updatedAt: Date;
148
+ deletedAt: Date | null;
149
+ }[];
150
+ }, {
151
+ requestId: string;
152
+ tags: {
153
+ name: string;
154
+ id: string;
155
+ createdAt: Date;
156
+ updatedAt: Date;
157
+ deletedAt: Date | null;
158
+ }[];
159
+ }>;
160
+ 400: z.ZodObject<{
161
+ message: z.ZodString;
162
+ }, "strip", z.ZodTypeAny, {
163
+ message: string;
164
+ }, {
165
+ message: string;
166
+ }>;
167
+ 409: z.ZodObject<{
168
+ message: z.ZodString;
169
+ }, "strip", z.ZodTypeAny, {
170
+ message: string;
171
+ }, {
172
+ message: string;
173
+ }>;
174
+ 401: z.ZodObject<{
175
+ message: z.ZodString;
176
+ error: z.ZodAny;
177
+ }, "strip", z.ZodTypeAny, {
178
+ message: string;
179
+ error?: any;
180
+ }, {
181
+ message: string;
182
+ error?: any;
183
+ }>;
184
+ 404: z.ZodObject<{
185
+ message: z.ZodString;
186
+ error: z.ZodAny;
187
+ }, "strip", z.ZodTypeAny, {
188
+ message: string;
189
+ error?: any;
190
+ }, {
191
+ message: string;
192
+ error?: any;
193
+ }>;
194
+ 422: z.ZodObject<{
195
+ message: z.ZodString;
196
+ error: z.ZodAny;
197
+ }, "strip", z.ZodTypeAny, {
198
+ message: string;
199
+ error?: any;
200
+ }, {
201
+ message: string;
202
+ error?: any;
203
+ }>;
204
+ 500: z.ZodObject<{
205
+ message: z.ZodString;
206
+ error: z.ZodAny;
207
+ }, "strip", z.ZodTypeAny, {
208
+ message: string;
209
+ error?: any;
210
+ }, {
211
+ message: string;
212
+ error?: any;
213
+ }>;
214
+ };
215
+ path: "api/v1/tags";
216
+ };
217
+ getAllChannel: {
218
+ method: "GET";
219
+ query: z.ZodObject<{
220
+ page: z.ZodDefault<z.ZodNumber>;
221
+ pageSize: z.ZodDefault<z.ZodNumber>;
222
+ keyword: z.ZodOptional<z.ZodString>;
223
+ }, "strip", z.ZodTypeAny, {
224
+ page: number;
225
+ pageSize: number;
226
+ keyword?: string | undefined;
227
+ }, {
228
+ page?: number | undefined;
229
+ pageSize?: number | undefined;
230
+ keyword?: string | undefined;
231
+ }>;
232
+ responses: {
233
+ 200: z.ZodObject<{
234
+ requestId: z.ZodString;
235
+ page: z.ZodNumber;
236
+ pageSize: z.ZodNumber;
237
+ total: z.ZodNumber;
238
+ lastPage: z.ZodNumber;
239
+ data: z.ZodAny;
240
+ }, "strip", z.ZodTypeAny, {
241
+ total: number;
242
+ page: number;
243
+ pageSize: number;
244
+ lastPage: number;
245
+ requestId: string;
246
+ data?: any;
247
+ }, {
248
+ total: number;
249
+ page: number;
250
+ pageSize: number;
251
+ lastPage: number;
252
+ requestId: string;
253
+ data?: any;
254
+ }>;
255
+ 400: z.ZodObject<{
256
+ message: z.ZodString;
257
+ }, "strip", z.ZodTypeAny, {
258
+ message: string;
259
+ }, {
260
+ message: string;
261
+ }>;
262
+ 409: z.ZodObject<{
263
+ message: z.ZodString;
264
+ }, "strip", z.ZodTypeAny, {
265
+ message: string;
266
+ }, {
267
+ message: string;
268
+ }>;
269
+ 401: z.ZodObject<{
270
+ message: z.ZodString;
271
+ error: z.ZodAny;
272
+ }, "strip", z.ZodTypeAny, {
273
+ message: string;
274
+ error?: any;
275
+ }, {
276
+ message: string;
277
+ error?: any;
278
+ }>;
279
+ 404: z.ZodObject<{
280
+ message: z.ZodString;
281
+ error: z.ZodAny;
282
+ }, "strip", z.ZodTypeAny, {
283
+ message: string;
284
+ error?: any;
285
+ }, {
286
+ message: string;
287
+ error?: any;
288
+ }>;
289
+ 422: z.ZodObject<{
290
+ message: z.ZodString;
291
+ error: z.ZodAny;
292
+ }, "strip", z.ZodTypeAny, {
293
+ message: string;
294
+ error?: any;
295
+ }, {
296
+ message: string;
297
+ error?: any;
298
+ }>;
299
+ 500: z.ZodObject<{
300
+ message: z.ZodString;
301
+ error: z.ZodAny;
302
+ }, "strip", z.ZodTypeAny, {
303
+ message: string;
304
+ error?: any;
305
+ }, {
306
+ message: string;
307
+ error?: any;
308
+ }>;
309
+ };
310
+ path: "api/v1/channels";
311
+ };
312
+ createContact: {
313
+ body: z.ZodObject<{
314
+ name: z.ZodString;
315
+ email: z.ZodOptional<z.ZodArray<z.ZodObject<{
316
+ email: z.ZodString;
317
+ isPrimary: z.ZodBoolean;
318
+ }, "strip", z.ZodTypeAny, {
319
+ isPrimary: boolean;
320
+ email: string;
321
+ }, {
322
+ isPrimary: boolean;
323
+ email: string;
324
+ }>, "many">>;
325
+ channel: z.ZodOptional<z.ZodString>;
326
+ address: z.ZodOptional<z.ZodString>;
327
+ phone: z.ZodOptional<z.ZodArray<z.ZodObject<{
328
+ phone: z.ZodString;
329
+ isPrimary: z.ZodBoolean;
330
+ }, "strip", z.ZodTypeAny, {
331
+ isPrimary: boolean;
332
+ phone: string;
333
+ }, {
334
+ isPrimary: boolean;
335
+ phone: string;
336
+ }>, "many">>;
337
+ notes: z.ZodOptional<z.ZodString>;
338
+ tags: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
339
+ company: z.ZodOptional<z.ZodString>;
340
+ customFields: z.ZodRecord<z.ZodString, z.ZodString>;
341
+ }, "strip", z.ZodTypeAny, {
342
+ name: string;
343
+ customFields: Record<string, string>;
344
+ email?: {
345
+ isPrimary: boolean;
346
+ email: string;
347
+ }[] | undefined;
348
+ channel?: string | undefined;
349
+ address?: string | undefined;
350
+ phone?: {
351
+ isPrimary: boolean;
352
+ phone: string;
353
+ }[] | undefined;
354
+ notes?: string | undefined;
355
+ tags?: string[] | undefined;
356
+ company?: string | undefined;
357
+ }, {
358
+ name: string;
359
+ customFields: Record<string, string>;
360
+ email?: {
361
+ isPrimary: boolean;
362
+ email: string;
363
+ }[] | undefined;
364
+ channel?: string | undefined;
365
+ address?: string | undefined;
366
+ phone?: {
367
+ isPrimary: boolean;
368
+ phone: string;
369
+ }[] | undefined;
370
+ notes?: string | undefined;
371
+ tags?: string[] | undefined;
372
+ company?: string | undefined;
373
+ }>;
374
+ summary: "Create a new contact";
375
+ method: "POST";
376
+ responses: {
377
+ 201: z.ZodObject<{
378
+ requestId: z.ZodString;
379
+ data: z.ZodObject<{
380
+ id: z.ZodString;
381
+ createdAt: z.ZodDate;
382
+ updatedAt: z.ZodDate;
383
+ deletedAt: z.ZodNullable<z.ZodDate>;
384
+ name: z.ZodString;
385
+ address: z.ZodNullable<z.ZodString>;
386
+ channel: z.ZodNullable<z.ZodString>;
387
+ notes: z.ZodNullable<z.ZodString>;
388
+ contactProfile: z.ZodNullable<z.ZodString>;
389
+ socialProfileUrl: z.ZodNullable<z.ZodString>;
390
+ tags: z.ZodArray<z.ZodObject<{
391
+ id: z.ZodString;
392
+ createdAt: z.ZodDate;
393
+ updatedAt: z.ZodDate;
394
+ deletedAt: z.ZodNullable<z.ZodDate>;
395
+ name: z.ZodString;
396
+ }, "strip", z.ZodTypeAny, {
397
+ name: string;
398
+ id: string;
399
+ createdAt: Date;
400
+ updatedAt: Date;
401
+ deletedAt: Date | null;
402
+ }, {
403
+ name: string;
404
+ id: string;
405
+ createdAt: Date;
406
+ updatedAt: Date;
407
+ deletedAt: Date | null;
408
+ }>, "many">;
409
+ company: z.ZodNullable<z.ZodObject<Omit<{
410
+ id: z.ZodString;
411
+ createdAt: z.ZodDate;
412
+ updatedAt: z.ZodDate;
413
+ deletedAt: z.ZodNullable<z.ZodDate>;
414
+ name: z.ZodOptional<z.ZodString>;
415
+ phone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
416
+ address: z.ZodOptional<z.ZodNullable<z.ZodString>>;
417
+ industry: z.ZodOptional<z.ZodNullable<z.ZodString>>;
418
+ customFields: z.ZodOptional<z.ZodArray<z.ZodObject<{
419
+ id: z.ZodString;
420
+ createdAt: z.ZodDate;
421
+ updatedAt: z.ZodDate;
422
+ deletedAt: z.ZodNullable<z.ZodDate>;
423
+ textValue: z.ZodNullable<z.ZodString>;
424
+ booleanValue: z.ZodNullable<z.ZodBoolean>;
425
+ numberValue: z.ZodNullable<z.ZodNumber>;
426
+ dateValue: z.ZodNullable<z.ZodDate>;
427
+ attribute: z.ZodObject<Omit<{
428
+ id: z.ZodString;
429
+ createdAt: z.ZodDate;
430
+ updatedAt: z.ZodDate;
431
+ deletedAt: z.ZodNullable<z.ZodDate>;
432
+ systemName: z.ZodString;
433
+ displayName: z.ZodString;
434
+ type: z.ZodUnion<[z.ZodLiteral<"text">, z.ZodLiteral<"textarea">, z.ZodLiteral<"date">, z.ZodLiteral<"select">, z.ZodLiteral<"link">, z.ZodLiteral<"attachment">]>;
435
+ position: z.ZodNumber;
436
+ isDefault: z.ZodBoolean;
437
+ isArchived: z.ZodBoolean;
438
+ isRequired: z.ZodBoolean;
439
+ isUnique: z.ZodBoolean;
440
+ options: z.ZodArray<z.ZodObject<{
441
+ position: z.ZodNumber;
442
+ value: z.ZodString;
443
+ label: z.ZodString;
444
+ isDefault: z.ZodBoolean;
445
+ id: z.ZodString;
446
+ }, "strip", z.ZodTypeAny, {
447
+ id: string;
448
+ position: number;
449
+ value: string;
450
+ label: string;
451
+ isDefault: boolean;
452
+ }, {
453
+ id: string;
454
+ position: number;
455
+ value: string;
456
+ label: string;
457
+ isDefault: boolean;
458
+ }>, "many">;
459
+ group: z.ZodObject<{
460
+ id: z.ZodString;
461
+ createdAt: z.ZodDate;
462
+ updatedAt: z.ZodDate;
463
+ deletedAt: z.ZodNullable<z.ZodDate>;
464
+ systemName: z.ZodString;
465
+ displayName: z.ZodString;
466
+ }, "strip", z.ZodTypeAny, {
467
+ id: string;
468
+ createdAt: Date;
469
+ updatedAt: Date;
470
+ deletedAt: Date | null;
471
+ systemName: string;
472
+ displayName: string;
473
+ }, {
474
+ id: string;
475
+ createdAt: Date;
476
+ updatedAt: Date;
477
+ deletedAt: Date | null;
478
+ systemName: string;
479
+ displayName: string;
480
+ }>;
481
+ }, "options" | "group">, "strip", z.ZodTypeAny, {
482
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
483
+ id: string;
484
+ position: number;
485
+ createdAt: Date;
486
+ updatedAt: Date;
487
+ deletedAt: Date | null;
488
+ systemName: string;
489
+ displayName: string;
490
+ isDefault: boolean;
491
+ isArchived: boolean;
492
+ isRequired: boolean;
493
+ isUnique: boolean;
494
+ }, {
495
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
496
+ id: string;
497
+ position: number;
498
+ createdAt: Date;
499
+ updatedAt: Date;
500
+ deletedAt: Date | null;
501
+ systemName: string;
502
+ displayName: string;
503
+ isDefault: boolean;
504
+ isArchived: boolean;
505
+ isRequired: boolean;
506
+ isUnique: boolean;
507
+ }>;
508
+ }, "strip", z.ZodTypeAny, {
509
+ id: string;
510
+ createdAt: Date;
511
+ updatedAt: Date;
512
+ deletedAt: Date | null;
513
+ attribute: {
514
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
515
+ id: string;
516
+ position: number;
517
+ createdAt: Date;
518
+ updatedAt: Date;
519
+ deletedAt: Date | null;
520
+ systemName: string;
521
+ displayName: string;
522
+ isDefault: boolean;
523
+ isArchived: boolean;
524
+ isRequired: boolean;
525
+ isUnique: boolean;
526
+ };
527
+ textValue: string | null;
528
+ booleanValue: boolean | null;
529
+ numberValue: number | null;
530
+ dateValue: Date | null;
531
+ }, {
532
+ id: string;
533
+ createdAt: Date;
534
+ updatedAt: Date;
535
+ deletedAt: Date | null;
536
+ attribute: {
537
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
538
+ id: string;
539
+ position: number;
540
+ createdAt: Date;
541
+ updatedAt: Date;
542
+ deletedAt: Date | null;
543
+ systemName: string;
544
+ displayName: string;
545
+ isDefault: boolean;
546
+ isArchived: boolean;
547
+ isRequired: boolean;
548
+ isUnique: boolean;
549
+ };
550
+ textValue: string | null;
551
+ booleanValue: boolean | null;
552
+ numberValue: number | null;
553
+ dateValue: Date | null;
554
+ }>, "many">>;
555
+ }, "customFields">, "strip", z.ZodTypeAny, {
556
+ id: string;
557
+ createdAt: Date;
558
+ updatedAt: Date;
559
+ deletedAt: Date | null;
560
+ name?: string | undefined;
561
+ address?: string | null | undefined;
562
+ phone?: string | null | undefined;
563
+ industry?: string | null | undefined;
564
+ }, {
565
+ id: string;
566
+ createdAt: Date;
567
+ updatedAt: Date;
568
+ deletedAt: Date | null;
569
+ name?: string | undefined;
570
+ address?: string | null | undefined;
571
+ phone?: string | null | undefined;
572
+ industry?: string | null | undefined;
573
+ }>>;
574
+ customFields: z.ZodArray<z.ZodObject<{
575
+ id: z.ZodString;
576
+ createdAt: z.ZodDate;
577
+ updatedAt: z.ZodDate;
578
+ deletedAt: z.ZodNullable<z.ZodDate>;
579
+ textValue: z.ZodNullable<z.ZodString>;
580
+ booleanValue: z.ZodNullable<z.ZodBoolean>;
581
+ numberValue: z.ZodNullable<z.ZodNumber>;
582
+ dateValue: z.ZodNullable<z.ZodDate>;
583
+ attribute: z.ZodObject<Omit<{
584
+ id: z.ZodString;
585
+ createdAt: z.ZodDate;
586
+ updatedAt: z.ZodDate;
587
+ deletedAt: z.ZodNullable<z.ZodDate>;
588
+ systemName: z.ZodString;
589
+ displayName: z.ZodString;
590
+ type: z.ZodUnion<[z.ZodLiteral<"text">, z.ZodLiteral<"textarea">, z.ZodLiteral<"date">, z.ZodLiteral<"select">, z.ZodLiteral<"link">, z.ZodLiteral<"attachment">]>;
591
+ position: z.ZodNumber;
592
+ isDefault: z.ZodBoolean;
593
+ isArchived: z.ZodBoolean;
594
+ isRequired: z.ZodBoolean;
595
+ isUnique: z.ZodBoolean;
596
+ options: z.ZodArray<z.ZodObject<{
597
+ position: z.ZodNumber;
598
+ value: z.ZodString;
599
+ label: z.ZodString;
600
+ isDefault: z.ZodBoolean;
601
+ id: z.ZodString;
602
+ }, "strip", z.ZodTypeAny, {
603
+ id: string;
604
+ position: number;
605
+ value: string;
606
+ label: string;
607
+ isDefault: boolean;
608
+ }, {
609
+ id: string;
610
+ position: number;
611
+ value: string;
612
+ label: string;
613
+ isDefault: boolean;
614
+ }>, "many">;
615
+ group: z.ZodObject<{
616
+ id: z.ZodString;
617
+ createdAt: z.ZodDate;
618
+ updatedAt: z.ZodDate;
619
+ deletedAt: z.ZodNullable<z.ZodDate>;
620
+ systemName: z.ZodString;
621
+ displayName: z.ZodString;
622
+ }, "strip", z.ZodTypeAny, {
623
+ id: string;
624
+ createdAt: Date;
625
+ updatedAt: Date;
626
+ deletedAt: Date | null;
627
+ systemName: string;
628
+ displayName: string;
629
+ }, {
630
+ id: string;
631
+ createdAt: Date;
632
+ updatedAt: Date;
633
+ deletedAt: Date | null;
634
+ systemName: string;
635
+ displayName: string;
636
+ }>;
637
+ }, "options" | "group">, "strip", z.ZodTypeAny, {
638
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
639
+ id: string;
640
+ position: number;
641
+ createdAt: Date;
642
+ updatedAt: Date;
643
+ deletedAt: Date | null;
644
+ systemName: string;
645
+ displayName: string;
646
+ isDefault: boolean;
647
+ isArchived: boolean;
648
+ isRequired: boolean;
649
+ isUnique: boolean;
650
+ }, {
651
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
652
+ id: string;
653
+ position: number;
654
+ createdAt: Date;
655
+ updatedAt: Date;
656
+ deletedAt: Date | null;
657
+ systemName: string;
658
+ displayName: string;
659
+ isDefault: boolean;
660
+ isArchived: boolean;
661
+ isRequired: boolean;
662
+ isUnique: boolean;
663
+ }>;
664
+ uploads: z.ZodArray<z.ZodObject<{
665
+ id: z.ZodString;
666
+ createdAt: z.ZodDate;
667
+ updatedAt: z.ZodDate;
668
+ deletedAt: z.ZodNullable<z.ZodDate>;
669
+ bucketName: z.ZodString;
670
+ fileName: z.ZodString;
671
+ fileSize: z.ZodNumber;
672
+ fileKey: z.ZodString;
673
+ fileUrl: z.ZodNullable<z.ZodString>;
674
+ status: z.ZodNullable<z.ZodString>;
675
+ }, "strip", z.ZodTypeAny, {
676
+ id: string;
677
+ status: string | null;
678
+ createdAt: Date;
679
+ updatedAt: Date;
680
+ deletedAt: Date | null;
681
+ fileName: string;
682
+ fileKey: string;
683
+ bucketName: string;
684
+ fileSize: number;
685
+ fileUrl: string | null;
686
+ }, {
687
+ id: string;
688
+ status: string | null;
689
+ createdAt: Date;
690
+ updatedAt: Date;
691
+ deletedAt: Date | null;
692
+ fileName: string;
693
+ fileKey: string;
694
+ bucketName: string;
695
+ fileSize: number;
696
+ fileUrl: string | null;
697
+ }>, "many">;
698
+ }, "strip", z.ZodTypeAny, {
699
+ id: string;
700
+ createdAt: Date;
701
+ updatedAt: Date;
702
+ deletedAt: Date | null;
703
+ attribute: {
704
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
705
+ id: string;
706
+ position: number;
707
+ createdAt: Date;
708
+ updatedAt: Date;
709
+ deletedAt: Date | null;
710
+ systemName: string;
711
+ displayName: string;
712
+ isDefault: boolean;
713
+ isArchived: boolean;
714
+ isRequired: boolean;
715
+ isUnique: boolean;
716
+ };
717
+ textValue: string | null;
718
+ booleanValue: boolean | null;
719
+ numberValue: number | null;
720
+ dateValue: Date | null;
721
+ uploads: {
722
+ id: string;
723
+ status: string | null;
724
+ createdAt: Date;
725
+ updatedAt: Date;
726
+ deletedAt: Date | null;
727
+ fileName: string;
728
+ fileKey: string;
729
+ bucketName: string;
730
+ fileSize: number;
731
+ fileUrl: string | null;
732
+ }[];
733
+ }, {
734
+ id: string;
735
+ createdAt: Date;
736
+ updatedAt: Date;
737
+ deletedAt: Date | null;
738
+ attribute: {
739
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
740
+ id: string;
741
+ position: number;
742
+ createdAt: Date;
743
+ updatedAt: Date;
744
+ deletedAt: Date | null;
745
+ systemName: string;
746
+ displayName: string;
747
+ isDefault: boolean;
748
+ isArchived: boolean;
749
+ isRequired: boolean;
750
+ isUnique: boolean;
751
+ };
752
+ textValue: string | null;
753
+ booleanValue: boolean | null;
754
+ numberValue: number | null;
755
+ dateValue: Date | null;
756
+ uploads: {
757
+ id: string;
758
+ status: string | null;
759
+ createdAt: Date;
760
+ updatedAt: Date;
761
+ deletedAt: Date | null;
762
+ fileName: string;
763
+ fileKey: string;
764
+ bucketName: string;
765
+ fileSize: number;
766
+ fileUrl: string | null;
767
+ }[];
768
+ }>, "many">;
769
+ contactEmails: z.ZodArray<z.ZodObject<{
770
+ id: z.ZodString;
771
+ createdAt: z.ZodDate;
772
+ updatedAt: z.ZodDate;
773
+ deletedAt: z.ZodNullable<z.ZodDate>;
774
+ email: z.ZodString;
775
+ isPrimary: z.ZodBoolean;
776
+ }, "strip", z.ZodTypeAny, {
777
+ id: string;
778
+ isPrimary: boolean;
779
+ email: string;
780
+ createdAt: Date;
781
+ updatedAt: Date;
782
+ deletedAt: Date | null;
783
+ }, {
784
+ id: string;
785
+ isPrimary: boolean;
786
+ email: string;
787
+ createdAt: Date;
788
+ updatedAt: Date;
789
+ deletedAt: Date | null;
790
+ }>, "many">;
791
+ contactPhones: z.ZodArray<z.ZodObject<{
792
+ id: z.ZodString;
793
+ createdAt: z.ZodDate;
794
+ updatedAt: z.ZodDate;
795
+ deletedAt: z.ZodNullable<z.ZodDate>;
796
+ phone: z.ZodString;
797
+ isPrimary: z.ZodBoolean;
798
+ }, "strip", z.ZodTypeAny, {
799
+ id: string;
800
+ isPrimary: boolean;
801
+ createdAt: Date;
802
+ updatedAt: Date;
803
+ deletedAt: Date | null;
804
+ phone: string;
805
+ }, {
806
+ id: string;
807
+ isPrimary: boolean;
808
+ createdAt: Date;
809
+ updatedAt: Date;
810
+ deletedAt: Date | null;
811
+ phone: string;
812
+ }>, "many">;
813
+ activityLogs: z.ZodOptional<z.ZodArray<z.ZodObject<{
814
+ id: z.ZodString;
815
+ createdAt: z.ZodDate;
816
+ updatedAt: z.ZodDate;
817
+ deletedAt: z.ZodNullable<z.ZodDate>;
818
+ entityId: z.ZodString;
819
+ description: z.ZodString;
820
+ entityType: z.ZodObject<{
821
+ id: z.ZodString;
822
+ createdAt: z.ZodDate;
823
+ updatedAt: z.ZodDate;
824
+ deletedAt: z.ZodNullable<z.ZodDate>;
825
+ entity: z.ZodString;
826
+ description: z.ZodNullable<z.ZodString>;
827
+ }, "strip", z.ZodTypeAny, {
828
+ id: string;
829
+ description: string | null;
830
+ createdAt: Date;
831
+ updatedAt: Date;
832
+ deletedAt: Date | null;
833
+ entity: string;
834
+ }, {
835
+ id: string;
836
+ description: string | null;
837
+ createdAt: Date;
838
+ updatedAt: Date;
839
+ deletedAt: Date | null;
840
+ entity: string;
841
+ }>;
842
+ }, "strip", z.ZodTypeAny, {
843
+ id: string;
844
+ description: string;
845
+ createdAt: Date;
846
+ updatedAt: Date;
847
+ deletedAt: Date | null;
848
+ entityId: string;
849
+ entityType: {
850
+ id: string;
851
+ description: string | null;
852
+ createdAt: Date;
853
+ updatedAt: Date;
854
+ deletedAt: Date | null;
855
+ entity: string;
856
+ };
857
+ }, {
858
+ id: string;
859
+ description: string;
860
+ createdAt: Date;
861
+ updatedAt: Date;
862
+ deletedAt: Date | null;
863
+ entityId: string;
864
+ entityType: {
865
+ id: string;
866
+ description: string | null;
867
+ createdAt: Date;
868
+ updatedAt: Date;
869
+ deletedAt: Date | null;
870
+ entity: string;
871
+ };
872
+ }>, "many">>;
873
+ }, "strip", z.ZodTypeAny, {
874
+ name: string;
875
+ id: string;
876
+ channel: string | null;
877
+ address: string | null;
878
+ createdAt: Date;
879
+ updatedAt: Date;
880
+ deletedAt: Date | null;
881
+ customFields: {
882
+ id: string;
883
+ createdAt: Date;
884
+ updatedAt: Date;
885
+ deletedAt: Date | null;
886
+ attribute: {
887
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
888
+ id: string;
889
+ position: number;
890
+ createdAt: Date;
891
+ updatedAt: Date;
892
+ deletedAt: Date | null;
893
+ systemName: string;
894
+ displayName: string;
895
+ isDefault: boolean;
896
+ isArchived: boolean;
897
+ isRequired: boolean;
898
+ isUnique: boolean;
899
+ };
900
+ textValue: string | null;
901
+ booleanValue: boolean | null;
902
+ numberValue: number | null;
903
+ dateValue: Date | null;
904
+ uploads: {
905
+ id: string;
906
+ status: string | null;
907
+ createdAt: Date;
908
+ updatedAt: Date;
909
+ deletedAt: Date | null;
910
+ fileName: string;
911
+ fileKey: string;
912
+ bucketName: string;
913
+ fileSize: number;
914
+ fileUrl: string | null;
915
+ }[];
916
+ }[];
917
+ company: {
918
+ id: string;
919
+ createdAt: Date;
920
+ updatedAt: Date;
921
+ deletedAt: Date | null;
922
+ name?: string | undefined;
923
+ address?: string | null | undefined;
924
+ phone?: string | null | undefined;
925
+ industry?: string | null | undefined;
926
+ } | null;
927
+ notes: string | null;
928
+ contactProfile: string | null;
929
+ socialProfileUrl: string | null;
930
+ tags: {
931
+ name: string;
932
+ id: string;
933
+ createdAt: Date;
934
+ updatedAt: Date;
935
+ deletedAt: Date | null;
936
+ }[];
937
+ contactEmails: {
938
+ id: string;
939
+ isPrimary: boolean;
940
+ email: string;
941
+ createdAt: Date;
942
+ updatedAt: Date;
943
+ deletedAt: Date | null;
944
+ }[];
945
+ contactPhones: {
946
+ id: string;
947
+ isPrimary: boolean;
948
+ createdAt: Date;
949
+ updatedAt: Date;
950
+ deletedAt: Date | null;
951
+ phone: string;
952
+ }[];
953
+ activityLogs?: {
954
+ id: string;
955
+ description: string;
956
+ createdAt: Date;
957
+ updatedAt: Date;
958
+ deletedAt: Date | null;
959
+ entityId: string;
960
+ entityType: {
961
+ id: string;
962
+ description: string | null;
963
+ createdAt: Date;
964
+ updatedAt: Date;
965
+ deletedAt: Date | null;
966
+ entity: string;
967
+ };
968
+ }[] | undefined;
969
+ }, {
970
+ name: string;
971
+ id: string;
972
+ channel: string | null;
973
+ address: string | null;
974
+ createdAt: Date;
975
+ updatedAt: Date;
976
+ deletedAt: Date | null;
977
+ customFields: {
978
+ id: string;
979
+ createdAt: Date;
980
+ updatedAt: Date;
981
+ deletedAt: Date | null;
982
+ attribute: {
983
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
984
+ id: string;
985
+ position: number;
986
+ createdAt: Date;
987
+ updatedAt: Date;
988
+ deletedAt: Date | null;
989
+ systemName: string;
990
+ displayName: string;
991
+ isDefault: boolean;
992
+ isArchived: boolean;
993
+ isRequired: boolean;
994
+ isUnique: boolean;
995
+ };
996
+ textValue: string | null;
997
+ booleanValue: boolean | null;
998
+ numberValue: number | null;
999
+ dateValue: Date | null;
1000
+ uploads: {
1001
+ id: string;
1002
+ status: string | null;
1003
+ createdAt: Date;
1004
+ updatedAt: Date;
1005
+ deletedAt: Date | null;
1006
+ fileName: string;
1007
+ fileKey: string;
1008
+ bucketName: string;
1009
+ fileSize: number;
1010
+ fileUrl: string | null;
1011
+ }[];
1012
+ }[];
1013
+ company: {
1014
+ id: string;
1015
+ createdAt: Date;
1016
+ updatedAt: Date;
1017
+ deletedAt: Date | null;
1018
+ name?: string | undefined;
1019
+ address?: string | null | undefined;
1020
+ phone?: string | null | undefined;
1021
+ industry?: string | null | undefined;
1022
+ } | null;
1023
+ notes: string | null;
1024
+ contactProfile: string | null;
1025
+ socialProfileUrl: string | null;
1026
+ tags: {
1027
+ name: string;
1028
+ id: string;
1029
+ createdAt: Date;
1030
+ updatedAt: Date;
1031
+ deletedAt: Date | null;
1032
+ }[];
1033
+ contactEmails: {
1034
+ id: string;
1035
+ isPrimary: boolean;
1036
+ email: string;
1037
+ createdAt: Date;
1038
+ updatedAt: Date;
1039
+ deletedAt: Date | null;
1040
+ }[];
1041
+ contactPhones: {
1042
+ id: string;
1043
+ isPrimary: boolean;
1044
+ createdAt: Date;
1045
+ updatedAt: Date;
1046
+ deletedAt: Date | null;
1047
+ phone: string;
1048
+ }[];
1049
+ activityLogs?: {
1050
+ id: string;
1051
+ description: string;
1052
+ createdAt: Date;
1053
+ updatedAt: Date;
1054
+ deletedAt: Date | null;
1055
+ entityId: string;
1056
+ entityType: {
1057
+ id: string;
1058
+ description: string | null;
1059
+ createdAt: Date;
1060
+ updatedAt: Date;
1061
+ deletedAt: Date | null;
1062
+ entity: string;
1063
+ };
1064
+ }[] | undefined;
1065
+ }>;
1066
+ }, "strip", z.ZodTypeAny, {
1067
+ data: {
1068
+ name: string;
1069
+ id: string;
1070
+ channel: string | null;
1071
+ address: string | null;
1072
+ createdAt: Date;
1073
+ updatedAt: Date;
1074
+ deletedAt: Date | null;
1075
+ customFields: {
1076
+ id: string;
1077
+ createdAt: Date;
1078
+ updatedAt: Date;
1079
+ deletedAt: Date | null;
1080
+ attribute: {
1081
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
1082
+ id: string;
1083
+ position: number;
1084
+ createdAt: Date;
1085
+ updatedAt: Date;
1086
+ deletedAt: Date | null;
1087
+ systemName: string;
1088
+ displayName: string;
1089
+ isDefault: boolean;
1090
+ isArchived: boolean;
1091
+ isRequired: boolean;
1092
+ isUnique: boolean;
1093
+ };
1094
+ textValue: string | null;
1095
+ booleanValue: boolean | null;
1096
+ numberValue: number | null;
1097
+ dateValue: Date | null;
1098
+ uploads: {
1099
+ id: string;
1100
+ status: string | null;
1101
+ createdAt: Date;
1102
+ updatedAt: Date;
1103
+ deletedAt: Date | null;
1104
+ fileName: string;
1105
+ fileKey: string;
1106
+ bucketName: string;
1107
+ fileSize: number;
1108
+ fileUrl: string | null;
1109
+ }[];
1110
+ }[];
1111
+ company: {
1112
+ id: string;
1113
+ createdAt: Date;
1114
+ updatedAt: Date;
1115
+ deletedAt: Date | null;
1116
+ name?: string | undefined;
1117
+ address?: string | null | undefined;
1118
+ phone?: string | null | undefined;
1119
+ industry?: string | null | undefined;
1120
+ } | null;
1121
+ notes: string | null;
1122
+ contactProfile: string | null;
1123
+ socialProfileUrl: string | null;
1124
+ tags: {
1125
+ name: string;
1126
+ id: string;
1127
+ createdAt: Date;
1128
+ updatedAt: Date;
1129
+ deletedAt: Date | null;
1130
+ }[];
1131
+ contactEmails: {
1132
+ id: string;
1133
+ isPrimary: boolean;
1134
+ email: string;
1135
+ createdAt: Date;
1136
+ updatedAt: Date;
1137
+ deletedAt: Date | null;
1138
+ }[];
1139
+ contactPhones: {
1140
+ id: string;
1141
+ isPrimary: boolean;
1142
+ createdAt: Date;
1143
+ updatedAt: Date;
1144
+ deletedAt: Date | null;
1145
+ phone: string;
1146
+ }[];
1147
+ activityLogs?: {
1148
+ id: string;
1149
+ description: string;
1150
+ createdAt: Date;
1151
+ updatedAt: Date;
1152
+ deletedAt: Date | null;
1153
+ entityId: string;
1154
+ entityType: {
1155
+ id: string;
1156
+ description: string | null;
1157
+ createdAt: Date;
1158
+ updatedAt: Date;
1159
+ deletedAt: Date | null;
1160
+ entity: string;
1161
+ };
1162
+ }[] | undefined;
1163
+ };
1164
+ requestId: string;
1165
+ }, {
1166
+ data: {
1167
+ name: string;
1168
+ id: string;
1169
+ channel: string | null;
1170
+ address: string | null;
1171
+ createdAt: Date;
1172
+ updatedAt: Date;
1173
+ deletedAt: Date | null;
1174
+ customFields: {
1175
+ id: string;
1176
+ createdAt: Date;
1177
+ updatedAt: Date;
1178
+ deletedAt: Date | null;
1179
+ attribute: {
1180
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
1181
+ id: string;
1182
+ position: number;
1183
+ createdAt: Date;
1184
+ updatedAt: Date;
1185
+ deletedAt: Date | null;
1186
+ systemName: string;
1187
+ displayName: string;
1188
+ isDefault: boolean;
1189
+ isArchived: boolean;
1190
+ isRequired: boolean;
1191
+ isUnique: boolean;
1192
+ };
1193
+ textValue: string | null;
1194
+ booleanValue: boolean | null;
1195
+ numberValue: number | null;
1196
+ dateValue: Date | null;
1197
+ uploads: {
1198
+ id: string;
1199
+ status: string | null;
1200
+ createdAt: Date;
1201
+ updatedAt: Date;
1202
+ deletedAt: Date | null;
1203
+ fileName: string;
1204
+ fileKey: string;
1205
+ bucketName: string;
1206
+ fileSize: number;
1207
+ fileUrl: string | null;
1208
+ }[];
1209
+ }[];
1210
+ company: {
1211
+ id: string;
1212
+ createdAt: Date;
1213
+ updatedAt: Date;
1214
+ deletedAt: Date | null;
1215
+ name?: string | undefined;
1216
+ address?: string | null | undefined;
1217
+ phone?: string | null | undefined;
1218
+ industry?: string | null | undefined;
1219
+ } | null;
1220
+ notes: string | null;
1221
+ contactProfile: string | null;
1222
+ socialProfileUrl: string | null;
1223
+ tags: {
1224
+ name: string;
1225
+ id: string;
1226
+ createdAt: Date;
1227
+ updatedAt: Date;
1228
+ deletedAt: Date | null;
1229
+ }[];
1230
+ contactEmails: {
1231
+ id: string;
1232
+ isPrimary: boolean;
1233
+ email: string;
1234
+ createdAt: Date;
1235
+ updatedAt: Date;
1236
+ deletedAt: Date | null;
1237
+ }[];
1238
+ contactPhones: {
1239
+ id: string;
1240
+ isPrimary: boolean;
1241
+ createdAt: Date;
1242
+ updatedAt: Date;
1243
+ deletedAt: Date | null;
1244
+ phone: string;
1245
+ }[];
1246
+ activityLogs?: {
1247
+ id: string;
1248
+ description: string;
1249
+ createdAt: Date;
1250
+ updatedAt: Date;
1251
+ deletedAt: Date | null;
1252
+ entityId: string;
1253
+ entityType: {
1254
+ id: string;
1255
+ description: string | null;
1256
+ createdAt: Date;
1257
+ updatedAt: Date;
1258
+ deletedAt: Date | null;
1259
+ entity: string;
1260
+ };
1261
+ }[] | undefined;
1262
+ };
1263
+ requestId: string;
1264
+ }>;
1265
+ 400: z.ZodObject<{
1266
+ message: z.ZodString;
21
1267
  }, "strip", z.ZodTypeAny, {
22
- isPrimary: boolean;
23
- email: string;
1268
+ message: string;
24
1269
  }, {
25
- isPrimary: boolean;
26
- email: string;
27
- }>, "many">>;
28
- channel: z.ZodOptional<z.ZodString>;
1270
+ message: string;
1271
+ }>;
1272
+ 409: z.ZodObject<{
1273
+ message: z.ZodString;
1274
+ }, "strip", z.ZodTypeAny, {
1275
+ message: string;
1276
+ }, {
1277
+ message: string;
1278
+ }>;
1279
+ 401: z.ZodObject<{
1280
+ message: z.ZodString;
1281
+ error: z.ZodAny;
1282
+ }, "strip", z.ZodTypeAny, {
1283
+ message: string;
1284
+ error?: any;
1285
+ }, {
1286
+ message: string;
1287
+ error?: any;
1288
+ }>;
1289
+ 404: z.ZodObject<{
1290
+ message: z.ZodString;
1291
+ error: z.ZodAny;
1292
+ }, "strip", z.ZodTypeAny, {
1293
+ message: string;
1294
+ error?: any;
1295
+ }, {
1296
+ message: string;
1297
+ error?: any;
1298
+ }>;
1299
+ 422: z.ZodObject<{
1300
+ message: z.ZodString;
1301
+ error: z.ZodAny;
1302
+ }, "strip", z.ZodTypeAny, {
1303
+ message: string;
1304
+ error?: any;
1305
+ }, {
1306
+ message: string;
1307
+ error?: any;
1308
+ }>;
1309
+ 500: z.ZodObject<{
1310
+ message: z.ZodString;
1311
+ error: z.ZodAny;
1312
+ }, "strip", z.ZodTypeAny, {
1313
+ message: string;
1314
+ error?: any;
1315
+ }, {
1316
+ message: string;
1317
+ error?: any;
1318
+ }>;
1319
+ };
1320
+ path: "api/v1/contacts";
1321
+ };
1322
+ getAllContact: {
1323
+ summary: "Get all contacts";
1324
+ method: "GET";
1325
+ query: z.ZodObject<{
1326
+ page: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
1327
+ pageSize: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
1328
+ keyword: z.ZodOptional<z.ZodOptional<z.ZodString>>;
1329
+ company: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1330
+ name: z.ZodOptional<z.ZodString>;
29
1331
  address: z.ZodOptional<z.ZodString>;
30
- phone: z.ZodOptional<z.ZodArray<z.ZodObject<{
31
- phone: z.ZodString;
32
- isPrimary: z.ZodBoolean;
1332
+ channel: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1333
+ selectedDate: z.ZodOptional<z.ZodString>;
1334
+ customFields: z.ZodOptional<z.ZodArray<z.ZodObject<{
1335
+ attributeId: z.ZodString;
1336
+ type: z.ZodString;
1337
+ value: z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>;
33
1338
  }, "strip", z.ZodTypeAny, {
34
- isPrimary: boolean;
35
- phone: string;
1339
+ type: string;
1340
+ value: (string | string[]) & (string | string[] | undefined);
1341
+ attributeId: string;
36
1342
  }, {
37
- isPrimary: boolean;
38
- phone: string;
1343
+ type: string;
1344
+ value: (string | string[]) & (string | string[] | undefined);
1345
+ attributeId: string;
39
1346
  }>, "many">>;
40
- notes: z.ZodOptional<z.ZodString>;
41
1347
  tags: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
42
- company: z.ZodOptional<z.ZodString>;
43
- customFields: z.ZodRecord<z.ZodString, z.ZodString>;
1348
+ phone: z.ZodOptional<z.ZodString>;
1349
+ email: z.ZodOptional<z.ZodString>;
1350
+ notes: z.ZodOptional<z.ZodString>;
44
1351
  }, "strip", z.ZodTypeAny, {
45
- name: string;
46
- customFields: Record<string, string>;
47
- email?: {
48
- isPrimary: boolean;
49
- email: string;
50
- }[] | undefined;
51
- channel?: string | undefined;
1352
+ page?: number | undefined;
1353
+ pageSize?: number | undefined;
1354
+ keyword?: string | undefined;
1355
+ company?: string[] | undefined;
1356
+ name?: string | undefined;
52
1357
  address?: string | undefined;
53
- phone?: {
54
- isPrimary: boolean;
55
- phone: string;
1358
+ channel?: string[] | undefined;
1359
+ selectedDate?: string | undefined;
1360
+ customFields?: {
1361
+ type: string;
1362
+ value: (string | string[]) & (string | string[] | undefined);
1363
+ attributeId: string;
56
1364
  }[] | undefined;
57
- notes?: string | undefined;
58
1365
  tags?: string[] | undefined;
59
- company?: string | undefined;
1366
+ phone?: string | undefined;
1367
+ email?: string | undefined;
1368
+ notes?: string | undefined;
60
1369
  }, {
61
- name: string;
62
- customFields: Record<string, string>;
63
- email?: {
64
- isPrimary: boolean;
65
- email: string;
66
- }[] | undefined;
67
- channel?: string | undefined;
1370
+ page?: number | undefined;
1371
+ pageSize?: number | undefined;
1372
+ keyword?: string | undefined;
1373
+ company?: string[] | undefined;
1374
+ name?: string | undefined;
68
1375
  address?: string | undefined;
69
- phone?: {
70
- isPrimary: boolean;
71
- phone: string;
1376
+ channel?: string[] | undefined;
1377
+ selectedDate?: string | undefined;
1378
+ customFields?: {
1379
+ type: string;
1380
+ value: (string | string[]) & (string | string[] | undefined);
1381
+ attributeId: string;
72
1382
  }[] | undefined;
73
- notes?: string | undefined;
74
1383
  tags?: string[] | undefined;
75
- company?: string | undefined;
1384
+ phone?: string | undefined;
1385
+ email?: string | undefined;
1386
+ notes?: string | undefined;
76
1387
  }>;
77
- summary: "Create a new contact";
78
- method: "POST";
79
1388
  responses: {
80
- 201: z.ZodObject<{
1389
+ 200: z.ZodObject<{
81
1390
  requestId: z.ZodString;
82
- data: z.ZodObject<{
1391
+ page: z.ZodNumber;
1392
+ pageSize: z.ZodNumber;
1393
+ total: z.ZodNumber;
1394
+ lastPage: z.ZodNumber;
1395
+ data: z.ZodArray<z.ZodObject<{
83
1396
  id: z.ZodString;
84
1397
  createdAt: z.ZodDate;
85
1398
  updatedAt: z.ZodDate;
@@ -765,7 +2078,7 @@ export declare const publicApiContract: {
765
2078
  entity: string;
766
2079
  };
767
2080
  }[] | undefined;
768
- }>;
2081
+ }>, "many">;
769
2082
  }, "strip", z.ZodTypeAny, {
770
2083
  data: {
771
2084
  name: string;
@@ -862,218 +2175,116 @@ export declare const publicApiContract: {
862
2175
  deletedAt: Date | null;
863
2176
  entity: string;
864
2177
  };
865
- }[] | undefined;
866
- };
867
- requestId: string;
868
- }, {
869
- data: {
870
- name: string;
871
- id: string;
872
- channel: string | null;
873
- address: string | null;
874
- createdAt: Date;
875
- updatedAt: Date;
876
- deletedAt: Date | null;
877
- customFields: {
878
- id: string;
879
- createdAt: Date;
880
- updatedAt: Date;
881
- deletedAt: Date | null;
882
- attribute: {
883
- type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
884
- id: string;
885
- position: number;
886
- createdAt: Date;
887
- updatedAt: Date;
888
- deletedAt: Date | null;
889
- systemName: string;
890
- displayName: string;
891
- isDefault: boolean;
892
- isArchived: boolean;
893
- isRequired: boolean;
894
- isUnique: boolean;
895
- };
896
- textValue: string | null;
897
- booleanValue: boolean | null;
898
- numberValue: number | null;
899
- dateValue: Date | null;
900
- uploads: {
901
- id: string;
902
- status: string | null;
903
- createdAt: Date;
904
- updatedAt: Date;
905
- deletedAt: Date | null;
906
- fileName: string;
907
- fileKey: string;
908
- bucketName: string;
909
- fileSize: number;
910
- fileUrl: string | null;
911
- }[];
912
- }[];
913
- company: {
914
- id: string;
915
- createdAt: Date;
916
- updatedAt: Date;
917
- deletedAt: Date | null;
918
- name?: string | undefined;
919
- address?: string | null | undefined;
920
- phone?: string | null | undefined;
921
- industry?: string | null | undefined;
922
- } | null;
923
- notes: string | null;
924
- contactProfile: string | null;
925
- socialProfileUrl: string | null;
926
- tags: {
927
- name: string;
928
- id: string;
929
- createdAt: Date;
930
- updatedAt: Date;
931
- deletedAt: Date | null;
932
- }[];
933
- contactEmails: {
934
- id: string;
935
- isPrimary: boolean;
936
- email: string;
937
- createdAt: Date;
938
- updatedAt: Date;
939
- deletedAt: Date | null;
940
- }[];
941
- contactPhones: {
942
- id: string;
943
- isPrimary: boolean;
944
- createdAt: Date;
945
- updatedAt: Date;
946
- deletedAt: Date | null;
947
- phone: string;
948
- }[];
949
- activityLogs?: {
950
- id: string;
951
- description: string;
952
- createdAt: Date;
953
- updatedAt: Date;
954
- deletedAt: Date | null;
955
- entityId: string;
956
- entityType: {
957
- id: string;
958
- description: string | null;
959
- createdAt: Date;
960
- updatedAt: Date;
961
- deletedAt: Date | null;
962
- entity: string;
963
- };
964
- }[] | undefined;
965
- };
966
- requestId: string;
967
- }>;
968
- 400: z.ZodObject<{
969
- message: z.ZodString;
970
- }, "strip", z.ZodTypeAny, {
971
- message: string;
972
- }, {
973
- message: string;
974
- }>;
975
- 409: z.ZodObject<{
976
- message: z.ZodString;
977
- }, "strip", z.ZodTypeAny, {
978
- message: string;
979
- }, {
980
- message: string;
981
- }>;
982
- 401: z.ZodObject<{
983
- message: z.ZodString;
984
- error: z.ZodAny;
985
- }, "strip", z.ZodTypeAny, {
986
- message: string;
987
- error?: any;
988
- }, {
989
- message: string;
990
- error?: any;
991
- }>;
992
- 404: z.ZodObject<{
993
- message: z.ZodString;
994
- error: z.ZodAny;
995
- }, "strip", z.ZodTypeAny, {
996
- message: string;
997
- error?: any;
998
- }, {
999
- message: string;
1000
- error?: any;
1001
- }>;
1002
- 422: z.ZodObject<{
1003
- message: z.ZodString;
1004
- error: z.ZodAny;
1005
- }, "strip", z.ZodTypeAny, {
1006
- message: string;
1007
- error?: any;
1008
- }, {
1009
- message: string;
1010
- error?: any;
1011
- }>;
1012
- 500: z.ZodObject<{
1013
- message: z.ZodString;
1014
- error: z.ZodAny;
1015
- }, "strip", z.ZodTypeAny, {
1016
- message: string;
1017
- error?: any;
1018
- }, {
1019
- message: string;
1020
- error?: any;
1021
- }>;
1022
- };
1023
- path: "api/v1/contacts";
1024
- };
1025
- getAllTags: {
1026
- method: "GET";
1027
- query: z.ZodOptional<z.ZodObject<{
1028
- group: z.ZodOptional<z.ZodDefault<z.ZodUnion<[z.ZodLiteral<"general">, z.ZodLiteral<"contact">]>>>;
1029
- keyword: z.ZodOptional<z.ZodString>;
1030
- }, "strip", z.ZodTypeAny, {
1031
- group?: "general" | "contact" | undefined;
1032
- keyword?: string | undefined;
1033
- }, {
1034
- group?: "general" | "contact" | undefined;
1035
- keyword?: string | undefined;
1036
- }>>;
1037
- responses: {
1038
- 200: z.ZodObject<{
1039
- requestId: z.ZodString;
1040
- tags: z.ZodArray<z.ZodObject<{
1041
- id: z.ZodString;
1042
- createdAt: z.ZodDate;
1043
- updatedAt: z.ZodDate;
1044
- deletedAt: z.ZodNullable<z.ZodDate>;
1045
- name: z.ZodString;
1046
- }, "strip", z.ZodTypeAny, {
1047
- name: string;
1048
- id: string;
1049
- createdAt: Date;
1050
- updatedAt: Date;
1051
- deletedAt: Date | null;
1052
- }, {
1053
- name: string;
1054
- id: string;
1055
- createdAt: Date;
1056
- updatedAt: Date;
1057
- deletedAt: Date | null;
1058
- }>, "many">;
1059
- }, "strip", z.ZodTypeAny, {
1060
- requestId: string;
1061
- tags: {
1062
- name: string;
1063
- id: string;
1064
- createdAt: Date;
1065
- updatedAt: Date;
1066
- deletedAt: Date | null;
2178
+ }[] | undefined;
1067
2179
  }[];
1068
- }, {
2180
+ total: number;
2181
+ page: number;
2182
+ pageSize: number;
2183
+ lastPage: number;
1069
2184
  requestId: string;
1070
- tags: {
2185
+ }, {
2186
+ data: {
1071
2187
  name: string;
1072
2188
  id: string;
2189
+ channel: string | null;
2190
+ address: string | null;
1073
2191
  createdAt: Date;
1074
2192
  updatedAt: Date;
1075
2193
  deletedAt: Date | null;
2194
+ customFields: {
2195
+ id: string;
2196
+ createdAt: Date;
2197
+ updatedAt: Date;
2198
+ deletedAt: Date | null;
2199
+ attribute: {
2200
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
2201
+ id: string;
2202
+ position: number;
2203
+ createdAt: Date;
2204
+ updatedAt: Date;
2205
+ deletedAt: Date | null;
2206
+ systemName: string;
2207
+ displayName: string;
2208
+ isDefault: boolean;
2209
+ isArchived: boolean;
2210
+ isRequired: boolean;
2211
+ isUnique: boolean;
2212
+ };
2213
+ textValue: string | null;
2214
+ booleanValue: boolean | null;
2215
+ numberValue: number | null;
2216
+ dateValue: Date | null;
2217
+ uploads: {
2218
+ id: string;
2219
+ status: string | null;
2220
+ createdAt: Date;
2221
+ updatedAt: Date;
2222
+ deletedAt: Date | null;
2223
+ fileName: string;
2224
+ fileKey: string;
2225
+ bucketName: string;
2226
+ fileSize: number;
2227
+ fileUrl: string | null;
2228
+ }[];
2229
+ }[];
2230
+ company: {
2231
+ id: string;
2232
+ createdAt: Date;
2233
+ updatedAt: Date;
2234
+ deletedAt: Date | null;
2235
+ name?: string | undefined;
2236
+ address?: string | null | undefined;
2237
+ phone?: string | null | undefined;
2238
+ industry?: string | null | undefined;
2239
+ } | null;
2240
+ notes: string | null;
2241
+ contactProfile: string | null;
2242
+ socialProfileUrl: string | null;
2243
+ tags: {
2244
+ name: string;
2245
+ id: string;
2246
+ createdAt: Date;
2247
+ updatedAt: Date;
2248
+ deletedAt: Date | null;
2249
+ }[];
2250
+ contactEmails: {
2251
+ id: string;
2252
+ isPrimary: boolean;
2253
+ email: string;
2254
+ createdAt: Date;
2255
+ updatedAt: Date;
2256
+ deletedAt: Date | null;
2257
+ }[];
2258
+ contactPhones: {
2259
+ id: string;
2260
+ isPrimary: boolean;
2261
+ createdAt: Date;
2262
+ updatedAt: Date;
2263
+ deletedAt: Date | null;
2264
+ phone: string;
2265
+ }[];
2266
+ activityLogs?: {
2267
+ id: string;
2268
+ description: string;
2269
+ createdAt: Date;
2270
+ updatedAt: Date;
2271
+ deletedAt: Date | null;
2272
+ entityId: string;
2273
+ entityType: {
2274
+ id: string;
2275
+ description: string | null;
2276
+ createdAt: Date;
2277
+ updatedAt: Date;
2278
+ deletedAt: Date | null;
2279
+ entity: string;
2280
+ };
2281
+ }[] | undefined;
1076
2282
  }[];
2283
+ total: number;
2284
+ page: number;
2285
+ pageSize: number;
2286
+ lastPage: number;
2287
+ requestId: string;
1077
2288
  }>;
1078
2289
  400: z.ZodObject<{
1079
2290
  message: z.ZodString;
@@ -1130,81 +2341,25 @@ export declare const publicApiContract: {
1130
2341
  error?: any;
1131
2342
  }>;
1132
2343
  };
1133
- path: "api/v1/tags";
2344
+ path: "api/v1/contacts";
1134
2345
  };
1135
- getAllContact: {
1136
- summary: "Get all contacts";
2346
+ getContactBySocialPlatformId: {
2347
+ summary: "Get contacts by social platform id.";
1137
2348
  method: "GET";
1138
2349
  query: z.ZodObject<{
1139
- page: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
1140
- pageSize: z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
1141
- keyword: z.ZodOptional<z.ZodOptional<z.ZodString>>;
1142
- company: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1143
- name: z.ZodOptional<z.ZodString>;
1144
- address: z.ZodOptional<z.ZodString>;
1145
- channel: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1146
- selectedDate: z.ZodOptional<z.ZodString>;
1147
- customFields: z.ZodOptional<z.ZodArray<z.ZodObject<{
1148
- attributeId: z.ZodString;
1149
- type: z.ZodString;
1150
- value: z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>;
1151
- }, "strip", z.ZodTypeAny, {
1152
- type: string;
1153
- value: (string | string[]) & (string | string[] | undefined);
1154
- attributeId: string;
1155
- }, {
1156
- type: string;
1157
- value: (string | string[]) & (string | string[] | undefined);
1158
- attributeId: string;
1159
- }>, "many">>;
1160
- tags: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1161
- phone: z.ZodOptional<z.ZodString>;
1162
- email: z.ZodOptional<z.ZodString>;
1163
- notes: z.ZodOptional<z.ZodString>;
2350
+ socialPlatformId: z.ZodString;
2351
+ channelType: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"whatsapp">, z.ZodLiteral<"messenger">, z.ZodLiteral<"telegram">, z.ZodLiteral<"instagram">, z.ZodLiteral<"line">, z.ZodLiteral<"viber">, z.ZodLiteral<"kakao">, z.ZodLiteral<"shopee">, z.ZodLiteral<"lazada">, z.ZodLiteral<"webchat">, z.ZodLiteral<"facebook_feed">, z.ZodLiteral<"sms_vonage">]>>;
1164
2352
  }, "strip", z.ZodTypeAny, {
1165
- page?: number | undefined;
1166
- pageSize?: number | undefined;
1167
- keyword?: string | undefined;
1168
- company?: string[] | undefined;
1169
- name?: string | undefined;
1170
- address?: string | undefined;
1171
- channel?: string[] | undefined;
1172
- selectedDate?: string | undefined;
1173
- customFields?: {
1174
- type: string;
1175
- value: (string | string[]) & (string | string[] | undefined);
1176
- attributeId: string;
1177
- }[] | undefined;
1178
- tags?: string[] | undefined;
1179
- phone?: string | undefined;
1180
- email?: string | undefined;
1181
- notes?: string | undefined;
2353
+ socialPlatformId: string;
2354
+ channelType?: "line" | "whatsapp" | "messenger" | "telegram" | "instagram" | "viber" | "kakao" | "shopee" | "lazada" | "webchat" | "facebook_feed" | "sms_vonage" | undefined;
1182
2355
  }, {
1183
- page?: number | undefined;
1184
- pageSize?: number | undefined;
1185
- keyword?: string | undefined;
1186
- company?: string[] | undefined;
1187
- name?: string | undefined;
1188
- address?: string | undefined;
1189
- channel?: string[] | undefined;
1190
- selectedDate?: string | undefined;
1191
- customFields?: {
1192
- type: string;
1193
- value: (string | string[]) & (string | string[] | undefined);
1194
- attributeId: string;
1195
- }[] | undefined;
1196
- tags?: string[] | undefined;
1197
- phone?: string | undefined;
1198
- email?: string | undefined;
1199
- notes?: string | undefined;
2356
+ socialPlatformId: string;
2357
+ channelType?: "line" | "whatsapp" | "messenger" | "telegram" | "instagram" | "viber" | "kakao" | "shopee" | "lazada" | "webchat" | "facebook_feed" | "sms_vonage" | undefined;
1200
2358
  }>;
1201
2359
  responses: {
1202
2360
  200: z.ZodObject<{
1203
- requestId: z.ZodString;
1204
- page: z.ZodNumber;
1205
- pageSize: z.ZodNumber;
1206
- total: z.ZodNumber;
1207
- lastPage: z.ZodNumber;
2361
+ status: z.ZodString;
2362
+ message: z.ZodString;
1208
2363
  data: z.ZodArray<z.ZodObject<{
1209
2364
  id: z.ZodString;
1210
2365
  createdAt: z.ZodDate;
@@ -1892,6 +3047,7 @@ export declare const publicApiContract: {
1892
3047
  };
1893
3048
  }[] | undefined;
1894
3049
  }>, "many">;
3050
+ requestId: z.ZodString;
1895
3051
  }, "strip", z.ZodTypeAny, {
1896
3052
  data: {
1897
3053
  name: string;
@@ -1990,10 +3146,8 @@ export declare const publicApiContract: {
1990
3146
  };
1991
3147
  }[] | undefined;
1992
3148
  }[];
1993
- total: number;
1994
- page: number;
1995
- pageSize: number;
1996
- lastPage: number;
3149
+ message: string;
3150
+ status: string;
1997
3151
  requestId: string;
1998
3152
  }, {
1999
3153
  data: {
@@ -2093,10 +3247,8 @@ export declare const publicApiContract: {
2093
3247
  };
2094
3248
  }[] | undefined;
2095
3249
  }[];
2096
- total: number;
2097
- page: number;
2098
- pageSize: number;
2099
- lastPage: number;
3250
+ message: string;
3251
+ status: string;
2100
3252
  requestId: string;
2101
3253
  }>;
2102
3254
  400: z.ZodObject<{
@@ -2154,7 +3306,7 @@ export declare const publicApiContract: {
2154
3306
  error?: any;
2155
3307
  }>;
2156
3308
  };
2157
- path: "api/v1/contacts";
3309
+ path: "api/v1/contacts/social-platform";
2158
3310
  };
2159
3311
  getContactFields: {
2160
3312
  summary: "Get contact custom fields.";
@@ -2509,74 +3661,13 @@ export declare const publicApiContract: {
2509
3661
  }, {
2510
3662
  message: string;
2511
3663
  error?: any;
2512
- }>;
2513
- };
2514
- path: "api/v1/contacts/fields";
2515
- };
2516
- updateContact: {
2517
- body: z.ZodObject<{
2518
- name: z.ZodOptional<z.ZodString>;
2519
- email: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodObject<{
2520
- email: z.ZodString;
2521
- isPrimary: z.ZodBoolean;
2522
- }, "strip", z.ZodTypeAny, {
2523
- isPrimary: boolean;
2524
- email: string;
2525
- }, {
2526
- isPrimary: boolean;
2527
- email: string;
2528
- }>, "many">>>;
2529
- channel: z.ZodOptional<z.ZodOptional<z.ZodString>>;
2530
- address: z.ZodOptional<z.ZodOptional<z.ZodString>>;
2531
- phone: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodObject<{
2532
- phone: z.ZodString;
2533
- isPrimary: z.ZodBoolean;
2534
- }, "strip", z.ZodTypeAny, {
2535
- isPrimary: boolean;
2536
- phone: string;
2537
- }, {
2538
- isPrimary: boolean;
2539
- phone: string;
2540
- }>, "many">>>;
2541
- notes: z.ZodOptional<z.ZodOptional<z.ZodString>>;
2542
- tags: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodString, "many">>>;
2543
- company: z.ZodOptional<z.ZodOptional<z.ZodString>>;
2544
- customFields: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
2545
- }, "strip", z.ZodTypeAny, {
2546
- name?: string | undefined;
2547
- email?: {
2548
- isPrimary: boolean;
2549
- email: string;
2550
- }[] | undefined;
2551
- channel?: string | undefined;
2552
- address?: string | undefined;
2553
- phone?: {
2554
- isPrimary: boolean;
2555
- phone: string;
2556
- }[] | undefined;
2557
- notes?: string | undefined;
2558
- tags?: string[] | undefined;
2559
- company?: string | undefined;
2560
- customFields?: Record<string, string> | undefined;
2561
- }, {
2562
- name?: string | undefined;
2563
- email?: {
2564
- isPrimary: boolean;
2565
- email: string;
2566
- }[] | undefined;
2567
- channel?: string | undefined;
2568
- address?: string | undefined;
2569
- phone?: {
2570
- isPrimary: boolean;
2571
- phone: string;
2572
- }[] | undefined;
2573
- notes?: string | undefined;
2574
- tags?: string[] | undefined;
2575
- company?: string | undefined;
2576
- customFields?: Record<string, string> | undefined;
2577
- }>;
2578
- summary: "Update a contact";
2579
- method: "PATCH";
3664
+ }>;
3665
+ };
3666
+ path: "api/v1/contacts/fields";
3667
+ };
3668
+ getContactById: {
3669
+ summary: "Get a contact by id";
3670
+ method: "GET";
2580
3671
  pathParams: z.ZodObject<{
2581
3672
  id: z.ZodString;
2582
3673
  }, "strip", z.ZodTypeAny, {
@@ -2992,273 +4083,66 @@ export declare const publicApiContract: {
2992
4083
  createdAt: Date;
2993
4084
  updatedAt: Date;
2994
4085
  deletedAt: Date | null;
2995
- }, {
2996
- id: string;
2997
- isPrimary: boolean;
2998
- email: string;
2999
- createdAt: Date;
3000
- updatedAt: Date;
3001
- deletedAt: Date | null;
3002
- }>, "many">;
3003
- contactPhones: z.ZodArray<z.ZodObject<{
3004
- id: z.ZodString;
3005
- createdAt: z.ZodDate;
3006
- updatedAt: z.ZodDate;
3007
- deletedAt: z.ZodNullable<z.ZodDate>;
3008
- phone: z.ZodString;
3009
- isPrimary: z.ZodBoolean;
3010
- }, "strip", z.ZodTypeAny, {
3011
- id: string;
3012
- isPrimary: boolean;
3013
- createdAt: Date;
3014
- updatedAt: Date;
3015
- deletedAt: Date | null;
3016
- phone: string;
3017
- }, {
3018
- id: string;
3019
- isPrimary: boolean;
3020
- createdAt: Date;
3021
- updatedAt: Date;
3022
- deletedAt: Date | null;
3023
- phone: string;
3024
- }>, "many">;
3025
- activityLogs: z.ZodOptional<z.ZodArray<z.ZodObject<{
3026
- id: z.ZodString;
3027
- createdAt: z.ZodDate;
3028
- updatedAt: z.ZodDate;
3029
- deletedAt: z.ZodNullable<z.ZodDate>;
3030
- entityId: z.ZodString;
3031
- description: z.ZodString;
3032
- entityType: z.ZodObject<{
3033
- id: z.ZodString;
3034
- createdAt: z.ZodDate;
3035
- updatedAt: z.ZodDate;
3036
- deletedAt: z.ZodNullable<z.ZodDate>;
3037
- entity: z.ZodString;
3038
- description: z.ZodNullable<z.ZodString>;
3039
- }, "strip", z.ZodTypeAny, {
3040
- id: string;
3041
- description: string | null;
3042
- createdAt: Date;
3043
- updatedAt: Date;
3044
- deletedAt: Date | null;
3045
- entity: string;
3046
- }, {
3047
- id: string;
3048
- description: string | null;
3049
- createdAt: Date;
3050
- updatedAt: Date;
3051
- deletedAt: Date | null;
3052
- entity: string;
3053
- }>;
3054
- }, "strip", z.ZodTypeAny, {
3055
- id: string;
3056
- description: string;
3057
- createdAt: Date;
3058
- updatedAt: Date;
3059
- deletedAt: Date | null;
3060
- entityId: string;
3061
- entityType: {
3062
- id: string;
3063
- description: string | null;
3064
- createdAt: Date;
3065
- updatedAt: Date;
3066
- deletedAt: Date | null;
3067
- entity: string;
3068
- };
3069
- }, {
3070
- id: string;
3071
- description: string;
3072
- createdAt: Date;
3073
- updatedAt: Date;
3074
- deletedAt: Date | null;
3075
- entityId: string;
3076
- entityType: {
3077
- id: string;
3078
- description: string | null;
3079
- createdAt: Date;
3080
- updatedAt: Date;
3081
- deletedAt: Date | null;
3082
- entity: string;
3083
- };
3084
- }>, "many">>;
3085
- }, "strip", z.ZodTypeAny, {
3086
- name: string;
3087
- id: string;
3088
- channel: string | null;
3089
- address: string | null;
3090
- createdAt: Date;
3091
- updatedAt: Date;
3092
- deletedAt: Date | null;
3093
- customFields: {
3094
- id: string;
3095
- createdAt: Date;
3096
- updatedAt: Date;
3097
- deletedAt: Date | null;
3098
- attribute: {
3099
- type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
3100
- id: string;
3101
- position: number;
3102
- createdAt: Date;
3103
- updatedAt: Date;
3104
- deletedAt: Date | null;
3105
- systemName: string;
3106
- displayName: string;
3107
- isDefault: boolean;
3108
- isArchived: boolean;
3109
- isRequired: boolean;
3110
- isUnique: boolean;
3111
- };
3112
- textValue: string | null;
3113
- booleanValue: boolean | null;
3114
- numberValue: number | null;
3115
- dateValue: Date | null;
3116
- uploads: {
3117
- id: string;
3118
- status: string | null;
3119
- createdAt: Date;
3120
- updatedAt: Date;
3121
- deletedAt: Date | null;
3122
- fileName: string;
3123
- fileKey: string;
3124
- bucketName: string;
3125
- fileSize: number;
3126
- fileUrl: string | null;
3127
- }[];
3128
- }[];
3129
- company: {
3130
- id: string;
3131
- createdAt: Date;
3132
- updatedAt: Date;
3133
- deletedAt: Date | null;
3134
- name?: string | undefined;
3135
- address?: string | null | undefined;
3136
- phone?: string | null | undefined;
3137
- industry?: string | null | undefined;
3138
- } | null;
3139
- notes: string | null;
3140
- contactProfile: string | null;
3141
- socialProfileUrl: string | null;
3142
- tags: {
3143
- name: string;
3144
- id: string;
3145
- createdAt: Date;
3146
- updatedAt: Date;
3147
- deletedAt: Date | null;
3148
- }[];
3149
- contactEmails: {
3150
- id: string;
3151
- isPrimary: boolean;
3152
- email: string;
3153
- createdAt: Date;
3154
- updatedAt: Date;
3155
- deletedAt: Date | null;
3156
- }[];
3157
- contactPhones: {
3158
- id: string;
3159
- isPrimary: boolean;
3160
- createdAt: Date;
3161
- updatedAt: Date;
3162
- deletedAt: Date | null;
3163
- phone: string;
3164
- }[];
3165
- activityLogs?: {
3166
- id: string;
3167
- description: string;
3168
- createdAt: Date;
3169
- updatedAt: Date;
3170
- deletedAt: Date | null;
3171
- entityId: string;
3172
- entityType: {
3173
- id: string;
3174
- description: string | null;
3175
- createdAt: Date;
3176
- updatedAt: Date;
3177
- deletedAt: Date | null;
3178
- entity: string;
3179
- };
3180
- }[] | undefined;
3181
- }, {
3182
- name: string;
3183
- id: string;
3184
- channel: string | null;
3185
- address: string | null;
3186
- createdAt: Date;
3187
- updatedAt: Date;
3188
- deletedAt: Date | null;
3189
- customFields: {
3190
- id: string;
3191
- createdAt: Date;
3192
- updatedAt: Date;
3193
- deletedAt: Date | null;
3194
- attribute: {
3195
- type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
3196
- id: string;
3197
- position: number;
3198
- createdAt: Date;
3199
- updatedAt: Date;
3200
- deletedAt: Date | null;
3201
- systemName: string;
3202
- displayName: string;
3203
- isDefault: boolean;
3204
- isArchived: boolean;
3205
- isRequired: boolean;
3206
- isUnique: boolean;
3207
- };
3208
- textValue: string | null;
3209
- booleanValue: boolean | null;
3210
- numberValue: number | null;
3211
- dateValue: Date | null;
3212
- uploads: {
3213
- id: string;
3214
- status: string | null;
3215
- createdAt: Date;
3216
- updatedAt: Date;
3217
- deletedAt: Date | null;
3218
- fileName: string;
3219
- fileKey: string;
3220
- bucketName: string;
3221
- fileSize: number;
3222
- fileUrl: string | null;
3223
- }[];
3224
- }[];
3225
- company: {
3226
- id: string;
3227
- createdAt: Date;
3228
- updatedAt: Date;
3229
- deletedAt: Date | null;
3230
- name?: string | undefined;
3231
- address?: string | null | undefined;
3232
- phone?: string | null | undefined;
3233
- industry?: string | null | undefined;
3234
- } | null;
3235
- notes: string | null;
3236
- contactProfile: string | null;
3237
- socialProfileUrl: string | null;
3238
- tags: {
3239
- name: string;
3240
- id: string;
3241
- createdAt: Date;
3242
- updatedAt: Date;
3243
- deletedAt: Date | null;
3244
- }[];
3245
- contactEmails: {
4086
+ }, {
3246
4087
  id: string;
3247
4088
  isPrimary: boolean;
3248
4089
  email: string;
3249
4090
  createdAt: Date;
3250
4091
  updatedAt: Date;
3251
4092
  deletedAt: Date | null;
3252
- }[];
3253
- contactPhones: {
4093
+ }>, "many">;
4094
+ contactPhones: z.ZodArray<z.ZodObject<{
4095
+ id: z.ZodString;
4096
+ createdAt: z.ZodDate;
4097
+ updatedAt: z.ZodDate;
4098
+ deletedAt: z.ZodNullable<z.ZodDate>;
4099
+ phone: z.ZodString;
4100
+ isPrimary: z.ZodBoolean;
4101
+ }, "strip", z.ZodTypeAny, {
3254
4102
  id: string;
3255
4103
  isPrimary: boolean;
3256
4104
  createdAt: Date;
3257
4105
  updatedAt: Date;
3258
4106
  deletedAt: Date | null;
3259
4107
  phone: string;
3260
- }[];
3261
- activityLogs?: {
4108
+ }, {
4109
+ id: string;
4110
+ isPrimary: boolean;
4111
+ createdAt: Date;
4112
+ updatedAt: Date;
4113
+ deletedAt: Date | null;
4114
+ phone: string;
4115
+ }>, "many">;
4116
+ activityLogs: z.ZodOptional<z.ZodArray<z.ZodObject<{
4117
+ id: z.ZodString;
4118
+ createdAt: z.ZodDate;
4119
+ updatedAt: z.ZodDate;
4120
+ deletedAt: z.ZodNullable<z.ZodDate>;
4121
+ entityId: z.ZodString;
4122
+ description: z.ZodString;
4123
+ entityType: z.ZodObject<{
4124
+ id: z.ZodString;
4125
+ createdAt: z.ZodDate;
4126
+ updatedAt: z.ZodDate;
4127
+ deletedAt: z.ZodNullable<z.ZodDate>;
4128
+ entity: z.ZodString;
4129
+ description: z.ZodNullable<z.ZodString>;
4130
+ }, "strip", z.ZodTypeAny, {
4131
+ id: string;
4132
+ description: string | null;
4133
+ createdAt: Date;
4134
+ updatedAt: Date;
4135
+ deletedAt: Date | null;
4136
+ entity: string;
4137
+ }, {
4138
+ id: string;
4139
+ description: string | null;
4140
+ createdAt: Date;
4141
+ updatedAt: Date;
4142
+ deletedAt: Date | null;
4143
+ entity: string;
4144
+ }>;
4145
+ }, "strip", z.ZodTypeAny, {
3262
4146
  id: string;
3263
4147
  description: string;
3264
4148
  createdAt: Date;
@@ -3273,11 +4157,23 @@ export declare const publicApiContract: {
3273
4157
  deletedAt: Date | null;
3274
4158
  entity: string;
3275
4159
  };
3276
- }[] | undefined;
3277
- }>;
3278
- requestId: z.ZodString;
3279
- }, "strip", z.ZodTypeAny, {
3280
- data: {
4160
+ }, {
4161
+ id: string;
4162
+ description: string;
4163
+ createdAt: Date;
4164
+ updatedAt: Date;
4165
+ deletedAt: Date | null;
4166
+ entityId: string;
4167
+ entityType: {
4168
+ id: string;
4169
+ description: string | null;
4170
+ createdAt: Date;
4171
+ updatedAt: Date;
4172
+ deletedAt: Date | null;
4173
+ entity: string;
4174
+ };
4175
+ }>, "many">>;
4176
+ }, "strip", z.ZodTypeAny, {
3281
4177
  name: string;
3282
4178
  id: string;
3283
4179
  channel: string | null;
@@ -3373,12 +4269,7 @@ export declare const publicApiContract: {
3373
4269
  entity: string;
3374
4270
  };
3375
4271
  }[] | undefined;
3376
- };
3377
- message: string;
3378
- status: string;
3379
- requestId: string;
3380
- }, {
3381
- data: {
4272
+ }, {
3382
4273
  name: string;
3383
4274
  id: string;
3384
4275
  channel: string | null;
@@ -3441,420 +4332,242 @@ export declare const publicApiContract: {
3441
4332
  createdAt: Date;
3442
4333
  updatedAt: Date;
3443
4334
  deletedAt: Date | null;
3444
- }[];
3445
- contactEmails: {
3446
- id: string;
3447
- isPrimary: boolean;
3448
- email: string;
3449
- createdAt: Date;
3450
- updatedAt: Date;
3451
- deletedAt: Date | null;
3452
- }[];
3453
- contactPhones: {
3454
- id: string;
3455
- isPrimary: boolean;
3456
- createdAt: Date;
3457
- updatedAt: Date;
3458
- deletedAt: Date | null;
3459
- phone: string;
3460
- }[];
3461
- activityLogs?: {
3462
- id: string;
3463
- description: string;
3464
- createdAt: Date;
3465
- updatedAt: Date;
3466
- deletedAt: Date | null;
3467
- entityId: string;
3468
- entityType: {
3469
- id: string;
3470
- description: string | null;
3471
- createdAt: Date;
3472
- updatedAt: Date;
3473
- deletedAt: Date | null;
3474
- entity: string;
3475
- };
3476
- }[] | undefined;
3477
- };
3478
- message: string;
3479
- status: string;
3480
- requestId: string;
3481
- }>;
3482
- 400: z.ZodObject<{
3483
- message: z.ZodString;
3484
- }, "strip", z.ZodTypeAny, {
3485
- message: string;
3486
- }, {
3487
- message: string;
3488
- }>;
3489
- 409: z.ZodObject<{
3490
- message: z.ZodString;
3491
- }, "strip", z.ZodTypeAny, {
3492
- message: string;
3493
- }, {
3494
- message: string;
3495
- }>;
3496
- 401: z.ZodObject<{
3497
- message: z.ZodString;
3498
- error: z.ZodAny;
3499
- }, "strip", z.ZodTypeAny, {
3500
- message: string;
3501
- error?: any;
3502
- }, {
3503
- message: string;
3504
- error?: any;
3505
- }>;
3506
- 404: z.ZodObject<{
3507
- message: z.ZodString;
3508
- error: z.ZodAny;
3509
- }, "strip", z.ZodTypeAny, {
3510
- message: string;
3511
- error?: any;
3512
- }, {
3513
- message: string;
3514
- error?: any;
3515
- }>;
3516
- 422: z.ZodObject<{
3517
- message: z.ZodString;
3518
- error: z.ZodAny;
3519
- }, "strip", z.ZodTypeAny, {
3520
- message: string;
3521
- error?: any;
3522
- }, {
3523
- message: string;
3524
- error?: any;
3525
- }>;
3526
- 500: z.ZodObject<{
3527
- message: z.ZodString;
3528
- error: z.ZodAny;
3529
- }, "strip", z.ZodTypeAny, {
3530
- message: string;
3531
- error?: any;
3532
- }, {
3533
- message: string;
3534
- error?: any;
3535
- }>;
3536
- };
3537
- path: "api/v1/contacts/:id";
3538
- };
3539
- createContactAttachmentRecords: {
3540
- body: z.ZodObject<{
3541
- contactId: z.ZodString;
3542
- attributeId: z.ZodString;
3543
- contactAttachmentRecords: z.ZodArray<z.ZodObject<{
3544
- bucketName: z.ZodString;
3545
- fileKey: z.ZodString;
3546
- fileName: z.ZodString;
3547
- fileSize: z.ZodNumber;
3548
- url: z.ZodString;
3549
- }, "strip", z.ZodTypeAny, {
3550
- url: string;
3551
- fileName: string;
3552
- fileKey: string;
3553
- bucketName: string;
3554
- fileSize: number;
3555
- }, {
3556
- url: string;
3557
- fileName: string;
3558
- fileKey: string;
3559
- bucketName: string;
3560
- fileSize: number;
3561
- }>, "many">;
3562
- }, "strip", z.ZodTypeAny, {
3563
- attributeId: string;
3564
- contactId: string;
3565
- contactAttachmentRecords: {
3566
- url: string;
3567
- fileName: string;
3568
- fileKey: string;
3569
- bucketName: string;
3570
- fileSize: number;
3571
- }[];
3572
- }, {
3573
- attributeId: string;
3574
- contactId: string;
3575
- contactAttachmentRecords: {
3576
- url: string;
3577
- fileName: string;
3578
- fileKey: string;
3579
- bucketName: string;
3580
- fileSize: number;
3581
- }[];
3582
- }>;
3583
- summary: "Create a new contact attachment";
3584
- method: "POST";
3585
- responses: {
3586
- 201: z.ZodObject<{
3587
- requestId: z.ZodString;
3588
- message: z.ZodObject<{
3589
- id: z.ZodString;
3590
- createdAt: z.ZodDate;
3591
- updatedAt: z.ZodDate;
3592
- deletedAt: z.ZodNullable<z.ZodDate>;
3593
- textValue: z.ZodNullable<z.ZodString>;
3594
- booleanValue: z.ZodNullable<z.ZodBoolean>;
3595
- numberValue: z.ZodNullable<z.ZodNumber>;
3596
- dateValue: z.ZodNullable<z.ZodDate>;
3597
- attribute: z.ZodObject<Omit<{
3598
- id: z.ZodString;
3599
- createdAt: z.ZodDate;
3600
- updatedAt: z.ZodDate;
3601
- deletedAt: z.ZodNullable<z.ZodDate>;
3602
- systemName: z.ZodString;
3603
- displayName: z.ZodString;
3604
- type: z.ZodUnion<[z.ZodLiteral<"text">, z.ZodLiteral<"textarea">, z.ZodLiteral<"date">, z.ZodLiteral<"select">, z.ZodLiteral<"link">, z.ZodLiteral<"attachment">]>;
3605
- position: z.ZodNumber;
3606
- isDefault: z.ZodBoolean;
3607
- isArchived: z.ZodBoolean;
3608
- isRequired: z.ZodBoolean;
3609
- isUnique: z.ZodBoolean;
3610
- options: z.ZodArray<z.ZodObject<{
3611
- position: z.ZodNumber;
3612
- value: z.ZodString;
3613
- label: z.ZodString;
3614
- isDefault: z.ZodBoolean;
3615
- id: z.ZodString;
3616
- }, "strip", z.ZodTypeAny, {
4335
+ }[];
4336
+ contactEmails: {
4337
+ id: string;
4338
+ isPrimary: boolean;
4339
+ email: string;
4340
+ createdAt: Date;
4341
+ updatedAt: Date;
4342
+ deletedAt: Date | null;
4343
+ }[];
4344
+ contactPhones: {
4345
+ id: string;
4346
+ isPrimary: boolean;
4347
+ createdAt: Date;
4348
+ updatedAt: Date;
4349
+ deletedAt: Date | null;
4350
+ phone: string;
4351
+ }[];
4352
+ activityLogs?: {
4353
+ id: string;
4354
+ description: string;
4355
+ createdAt: Date;
4356
+ updatedAt: Date;
4357
+ deletedAt: Date | null;
4358
+ entityId: string;
4359
+ entityType: {
3617
4360
  id: string;
3618
- position: number;
3619
- value: string;
3620
- label: string;
3621
- isDefault: boolean;
3622
- }, {
4361
+ description: string | null;
4362
+ createdAt: Date;
4363
+ updatedAt: Date;
4364
+ deletedAt: Date | null;
4365
+ entity: string;
4366
+ };
4367
+ }[] | undefined;
4368
+ }>;
4369
+ requestId: z.ZodString;
4370
+ }, "strip", z.ZodTypeAny, {
4371
+ data: {
4372
+ name: string;
4373
+ id: string;
4374
+ channel: string | null;
4375
+ address: string | null;
4376
+ createdAt: Date;
4377
+ updatedAt: Date;
4378
+ deletedAt: Date | null;
4379
+ customFields: {
4380
+ id: string;
4381
+ createdAt: Date;
4382
+ updatedAt: Date;
4383
+ deletedAt: Date | null;
4384
+ attribute: {
4385
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
3623
4386
  id: string;
3624
4387
  position: number;
3625
- value: string;
3626
- label: string;
3627
- isDefault: boolean;
3628
- }>, "many">;
3629
- group: z.ZodObject<{
3630
- id: z.ZodString;
3631
- createdAt: z.ZodDate;
3632
- updatedAt: z.ZodDate;
3633
- deletedAt: z.ZodNullable<z.ZodDate>;
3634
- systemName: z.ZodString;
3635
- displayName: z.ZodString;
3636
- }, "strip", z.ZodTypeAny, {
3637
- id: string;
3638
4388
  createdAt: Date;
3639
4389
  updatedAt: Date;
3640
4390
  deletedAt: Date | null;
3641
4391
  systemName: string;
3642
4392
  displayName: string;
3643
- }, {
4393
+ isDefault: boolean;
4394
+ isArchived: boolean;
4395
+ isRequired: boolean;
4396
+ isUnique: boolean;
4397
+ };
4398
+ textValue: string | null;
4399
+ booleanValue: boolean | null;
4400
+ numberValue: number | null;
4401
+ dateValue: Date | null;
4402
+ uploads: {
3644
4403
  id: string;
4404
+ status: string | null;
3645
4405
  createdAt: Date;
3646
4406
  updatedAt: Date;
3647
4407
  deletedAt: Date | null;
3648
- systemName: string;
3649
- displayName: string;
3650
- }>;
3651
- }, "options" | "group">, "strip", z.ZodTypeAny, {
3652
- type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
3653
- id: string;
3654
- position: number;
3655
- createdAt: Date;
3656
- updatedAt: Date;
3657
- deletedAt: Date | null;
3658
- systemName: string;
3659
- displayName: string;
3660
- isDefault: boolean;
3661
- isArchived: boolean;
3662
- isRequired: boolean;
3663
- isUnique: boolean;
3664
- }, {
3665
- type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
4408
+ fileName: string;
4409
+ fileKey: string;
4410
+ bucketName: string;
4411
+ fileSize: number;
4412
+ fileUrl: string | null;
4413
+ }[];
4414
+ }[];
4415
+ company: {
3666
4416
  id: string;
3667
- position: number;
3668
4417
  createdAt: Date;
3669
4418
  updatedAt: Date;
3670
4419
  deletedAt: Date | null;
3671
- systemName: string;
3672
- displayName: string;
3673
- isDefault: boolean;
3674
- isArchived: boolean;
3675
- isRequired: boolean;
3676
- isUnique: boolean;
3677
- }>;
3678
- uploads: z.ZodArray<z.ZodObject<{
3679
- id: z.ZodString;
3680
- createdAt: z.ZodDate;
3681
- updatedAt: z.ZodDate;
3682
- deletedAt: z.ZodNullable<z.ZodDate>;
3683
- bucketName: z.ZodString;
3684
- fileName: z.ZodString;
3685
- fileSize: z.ZodNumber;
3686
- fileKey: z.ZodString;
3687
- fileUrl: z.ZodNullable<z.ZodString>;
3688
- status: z.ZodNullable<z.ZodString>;
3689
- }, "strip", z.ZodTypeAny, {
4420
+ name?: string | undefined;
4421
+ address?: string | null | undefined;
4422
+ phone?: string | null | undefined;
4423
+ industry?: string | null | undefined;
4424
+ } | null;
4425
+ notes: string | null;
4426
+ contactProfile: string | null;
4427
+ socialProfileUrl: string | null;
4428
+ tags: {
4429
+ name: string;
3690
4430
  id: string;
3691
- status: string | null;
3692
4431
  createdAt: Date;
3693
4432
  updatedAt: Date;
3694
4433
  deletedAt: Date | null;
3695
- fileName: string;
3696
- fileKey: string;
3697
- bucketName: string;
3698
- fileSize: number;
3699
- fileUrl: string | null;
3700
- }, {
4434
+ }[];
4435
+ contactEmails: {
3701
4436
  id: string;
3702
- status: string | null;
4437
+ isPrimary: boolean;
4438
+ email: string;
3703
4439
  createdAt: Date;
3704
4440
  updatedAt: Date;
3705
4441
  deletedAt: Date | null;
3706
- fileName: string;
3707
- fileKey: string;
3708
- bucketName: string;
3709
- fileSize: number;
3710
- fileUrl: string | null;
3711
- }>, "many">;
3712
- }, "strip", z.ZodTypeAny, {
3713
- id: string;
3714
- createdAt: Date;
3715
- updatedAt: Date;
3716
- deletedAt: Date | null;
3717
- attribute: {
3718
- type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
4442
+ }[];
4443
+ contactPhones: {
3719
4444
  id: string;
3720
- position: number;
4445
+ isPrimary: boolean;
3721
4446
  createdAt: Date;
3722
4447
  updatedAt: Date;
3723
4448
  deletedAt: Date | null;
3724
- systemName: string;
3725
- displayName: string;
3726
- isDefault: boolean;
3727
- isArchived: boolean;
3728
- isRequired: boolean;
3729
- isUnique: boolean;
3730
- };
3731
- textValue: string | null;
3732
- booleanValue: boolean | null;
3733
- numberValue: number | null;
3734
- dateValue: Date | null;
3735
- uploads: {
4449
+ phone: string;
4450
+ }[];
4451
+ activityLogs?: {
3736
4452
  id: string;
3737
- status: string | null;
4453
+ description: string;
3738
4454
  createdAt: Date;
3739
4455
  updatedAt: Date;
3740
4456
  deletedAt: Date | null;
3741
- fileName: string;
3742
- fileKey: string;
3743
- bucketName: string;
3744
- fileSize: number;
3745
- fileUrl: string | null;
3746
- }[];
3747
- }, {
4457
+ entityId: string;
4458
+ entityType: {
4459
+ id: string;
4460
+ description: string | null;
4461
+ createdAt: Date;
4462
+ updatedAt: Date;
4463
+ deletedAt: Date | null;
4464
+ entity: string;
4465
+ };
4466
+ }[] | undefined;
4467
+ };
4468
+ message: string;
4469
+ status: string;
4470
+ requestId: string;
4471
+ }, {
4472
+ data: {
4473
+ name: string;
3748
4474
  id: string;
4475
+ channel: string | null;
4476
+ address: string | null;
3749
4477
  createdAt: Date;
3750
4478
  updatedAt: Date;
3751
4479
  deletedAt: Date | null;
3752
- attribute: {
3753
- type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
4480
+ customFields: {
3754
4481
  id: string;
3755
- position: number;
3756
4482
  createdAt: Date;
3757
4483
  updatedAt: Date;
3758
4484
  deletedAt: Date | null;
3759
- systemName: string;
3760
- displayName: string;
3761
- isDefault: boolean;
3762
- isArchived: boolean;
3763
- isRequired: boolean;
3764
- isUnique: boolean;
3765
- };
3766
- textValue: string | null;
3767
- booleanValue: boolean | null;
3768
- numberValue: number | null;
3769
- dateValue: Date | null;
3770
- uploads: {
4485
+ attribute: {
4486
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
4487
+ id: string;
4488
+ position: number;
4489
+ createdAt: Date;
4490
+ updatedAt: Date;
4491
+ deletedAt: Date | null;
4492
+ systemName: string;
4493
+ displayName: string;
4494
+ isDefault: boolean;
4495
+ isArchived: boolean;
4496
+ isRequired: boolean;
4497
+ isUnique: boolean;
4498
+ };
4499
+ textValue: string | null;
4500
+ booleanValue: boolean | null;
4501
+ numberValue: number | null;
4502
+ dateValue: Date | null;
4503
+ uploads: {
4504
+ id: string;
4505
+ status: string | null;
4506
+ createdAt: Date;
4507
+ updatedAt: Date;
4508
+ deletedAt: Date | null;
4509
+ fileName: string;
4510
+ fileKey: string;
4511
+ bucketName: string;
4512
+ fileSize: number;
4513
+ fileUrl: string | null;
4514
+ }[];
4515
+ }[];
4516
+ company: {
3771
4517
  id: string;
3772
- status: string | null;
3773
4518
  createdAt: Date;
3774
4519
  updatedAt: Date;
3775
4520
  deletedAt: Date | null;
3776
- fileName: string;
3777
- fileKey: string;
3778
- bucketName: string;
3779
- fileSize: number;
3780
- fileUrl: string | null;
3781
- }[];
3782
- }>;
3783
- }, "strip", z.ZodTypeAny, {
3784
- message: {
3785
- id: string;
3786
- createdAt: Date;
3787
- updatedAt: Date;
3788
- deletedAt: Date | null;
3789
- attribute: {
3790
- type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
4521
+ name?: string | undefined;
4522
+ address?: string | null | undefined;
4523
+ phone?: string | null | undefined;
4524
+ industry?: string | null | undefined;
4525
+ } | null;
4526
+ notes: string | null;
4527
+ contactProfile: string | null;
4528
+ socialProfileUrl: string | null;
4529
+ tags: {
4530
+ name: string;
3791
4531
  id: string;
3792
- position: number;
3793
4532
  createdAt: Date;
3794
4533
  updatedAt: Date;
3795
4534
  deletedAt: Date | null;
3796
- systemName: string;
3797
- displayName: string;
3798
- isDefault: boolean;
3799
- isArchived: boolean;
3800
- isRequired: boolean;
3801
- isUnique: boolean;
3802
- };
3803
- textValue: string | null;
3804
- booleanValue: boolean | null;
3805
- numberValue: number | null;
3806
- dateValue: Date | null;
3807
- uploads: {
4535
+ }[];
4536
+ contactEmails: {
3808
4537
  id: string;
3809
- status: string | null;
4538
+ isPrimary: boolean;
4539
+ email: string;
3810
4540
  createdAt: Date;
3811
4541
  updatedAt: Date;
3812
4542
  deletedAt: Date | null;
3813
- fileName: string;
3814
- fileKey: string;
3815
- bucketName: string;
3816
- fileSize: number;
3817
- fileUrl: string | null;
3818
4543
  }[];
3819
- };
3820
- requestId: string;
3821
- }, {
3822
- message: {
3823
- id: string;
3824
- createdAt: Date;
3825
- updatedAt: Date;
3826
- deletedAt: Date | null;
3827
- attribute: {
3828
- type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
4544
+ contactPhones: {
3829
4545
  id: string;
3830
- position: number;
4546
+ isPrimary: boolean;
3831
4547
  createdAt: Date;
3832
4548
  updatedAt: Date;
3833
4549
  deletedAt: Date | null;
3834
- systemName: string;
3835
- displayName: string;
3836
- isDefault: boolean;
3837
- isArchived: boolean;
3838
- isRequired: boolean;
3839
- isUnique: boolean;
3840
- };
3841
- textValue: string | null;
3842
- booleanValue: boolean | null;
3843
- numberValue: number | null;
3844
- dateValue: Date | null;
3845
- uploads: {
4550
+ phone: string;
4551
+ }[];
4552
+ activityLogs?: {
3846
4553
  id: string;
3847
- status: string | null;
4554
+ description: string;
3848
4555
  createdAt: Date;
3849
4556
  updatedAt: Date;
3850
4557
  deletedAt: Date | null;
3851
- fileName: string;
3852
- fileKey: string;
3853
- bucketName: string;
3854
- fileSize: number;
3855
- fileUrl: string | null;
3856
- }[];
4558
+ entityId: string;
4559
+ entityType: {
4560
+ id: string;
4561
+ description: string | null;
4562
+ createdAt: Date;
4563
+ updatedAt: Date;
4564
+ deletedAt: Date | null;
4565
+ entity: string;
4566
+ };
4567
+ }[] | undefined;
3857
4568
  };
4569
+ message: string;
4570
+ status: string;
3858
4571
  requestId: string;
3859
4572
  }>;
3860
4573
  400: z.ZodObject<{
@@ -3912,11 +4625,72 @@ export declare const publicApiContract: {
3912
4625
  error?: any;
3913
4626
  }>;
3914
4627
  };
3915
- path: "api/v1/contacts/attachments";
4628
+ path: "api/v1/contacts/:id";
3916
4629
  };
3917
- getContactById: {
3918
- summary: "Get a contact by id";
3919
- method: "GET";
4630
+ updateContact: {
4631
+ body: z.ZodObject<{
4632
+ name: z.ZodOptional<z.ZodString>;
4633
+ email: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodObject<{
4634
+ email: z.ZodString;
4635
+ isPrimary: z.ZodBoolean;
4636
+ }, "strip", z.ZodTypeAny, {
4637
+ isPrimary: boolean;
4638
+ email: string;
4639
+ }, {
4640
+ isPrimary: boolean;
4641
+ email: string;
4642
+ }>, "many">>>;
4643
+ channel: z.ZodOptional<z.ZodOptional<z.ZodString>>;
4644
+ address: z.ZodOptional<z.ZodOptional<z.ZodString>>;
4645
+ phone: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodObject<{
4646
+ phone: z.ZodString;
4647
+ isPrimary: z.ZodBoolean;
4648
+ }, "strip", z.ZodTypeAny, {
4649
+ isPrimary: boolean;
4650
+ phone: string;
4651
+ }, {
4652
+ isPrimary: boolean;
4653
+ phone: string;
4654
+ }>, "many">>>;
4655
+ notes: z.ZodOptional<z.ZodOptional<z.ZodString>>;
4656
+ tags: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodString, "many">>>;
4657
+ company: z.ZodOptional<z.ZodOptional<z.ZodString>>;
4658
+ customFields: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
4659
+ }, "strip", z.ZodTypeAny, {
4660
+ name?: string | undefined;
4661
+ email?: {
4662
+ isPrimary: boolean;
4663
+ email: string;
4664
+ }[] | undefined;
4665
+ channel?: string | undefined;
4666
+ address?: string | undefined;
4667
+ phone?: {
4668
+ isPrimary: boolean;
4669
+ phone: string;
4670
+ }[] | undefined;
4671
+ notes?: string | undefined;
4672
+ tags?: string[] | undefined;
4673
+ company?: string | undefined;
4674
+ customFields?: Record<string, string> | undefined;
4675
+ }, {
4676
+ name?: string | undefined;
4677
+ email?: {
4678
+ isPrimary: boolean;
4679
+ email: string;
4680
+ }[] | undefined;
4681
+ channel?: string | undefined;
4682
+ address?: string | undefined;
4683
+ phone?: {
4684
+ isPrimary: boolean;
4685
+ phone: string;
4686
+ }[] | undefined;
4687
+ notes?: string | undefined;
4688
+ tags?: string[] | undefined;
4689
+ company?: string | undefined;
4690
+ customFields?: Record<string, string> | undefined;
4691
+ }>;
4692
+ summary: "Update a contact";
4693
+ method: "PATCH";
3920
4694
  pathParams: z.ZodObject<{
3921
4695
  id: z.ZodString;
3922
4696
  }, "strip", z.ZodTypeAny, {
@@ -4421,8 +5195,104 @@ export declare const publicApiContract: {
4421
5195
  deletedAt: Date | null;
4422
5196
  entity: string;
4423
5197
  };
4424
- }>, "many">>;
4425
- }, "strip", z.ZodTypeAny, {
5198
+ }>, "many">>;
5199
+ }, "strip", z.ZodTypeAny, {
5200
+ name: string;
5201
+ id: string;
5202
+ channel: string | null;
5203
+ address: string | null;
5204
+ createdAt: Date;
5205
+ updatedAt: Date;
5206
+ deletedAt: Date | null;
5207
+ customFields: {
5208
+ id: string;
5209
+ createdAt: Date;
5210
+ updatedAt: Date;
5211
+ deletedAt: Date | null;
5212
+ attribute: {
5213
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
5214
+ id: string;
5215
+ position: number;
5216
+ createdAt: Date;
5217
+ updatedAt: Date;
5218
+ deletedAt: Date | null;
5219
+ systemName: string;
5220
+ displayName: string;
5221
+ isDefault: boolean;
5222
+ isArchived: boolean;
5223
+ isRequired: boolean;
5224
+ isUnique: boolean;
5225
+ };
5226
+ textValue: string | null;
5227
+ booleanValue: boolean | null;
5228
+ numberValue: number | null;
5229
+ dateValue: Date | null;
5230
+ uploads: {
5231
+ id: string;
5232
+ status: string | null;
5233
+ createdAt: Date;
5234
+ updatedAt: Date;
5235
+ deletedAt: Date | null;
5236
+ fileName: string;
5237
+ fileKey: string;
5238
+ bucketName: string;
5239
+ fileSize: number;
5240
+ fileUrl: string | null;
5241
+ }[];
5242
+ }[];
5243
+ company: {
5244
+ id: string;
5245
+ createdAt: Date;
5246
+ updatedAt: Date;
5247
+ deletedAt: Date | null;
5248
+ name?: string | undefined;
5249
+ address?: string | null | undefined;
5250
+ phone?: string | null | undefined;
5251
+ industry?: string | null | undefined;
5252
+ } | null;
5253
+ notes: string | null;
5254
+ contactProfile: string | null;
5255
+ socialProfileUrl: string | null;
5256
+ tags: {
5257
+ name: string;
5258
+ id: string;
5259
+ createdAt: Date;
5260
+ updatedAt: Date;
5261
+ deletedAt: Date | null;
5262
+ }[];
5263
+ contactEmails: {
5264
+ id: string;
5265
+ isPrimary: boolean;
5266
+ email: string;
5267
+ createdAt: Date;
5268
+ updatedAt: Date;
5269
+ deletedAt: Date | null;
5270
+ }[];
5271
+ contactPhones: {
5272
+ id: string;
5273
+ isPrimary: boolean;
5274
+ createdAt: Date;
5275
+ updatedAt: Date;
5276
+ deletedAt: Date | null;
5277
+ phone: string;
5278
+ }[];
5279
+ activityLogs?: {
5280
+ id: string;
5281
+ description: string;
5282
+ createdAt: Date;
5283
+ updatedAt: Date;
5284
+ deletedAt: Date | null;
5285
+ entityId: string;
5286
+ entityType: {
5287
+ id: string;
5288
+ description: string | null;
5289
+ createdAt: Date;
5290
+ updatedAt: Date;
5291
+ deletedAt: Date | null;
5292
+ entity: string;
5293
+ };
5294
+ }[] | undefined;
5295
+ }, {
4426
5296
  name: string;
4427
5297
  id: string;
4428
5298
  channel: string | null;
@@ -4518,7 +5388,10 @@ export declare const publicApiContract: {
4518
5388
  entity: string;
4519
5389
  };
4520
5390
  }[] | undefined;
4521
- }, {
5391
+ }>;
5392
+ requestId: z.ZodString;
5393
+ }, "strip", z.ZodTypeAny, {
5394
+ data: {
4522
5395
  name: string;
4523
5396
  id: string;
4524
5397
  channel: string | null;
@@ -4614,9 +5487,11 @@ export declare const publicApiContract: {
4614
5487
  entity: string;
4615
5488
  };
4616
5489
  }[] | undefined;
4617
- }>;
4618
- requestId: z.ZodString;
4619
- }, "strip", z.ZodTypeAny, {
5490
+ };
5491
+ message: string;
5492
+ status: string;
5493
+ requestId: string;
5494
+ }, {
4620
5495
  data: {
4621
5496
  name: string;
4622
5497
  id: string;
@@ -4666,157 +5541,434 @@ export declare const publicApiContract: {
4666
5541
  createdAt: Date;
4667
5542
  updatedAt: Date;
4668
5543
  deletedAt: Date | null;
4669
- name?: string | undefined;
4670
- address?: string | null | undefined;
4671
- phone?: string | null | undefined;
4672
- industry?: string | null | undefined;
4673
- } | null;
4674
- notes: string | null;
4675
- contactProfile: string | null;
4676
- socialProfileUrl: string | null;
4677
- tags: {
4678
- name: string;
5544
+ name?: string | undefined;
5545
+ address?: string | null | undefined;
5546
+ phone?: string | null | undefined;
5547
+ industry?: string | null | undefined;
5548
+ } | null;
5549
+ notes: string | null;
5550
+ contactProfile: string | null;
5551
+ socialProfileUrl: string | null;
5552
+ tags: {
5553
+ name: string;
5554
+ id: string;
5555
+ createdAt: Date;
5556
+ updatedAt: Date;
5557
+ deletedAt: Date | null;
5558
+ }[];
5559
+ contactEmails: {
5560
+ id: string;
5561
+ isPrimary: boolean;
5562
+ email: string;
5563
+ createdAt: Date;
5564
+ updatedAt: Date;
5565
+ deletedAt: Date | null;
5566
+ }[];
5567
+ contactPhones: {
5568
+ id: string;
5569
+ isPrimary: boolean;
5570
+ createdAt: Date;
5571
+ updatedAt: Date;
5572
+ deletedAt: Date | null;
5573
+ phone: string;
5574
+ }[];
5575
+ activityLogs?: {
5576
+ id: string;
5577
+ description: string;
5578
+ createdAt: Date;
5579
+ updatedAt: Date;
5580
+ deletedAt: Date | null;
5581
+ entityId: string;
5582
+ entityType: {
5583
+ id: string;
5584
+ description: string | null;
5585
+ createdAt: Date;
5586
+ updatedAt: Date;
5587
+ deletedAt: Date | null;
5588
+ entity: string;
5589
+ };
5590
+ }[] | undefined;
5591
+ };
5592
+ message: string;
5593
+ status: string;
5594
+ requestId: string;
5595
+ }>;
5596
+ 400: z.ZodObject<{
5597
+ message: z.ZodString;
5598
+ }, "strip", z.ZodTypeAny, {
5599
+ message: string;
5600
+ }, {
5601
+ message: string;
5602
+ }>;
5603
+ 409: z.ZodObject<{
5604
+ message: z.ZodString;
5605
+ }, "strip", z.ZodTypeAny, {
5606
+ message: string;
5607
+ }, {
5608
+ message: string;
5609
+ }>;
5610
+ 401: z.ZodObject<{
5611
+ message: z.ZodString;
5612
+ error: z.ZodAny;
5613
+ }, "strip", z.ZodTypeAny, {
5614
+ message: string;
5615
+ error?: any;
5616
+ }, {
5617
+ message: string;
5618
+ error?: any;
5619
+ }>;
5620
+ 404: z.ZodObject<{
5621
+ message: z.ZodString;
5622
+ error: z.ZodAny;
5623
+ }, "strip", z.ZodTypeAny, {
5624
+ message: string;
5625
+ error?: any;
5626
+ }, {
5627
+ message: string;
5628
+ error?: any;
5629
+ }>;
5630
+ 422: z.ZodObject<{
5631
+ message: z.ZodString;
5632
+ error: z.ZodAny;
5633
+ }, "strip", z.ZodTypeAny, {
5634
+ message: string;
5635
+ error?: any;
5636
+ }, {
5637
+ message: string;
5638
+ error?: any;
5639
+ }>;
5640
+ 500: z.ZodObject<{
5641
+ message: z.ZodString;
5642
+ error: z.ZodAny;
5643
+ }, "strip", z.ZodTypeAny, {
5644
+ message: string;
5645
+ error?: any;
5646
+ }, {
5647
+ message: string;
5648
+ error?: any;
5649
+ }>;
5650
+ };
5651
+ path: "api/v1/contacts/:id";
5652
+ };
5653
+ createContactAttachmentRecords: {
5654
+ body: z.ZodObject<{
5655
+ contactId: z.ZodString;
5656
+ attributeId: z.ZodString;
5657
+ contactAttachmentRecords: z.ZodArray<z.ZodObject<{
5658
+ bucketName: z.ZodString;
5659
+ fileKey: z.ZodString;
5660
+ fileName: z.ZodString;
5661
+ fileSize: z.ZodNumber;
5662
+ url: z.ZodString;
5663
+ }, "strip", z.ZodTypeAny, {
5664
+ url: string;
5665
+ fileName: string;
5666
+ fileKey: string;
5667
+ bucketName: string;
5668
+ fileSize: number;
5669
+ }, {
5670
+ url: string;
5671
+ fileName: string;
5672
+ fileKey: string;
5673
+ bucketName: string;
5674
+ fileSize: number;
5675
+ }>, "many">;
5676
+ }, "strip", z.ZodTypeAny, {
5677
+ attributeId: string;
5678
+ contactId: string;
5679
+ contactAttachmentRecords: {
5680
+ url: string;
5681
+ fileName: string;
5682
+ fileKey: string;
5683
+ bucketName: string;
5684
+ fileSize: number;
5685
+ }[];
5686
+ }, {
5687
+ attributeId: string;
5688
+ contactId: string;
5689
+ contactAttachmentRecords: {
5690
+ url: string;
5691
+ fileName: string;
5692
+ fileKey: string;
5693
+ bucketName: string;
5694
+ fileSize: number;
5695
+ }[];
5696
+ }>;
5697
+ summary: "Create a new contact attachment";
5698
+ method: "POST";
5699
+ responses: {
5700
+ 201: z.ZodObject<{
5701
+ requestId: z.ZodString;
5702
+ message: z.ZodObject<{
5703
+ id: z.ZodString;
5704
+ createdAt: z.ZodDate;
5705
+ updatedAt: z.ZodDate;
5706
+ deletedAt: z.ZodNullable<z.ZodDate>;
5707
+ textValue: z.ZodNullable<z.ZodString>;
5708
+ booleanValue: z.ZodNullable<z.ZodBoolean>;
5709
+ numberValue: z.ZodNullable<z.ZodNumber>;
5710
+ dateValue: z.ZodNullable<z.ZodDate>;
5711
+ attribute: z.ZodObject<Omit<{
5712
+ id: z.ZodString;
5713
+ createdAt: z.ZodDate;
5714
+ updatedAt: z.ZodDate;
5715
+ deletedAt: z.ZodNullable<z.ZodDate>;
5716
+ systemName: z.ZodString;
5717
+ displayName: z.ZodString;
5718
+ type: z.ZodUnion<[z.ZodLiteral<"text">, z.ZodLiteral<"textarea">, z.ZodLiteral<"date">, z.ZodLiteral<"select">, z.ZodLiteral<"link">, z.ZodLiteral<"attachment">]>;
5719
+ position: z.ZodNumber;
5720
+ isDefault: z.ZodBoolean;
5721
+ isArchived: z.ZodBoolean;
5722
+ isRequired: z.ZodBoolean;
5723
+ isUnique: z.ZodBoolean;
5724
+ options: z.ZodArray<z.ZodObject<{
5725
+ position: z.ZodNumber;
5726
+ value: z.ZodString;
5727
+ label: z.ZodString;
5728
+ isDefault: z.ZodBoolean;
5729
+ id: z.ZodString;
5730
+ }, "strip", z.ZodTypeAny, {
5731
+ id: string;
5732
+ position: number;
5733
+ value: string;
5734
+ label: string;
5735
+ isDefault: boolean;
5736
+ }, {
5737
+ id: string;
5738
+ position: number;
5739
+ value: string;
5740
+ label: string;
5741
+ isDefault: boolean;
5742
+ }>, "many">;
5743
+ group: z.ZodObject<{
5744
+ id: z.ZodString;
5745
+ createdAt: z.ZodDate;
5746
+ updatedAt: z.ZodDate;
5747
+ deletedAt: z.ZodNullable<z.ZodDate>;
5748
+ systemName: z.ZodString;
5749
+ displayName: z.ZodString;
5750
+ }, "strip", z.ZodTypeAny, {
5751
+ id: string;
5752
+ createdAt: Date;
5753
+ updatedAt: Date;
5754
+ deletedAt: Date | null;
5755
+ systemName: string;
5756
+ displayName: string;
5757
+ }, {
5758
+ id: string;
5759
+ createdAt: Date;
5760
+ updatedAt: Date;
5761
+ deletedAt: Date | null;
5762
+ systemName: string;
5763
+ displayName: string;
5764
+ }>;
5765
+ }, "options" | "group">, "strip", z.ZodTypeAny, {
5766
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
5767
+ id: string;
5768
+ position: number;
5769
+ createdAt: Date;
5770
+ updatedAt: Date;
5771
+ deletedAt: Date | null;
5772
+ systemName: string;
5773
+ displayName: string;
5774
+ isDefault: boolean;
5775
+ isArchived: boolean;
5776
+ isRequired: boolean;
5777
+ isUnique: boolean;
5778
+ }, {
5779
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
5780
+ id: string;
5781
+ position: number;
5782
+ createdAt: Date;
5783
+ updatedAt: Date;
5784
+ deletedAt: Date | null;
5785
+ systemName: string;
5786
+ displayName: string;
5787
+ isDefault: boolean;
5788
+ isArchived: boolean;
5789
+ isRequired: boolean;
5790
+ isUnique: boolean;
5791
+ }>;
5792
+ uploads: z.ZodArray<z.ZodObject<{
5793
+ id: z.ZodString;
5794
+ createdAt: z.ZodDate;
5795
+ updatedAt: z.ZodDate;
5796
+ deletedAt: z.ZodNullable<z.ZodDate>;
5797
+ bucketName: z.ZodString;
5798
+ fileName: z.ZodString;
5799
+ fileSize: z.ZodNumber;
5800
+ fileKey: z.ZodString;
5801
+ fileUrl: z.ZodNullable<z.ZodString>;
5802
+ status: z.ZodNullable<z.ZodString>;
5803
+ }, "strip", z.ZodTypeAny, {
4679
5804
  id: string;
5805
+ status: string | null;
4680
5806
  createdAt: Date;
4681
5807
  updatedAt: Date;
4682
5808
  deletedAt: Date | null;
4683
- }[];
4684
- contactEmails: {
5809
+ fileName: string;
5810
+ fileKey: string;
5811
+ bucketName: string;
5812
+ fileSize: number;
5813
+ fileUrl: string | null;
5814
+ }, {
4685
5815
  id: string;
4686
- isPrimary: boolean;
4687
- email: string;
5816
+ status: string | null;
4688
5817
  createdAt: Date;
4689
5818
  updatedAt: Date;
4690
5819
  deletedAt: Date | null;
4691
- }[];
4692
- contactPhones: {
5820
+ fileName: string;
5821
+ fileKey: string;
5822
+ bucketName: string;
5823
+ fileSize: number;
5824
+ fileUrl: string | null;
5825
+ }>, "many">;
5826
+ }, "strip", z.ZodTypeAny, {
5827
+ id: string;
5828
+ createdAt: Date;
5829
+ updatedAt: Date;
5830
+ deletedAt: Date | null;
5831
+ attribute: {
5832
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
4693
5833
  id: string;
4694
- isPrimary: boolean;
5834
+ position: number;
4695
5835
  createdAt: Date;
4696
5836
  updatedAt: Date;
4697
5837
  deletedAt: Date | null;
4698
- phone: string;
4699
- }[];
4700
- activityLogs?: {
5838
+ systemName: string;
5839
+ displayName: string;
5840
+ isDefault: boolean;
5841
+ isArchived: boolean;
5842
+ isRequired: boolean;
5843
+ isUnique: boolean;
5844
+ };
5845
+ textValue: string | null;
5846
+ booleanValue: boolean | null;
5847
+ numberValue: number | null;
5848
+ dateValue: Date | null;
5849
+ uploads: {
4701
5850
  id: string;
4702
- description: string;
5851
+ status: string | null;
4703
5852
  createdAt: Date;
4704
5853
  updatedAt: Date;
4705
5854
  deletedAt: Date | null;
4706
- entityId: string;
4707
- entityType: {
4708
- id: string;
4709
- description: string | null;
4710
- createdAt: Date;
4711
- updatedAt: Date;
4712
- deletedAt: Date | null;
4713
- entity: string;
4714
- };
4715
- }[] | undefined;
4716
- };
4717
- message: string;
4718
- status: string;
4719
- requestId: string;
4720
- }, {
4721
- data: {
4722
- name: string;
5855
+ fileName: string;
5856
+ fileKey: string;
5857
+ bucketName: string;
5858
+ fileSize: number;
5859
+ fileUrl: string | null;
5860
+ }[];
5861
+ }, {
4723
5862
  id: string;
4724
- channel: string | null;
4725
- address: string | null;
4726
5863
  createdAt: Date;
4727
5864
  updatedAt: Date;
4728
5865
  deletedAt: Date | null;
4729
- customFields: {
5866
+ attribute: {
5867
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
4730
5868
  id: string;
5869
+ position: number;
4731
5870
  createdAt: Date;
4732
5871
  updatedAt: Date;
4733
5872
  deletedAt: Date | null;
4734
- attribute: {
4735
- type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
4736
- id: string;
4737
- position: number;
4738
- createdAt: Date;
4739
- updatedAt: Date;
4740
- deletedAt: Date | null;
4741
- systemName: string;
4742
- displayName: string;
4743
- isDefault: boolean;
4744
- isArchived: boolean;
4745
- isRequired: boolean;
4746
- isUnique: boolean;
4747
- };
4748
- textValue: string | null;
4749
- booleanValue: boolean | null;
4750
- numberValue: number | null;
4751
- dateValue: Date | null;
4752
- uploads: {
4753
- id: string;
4754
- status: string | null;
4755
- createdAt: Date;
4756
- updatedAt: Date;
4757
- deletedAt: Date | null;
4758
- fileName: string;
4759
- fileKey: string;
4760
- bucketName: string;
4761
- fileSize: number;
4762
- fileUrl: string | null;
4763
- }[];
4764
- }[];
4765
- company: {
5873
+ systemName: string;
5874
+ displayName: string;
5875
+ isDefault: boolean;
5876
+ isArchived: boolean;
5877
+ isRequired: boolean;
5878
+ isUnique: boolean;
5879
+ };
5880
+ textValue: string | null;
5881
+ booleanValue: boolean | null;
5882
+ numberValue: number | null;
5883
+ dateValue: Date | null;
5884
+ uploads: {
4766
5885
  id: string;
5886
+ status: string | null;
4767
5887
  createdAt: Date;
4768
5888
  updatedAt: Date;
4769
5889
  deletedAt: Date | null;
4770
- name?: string | undefined;
4771
- address?: string | null | undefined;
4772
- phone?: string | null | undefined;
4773
- industry?: string | null | undefined;
4774
- } | null;
4775
- notes: string | null;
4776
- contactProfile: string | null;
4777
- socialProfileUrl: string | null;
4778
- tags: {
4779
- name: string;
5890
+ fileName: string;
5891
+ fileKey: string;
5892
+ bucketName: string;
5893
+ fileSize: number;
5894
+ fileUrl: string | null;
5895
+ }[];
5896
+ }>;
5897
+ }, "strip", z.ZodTypeAny, {
5898
+ message: {
5899
+ id: string;
5900
+ createdAt: Date;
5901
+ updatedAt: Date;
5902
+ deletedAt: Date | null;
5903
+ attribute: {
5904
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
4780
5905
  id: string;
5906
+ position: number;
4781
5907
  createdAt: Date;
4782
5908
  updatedAt: Date;
4783
5909
  deletedAt: Date | null;
4784
- }[];
4785
- contactEmails: {
5910
+ systemName: string;
5911
+ displayName: string;
5912
+ isDefault: boolean;
5913
+ isArchived: boolean;
5914
+ isRequired: boolean;
5915
+ isUnique: boolean;
5916
+ };
5917
+ textValue: string | null;
5918
+ booleanValue: boolean | null;
5919
+ numberValue: number | null;
5920
+ dateValue: Date | null;
5921
+ uploads: {
4786
5922
  id: string;
4787
- isPrimary: boolean;
4788
- email: string;
5923
+ status: string | null;
4789
5924
  createdAt: Date;
4790
5925
  updatedAt: Date;
4791
5926
  deletedAt: Date | null;
5927
+ fileName: string;
5928
+ fileKey: string;
5929
+ bucketName: string;
5930
+ fileSize: number;
5931
+ fileUrl: string | null;
4792
5932
  }[];
4793
- contactPhones: {
5933
+ };
5934
+ requestId: string;
5935
+ }, {
5936
+ message: {
5937
+ id: string;
5938
+ createdAt: Date;
5939
+ updatedAt: Date;
5940
+ deletedAt: Date | null;
5941
+ attribute: {
5942
+ type: "link" | "attachment" | "select" | "textarea" | "text" | "date";
4794
5943
  id: string;
4795
- isPrimary: boolean;
5944
+ position: number;
4796
5945
  createdAt: Date;
4797
5946
  updatedAt: Date;
4798
5947
  deletedAt: Date | null;
4799
- phone: string;
4800
- }[];
4801
- activityLogs?: {
5948
+ systemName: string;
5949
+ displayName: string;
5950
+ isDefault: boolean;
5951
+ isArchived: boolean;
5952
+ isRequired: boolean;
5953
+ isUnique: boolean;
5954
+ };
5955
+ textValue: string | null;
5956
+ booleanValue: boolean | null;
5957
+ numberValue: number | null;
5958
+ dateValue: Date | null;
5959
+ uploads: {
4802
5960
  id: string;
4803
- description: string;
5961
+ status: string | null;
4804
5962
  createdAt: Date;
4805
5963
  updatedAt: Date;
4806
5964
  deletedAt: Date | null;
4807
- entityId: string;
4808
- entityType: {
4809
- id: string;
4810
- description: string | null;
4811
- createdAt: Date;
4812
- updatedAt: Date;
4813
- deletedAt: Date | null;
4814
- entity: string;
4815
- };
4816
- }[] | undefined;
5965
+ fileName: string;
5966
+ fileKey: string;
5967
+ bucketName: string;
5968
+ fileSize: number;
5969
+ fileUrl: string | null;
5970
+ }[];
4817
5971
  };
4818
- message: string;
4819
- status: string;
4820
5972
  requestId: string;
4821
5973
  }>;
4822
5974
  400: z.ZodObject<{
@@ -4874,7 +6026,7 @@ export declare const publicApiContract: {
4874
6026
  error?: any;
4875
6027
  }>;
4876
6028
  };
4877
- path: "api/v1/contacts/:id";
6029
+ path: "api/v1/contacts/attachments";
4878
6030
  };
4879
6031
  deleteContact: {
4880
6032
  body: null;