zitejs 0.9.39 → 0.9.40

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.
@@ -0,0 +1,4624 @@
1
+ import { z } from "zod";
2
+ export declare const fieldSchema: z.ZodIntersection<z.ZodObject<{
3
+ id: z.ZodString;
4
+ order: z.ZodNumber;
5
+ }, "strip", z.ZodTypeAny, {
6
+ id: string;
7
+ order: number;
8
+ }, {
9
+ id: string;
10
+ order: number;
11
+ }>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
12
+ name: z.ZodString;
13
+ } & {
14
+ type: z.ZodLiteral<"currency">;
15
+ template: z.ZodObject<{
16
+ currencySymbol: z.ZodString;
17
+ decimalPlaces: z.ZodNumber;
18
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
19
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
20
+ }, "strip", z.ZodTypeAny, {
21
+ currencySymbol: string;
22
+ decimalPlaces: number;
23
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
24
+ defaultValue?: number | null | undefined;
25
+ }, {
26
+ currencySymbol: string;
27
+ decimalPlaces: number;
28
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
29
+ defaultValue?: number | null | undefined;
30
+ }>;
31
+ }, "strip", z.ZodTypeAny, {
32
+ type: "currency";
33
+ name: string;
34
+ template: {
35
+ currencySymbol: string;
36
+ decimalPlaces: number;
37
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
38
+ defaultValue?: number | null | undefined;
39
+ };
40
+ }, {
41
+ type: "currency";
42
+ name: string;
43
+ template: {
44
+ currencySymbol: string;
45
+ decimalPlaces: number;
46
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
47
+ defaultValue?: number | null | undefined;
48
+ };
49
+ }>, z.ZodObject<{
50
+ name: z.ZodString;
51
+ } & {
52
+ type: z.ZodLiteral<"single_line_text">;
53
+ template: z.ZodObject<{
54
+ defaultValue: z.ZodOptional<z.ZodString>;
55
+ }, "strip", z.ZodTypeAny, {
56
+ defaultValue?: string | undefined;
57
+ }, {
58
+ defaultValue?: string | undefined;
59
+ }>;
60
+ }, "strip", z.ZodTypeAny, {
61
+ type: "single_line_text";
62
+ name: string;
63
+ template: {
64
+ defaultValue?: string | undefined;
65
+ };
66
+ }, {
67
+ type: "single_line_text";
68
+ name: string;
69
+ template: {
70
+ defaultValue?: string | undefined;
71
+ };
72
+ }>, z.ZodObject<{
73
+ name: z.ZodString;
74
+ } & {
75
+ type: z.ZodLiteral<"long_text">;
76
+ template: z.ZodObject<{
77
+ defaultValue: z.ZodOptional<z.ZodString>;
78
+ }, "strip", z.ZodTypeAny, {
79
+ defaultValue?: string | undefined;
80
+ }, {
81
+ defaultValue?: string | undefined;
82
+ }>;
83
+ }, "strip", z.ZodTypeAny, {
84
+ type: "long_text";
85
+ name: string;
86
+ template: {
87
+ defaultValue?: string | undefined;
88
+ };
89
+ }, {
90
+ type: "long_text";
91
+ name: string;
92
+ template: {
93
+ defaultValue?: string | undefined;
94
+ };
95
+ }>, z.ZodObject<{
96
+ name: z.ZodString;
97
+ } & {
98
+ type: z.ZodLiteral<"rich_text">;
99
+ template: z.ZodObject<{
100
+ defaultValue: z.ZodOptional<z.ZodString>;
101
+ }, "strip", z.ZodTypeAny, {
102
+ defaultValue?: string | undefined;
103
+ }, {
104
+ defaultValue?: string | undefined;
105
+ }>;
106
+ }, "strip", z.ZodTypeAny, {
107
+ type: "rich_text";
108
+ name: string;
109
+ template: {
110
+ defaultValue?: string | undefined;
111
+ };
112
+ }, {
113
+ type: "rich_text";
114
+ name: string;
115
+ template: {
116
+ defaultValue?: string | undefined;
117
+ };
118
+ }>, z.ZodObject<{
119
+ name: z.ZodString;
120
+ } & {
121
+ type: z.ZodLiteral<"number">;
122
+ template: z.ZodObject<{
123
+ decimalPlaces: z.ZodNumber;
124
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
125
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
126
+ }, "strip", z.ZodTypeAny, {
127
+ decimalPlaces: number;
128
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
129
+ defaultValue?: number | null | undefined;
130
+ }, {
131
+ decimalPlaces: number;
132
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
133
+ defaultValue?: number | null | undefined;
134
+ }>;
135
+ }, "strip", z.ZodTypeAny, {
136
+ type: "number";
137
+ name: string;
138
+ template: {
139
+ decimalPlaces: number;
140
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
141
+ defaultValue?: number | null | undefined;
142
+ };
143
+ }, {
144
+ type: "number";
145
+ name: string;
146
+ template: {
147
+ decimalPlaces: number;
148
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
149
+ defaultValue?: number | null | undefined;
150
+ };
151
+ }>, z.ZodObject<{
152
+ name: z.ZodString;
153
+ } & {
154
+ type: z.ZodLiteral<"single_select">;
155
+ template: z.ZodObject<{
156
+ options: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
157
+ value: z.ZodString;
158
+ label: z.ZodString;
159
+ color: z.ZodOptional<z.ZodString>;
160
+ }, "strip", z.ZodTypeAny, {
161
+ value: string;
162
+ label: string;
163
+ color?: string | undefined;
164
+ }, {
165
+ value: string;
166
+ label: string;
167
+ color?: string | undefined;
168
+ }>, "many">>>, {
169
+ value: string;
170
+ label: string;
171
+ color?: string | undefined;
172
+ }[], {
173
+ value: string;
174
+ label: string;
175
+ color?: string | undefined;
176
+ }[] | null | undefined>;
177
+ disableColors: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
178
+ defaultValue: z.ZodOptional<z.ZodString>;
179
+ }, "strip", z.ZodTypeAny, {
180
+ options: {
181
+ value: string;
182
+ label: string;
183
+ color?: string | undefined;
184
+ }[];
185
+ disableColors: boolean;
186
+ defaultValue?: string | undefined;
187
+ }, {
188
+ options?: {
189
+ value: string;
190
+ label: string;
191
+ color?: string | undefined;
192
+ }[] | null | undefined;
193
+ defaultValue?: string | undefined;
194
+ disableColors?: boolean | null | undefined;
195
+ }>;
196
+ }, "strip", z.ZodTypeAny, {
197
+ type: "single_select";
198
+ name: string;
199
+ template: {
200
+ options: {
201
+ value: string;
202
+ label: string;
203
+ color?: string | undefined;
204
+ }[];
205
+ disableColors: boolean;
206
+ defaultValue?: string | undefined;
207
+ };
208
+ }, {
209
+ type: "single_select";
210
+ name: string;
211
+ template: {
212
+ options?: {
213
+ value: string;
214
+ label: string;
215
+ color?: string | undefined;
216
+ }[] | null | undefined;
217
+ defaultValue?: string | undefined;
218
+ disableColors?: boolean | null | undefined;
219
+ };
220
+ }>, z.ZodObject<{
221
+ name: z.ZodString;
222
+ } & {
223
+ type: z.ZodLiteral<"multiple_select">;
224
+ template: z.ZodObject<{
225
+ options: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
226
+ value: z.ZodString;
227
+ label: z.ZodString;
228
+ color: z.ZodOptional<z.ZodString>;
229
+ }, "strip", z.ZodTypeAny, {
230
+ value: string;
231
+ label: string;
232
+ color?: string | undefined;
233
+ }, {
234
+ value: string;
235
+ label: string;
236
+ color?: string | undefined;
237
+ }>, "many">>>, {
238
+ value: string;
239
+ label: string;
240
+ color?: string | undefined;
241
+ }[], {
242
+ value: string;
243
+ label: string;
244
+ color?: string | undefined;
245
+ }[] | null | undefined>;
246
+ disableColors: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
247
+ defaultValue: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
248
+ }, "strip", z.ZodTypeAny, {
249
+ options: {
250
+ value: string;
251
+ label: string;
252
+ color?: string | undefined;
253
+ }[];
254
+ disableColors: boolean;
255
+ defaultValue?: string[] | undefined;
256
+ }, {
257
+ options?: {
258
+ value: string;
259
+ label: string;
260
+ color?: string | undefined;
261
+ }[] | null | undefined;
262
+ defaultValue?: string[] | undefined;
263
+ disableColors?: boolean | null | undefined;
264
+ }>;
265
+ }, "strip", z.ZodTypeAny, {
266
+ type: "multiple_select";
267
+ name: string;
268
+ template: {
269
+ options: {
270
+ value: string;
271
+ label: string;
272
+ color?: string | undefined;
273
+ }[];
274
+ disableColors: boolean;
275
+ defaultValue?: string[] | undefined;
276
+ };
277
+ }, {
278
+ type: "multiple_select";
279
+ name: string;
280
+ template: {
281
+ options?: {
282
+ value: string;
283
+ label: string;
284
+ color?: string | undefined;
285
+ }[] | null | undefined;
286
+ defaultValue?: string[] | undefined;
287
+ disableColors?: boolean | null | undefined;
288
+ };
289
+ }>, z.ZodObject<{
290
+ name: z.ZodString;
291
+ } & {
292
+ type: z.ZodLiteral<"date">;
293
+ template: z.ZodObject<{
294
+ dateFormat: z.ZodEnum<["local", "long", "us", "european", "iso"]>;
295
+ }, "strip", z.ZodTypeAny, {
296
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
297
+ }, {
298
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
299
+ }>;
300
+ }, "strip", z.ZodTypeAny, {
301
+ type: "date";
302
+ name: string;
303
+ template: {
304
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
305
+ };
306
+ }, {
307
+ type: "date";
308
+ name: string;
309
+ template: {
310
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
311
+ };
312
+ }>, z.ZodObject<{
313
+ name: z.ZodString;
314
+ } & {
315
+ type: z.ZodLiteral<"datetime">;
316
+ template: z.ZodObject<{
317
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
318
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
319
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
320
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
321
+ }, "strip", z.ZodTypeAny, {
322
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
323
+ displayTimeZone: boolean;
324
+ timeFormat: "12h" | "24h";
325
+ timezone: string;
326
+ }, {
327
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
328
+ displayTimeZone?: boolean | null | undefined;
329
+ timeFormat?: "12h" | "24h" | null | undefined;
330
+ timezone?: string | null | undefined;
331
+ }>;
332
+ }, "strip", z.ZodTypeAny, {
333
+ type: "datetime";
334
+ name: string;
335
+ template: {
336
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
337
+ displayTimeZone: boolean;
338
+ timeFormat: "12h" | "24h";
339
+ timezone: string;
340
+ };
341
+ }, {
342
+ type: "datetime";
343
+ name: string;
344
+ template: {
345
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
346
+ displayTimeZone?: boolean | null | undefined;
347
+ timeFormat?: "12h" | "24h" | null | undefined;
348
+ timezone?: string | null | undefined;
349
+ };
350
+ }>, z.ZodObject<{
351
+ name: z.ZodString;
352
+ } & {
353
+ type: z.ZodLiteral<"checkbox">;
354
+ template: z.ZodObject<{
355
+ defaultValue: z.ZodOptional<z.ZodBoolean>;
356
+ }, "strip", z.ZodTypeAny, {
357
+ defaultValue?: boolean | undefined;
358
+ }, {
359
+ defaultValue?: boolean | undefined;
360
+ }>;
361
+ }, "strip", z.ZodTypeAny, {
362
+ type: "checkbox";
363
+ name: string;
364
+ template: {
365
+ defaultValue?: boolean | undefined;
366
+ };
367
+ }, {
368
+ type: "checkbox";
369
+ name: string;
370
+ template: {
371
+ defaultValue?: boolean | undefined;
372
+ };
373
+ }>, z.ZodObject<{
374
+ name: z.ZodString;
375
+ } & {
376
+ type: z.ZodLiteral<"attachments">;
377
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
378
+ }, "strip", z.ZodTypeAny, {
379
+ type: "attachments";
380
+ name: string;
381
+ template: {};
382
+ }, {
383
+ type: "attachments";
384
+ name: string;
385
+ template: {};
386
+ }>, z.ZodObject<{
387
+ name: z.ZodString;
388
+ } & {
389
+ type: z.ZodLiteral<"email">;
390
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
391
+ }, "strip", z.ZodTypeAny, {
392
+ type: "email";
393
+ name: string;
394
+ template: {};
395
+ }, {
396
+ type: "email";
397
+ name: string;
398
+ template: {};
399
+ }>, z.ZodObject<{
400
+ name: z.ZodString;
401
+ } & {
402
+ type: z.ZodLiteral<"url">;
403
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
404
+ }, "strip", z.ZodTypeAny, {
405
+ type: "url";
406
+ name: string;
407
+ template: {};
408
+ }, {
409
+ type: "url";
410
+ name: string;
411
+ template: {};
412
+ }>, z.ZodObject<{
413
+ name: z.ZodString;
414
+ } & {
415
+ type: z.ZodLiteral<"phone_number">;
416
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
417
+ }, "strip", z.ZodTypeAny, {
418
+ type: "phone_number";
419
+ name: string;
420
+ template: {};
421
+ }, {
422
+ type: "phone_number";
423
+ name: string;
424
+ template: {};
425
+ }>, z.ZodObject<{
426
+ name: z.ZodString;
427
+ } & {
428
+ type: z.ZodLiteral<"rating">;
429
+ template: z.ZodObject<{
430
+ maxRating: z.ZodNumber;
431
+ defaultValue: z.ZodOptional<z.ZodNumber>;
432
+ }, "strip", z.ZodTypeAny, {
433
+ maxRating: number;
434
+ defaultValue?: number | undefined;
435
+ }, {
436
+ maxRating: number;
437
+ defaultValue?: number | undefined;
438
+ }>;
439
+ }, "strip", z.ZodTypeAny, {
440
+ type: "rating";
441
+ name: string;
442
+ template: {
443
+ maxRating: number;
444
+ defaultValue?: number | undefined;
445
+ };
446
+ }, {
447
+ type: "rating";
448
+ name: string;
449
+ template: {
450
+ maxRating: number;
451
+ defaultValue?: number | undefined;
452
+ };
453
+ }>, z.ZodObject<{
454
+ name: z.ZodString;
455
+ } & {
456
+ type: z.ZodLiteral<"duration">;
457
+ template: z.ZodObject<{
458
+ format: z.ZodEnum<["h:mm", "h:mm:ss", "h:mm:ss.s", "h:mm:ss.ss", "h:mm:ss.sss"]>;
459
+ defaultValue: z.ZodOptional<z.ZodNumber>;
460
+ }, "strip", z.ZodTypeAny, {
461
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
462
+ defaultValue?: number | undefined;
463
+ }, {
464
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
465
+ defaultValue?: number | undefined;
466
+ }>;
467
+ }, "strip", z.ZodTypeAny, {
468
+ type: "duration";
469
+ name: string;
470
+ template: {
471
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
472
+ defaultValue?: number | undefined;
473
+ };
474
+ }, {
475
+ type: "duration";
476
+ name: string;
477
+ template: {
478
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
479
+ defaultValue?: number | undefined;
480
+ };
481
+ }>, z.ZodObject<{
482
+ name: z.ZodString;
483
+ } & {
484
+ type: z.ZodLiteral<"percent">;
485
+ template: z.ZodObject<{
486
+ decimalPlaces: z.ZodNumber;
487
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
488
+ showProgressBar: z.ZodBoolean;
489
+ allowNegative: z.ZodBoolean;
490
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
491
+ }, "strip", z.ZodTypeAny, {
492
+ decimalPlaces: number;
493
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
494
+ showProgressBar: boolean;
495
+ allowNegative: boolean;
496
+ defaultValue?: number | null | undefined;
497
+ }, {
498
+ decimalPlaces: number;
499
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
500
+ showProgressBar: boolean;
501
+ allowNegative: boolean;
502
+ defaultValue?: number | null | undefined;
503
+ }>;
504
+ }, "strip", z.ZodTypeAny, {
505
+ type: "percent";
506
+ name: string;
507
+ template: {
508
+ decimalPlaces: number;
509
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
510
+ showProgressBar: boolean;
511
+ allowNegative: boolean;
512
+ defaultValue?: number | null | undefined;
513
+ };
514
+ }, {
515
+ type: "percent";
516
+ name: string;
517
+ template: {
518
+ decimalPlaces: number;
519
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
520
+ showProgressBar: boolean;
521
+ allowNegative: boolean;
522
+ defaultValue?: number | null | undefined;
523
+ };
524
+ }>, z.ZodObject<{
525
+ name: z.ZodString;
526
+ } & {
527
+ type: z.ZodLiteral<"linked_record">;
528
+ template: z.ZodObject<{
529
+ tableId: z.ZodString;
530
+ allowMultiple: z.ZodOptional<z.ZodBoolean>;
531
+ }, "strip", z.ZodTypeAny, {
532
+ tableId: string;
533
+ allowMultiple?: boolean | undefined;
534
+ }, {
535
+ tableId: string;
536
+ allowMultiple?: boolean | undefined;
537
+ }>;
538
+ }, "strip", z.ZodTypeAny, {
539
+ type: "linked_record";
540
+ name: string;
541
+ template: {
542
+ tableId: string;
543
+ allowMultiple?: boolean | undefined;
544
+ };
545
+ }, {
546
+ type: "linked_record";
547
+ name: string;
548
+ template: {
549
+ tableId: string;
550
+ allowMultiple?: boolean | undefined;
551
+ };
552
+ }>, z.ZodObject<{
553
+ name: z.ZodString;
554
+ } & {
555
+ type: z.ZodLiteral<"lookup">;
556
+ template: z.ZodObject<{
557
+ linkedRecordFieldId: z.ZodString;
558
+ lookupFieldId: z.ZodString;
559
+ formulaExpression: z.ZodOptional<z.ZodString>;
560
+ resultType: z.ZodOptional<z.ZodEnum<["text", "number", "date", "boolean", "array"]>>;
561
+ }, "strip", z.ZodTypeAny, {
562
+ linkedRecordFieldId: string;
563
+ lookupFieldId: string;
564
+ formulaExpression?: string | undefined;
565
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
566
+ }, {
567
+ linkedRecordFieldId: string;
568
+ lookupFieldId: string;
569
+ formulaExpression?: string | undefined;
570
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
571
+ }>;
572
+ }, "strip", z.ZodTypeAny, {
573
+ type: "lookup";
574
+ name: string;
575
+ template: {
576
+ linkedRecordFieldId: string;
577
+ lookupFieldId: string;
578
+ formulaExpression?: string | undefined;
579
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
580
+ };
581
+ }, {
582
+ type: "lookup";
583
+ name: string;
584
+ template: {
585
+ linkedRecordFieldId: string;
586
+ lookupFieldId: string;
587
+ formulaExpression?: string | undefined;
588
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
589
+ };
590
+ }>, z.ZodObject<{
591
+ name: z.ZodString;
592
+ } & {
593
+ type: z.ZodLiteral<"source">;
594
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
595
+ }, "strip", z.ZodTypeAny, {
596
+ type: "source";
597
+ name: string;
598
+ template: {};
599
+ }, {
600
+ type: "source";
601
+ name: string;
602
+ template: {};
603
+ }>, z.ZodObject<{
604
+ name: z.ZodString;
605
+ } & {
606
+ type: z.ZodLiteral<"formula">;
607
+ template: z.ZodObject<{
608
+ expression: z.ZodString;
609
+ resultType: z.ZodOptional<z.ZodEnum<["text", "number", "date", "boolean", "array"]>>;
610
+ formatting: z.ZodOptional<z.ZodObject<{
611
+ numberDisplayType: z.ZodOptional<z.ZodEnum<["number", "currency", "percent", "duration"]>>;
612
+ currencyCode: z.ZodOptional<z.ZodString>;
613
+ decimalPlaces: z.ZodOptional<z.ZodNumber>;
614
+ numberFormat: z.ZodOptional<z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period"]>>;
615
+ }, "strip", z.ZodTypeAny, {
616
+ decimalPlaces?: number | undefined;
617
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
618
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
619
+ currencyCode?: string | undefined;
620
+ }, {
621
+ decimalPlaces?: number | undefined;
622
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
623
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
624
+ currencyCode?: string | undefined;
625
+ }>>;
626
+ }, "strip", z.ZodTypeAny, {
627
+ expression: string;
628
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
629
+ formatting?: {
630
+ decimalPlaces?: number | undefined;
631
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
632
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
633
+ currencyCode?: string | undefined;
634
+ } | undefined;
635
+ }, {
636
+ expression: string;
637
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
638
+ formatting?: {
639
+ decimalPlaces?: number | undefined;
640
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
641
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
642
+ currencyCode?: string | undefined;
643
+ } | undefined;
644
+ }>;
645
+ }, "strip", z.ZodTypeAny, {
646
+ type: "formula";
647
+ name: string;
648
+ template: {
649
+ expression: string;
650
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
651
+ formatting?: {
652
+ decimalPlaces?: number | undefined;
653
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
654
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
655
+ currencyCode?: string | undefined;
656
+ } | undefined;
657
+ };
658
+ }, {
659
+ type: "formula";
660
+ name: string;
661
+ template: {
662
+ expression: string;
663
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
664
+ formatting?: {
665
+ decimalPlaces?: number | undefined;
666
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
667
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
668
+ currencyCode?: string | undefined;
669
+ } | undefined;
670
+ };
671
+ }>, z.ZodObject<{
672
+ name: z.ZodString;
673
+ } & {
674
+ type: z.ZodLiteral<"autonumber">;
675
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
676
+ }, "strip", z.ZodTypeAny, {
677
+ type: "autonumber";
678
+ name: string;
679
+ template: {};
680
+ }, {
681
+ type: "autonumber";
682
+ name: string;
683
+ template: {};
684
+ }>, z.ZodObject<{
685
+ name: z.ZodString;
686
+ } & {
687
+ type: z.ZodLiteral<"created_at">;
688
+ template: z.ZodObject<{
689
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
690
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
691
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
692
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
693
+ }, "strip", z.ZodTypeAny, {
694
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
695
+ displayTimeZone: boolean;
696
+ timeFormat: "12h" | "24h";
697
+ timezone: string;
698
+ }, {
699
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
700
+ displayTimeZone?: boolean | null | undefined;
701
+ timeFormat?: "12h" | "24h" | null | undefined;
702
+ timezone?: string | null | undefined;
703
+ }>;
704
+ }, "strip", z.ZodTypeAny, {
705
+ type: "created_at";
706
+ name: string;
707
+ template: {
708
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
709
+ displayTimeZone: boolean;
710
+ timeFormat: "12h" | "24h";
711
+ timezone: string;
712
+ };
713
+ }, {
714
+ type: "created_at";
715
+ name: string;
716
+ template: {
717
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
718
+ displayTimeZone?: boolean | null | undefined;
719
+ timeFormat?: "12h" | "24h" | null | undefined;
720
+ timezone?: string | null | undefined;
721
+ };
722
+ }>, z.ZodObject<{
723
+ name: z.ZodString;
724
+ } & {
725
+ type: z.ZodLiteral<"updated_at">;
726
+ template: z.ZodObject<{
727
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
728
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
729
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
730
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
731
+ }, "strip", z.ZodTypeAny, {
732
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
733
+ displayTimeZone: boolean;
734
+ timeFormat: "12h" | "24h";
735
+ timezone: string;
736
+ }, {
737
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
738
+ displayTimeZone?: boolean | null | undefined;
739
+ timeFormat?: "12h" | "24h" | null | undefined;
740
+ timezone?: string | null | undefined;
741
+ }>;
742
+ }, "strip", z.ZodTypeAny, {
743
+ type: "updated_at";
744
+ name: string;
745
+ template: {
746
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
747
+ displayTimeZone: boolean;
748
+ timeFormat: "12h" | "24h";
749
+ timezone: string;
750
+ };
751
+ }, {
752
+ type: "updated_at";
753
+ name: string;
754
+ template: {
755
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
756
+ displayTimeZone?: boolean | null | undefined;
757
+ timeFormat?: "12h" | "24h" | null | undefined;
758
+ timezone?: string | null | undefined;
759
+ };
760
+ }>]>>;
761
+ export type Field = z.infer<typeof fieldSchema>;
762
+ export declare const viewSchema: z.ZodObject<{
763
+ id: z.ZodString;
764
+ name: z.ZodString;
765
+ type: z.ZodString;
766
+ config: z.ZodUnknown;
767
+ }, "strip", z.ZodTypeAny, {
768
+ id: string;
769
+ type: string;
770
+ name: string;
771
+ config?: unknown;
772
+ }, {
773
+ id: string;
774
+ type: string;
775
+ name: string;
776
+ config?: unknown;
777
+ }>;
778
+ export type View = z.infer<typeof viewSchema>;
779
+ export declare const tableSchema: z.ZodObject<{
780
+ id: z.ZodString;
781
+ name: z.ZodString;
782
+ order: z.ZodNumber;
783
+ primaryFieldId: z.ZodString;
784
+ fields: z.ZodArray<z.ZodIntersection<z.ZodObject<{
785
+ id: z.ZodString;
786
+ order: z.ZodNumber;
787
+ }, "strip", z.ZodTypeAny, {
788
+ id: string;
789
+ order: number;
790
+ }, {
791
+ id: string;
792
+ order: number;
793
+ }>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
794
+ name: z.ZodString;
795
+ } & {
796
+ type: z.ZodLiteral<"currency">;
797
+ template: z.ZodObject<{
798
+ currencySymbol: z.ZodString;
799
+ decimalPlaces: z.ZodNumber;
800
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
801
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
802
+ }, "strip", z.ZodTypeAny, {
803
+ currencySymbol: string;
804
+ decimalPlaces: number;
805
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
806
+ defaultValue?: number | null | undefined;
807
+ }, {
808
+ currencySymbol: string;
809
+ decimalPlaces: number;
810
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
811
+ defaultValue?: number | null | undefined;
812
+ }>;
813
+ }, "strip", z.ZodTypeAny, {
814
+ type: "currency";
815
+ name: string;
816
+ template: {
817
+ currencySymbol: string;
818
+ decimalPlaces: number;
819
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
820
+ defaultValue?: number | null | undefined;
821
+ };
822
+ }, {
823
+ type: "currency";
824
+ name: string;
825
+ template: {
826
+ currencySymbol: string;
827
+ decimalPlaces: number;
828
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
829
+ defaultValue?: number | null | undefined;
830
+ };
831
+ }>, z.ZodObject<{
832
+ name: z.ZodString;
833
+ } & {
834
+ type: z.ZodLiteral<"single_line_text">;
835
+ template: z.ZodObject<{
836
+ defaultValue: z.ZodOptional<z.ZodString>;
837
+ }, "strip", z.ZodTypeAny, {
838
+ defaultValue?: string | undefined;
839
+ }, {
840
+ defaultValue?: string | undefined;
841
+ }>;
842
+ }, "strip", z.ZodTypeAny, {
843
+ type: "single_line_text";
844
+ name: string;
845
+ template: {
846
+ defaultValue?: string | undefined;
847
+ };
848
+ }, {
849
+ type: "single_line_text";
850
+ name: string;
851
+ template: {
852
+ defaultValue?: string | undefined;
853
+ };
854
+ }>, z.ZodObject<{
855
+ name: z.ZodString;
856
+ } & {
857
+ type: z.ZodLiteral<"long_text">;
858
+ template: z.ZodObject<{
859
+ defaultValue: z.ZodOptional<z.ZodString>;
860
+ }, "strip", z.ZodTypeAny, {
861
+ defaultValue?: string | undefined;
862
+ }, {
863
+ defaultValue?: string | undefined;
864
+ }>;
865
+ }, "strip", z.ZodTypeAny, {
866
+ type: "long_text";
867
+ name: string;
868
+ template: {
869
+ defaultValue?: string | undefined;
870
+ };
871
+ }, {
872
+ type: "long_text";
873
+ name: string;
874
+ template: {
875
+ defaultValue?: string | undefined;
876
+ };
877
+ }>, z.ZodObject<{
878
+ name: z.ZodString;
879
+ } & {
880
+ type: z.ZodLiteral<"rich_text">;
881
+ template: z.ZodObject<{
882
+ defaultValue: z.ZodOptional<z.ZodString>;
883
+ }, "strip", z.ZodTypeAny, {
884
+ defaultValue?: string | undefined;
885
+ }, {
886
+ defaultValue?: string | undefined;
887
+ }>;
888
+ }, "strip", z.ZodTypeAny, {
889
+ type: "rich_text";
890
+ name: string;
891
+ template: {
892
+ defaultValue?: string | undefined;
893
+ };
894
+ }, {
895
+ type: "rich_text";
896
+ name: string;
897
+ template: {
898
+ defaultValue?: string | undefined;
899
+ };
900
+ }>, z.ZodObject<{
901
+ name: z.ZodString;
902
+ } & {
903
+ type: z.ZodLiteral<"number">;
904
+ template: z.ZodObject<{
905
+ decimalPlaces: z.ZodNumber;
906
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
907
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
908
+ }, "strip", z.ZodTypeAny, {
909
+ decimalPlaces: number;
910
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
911
+ defaultValue?: number | null | undefined;
912
+ }, {
913
+ decimalPlaces: number;
914
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
915
+ defaultValue?: number | null | undefined;
916
+ }>;
917
+ }, "strip", z.ZodTypeAny, {
918
+ type: "number";
919
+ name: string;
920
+ template: {
921
+ decimalPlaces: number;
922
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
923
+ defaultValue?: number | null | undefined;
924
+ };
925
+ }, {
926
+ type: "number";
927
+ name: string;
928
+ template: {
929
+ decimalPlaces: number;
930
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
931
+ defaultValue?: number | null | undefined;
932
+ };
933
+ }>, z.ZodObject<{
934
+ name: z.ZodString;
935
+ } & {
936
+ type: z.ZodLiteral<"single_select">;
937
+ template: z.ZodObject<{
938
+ options: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
939
+ value: z.ZodString;
940
+ label: z.ZodString;
941
+ color: z.ZodOptional<z.ZodString>;
942
+ }, "strip", z.ZodTypeAny, {
943
+ value: string;
944
+ label: string;
945
+ color?: string | undefined;
946
+ }, {
947
+ value: string;
948
+ label: string;
949
+ color?: string | undefined;
950
+ }>, "many">>>, {
951
+ value: string;
952
+ label: string;
953
+ color?: string | undefined;
954
+ }[], {
955
+ value: string;
956
+ label: string;
957
+ color?: string | undefined;
958
+ }[] | null | undefined>;
959
+ disableColors: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
960
+ defaultValue: z.ZodOptional<z.ZodString>;
961
+ }, "strip", z.ZodTypeAny, {
962
+ options: {
963
+ value: string;
964
+ label: string;
965
+ color?: string | undefined;
966
+ }[];
967
+ disableColors: boolean;
968
+ defaultValue?: string | undefined;
969
+ }, {
970
+ options?: {
971
+ value: string;
972
+ label: string;
973
+ color?: string | undefined;
974
+ }[] | null | undefined;
975
+ defaultValue?: string | undefined;
976
+ disableColors?: boolean | null | undefined;
977
+ }>;
978
+ }, "strip", z.ZodTypeAny, {
979
+ type: "single_select";
980
+ name: string;
981
+ template: {
982
+ options: {
983
+ value: string;
984
+ label: string;
985
+ color?: string | undefined;
986
+ }[];
987
+ disableColors: boolean;
988
+ defaultValue?: string | undefined;
989
+ };
990
+ }, {
991
+ type: "single_select";
992
+ name: string;
993
+ template: {
994
+ options?: {
995
+ value: string;
996
+ label: string;
997
+ color?: string | undefined;
998
+ }[] | null | undefined;
999
+ defaultValue?: string | undefined;
1000
+ disableColors?: boolean | null | undefined;
1001
+ };
1002
+ }>, z.ZodObject<{
1003
+ name: z.ZodString;
1004
+ } & {
1005
+ type: z.ZodLiteral<"multiple_select">;
1006
+ template: z.ZodObject<{
1007
+ options: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
1008
+ value: z.ZodString;
1009
+ label: z.ZodString;
1010
+ color: z.ZodOptional<z.ZodString>;
1011
+ }, "strip", z.ZodTypeAny, {
1012
+ value: string;
1013
+ label: string;
1014
+ color?: string | undefined;
1015
+ }, {
1016
+ value: string;
1017
+ label: string;
1018
+ color?: string | undefined;
1019
+ }>, "many">>>, {
1020
+ value: string;
1021
+ label: string;
1022
+ color?: string | undefined;
1023
+ }[], {
1024
+ value: string;
1025
+ label: string;
1026
+ color?: string | undefined;
1027
+ }[] | null | undefined>;
1028
+ disableColors: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
1029
+ defaultValue: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1030
+ }, "strip", z.ZodTypeAny, {
1031
+ options: {
1032
+ value: string;
1033
+ label: string;
1034
+ color?: string | undefined;
1035
+ }[];
1036
+ disableColors: boolean;
1037
+ defaultValue?: string[] | undefined;
1038
+ }, {
1039
+ options?: {
1040
+ value: string;
1041
+ label: string;
1042
+ color?: string | undefined;
1043
+ }[] | null | undefined;
1044
+ defaultValue?: string[] | undefined;
1045
+ disableColors?: boolean | null | undefined;
1046
+ }>;
1047
+ }, "strip", z.ZodTypeAny, {
1048
+ type: "multiple_select";
1049
+ name: string;
1050
+ template: {
1051
+ options: {
1052
+ value: string;
1053
+ label: string;
1054
+ color?: string | undefined;
1055
+ }[];
1056
+ disableColors: boolean;
1057
+ defaultValue?: string[] | undefined;
1058
+ };
1059
+ }, {
1060
+ type: "multiple_select";
1061
+ name: string;
1062
+ template: {
1063
+ options?: {
1064
+ value: string;
1065
+ label: string;
1066
+ color?: string | undefined;
1067
+ }[] | null | undefined;
1068
+ defaultValue?: string[] | undefined;
1069
+ disableColors?: boolean | null | undefined;
1070
+ };
1071
+ }>, z.ZodObject<{
1072
+ name: z.ZodString;
1073
+ } & {
1074
+ type: z.ZodLiteral<"date">;
1075
+ template: z.ZodObject<{
1076
+ dateFormat: z.ZodEnum<["local", "long", "us", "european", "iso"]>;
1077
+ }, "strip", z.ZodTypeAny, {
1078
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1079
+ }, {
1080
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1081
+ }>;
1082
+ }, "strip", z.ZodTypeAny, {
1083
+ type: "date";
1084
+ name: string;
1085
+ template: {
1086
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1087
+ };
1088
+ }, {
1089
+ type: "date";
1090
+ name: string;
1091
+ template: {
1092
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1093
+ };
1094
+ }>, z.ZodObject<{
1095
+ name: z.ZodString;
1096
+ } & {
1097
+ type: z.ZodLiteral<"datetime">;
1098
+ template: z.ZodObject<{
1099
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
1100
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
1101
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
1102
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
1103
+ }, "strip", z.ZodTypeAny, {
1104
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1105
+ displayTimeZone: boolean;
1106
+ timeFormat: "12h" | "24h";
1107
+ timezone: string;
1108
+ }, {
1109
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
1110
+ displayTimeZone?: boolean | null | undefined;
1111
+ timeFormat?: "12h" | "24h" | null | undefined;
1112
+ timezone?: string | null | undefined;
1113
+ }>;
1114
+ }, "strip", z.ZodTypeAny, {
1115
+ type: "datetime";
1116
+ name: string;
1117
+ template: {
1118
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1119
+ displayTimeZone: boolean;
1120
+ timeFormat: "12h" | "24h";
1121
+ timezone: string;
1122
+ };
1123
+ }, {
1124
+ type: "datetime";
1125
+ name: string;
1126
+ template: {
1127
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
1128
+ displayTimeZone?: boolean | null | undefined;
1129
+ timeFormat?: "12h" | "24h" | null | undefined;
1130
+ timezone?: string | null | undefined;
1131
+ };
1132
+ }>, z.ZodObject<{
1133
+ name: z.ZodString;
1134
+ } & {
1135
+ type: z.ZodLiteral<"checkbox">;
1136
+ template: z.ZodObject<{
1137
+ defaultValue: z.ZodOptional<z.ZodBoolean>;
1138
+ }, "strip", z.ZodTypeAny, {
1139
+ defaultValue?: boolean | undefined;
1140
+ }, {
1141
+ defaultValue?: boolean | undefined;
1142
+ }>;
1143
+ }, "strip", z.ZodTypeAny, {
1144
+ type: "checkbox";
1145
+ name: string;
1146
+ template: {
1147
+ defaultValue?: boolean | undefined;
1148
+ };
1149
+ }, {
1150
+ type: "checkbox";
1151
+ name: string;
1152
+ template: {
1153
+ defaultValue?: boolean | undefined;
1154
+ };
1155
+ }>, z.ZodObject<{
1156
+ name: z.ZodString;
1157
+ } & {
1158
+ type: z.ZodLiteral<"attachments">;
1159
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
1160
+ }, "strip", z.ZodTypeAny, {
1161
+ type: "attachments";
1162
+ name: string;
1163
+ template: {};
1164
+ }, {
1165
+ type: "attachments";
1166
+ name: string;
1167
+ template: {};
1168
+ }>, z.ZodObject<{
1169
+ name: z.ZodString;
1170
+ } & {
1171
+ type: z.ZodLiteral<"email">;
1172
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
1173
+ }, "strip", z.ZodTypeAny, {
1174
+ type: "email";
1175
+ name: string;
1176
+ template: {};
1177
+ }, {
1178
+ type: "email";
1179
+ name: string;
1180
+ template: {};
1181
+ }>, z.ZodObject<{
1182
+ name: z.ZodString;
1183
+ } & {
1184
+ type: z.ZodLiteral<"url">;
1185
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
1186
+ }, "strip", z.ZodTypeAny, {
1187
+ type: "url";
1188
+ name: string;
1189
+ template: {};
1190
+ }, {
1191
+ type: "url";
1192
+ name: string;
1193
+ template: {};
1194
+ }>, z.ZodObject<{
1195
+ name: z.ZodString;
1196
+ } & {
1197
+ type: z.ZodLiteral<"phone_number">;
1198
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
1199
+ }, "strip", z.ZodTypeAny, {
1200
+ type: "phone_number";
1201
+ name: string;
1202
+ template: {};
1203
+ }, {
1204
+ type: "phone_number";
1205
+ name: string;
1206
+ template: {};
1207
+ }>, z.ZodObject<{
1208
+ name: z.ZodString;
1209
+ } & {
1210
+ type: z.ZodLiteral<"rating">;
1211
+ template: z.ZodObject<{
1212
+ maxRating: z.ZodNumber;
1213
+ defaultValue: z.ZodOptional<z.ZodNumber>;
1214
+ }, "strip", z.ZodTypeAny, {
1215
+ maxRating: number;
1216
+ defaultValue?: number | undefined;
1217
+ }, {
1218
+ maxRating: number;
1219
+ defaultValue?: number | undefined;
1220
+ }>;
1221
+ }, "strip", z.ZodTypeAny, {
1222
+ type: "rating";
1223
+ name: string;
1224
+ template: {
1225
+ maxRating: number;
1226
+ defaultValue?: number | undefined;
1227
+ };
1228
+ }, {
1229
+ type: "rating";
1230
+ name: string;
1231
+ template: {
1232
+ maxRating: number;
1233
+ defaultValue?: number | undefined;
1234
+ };
1235
+ }>, z.ZodObject<{
1236
+ name: z.ZodString;
1237
+ } & {
1238
+ type: z.ZodLiteral<"duration">;
1239
+ template: z.ZodObject<{
1240
+ format: z.ZodEnum<["h:mm", "h:mm:ss", "h:mm:ss.s", "h:mm:ss.ss", "h:mm:ss.sss"]>;
1241
+ defaultValue: z.ZodOptional<z.ZodNumber>;
1242
+ }, "strip", z.ZodTypeAny, {
1243
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
1244
+ defaultValue?: number | undefined;
1245
+ }, {
1246
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
1247
+ defaultValue?: number | undefined;
1248
+ }>;
1249
+ }, "strip", z.ZodTypeAny, {
1250
+ type: "duration";
1251
+ name: string;
1252
+ template: {
1253
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
1254
+ defaultValue?: number | undefined;
1255
+ };
1256
+ }, {
1257
+ type: "duration";
1258
+ name: string;
1259
+ template: {
1260
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
1261
+ defaultValue?: number | undefined;
1262
+ };
1263
+ }>, z.ZodObject<{
1264
+ name: z.ZodString;
1265
+ } & {
1266
+ type: z.ZodLiteral<"percent">;
1267
+ template: z.ZodObject<{
1268
+ decimalPlaces: z.ZodNumber;
1269
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
1270
+ showProgressBar: z.ZodBoolean;
1271
+ allowNegative: z.ZodBoolean;
1272
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1273
+ }, "strip", z.ZodTypeAny, {
1274
+ decimalPlaces: number;
1275
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1276
+ showProgressBar: boolean;
1277
+ allowNegative: boolean;
1278
+ defaultValue?: number | null | undefined;
1279
+ }, {
1280
+ decimalPlaces: number;
1281
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1282
+ showProgressBar: boolean;
1283
+ allowNegative: boolean;
1284
+ defaultValue?: number | null | undefined;
1285
+ }>;
1286
+ }, "strip", z.ZodTypeAny, {
1287
+ type: "percent";
1288
+ name: string;
1289
+ template: {
1290
+ decimalPlaces: number;
1291
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1292
+ showProgressBar: boolean;
1293
+ allowNegative: boolean;
1294
+ defaultValue?: number | null | undefined;
1295
+ };
1296
+ }, {
1297
+ type: "percent";
1298
+ name: string;
1299
+ template: {
1300
+ decimalPlaces: number;
1301
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1302
+ showProgressBar: boolean;
1303
+ allowNegative: boolean;
1304
+ defaultValue?: number | null | undefined;
1305
+ };
1306
+ }>, z.ZodObject<{
1307
+ name: z.ZodString;
1308
+ } & {
1309
+ type: z.ZodLiteral<"linked_record">;
1310
+ template: z.ZodObject<{
1311
+ tableId: z.ZodString;
1312
+ allowMultiple: z.ZodOptional<z.ZodBoolean>;
1313
+ }, "strip", z.ZodTypeAny, {
1314
+ tableId: string;
1315
+ allowMultiple?: boolean | undefined;
1316
+ }, {
1317
+ tableId: string;
1318
+ allowMultiple?: boolean | undefined;
1319
+ }>;
1320
+ }, "strip", z.ZodTypeAny, {
1321
+ type: "linked_record";
1322
+ name: string;
1323
+ template: {
1324
+ tableId: string;
1325
+ allowMultiple?: boolean | undefined;
1326
+ };
1327
+ }, {
1328
+ type: "linked_record";
1329
+ name: string;
1330
+ template: {
1331
+ tableId: string;
1332
+ allowMultiple?: boolean | undefined;
1333
+ };
1334
+ }>, z.ZodObject<{
1335
+ name: z.ZodString;
1336
+ } & {
1337
+ type: z.ZodLiteral<"lookup">;
1338
+ template: z.ZodObject<{
1339
+ linkedRecordFieldId: z.ZodString;
1340
+ lookupFieldId: z.ZodString;
1341
+ formulaExpression: z.ZodOptional<z.ZodString>;
1342
+ resultType: z.ZodOptional<z.ZodEnum<["text", "number", "date", "boolean", "array"]>>;
1343
+ }, "strip", z.ZodTypeAny, {
1344
+ linkedRecordFieldId: string;
1345
+ lookupFieldId: string;
1346
+ formulaExpression?: string | undefined;
1347
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1348
+ }, {
1349
+ linkedRecordFieldId: string;
1350
+ lookupFieldId: string;
1351
+ formulaExpression?: string | undefined;
1352
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1353
+ }>;
1354
+ }, "strip", z.ZodTypeAny, {
1355
+ type: "lookup";
1356
+ name: string;
1357
+ template: {
1358
+ linkedRecordFieldId: string;
1359
+ lookupFieldId: string;
1360
+ formulaExpression?: string | undefined;
1361
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1362
+ };
1363
+ }, {
1364
+ type: "lookup";
1365
+ name: string;
1366
+ template: {
1367
+ linkedRecordFieldId: string;
1368
+ lookupFieldId: string;
1369
+ formulaExpression?: string | undefined;
1370
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1371
+ };
1372
+ }>, z.ZodObject<{
1373
+ name: z.ZodString;
1374
+ } & {
1375
+ type: z.ZodLiteral<"source">;
1376
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
1377
+ }, "strip", z.ZodTypeAny, {
1378
+ type: "source";
1379
+ name: string;
1380
+ template: {};
1381
+ }, {
1382
+ type: "source";
1383
+ name: string;
1384
+ template: {};
1385
+ }>, z.ZodObject<{
1386
+ name: z.ZodString;
1387
+ } & {
1388
+ type: z.ZodLiteral<"formula">;
1389
+ template: z.ZodObject<{
1390
+ expression: z.ZodString;
1391
+ resultType: z.ZodOptional<z.ZodEnum<["text", "number", "date", "boolean", "array"]>>;
1392
+ formatting: z.ZodOptional<z.ZodObject<{
1393
+ numberDisplayType: z.ZodOptional<z.ZodEnum<["number", "currency", "percent", "duration"]>>;
1394
+ currencyCode: z.ZodOptional<z.ZodString>;
1395
+ decimalPlaces: z.ZodOptional<z.ZodNumber>;
1396
+ numberFormat: z.ZodOptional<z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period"]>>;
1397
+ }, "strip", z.ZodTypeAny, {
1398
+ decimalPlaces?: number | undefined;
1399
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
1400
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
1401
+ currencyCode?: string | undefined;
1402
+ }, {
1403
+ decimalPlaces?: number | undefined;
1404
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
1405
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
1406
+ currencyCode?: string | undefined;
1407
+ }>>;
1408
+ }, "strip", z.ZodTypeAny, {
1409
+ expression: string;
1410
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1411
+ formatting?: {
1412
+ decimalPlaces?: number | undefined;
1413
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
1414
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
1415
+ currencyCode?: string | undefined;
1416
+ } | undefined;
1417
+ }, {
1418
+ expression: string;
1419
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1420
+ formatting?: {
1421
+ decimalPlaces?: number | undefined;
1422
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
1423
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
1424
+ currencyCode?: string | undefined;
1425
+ } | undefined;
1426
+ }>;
1427
+ }, "strip", z.ZodTypeAny, {
1428
+ type: "formula";
1429
+ name: string;
1430
+ template: {
1431
+ expression: string;
1432
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1433
+ formatting?: {
1434
+ decimalPlaces?: number | undefined;
1435
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
1436
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
1437
+ currencyCode?: string | undefined;
1438
+ } | undefined;
1439
+ };
1440
+ }, {
1441
+ type: "formula";
1442
+ name: string;
1443
+ template: {
1444
+ expression: string;
1445
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1446
+ formatting?: {
1447
+ decimalPlaces?: number | undefined;
1448
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
1449
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
1450
+ currencyCode?: string | undefined;
1451
+ } | undefined;
1452
+ };
1453
+ }>, z.ZodObject<{
1454
+ name: z.ZodString;
1455
+ } & {
1456
+ type: z.ZodLiteral<"autonumber">;
1457
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
1458
+ }, "strip", z.ZodTypeAny, {
1459
+ type: "autonumber";
1460
+ name: string;
1461
+ template: {};
1462
+ }, {
1463
+ type: "autonumber";
1464
+ name: string;
1465
+ template: {};
1466
+ }>, z.ZodObject<{
1467
+ name: z.ZodString;
1468
+ } & {
1469
+ type: z.ZodLiteral<"created_at">;
1470
+ template: z.ZodObject<{
1471
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
1472
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
1473
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
1474
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
1475
+ }, "strip", z.ZodTypeAny, {
1476
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1477
+ displayTimeZone: boolean;
1478
+ timeFormat: "12h" | "24h";
1479
+ timezone: string;
1480
+ }, {
1481
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
1482
+ displayTimeZone?: boolean | null | undefined;
1483
+ timeFormat?: "12h" | "24h" | null | undefined;
1484
+ timezone?: string | null | undefined;
1485
+ }>;
1486
+ }, "strip", z.ZodTypeAny, {
1487
+ type: "created_at";
1488
+ name: string;
1489
+ template: {
1490
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1491
+ displayTimeZone: boolean;
1492
+ timeFormat: "12h" | "24h";
1493
+ timezone: string;
1494
+ };
1495
+ }, {
1496
+ type: "created_at";
1497
+ name: string;
1498
+ template: {
1499
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
1500
+ displayTimeZone?: boolean | null | undefined;
1501
+ timeFormat?: "12h" | "24h" | null | undefined;
1502
+ timezone?: string | null | undefined;
1503
+ };
1504
+ }>, z.ZodObject<{
1505
+ name: z.ZodString;
1506
+ } & {
1507
+ type: z.ZodLiteral<"updated_at">;
1508
+ template: z.ZodObject<{
1509
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
1510
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
1511
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
1512
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
1513
+ }, "strip", z.ZodTypeAny, {
1514
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1515
+ displayTimeZone: boolean;
1516
+ timeFormat: "12h" | "24h";
1517
+ timezone: string;
1518
+ }, {
1519
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
1520
+ displayTimeZone?: boolean | null | undefined;
1521
+ timeFormat?: "12h" | "24h" | null | undefined;
1522
+ timezone?: string | null | undefined;
1523
+ }>;
1524
+ }, "strip", z.ZodTypeAny, {
1525
+ type: "updated_at";
1526
+ name: string;
1527
+ template: {
1528
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1529
+ displayTimeZone: boolean;
1530
+ timeFormat: "12h" | "24h";
1531
+ timezone: string;
1532
+ };
1533
+ }, {
1534
+ type: "updated_at";
1535
+ name: string;
1536
+ template: {
1537
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
1538
+ displayTimeZone?: boolean | null | undefined;
1539
+ timeFormat?: "12h" | "24h" | null | undefined;
1540
+ timezone?: string | null | undefined;
1541
+ };
1542
+ }>]>>, "many">;
1543
+ views: z.ZodArray<z.ZodObject<{
1544
+ id: z.ZodString;
1545
+ name: z.ZodString;
1546
+ type: z.ZodString;
1547
+ config: z.ZodUnknown;
1548
+ }, "strip", z.ZodTypeAny, {
1549
+ id: string;
1550
+ type: string;
1551
+ name: string;
1552
+ config?: unknown;
1553
+ }, {
1554
+ id: string;
1555
+ type: string;
1556
+ name: string;
1557
+ config?: unknown;
1558
+ }>, "many">;
1559
+ url: z.ZodString;
1560
+ }, "strip", z.ZodTypeAny, {
1561
+ url: string;
1562
+ id: string;
1563
+ name: string;
1564
+ order: number;
1565
+ primaryFieldId: string;
1566
+ fields: ({
1567
+ id: string;
1568
+ order: number;
1569
+ } & ({
1570
+ type: "currency";
1571
+ name: string;
1572
+ template: {
1573
+ currencySymbol: string;
1574
+ decimalPlaces: number;
1575
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1576
+ defaultValue?: number | null | undefined;
1577
+ };
1578
+ } | {
1579
+ type: "single_line_text";
1580
+ name: string;
1581
+ template: {
1582
+ defaultValue?: string | undefined;
1583
+ };
1584
+ } | {
1585
+ type: "long_text";
1586
+ name: string;
1587
+ template: {
1588
+ defaultValue?: string | undefined;
1589
+ };
1590
+ } | {
1591
+ type: "rich_text";
1592
+ name: string;
1593
+ template: {
1594
+ defaultValue?: string | undefined;
1595
+ };
1596
+ } | {
1597
+ type: "number";
1598
+ name: string;
1599
+ template: {
1600
+ decimalPlaces: number;
1601
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1602
+ defaultValue?: number | null | undefined;
1603
+ };
1604
+ } | {
1605
+ type: "single_select";
1606
+ name: string;
1607
+ template: {
1608
+ options: {
1609
+ value: string;
1610
+ label: string;
1611
+ color?: string | undefined;
1612
+ }[];
1613
+ disableColors: boolean;
1614
+ defaultValue?: string | undefined;
1615
+ };
1616
+ } | {
1617
+ type: "multiple_select";
1618
+ name: string;
1619
+ template: {
1620
+ options: {
1621
+ value: string;
1622
+ label: string;
1623
+ color?: string | undefined;
1624
+ }[];
1625
+ disableColors: boolean;
1626
+ defaultValue?: string[] | undefined;
1627
+ };
1628
+ } | {
1629
+ type: "date";
1630
+ name: string;
1631
+ template: {
1632
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1633
+ };
1634
+ } | {
1635
+ type: "datetime";
1636
+ name: string;
1637
+ template: {
1638
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1639
+ displayTimeZone: boolean;
1640
+ timeFormat: "12h" | "24h";
1641
+ timezone: string;
1642
+ };
1643
+ } | {
1644
+ type: "checkbox";
1645
+ name: string;
1646
+ template: {
1647
+ defaultValue?: boolean | undefined;
1648
+ };
1649
+ } | {
1650
+ type: "attachments";
1651
+ name: string;
1652
+ template: {};
1653
+ } | {
1654
+ type: "email";
1655
+ name: string;
1656
+ template: {};
1657
+ } | {
1658
+ type: "url";
1659
+ name: string;
1660
+ template: {};
1661
+ } | {
1662
+ type: "phone_number";
1663
+ name: string;
1664
+ template: {};
1665
+ } | {
1666
+ type: "rating";
1667
+ name: string;
1668
+ template: {
1669
+ maxRating: number;
1670
+ defaultValue?: number | undefined;
1671
+ };
1672
+ } | {
1673
+ type: "duration";
1674
+ name: string;
1675
+ template: {
1676
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
1677
+ defaultValue?: number | undefined;
1678
+ };
1679
+ } | {
1680
+ type: "percent";
1681
+ name: string;
1682
+ template: {
1683
+ decimalPlaces: number;
1684
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1685
+ showProgressBar: boolean;
1686
+ allowNegative: boolean;
1687
+ defaultValue?: number | null | undefined;
1688
+ };
1689
+ } | {
1690
+ type: "linked_record";
1691
+ name: string;
1692
+ template: {
1693
+ tableId: string;
1694
+ allowMultiple?: boolean | undefined;
1695
+ };
1696
+ } | {
1697
+ type: "lookup";
1698
+ name: string;
1699
+ template: {
1700
+ linkedRecordFieldId: string;
1701
+ lookupFieldId: string;
1702
+ formulaExpression?: string | undefined;
1703
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1704
+ };
1705
+ } | {
1706
+ type: "source";
1707
+ name: string;
1708
+ template: {};
1709
+ } | {
1710
+ type: "formula";
1711
+ name: string;
1712
+ template: {
1713
+ expression: string;
1714
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1715
+ formatting?: {
1716
+ decimalPlaces?: number | undefined;
1717
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
1718
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
1719
+ currencyCode?: string | undefined;
1720
+ } | undefined;
1721
+ };
1722
+ } | {
1723
+ type: "autonumber";
1724
+ name: string;
1725
+ template: {};
1726
+ } | {
1727
+ type: "created_at";
1728
+ name: string;
1729
+ template: {
1730
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1731
+ displayTimeZone: boolean;
1732
+ timeFormat: "12h" | "24h";
1733
+ timezone: string;
1734
+ };
1735
+ } | {
1736
+ type: "updated_at";
1737
+ name: string;
1738
+ template: {
1739
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1740
+ displayTimeZone: boolean;
1741
+ timeFormat: "12h" | "24h";
1742
+ timezone: string;
1743
+ };
1744
+ }))[];
1745
+ views: {
1746
+ id: string;
1747
+ type: string;
1748
+ name: string;
1749
+ config?: unknown;
1750
+ }[];
1751
+ }, {
1752
+ url: string;
1753
+ id: string;
1754
+ name: string;
1755
+ order: number;
1756
+ primaryFieldId: string;
1757
+ fields: ({
1758
+ id: string;
1759
+ order: number;
1760
+ } & ({
1761
+ type: "currency";
1762
+ name: string;
1763
+ template: {
1764
+ currencySymbol: string;
1765
+ decimalPlaces: number;
1766
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1767
+ defaultValue?: number | null | undefined;
1768
+ };
1769
+ } | {
1770
+ type: "single_line_text";
1771
+ name: string;
1772
+ template: {
1773
+ defaultValue?: string | undefined;
1774
+ };
1775
+ } | {
1776
+ type: "long_text";
1777
+ name: string;
1778
+ template: {
1779
+ defaultValue?: string | undefined;
1780
+ };
1781
+ } | {
1782
+ type: "rich_text";
1783
+ name: string;
1784
+ template: {
1785
+ defaultValue?: string | undefined;
1786
+ };
1787
+ } | {
1788
+ type: "number";
1789
+ name: string;
1790
+ template: {
1791
+ decimalPlaces: number;
1792
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1793
+ defaultValue?: number | null | undefined;
1794
+ };
1795
+ } | {
1796
+ type: "single_select";
1797
+ name: string;
1798
+ template: {
1799
+ options?: {
1800
+ value: string;
1801
+ label: string;
1802
+ color?: string | undefined;
1803
+ }[] | null | undefined;
1804
+ defaultValue?: string | undefined;
1805
+ disableColors?: boolean | null | undefined;
1806
+ };
1807
+ } | {
1808
+ type: "multiple_select";
1809
+ name: string;
1810
+ template: {
1811
+ options?: {
1812
+ value: string;
1813
+ label: string;
1814
+ color?: string | undefined;
1815
+ }[] | null | undefined;
1816
+ defaultValue?: string[] | undefined;
1817
+ disableColors?: boolean | null | undefined;
1818
+ };
1819
+ } | {
1820
+ type: "date";
1821
+ name: string;
1822
+ template: {
1823
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
1824
+ };
1825
+ } | {
1826
+ type: "datetime";
1827
+ name: string;
1828
+ template: {
1829
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
1830
+ displayTimeZone?: boolean | null | undefined;
1831
+ timeFormat?: "12h" | "24h" | null | undefined;
1832
+ timezone?: string | null | undefined;
1833
+ };
1834
+ } | {
1835
+ type: "checkbox";
1836
+ name: string;
1837
+ template: {
1838
+ defaultValue?: boolean | undefined;
1839
+ };
1840
+ } | {
1841
+ type: "attachments";
1842
+ name: string;
1843
+ template: {};
1844
+ } | {
1845
+ type: "email";
1846
+ name: string;
1847
+ template: {};
1848
+ } | {
1849
+ type: "url";
1850
+ name: string;
1851
+ template: {};
1852
+ } | {
1853
+ type: "phone_number";
1854
+ name: string;
1855
+ template: {};
1856
+ } | {
1857
+ type: "rating";
1858
+ name: string;
1859
+ template: {
1860
+ maxRating: number;
1861
+ defaultValue?: number | undefined;
1862
+ };
1863
+ } | {
1864
+ type: "duration";
1865
+ name: string;
1866
+ template: {
1867
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
1868
+ defaultValue?: number | undefined;
1869
+ };
1870
+ } | {
1871
+ type: "percent";
1872
+ name: string;
1873
+ template: {
1874
+ decimalPlaces: number;
1875
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1876
+ showProgressBar: boolean;
1877
+ allowNegative: boolean;
1878
+ defaultValue?: number | null | undefined;
1879
+ };
1880
+ } | {
1881
+ type: "linked_record";
1882
+ name: string;
1883
+ template: {
1884
+ tableId: string;
1885
+ allowMultiple?: boolean | undefined;
1886
+ };
1887
+ } | {
1888
+ type: "lookup";
1889
+ name: string;
1890
+ template: {
1891
+ linkedRecordFieldId: string;
1892
+ lookupFieldId: string;
1893
+ formulaExpression?: string | undefined;
1894
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1895
+ };
1896
+ } | {
1897
+ type: "source";
1898
+ name: string;
1899
+ template: {};
1900
+ } | {
1901
+ type: "formula";
1902
+ name: string;
1903
+ template: {
1904
+ expression: string;
1905
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
1906
+ formatting?: {
1907
+ decimalPlaces?: number | undefined;
1908
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
1909
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
1910
+ currencyCode?: string | undefined;
1911
+ } | undefined;
1912
+ };
1913
+ } | {
1914
+ type: "autonumber";
1915
+ name: string;
1916
+ template: {};
1917
+ } | {
1918
+ type: "created_at";
1919
+ name: string;
1920
+ template: {
1921
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
1922
+ displayTimeZone?: boolean | null | undefined;
1923
+ timeFormat?: "12h" | "24h" | null | undefined;
1924
+ timezone?: string | null | undefined;
1925
+ };
1926
+ } | {
1927
+ type: "updated_at";
1928
+ name: string;
1929
+ template: {
1930
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
1931
+ displayTimeZone?: boolean | null | undefined;
1932
+ timeFormat?: "12h" | "24h" | null | undefined;
1933
+ timezone?: string | null | undefined;
1934
+ };
1935
+ }))[];
1936
+ views: {
1937
+ id: string;
1938
+ type: string;
1939
+ name: string;
1940
+ config?: unknown;
1941
+ }[];
1942
+ }>;
1943
+ export type Table = z.infer<typeof tableSchema>;
1944
+ export declare const publicTableDefinitionSchema: z.ZodObject<{
1945
+ name: z.ZodString;
1946
+ fields: z.ZodArray<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
1947
+ name: z.ZodString;
1948
+ } & {
1949
+ type: z.ZodLiteral<"currency">;
1950
+ template: z.ZodObject<{
1951
+ currencySymbol: z.ZodString;
1952
+ decimalPlaces: z.ZodNumber;
1953
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
1954
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1955
+ }, "strip", z.ZodTypeAny, {
1956
+ currencySymbol: string;
1957
+ decimalPlaces: number;
1958
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1959
+ defaultValue?: number | null | undefined;
1960
+ }, {
1961
+ currencySymbol: string;
1962
+ decimalPlaces: number;
1963
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1964
+ defaultValue?: number | null | undefined;
1965
+ }>;
1966
+ }, "strip", z.ZodTypeAny, {
1967
+ type: "currency";
1968
+ name: string;
1969
+ template: {
1970
+ currencySymbol: string;
1971
+ decimalPlaces: number;
1972
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1973
+ defaultValue?: number | null | undefined;
1974
+ };
1975
+ }, {
1976
+ type: "currency";
1977
+ name: string;
1978
+ template: {
1979
+ currencySymbol: string;
1980
+ decimalPlaces: number;
1981
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
1982
+ defaultValue?: number | null | undefined;
1983
+ };
1984
+ }>, z.ZodObject<{
1985
+ name: z.ZodString;
1986
+ } & {
1987
+ type: z.ZodLiteral<"single_line_text">;
1988
+ template: z.ZodObject<{
1989
+ defaultValue: z.ZodOptional<z.ZodString>;
1990
+ }, "strip", z.ZodTypeAny, {
1991
+ defaultValue?: string | undefined;
1992
+ }, {
1993
+ defaultValue?: string | undefined;
1994
+ }>;
1995
+ }, "strip", z.ZodTypeAny, {
1996
+ type: "single_line_text";
1997
+ name: string;
1998
+ template: {
1999
+ defaultValue?: string | undefined;
2000
+ };
2001
+ }, {
2002
+ type: "single_line_text";
2003
+ name: string;
2004
+ template: {
2005
+ defaultValue?: string | undefined;
2006
+ };
2007
+ }>, z.ZodObject<{
2008
+ name: z.ZodString;
2009
+ } & {
2010
+ type: z.ZodLiteral<"long_text">;
2011
+ template: z.ZodObject<{
2012
+ defaultValue: z.ZodOptional<z.ZodString>;
2013
+ }, "strip", z.ZodTypeAny, {
2014
+ defaultValue?: string | undefined;
2015
+ }, {
2016
+ defaultValue?: string | undefined;
2017
+ }>;
2018
+ }, "strip", z.ZodTypeAny, {
2019
+ type: "long_text";
2020
+ name: string;
2021
+ template: {
2022
+ defaultValue?: string | undefined;
2023
+ };
2024
+ }, {
2025
+ type: "long_text";
2026
+ name: string;
2027
+ template: {
2028
+ defaultValue?: string | undefined;
2029
+ };
2030
+ }>, z.ZodObject<{
2031
+ name: z.ZodString;
2032
+ } & {
2033
+ type: z.ZodLiteral<"rich_text">;
2034
+ template: z.ZodObject<{
2035
+ defaultValue: z.ZodOptional<z.ZodString>;
2036
+ }, "strip", z.ZodTypeAny, {
2037
+ defaultValue?: string | undefined;
2038
+ }, {
2039
+ defaultValue?: string | undefined;
2040
+ }>;
2041
+ }, "strip", z.ZodTypeAny, {
2042
+ type: "rich_text";
2043
+ name: string;
2044
+ template: {
2045
+ defaultValue?: string | undefined;
2046
+ };
2047
+ }, {
2048
+ type: "rich_text";
2049
+ name: string;
2050
+ template: {
2051
+ defaultValue?: string | undefined;
2052
+ };
2053
+ }>, z.ZodObject<{
2054
+ name: z.ZodString;
2055
+ } & {
2056
+ type: z.ZodLiteral<"number">;
2057
+ template: z.ZodObject<{
2058
+ decimalPlaces: z.ZodNumber;
2059
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
2060
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2061
+ }, "strip", z.ZodTypeAny, {
2062
+ decimalPlaces: number;
2063
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2064
+ defaultValue?: number | null | undefined;
2065
+ }, {
2066
+ decimalPlaces: number;
2067
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2068
+ defaultValue?: number | null | undefined;
2069
+ }>;
2070
+ }, "strip", z.ZodTypeAny, {
2071
+ type: "number";
2072
+ name: string;
2073
+ template: {
2074
+ decimalPlaces: number;
2075
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2076
+ defaultValue?: number | null | undefined;
2077
+ };
2078
+ }, {
2079
+ type: "number";
2080
+ name: string;
2081
+ template: {
2082
+ decimalPlaces: number;
2083
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2084
+ defaultValue?: number | null | undefined;
2085
+ };
2086
+ }>, z.ZodObject<{
2087
+ name: z.ZodString;
2088
+ } & {
2089
+ type: z.ZodLiteral<"single_select">;
2090
+ template: z.ZodObject<{
2091
+ options: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
2092
+ value: z.ZodString;
2093
+ label: z.ZodString;
2094
+ color: z.ZodOptional<z.ZodString>;
2095
+ }, "strip", z.ZodTypeAny, {
2096
+ value: string;
2097
+ label: string;
2098
+ color?: string | undefined;
2099
+ }, {
2100
+ value: string;
2101
+ label: string;
2102
+ color?: string | undefined;
2103
+ }>, "many">>>, {
2104
+ value: string;
2105
+ label: string;
2106
+ color?: string | undefined;
2107
+ }[], {
2108
+ value: string;
2109
+ label: string;
2110
+ color?: string | undefined;
2111
+ }[] | null | undefined>;
2112
+ disableColors: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
2113
+ defaultValue: z.ZodOptional<z.ZodString>;
2114
+ }, "strip", z.ZodTypeAny, {
2115
+ options: {
2116
+ value: string;
2117
+ label: string;
2118
+ color?: string | undefined;
2119
+ }[];
2120
+ disableColors: boolean;
2121
+ defaultValue?: string | undefined;
2122
+ }, {
2123
+ options?: {
2124
+ value: string;
2125
+ label: string;
2126
+ color?: string | undefined;
2127
+ }[] | null | undefined;
2128
+ defaultValue?: string | undefined;
2129
+ disableColors?: boolean | null | undefined;
2130
+ }>;
2131
+ }, "strip", z.ZodTypeAny, {
2132
+ type: "single_select";
2133
+ name: string;
2134
+ template: {
2135
+ options: {
2136
+ value: string;
2137
+ label: string;
2138
+ color?: string | undefined;
2139
+ }[];
2140
+ disableColors: boolean;
2141
+ defaultValue?: string | undefined;
2142
+ };
2143
+ }, {
2144
+ type: "single_select";
2145
+ name: string;
2146
+ template: {
2147
+ options?: {
2148
+ value: string;
2149
+ label: string;
2150
+ color?: string | undefined;
2151
+ }[] | null | undefined;
2152
+ defaultValue?: string | undefined;
2153
+ disableColors?: boolean | null | undefined;
2154
+ };
2155
+ }>, z.ZodObject<{
2156
+ name: z.ZodString;
2157
+ } & {
2158
+ type: z.ZodLiteral<"multiple_select">;
2159
+ template: z.ZodObject<{
2160
+ options: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
2161
+ value: z.ZodString;
2162
+ label: z.ZodString;
2163
+ color: z.ZodOptional<z.ZodString>;
2164
+ }, "strip", z.ZodTypeAny, {
2165
+ value: string;
2166
+ label: string;
2167
+ color?: string | undefined;
2168
+ }, {
2169
+ value: string;
2170
+ label: string;
2171
+ color?: string | undefined;
2172
+ }>, "many">>>, {
2173
+ value: string;
2174
+ label: string;
2175
+ color?: string | undefined;
2176
+ }[], {
2177
+ value: string;
2178
+ label: string;
2179
+ color?: string | undefined;
2180
+ }[] | null | undefined>;
2181
+ disableColors: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
2182
+ defaultValue: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
2183
+ }, "strip", z.ZodTypeAny, {
2184
+ options: {
2185
+ value: string;
2186
+ label: string;
2187
+ color?: string | undefined;
2188
+ }[];
2189
+ disableColors: boolean;
2190
+ defaultValue?: string[] | undefined;
2191
+ }, {
2192
+ options?: {
2193
+ value: string;
2194
+ label: string;
2195
+ color?: string | undefined;
2196
+ }[] | null | undefined;
2197
+ defaultValue?: string[] | undefined;
2198
+ disableColors?: boolean | null | undefined;
2199
+ }>;
2200
+ }, "strip", z.ZodTypeAny, {
2201
+ type: "multiple_select";
2202
+ name: string;
2203
+ template: {
2204
+ options: {
2205
+ value: string;
2206
+ label: string;
2207
+ color?: string | undefined;
2208
+ }[];
2209
+ disableColors: boolean;
2210
+ defaultValue?: string[] | undefined;
2211
+ };
2212
+ }, {
2213
+ type: "multiple_select";
2214
+ name: string;
2215
+ template: {
2216
+ options?: {
2217
+ value: string;
2218
+ label: string;
2219
+ color?: string | undefined;
2220
+ }[] | null | undefined;
2221
+ defaultValue?: string[] | undefined;
2222
+ disableColors?: boolean | null | undefined;
2223
+ };
2224
+ }>, z.ZodObject<{
2225
+ name: z.ZodString;
2226
+ } & {
2227
+ type: z.ZodLiteral<"date">;
2228
+ template: z.ZodObject<{
2229
+ dateFormat: z.ZodEnum<["local", "long", "us", "european", "iso"]>;
2230
+ }, "strip", z.ZodTypeAny, {
2231
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2232
+ }, {
2233
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2234
+ }>;
2235
+ }, "strip", z.ZodTypeAny, {
2236
+ type: "date";
2237
+ name: string;
2238
+ template: {
2239
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2240
+ };
2241
+ }, {
2242
+ type: "date";
2243
+ name: string;
2244
+ template: {
2245
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2246
+ };
2247
+ }>, z.ZodObject<{
2248
+ name: z.ZodString;
2249
+ } & {
2250
+ type: z.ZodLiteral<"datetime">;
2251
+ template: z.ZodObject<{
2252
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
2253
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
2254
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
2255
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
2256
+ }, "strip", z.ZodTypeAny, {
2257
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2258
+ displayTimeZone: boolean;
2259
+ timeFormat: "12h" | "24h";
2260
+ timezone: string;
2261
+ }, {
2262
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
2263
+ displayTimeZone?: boolean | null | undefined;
2264
+ timeFormat?: "12h" | "24h" | null | undefined;
2265
+ timezone?: string | null | undefined;
2266
+ }>;
2267
+ }, "strip", z.ZodTypeAny, {
2268
+ type: "datetime";
2269
+ name: string;
2270
+ template: {
2271
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2272
+ displayTimeZone: boolean;
2273
+ timeFormat: "12h" | "24h";
2274
+ timezone: string;
2275
+ };
2276
+ }, {
2277
+ type: "datetime";
2278
+ name: string;
2279
+ template: {
2280
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
2281
+ displayTimeZone?: boolean | null | undefined;
2282
+ timeFormat?: "12h" | "24h" | null | undefined;
2283
+ timezone?: string | null | undefined;
2284
+ };
2285
+ }>, z.ZodObject<{
2286
+ name: z.ZodString;
2287
+ } & {
2288
+ type: z.ZodLiteral<"checkbox">;
2289
+ template: z.ZodObject<{
2290
+ defaultValue: z.ZodOptional<z.ZodBoolean>;
2291
+ }, "strip", z.ZodTypeAny, {
2292
+ defaultValue?: boolean | undefined;
2293
+ }, {
2294
+ defaultValue?: boolean | undefined;
2295
+ }>;
2296
+ }, "strip", z.ZodTypeAny, {
2297
+ type: "checkbox";
2298
+ name: string;
2299
+ template: {
2300
+ defaultValue?: boolean | undefined;
2301
+ };
2302
+ }, {
2303
+ type: "checkbox";
2304
+ name: string;
2305
+ template: {
2306
+ defaultValue?: boolean | undefined;
2307
+ };
2308
+ }>, z.ZodObject<{
2309
+ name: z.ZodString;
2310
+ } & {
2311
+ type: z.ZodLiteral<"attachments">;
2312
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
2313
+ }, "strip", z.ZodTypeAny, {
2314
+ type: "attachments";
2315
+ name: string;
2316
+ template: {};
2317
+ }, {
2318
+ type: "attachments";
2319
+ name: string;
2320
+ template: {};
2321
+ }>, z.ZodObject<{
2322
+ name: z.ZodString;
2323
+ } & {
2324
+ type: z.ZodLiteral<"email">;
2325
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
2326
+ }, "strip", z.ZodTypeAny, {
2327
+ type: "email";
2328
+ name: string;
2329
+ template: {};
2330
+ }, {
2331
+ type: "email";
2332
+ name: string;
2333
+ template: {};
2334
+ }>, z.ZodObject<{
2335
+ name: z.ZodString;
2336
+ } & {
2337
+ type: z.ZodLiteral<"url">;
2338
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
2339
+ }, "strip", z.ZodTypeAny, {
2340
+ type: "url";
2341
+ name: string;
2342
+ template: {};
2343
+ }, {
2344
+ type: "url";
2345
+ name: string;
2346
+ template: {};
2347
+ }>, z.ZodObject<{
2348
+ name: z.ZodString;
2349
+ } & {
2350
+ type: z.ZodLiteral<"phone_number">;
2351
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
2352
+ }, "strip", z.ZodTypeAny, {
2353
+ type: "phone_number";
2354
+ name: string;
2355
+ template: {};
2356
+ }, {
2357
+ type: "phone_number";
2358
+ name: string;
2359
+ template: {};
2360
+ }>, z.ZodObject<{
2361
+ name: z.ZodString;
2362
+ } & {
2363
+ type: z.ZodLiteral<"rating">;
2364
+ template: z.ZodObject<{
2365
+ maxRating: z.ZodNumber;
2366
+ defaultValue: z.ZodOptional<z.ZodNumber>;
2367
+ }, "strip", z.ZodTypeAny, {
2368
+ maxRating: number;
2369
+ defaultValue?: number | undefined;
2370
+ }, {
2371
+ maxRating: number;
2372
+ defaultValue?: number | undefined;
2373
+ }>;
2374
+ }, "strip", z.ZodTypeAny, {
2375
+ type: "rating";
2376
+ name: string;
2377
+ template: {
2378
+ maxRating: number;
2379
+ defaultValue?: number | undefined;
2380
+ };
2381
+ }, {
2382
+ type: "rating";
2383
+ name: string;
2384
+ template: {
2385
+ maxRating: number;
2386
+ defaultValue?: number | undefined;
2387
+ };
2388
+ }>, z.ZodObject<{
2389
+ name: z.ZodString;
2390
+ } & {
2391
+ type: z.ZodLiteral<"duration">;
2392
+ template: z.ZodObject<{
2393
+ format: z.ZodEnum<["h:mm", "h:mm:ss", "h:mm:ss.s", "h:mm:ss.ss", "h:mm:ss.sss"]>;
2394
+ defaultValue: z.ZodOptional<z.ZodNumber>;
2395
+ }, "strip", z.ZodTypeAny, {
2396
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
2397
+ defaultValue?: number | undefined;
2398
+ }, {
2399
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
2400
+ defaultValue?: number | undefined;
2401
+ }>;
2402
+ }, "strip", z.ZodTypeAny, {
2403
+ type: "duration";
2404
+ name: string;
2405
+ template: {
2406
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
2407
+ defaultValue?: number | undefined;
2408
+ };
2409
+ }, {
2410
+ type: "duration";
2411
+ name: string;
2412
+ template: {
2413
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
2414
+ defaultValue?: number | undefined;
2415
+ };
2416
+ }>, z.ZodObject<{
2417
+ name: z.ZodString;
2418
+ } & {
2419
+ type: z.ZodLiteral<"percent">;
2420
+ template: z.ZodObject<{
2421
+ decimalPlaces: z.ZodNumber;
2422
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
2423
+ showProgressBar: z.ZodBoolean;
2424
+ allowNegative: z.ZodBoolean;
2425
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
2426
+ }, "strip", z.ZodTypeAny, {
2427
+ decimalPlaces: number;
2428
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2429
+ showProgressBar: boolean;
2430
+ allowNegative: boolean;
2431
+ defaultValue?: number | null | undefined;
2432
+ }, {
2433
+ decimalPlaces: number;
2434
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2435
+ showProgressBar: boolean;
2436
+ allowNegative: boolean;
2437
+ defaultValue?: number | null | undefined;
2438
+ }>;
2439
+ }, "strip", z.ZodTypeAny, {
2440
+ type: "percent";
2441
+ name: string;
2442
+ template: {
2443
+ decimalPlaces: number;
2444
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2445
+ showProgressBar: boolean;
2446
+ allowNegative: boolean;
2447
+ defaultValue?: number | null | undefined;
2448
+ };
2449
+ }, {
2450
+ type: "percent";
2451
+ name: string;
2452
+ template: {
2453
+ decimalPlaces: number;
2454
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2455
+ showProgressBar: boolean;
2456
+ allowNegative: boolean;
2457
+ defaultValue?: number | null | undefined;
2458
+ };
2459
+ }>, z.ZodObject<{
2460
+ name: z.ZodString;
2461
+ } & {
2462
+ type: z.ZodLiteral<"linked_record">;
2463
+ template: z.ZodObject<{
2464
+ tableId: z.ZodString;
2465
+ allowMultiple: z.ZodOptional<z.ZodBoolean>;
2466
+ }, "strip", z.ZodTypeAny, {
2467
+ tableId: string;
2468
+ allowMultiple?: boolean | undefined;
2469
+ }, {
2470
+ tableId: string;
2471
+ allowMultiple?: boolean | undefined;
2472
+ }>;
2473
+ }, "strip", z.ZodTypeAny, {
2474
+ type: "linked_record";
2475
+ name: string;
2476
+ template: {
2477
+ tableId: string;
2478
+ allowMultiple?: boolean | undefined;
2479
+ };
2480
+ }, {
2481
+ type: "linked_record";
2482
+ name: string;
2483
+ template: {
2484
+ tableId: string;
2485
+ allowMultiple?: boolean | undefined;
2486
+ };
2487
+ }>, z.ZodObject<{
2488
+ name: z.ZodString;
2489
+ } & {
2490
+ type: z.ZodLiteral<"lookup">;
2491
+ template: z.ZodObject<{
2492
+ linkedRecordFieldId: z.ZodString;
2493
+ lookupFieldId: z.ZodString;
2494
+ formulaExpression: z.ZodOptional<z.ZodString>;
2495
+ resultType: z.ZodOptional<z.ZodEnum<["text", "number", "date", "boolean", "array"]>>;
2496
+ }, "strip", z.ZodTypeAny, {
2497
+ linkedRecordFieldId: string;
2498
+ lookupFieldId: string;
2499
+ formulaExpression?: string | undefined;
2500
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
2501
+ }, {
2502
+ linkedRecordFieldId: string;
2503
+ lookupFieldId: string;
2504
+ formulaExpression?: string | undefined;
2505
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
2506
+ }>;
2507
+ }, "strip", z.ZodTypeAny, {
2508
+ type: "lookup";
2509
+ name: string;
2510
+ template: {
2511
+ linkedRecordFieldId: string;
2512
+ lookupFieldId: string;
2513
+ formulaExpression?: string | undefined;
2514
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
2515
+ };
2516
+ }, {
2517
+ type: "lookup";
2518
+ name: string;
2519
+ template: {
2520
+ linkedRecordFieldId: string;
2521
+ lookupFieldId: string;
2522
+ formulaExpression?: string | undefined;
2523
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
2524
+ };
2525
+ }>, z.ZodObject<{
2526
+ name: z.ZodString;
2527
+ } & {
2528
+ type: z.ZodLiteral<"source">;
2529
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
2530
+ }, "strip", z.ZodTypeAny, {
2531
+ type: "source";
2532
+ name: string;
2533
+ template: {};
2534
+ }, {
2535
+ type: "source";
2536
+ name: string;
2537
+ template: {};
2538
+ }>, z.ZodObject<{
2539
+ name: z.ZodString;
2540
+ } & {
2541
+ type: z.ZodLiteral<"formula">;
2542
+ template: z.ZodObject<{
2543
+ expression: z.ZodString;
2544
+ resultType: z.ZodOptional<z.ZodEnum<["text", "number", "date", "boolean", "array"]>>;
2545
+ formatting: z.ZodOptional<z.ZodObject<{
2546
+ numberDisplayType: z.ZodOptional<z.ZodEnum<["number", "currency", "percent", "duration"]>>;
2547
+ currencyCode: z.ZodOptional<z.ZodString>;
2548
+ decimalPlaces: z.ZodOptional<z.ZodNumber>;
2549
+ numberFormat: z.ZodOptional<z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period"]>>;
2550
+ }, "strip", z.ZodTypeAny, {
2551
+ decimalPlaces?: number | undefined;
2552
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
2553
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
2554
+ currencyCode?: string | undefined;
2555
+ }, {
2556
+ decimalPlaces?: number | undefined;
2557
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
2558
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
2559
+ currencyCode?: string | undefined;
2560
+ }>>;
2561
+ }, "strip", z.ZodTypeAny, {
2562
+ expression: string;
2563
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
2564
+ formatting?: {
2565
+ decimalPlaces?: number | undefined;
2566
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
2567
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
2568
+ currencyCode?: string | undefined;
2569
+ } | undefined;
2570
+ }, {
2571
+ expression: string;
2572
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
2573
+ formatting?: {
2574
+ decimalPlaces?: number | undefined;
2575
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
2576
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
2577
+ currencyCode?: string | undefined;
2578
+ } | undefined;
2579
+ }>;
2580
+ }, "strip", z.ZodTypeAny, {
2581
+ type: "formula";
2582
+ name: string;
2583
+ template: {
2584
+ expression: string;
2585
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
2586
+ formatting?: {
2587
+ decimalPlaces?: number | undefined;
2588
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
2589
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
2590
+ currencyCode?: string | undefined;
2591
+ } | undefined;
2592
+ };
2593
+ }, {
2594
+ type: "formula";
2595
+ name: string;
2596
+ template: {
2597
+ expression: string;
2598
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
2599
+ formatting?: {
2600
+ decimalPlaces?: number | undefined;
2601
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
2602
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
2603
+ currencyCode?: string | undefined;
2604
+ } | undefined;
2605
+ };
2606
+ }>, z.ZodObject<{
2607
+ name: z.ZodString;
2608
+ } & {
2609
+ type: z.ZodLiteral<"autonumber">;
2610
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
2611
+ }, "strip", z.ZodTypeAny, {
2612
+ type: "autonumber";
2613
+ name: string;
2614
+ template: {};
2615
+ }, {
2616
+ type: "autonumber";
2617
+ name: string;
2618
+ template: {};
2619
+ }>, z.ZodObject<{
2620
+ name: z.ZodString;
2621
+ } & {
2622
+ type: z.ZodLiteral<"created_at">;
2623
+ template: z.ZodObject<{
2624
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
2625
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
2626
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
2627
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
2628
+ }, "strip", z.ZodTypeAny, {
2629
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2630
+ displayTimeZone: boolean;
2631
+ timeFormat: "12h" | "24h";
2632
+ timezone: string;
2633
+ }, {
2634
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
2635
+ displayTimeZone?: boolean | null | undefined;
2636
+ timeFormat?: "12h" | "24h" | null | undefined;
2637
+ timezone?: string | null | undefined;
2638
+ }>;
2639
+ }, "strip", z.ZodTypeAny, {
2640
+ type: "created_at";
2641
+ name: string;
2642
+ template: {
2643
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2644
+ displayTimeZone: boolean;
2645
+ timeFormat: "12h" | "24h";
2646
+ timezone: string;
2647
+ };
2648
+ }, {
2649
+ type: "created_at";
2650
+ name: string;
2651
+ template: {
2652
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
2653
+ displayTimeZone?: boolean | null | undefined;
2654
+ timeFormat?: "12h" | "24h" | null | undefined;
2655
+ timezone?: string | null | undefined;
2656
+ };
2657
+ }>, z.ZodObject<{
2658
+ name: z.ZodString;
2659
+ } & {
2660
+ type: z.ZodLiteral<"updated_at">;
2661
+ template: z.ZodObject<{
2662
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
2663
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
2664
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
2665
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
2666
+ }, "strip", z.ZodTypeAny, {
2667
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2668
+ displayTimeZone: boolean;
2669
+ timeFormat: "12h" | "24h";
2670
+ timezone: string;
2671
+ }, {
2672
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
2673
+ displayTimeZone?: boolean | null | undefined;
2674
+ timeFormat?: "12h" | "24h" | null | undefined;
2675
+ timezone?: string | null | undefined;
2676
+ }>;
2677
+ }, "strip", z.ZodTypeAny, {
2678
+ type: "updated_at";
2679
+ name: string;
2680
+ template: {
2681
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2682
+ displayTimeZone: boolean;
2683
+ timeFormat: "12h" | "24h";
2684
+ timezone: string;
2685
+ };
2686
+ }, {
2687
+ type: "updated_at";
2688
+ name: string;
2689
+ template: {
2690
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
2691
+ displayTimeZone?: boolean | null | undefined;
2692
+ timeFormat?: "12h" | "24h" | null | undefined;
2693
+ timezone?: string | null | undefined;
2694
+ };
2695
+ }>]>, "many">;
2696
+ }, "strip", z.ZodTypeAny, {
2697
+ name: string;
2698
+ fields: ({
2699
+ type: "currency";
2700
+ name: string;
2701
+ template: {
2702
+ currencySymbol: string;
2703
+ decimalPlaces: number;
2704
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2705
+ defaultValue?: number | null | undefined;
2706
+ };
2707
+ } | {
2708
+ type: "single_line_text";
2709
+ name: string;
2710
+ template: {
2711
+ defaultValue?: string | undefined;
2712
+ };
2713
+ } | {
2714
+ type: "long_text";
2715
+ name: string;
2716
+ template: {
2717
+ defaultValue?: string | undefined;
2718
+ };
2719
+ } | {
2720
+ type: "rich_text";
2721
+ name: string;
2722
+ template: {
2723
+ defaultValue?: string | undefined;
2724
+ };
2725
+ } | {
2726
+ type: "number";
2727
+ name: string;
2728
+ template: {
2729
+ decimalPlaces: number;
2730
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2731
+ defaultValue?: number | null | undefined;
2732
+ };
2733
+ } | {
2734
+ type: "single_select";
2735
+ name: string;
2736
+ template: {
2737
+ options: {
2738
+ value: string;
2739
+ label: string;
2740
+ color?: string | undefined;
2741
+ }[];
2742
+ disableColors: boolean;
2743
+ defaultValue?: string | undefined;
2744
+ };
2745
+ } | {
2746
+ type: "multiple_select";
2747
+ name: string;
2748
+ template: {
2749
+ options: {
2750
+ value: string;
2751
+ label: string;
2752
+ color?: string | undefined;
2753
+ }[];
2754
+ disableColors: boolean;
2755
+ defaultValue?: string[] | undefined;
2756
+ };
2757
+ } | {
2758
+ type: "date";
2759
+ name: string;
2760
+ template: {
2761
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2762
+ };
2763
+ } | {
2764
+ type: "datetime";
2765
+ name: string;
2766
+ template: {
2767
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2768
+ displayTimeZone: boolean;
2769
+ timeFormat: "12h" | "24h";
2770
+ timezone: string;
2771
+ };
2772
+ } | {
2773
+ type: "checkbox";
2774
+ name: string;
2775
+ template: {
2776
+ defaultValue?: boolean | undefined;
2777
+ };
2778
+ } | {
2779
+ type: "attachments";
2780
+ name: string;
2781
+ template: {};
2782
+ } | {
2783
+ type: "email";
2784
+ name: string;
2785
+ template: {};
2786
+ } | {
2787
+ type: "url";
2788
+ name: string;
2789
+ template: {};
2790
+ } | {
2791
+ type: "phone_number";
2792
+ name: string;
2793
+ template: {};
2794
+ } | {
2795
+ type: "rating";
2796
+ name: string;
2797
+ template: {
2798
+ maxRating: number;
2799
+ defaultValue?: number | undefined;
2800
+ };
2801
+ } | {
2802
+ type: "duration";
2803
+ name: string;
2804
+ template: {
2805
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
2806
+ defaultValue?: number | undefined;
2807
+ };
2808
+ } | {
2809
+ type: "percent";
2810
+ name: string;
2811
+ template: {
2812
+ decimalPlaces: number;
2813
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2814
+ showProgressBar: boolean;
2815
+ allowNegative: boolean;
2816
+ defaultValue?: number | null | undefined;
2817
+ };
2818
+ } | {
2819
+ type: "linked_record";
2820
+ name: string;
2821
+ template: {
2822
+ tableId: string;
2823
+ allowMultiple?: boolean | undefined;
2824
+ };
2825
+ } | {
2826
+ type: "lookup";
2827
+ name: string;
2828
+ template: {
2829
+ linkedRecordFieldId: string;
2830
+ lookupFieldId: string;
2831
+ formulaExpression?: string | undefined;
2832
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
2833
+ };
2834
+ } | {
2835
+ type: "source";
2836
+ name: string;
2837
+ template: {};
2838
+ } | {
2839
+ type: "formula";
2840
+ name: string;
2841
+ template: {
2842
+ expression: string;
2843
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
2844
+ formatting?: {
2845
+ decimalPlaces?: number | undefined;
2846
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
2847
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
2848
+ currencyCode?: string | undefined;
2849
+ } | undefined;
2850
+ };
2851
+ } | {
2852
+ type: "autonumber";
2853
+ name: string;
2854
+ template: {};
2855
+ } | {
2856
+ type: "created_at";
2857
+ name: string;
2858
+ template: {
2859
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2860
+ displayTimeZone: boolean;
2861
+ timeFormat: "12h" | "24h";
2862
+ timezone: string;
2863
+ };
2864
+ } | {
2865
+ type: "updated_at";
2866
+ name: string;
2867
+ template: {
2868
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2869
+ displayTimeZone: boolean;
2870
+ timeFormat: "12h" | "24h";
2871
+ timezone: string;
2872
+ };
2873
+ })[];
2874
+ }, {
2875
+ name: string;
2876
+ fields: ({
2877
+ type: "currency";
2878
+ name: string;
2879
+ template: {
2880
+ currencySymbol: string;
2881
+ decimalPlaces: number;
2882
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2883
+ defaultValue?: number | null | undefined;
2884
+ };
2885
+ } | {
2886
+ type: "single_line_text";
2887
+ name: string;
2888
+ template: {
2889
+ defaultValue?: string | undefined;
2890
+ };
2891
+ } | {
2892
+ type: "long_text";
2893
+ name: string;
2894
+ template: {
2895
+ defaultValue?: string | undefined;
2896
+ };
2897
+ } | {
2898
+ type: "rich_text";
2899
+ name: string;
2900
+ template: {
2901
+ defaultValue?: string | undefined;
2902
+ };
2903
+ } | {
2904
+ type: "number";
2905
+ name: string;
2906
+ template: {
2907
+ decimalPlaces: number;
2908
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2909
+ defaultValue?: number | null | undefined;
2910
+ };
2911
+ } | {
2912
+ type: "single_select";
2913
+ name: string;
2914
+ template: {
2915
+ options?: {
2916
+ value: string;
2917
+ label: string;
2918
+ color?: string | undefined;
2919
+ }[] | null | undefined;
2920
+ defaultValue?: string | undefined;
2921
+ disableColors?: boolean | null | undefined;
2922
+ };
2923
+ } | {
2924
+ type: "multiple_select";
2925
+ name: string;
2926
+ template: {
2927
+ options?: {
2928
+ value: string;
2929
+ label: string;
2930
+ color?: string | undefined;
2931
+ }[] | null | undefined;
2932
+ defaultValue?: string[] | undefined;
2933
+ disableColors?: boolean | null | undefined;
2934
+ };
2935
+ } | {
2936
+ type: "date";
2937
+ name: string;
2938
+ template: {
2939
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
2940
+ };
2941
+ } | {
2942
+ type: "datetime";
2943
+ name: string;
2944
+ template: {
2945
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
2946
+ displayTimeZone?: boolean | null | undefined;
2947
+ timeFormat?: "12h" | "24h" | null | undefined;
2948
+ timezone?: string | null | undefined;
2949
+ };
2950
+ } | {
2951
+ type: "checkbox";
2952
+ name: string;
2953
+ template: {
2954
+ defaultValue?: boolean | undefined;
2955
+ };
2956
+ } | {
2957
+ type: "attachments";
2958
+ name: string;
2959
+ template: {};
2960
+ } | {
2961
+ type: "email";
2962
+ name: string;
2963
+ template: {};
2964
+ } | {
2965
+ type: "url";
2966
+ name: string;
2967
+ template: {};
2968
+ } | {
2969
+ type: "phone_number";
2970
+ name: string;
2971
+ template: {};
2972
+ } | {
2973
+ type: "rating";
2974
+ name: string;
2975
+ template: {
2976
+ maxRating: number;
2977
+ defaultValue?: number | undefined;
2978
+ };
2979
+ } | {
2980
+ type: "duration";
2981
+ name: string;
2982
+ template: {
2983
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
2984
+ defaultValue?: number | undefined;
2985
+ };
2986
+ } | {
2987
+ type: "percent";
2988
+ name: string;
2989
+ template: {
2990
+ decimalPlaces: number;
2991
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
2992
+ showProgressBar: boolean;
2993
+ allowNegative: boolean;
2994
+ defaultValue?: number | null | undefined;
2995
+ };
2996
+ } | {
2997
+ type: "linked_record";
2998
+ name: string;
2999
+ template: {
3000
+ tableId: string;
3001
+ allowMultiple?: boolean | undefined;
3002
+ };
3003
+ } | {
3004
+ type: "lookup";
3005
+ name: string;
3006
+ template: {
3007
+ linkedRecordFieldId: string;
3008
+ lookupFieldId: string;
3009
+ formulaExpression?: string | undefined;
3010
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3011
+ };
3012
+ } | {
3013
+ type: "source";
3014
+ name: string;
3015
+ template: {};
3016
+ } | {
3017
+ type: "formula";
3018
+ name: string;
3019
+ template: {
3020
+ expression: string;
3021
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3022
+ formatting?: {
3023
+ decimalPlaces?: number | undefined;
3024
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
3025
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
3026
+ currencyCode?: string | undefined;
3027
+ } | undefined;
3028
+ };
3029
+ } | {
3030
+ type: "autonumber";
3031
+ name: string;
3032
+ template: {};
3033
+ } | {
3034
+ type: "created_at";
3035
+ name: string;
3036
+ template: {
3037
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
3038
+ displayTimeZone?: boolean | null | undefined;
3039
+ timeFormat?: "12h" | "24h" | null | undefined;
3040
+ timezone?: string | null | undefined;
3041
+ };
3042
+ } | {
3043
+ type: "updated_at";
3044
+ name: string;
3045
+ template: {
3046
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
3047
+ displayTimeZone?: boolean | null | undefined;
3048
+ timeFormat?: "12h" | "24h" | null | undefined;
3049
+ timezone?: string | null | undefined;
3050
+ };
3051
+ })[];
3052
+ }>;
3053
+ export type PublicTableDefinition = z.infer<typeof publicTableDefinitionSchema>;
3054
+ export declare const databaseSchema: z.ZodObject<{
3055
+ id: z.ZodString;
3056
+ name: z.ZodString;
3057
+ tables: z.ZodArray<z.ZodObject<{
3058
+ id: z.ZodString;
3059
+ name: z.ZodString;
3060
+ order: z.ZodNumber;
3061
+ primaryFieldId: z.ZodString;
3062
+ fields: z.ZodArray<z.ZodIntersection<z.ZodObject<{
3063
+ id: z.ZodString;
3064
+ order: z.ZodNumber;
3065
+ }, "strip", z.ZodTypeAny, {
3066
+ id: string;
3067
+ order: number;
3068
+ }, {
3069
+ id: string;
3070
+ order: number;
3071
+ }>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
3072
+ name: z.ZodString;
3073
+ } & {
3074
+ type: z.ZodLiteral<"currency">;
3075
+ template: z.ZodObject<{
3076
+ currencySymbol: z.ZodString;
3077
+ decimalPlaces: z.ZodNumber;
3078
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
3079
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
3080
+ }, "strip", z.ZodTypeAny, {
3081
+ currencySymbol: string;
3082
+ decimalPlaces: number;
3083
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3084
+ defaultValue?: number | null | undefined;
3085
+ }, {
3086
+ currencySymbol: string;
3087
+ decimalPlaces: number;
3088
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3089
+ defaultValue?: number | null | undefined;
3090
+ }>;
3091
+ }, "strip", z.ZodTypeAny, {
3092
+ type: "currency";
3093
+ name: string;
3094
+ template: {
3095
+ currencySymbol: string;
3096
+ decimalPlaces: number;
3097
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3098
+ defaultValue?: number | null | undefined;
3099
+ };
3100
+ }, {
3101
+ type: "currency";
3102
+ name: string;
3103
+ template: {
3104
+ currencySymbol: string;
3105
+ decimalPlaces: number;
3106
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3107
+ defaultValue?: number | null | undefined;
3108
+ };
3109
+ }>, z.ZodObject<{
3110
+ name: z.ZodString;
3111
+ } & {
3112
+ type: z.ZodLiteral<"single_line_text">;
3113
+ template: z.ZodObject<{
3114
+ defaultValue: z.ZodOptional<z.ZodString>;
3115
+ }, "strip", z.ZodTypeAny, {
3116
+ defaultValue?: string | undefined;
3117
+ }, {
3118
+ defaultValue?: string | undefined;
3119
+ }>;
3120
+ }, "strip", z.ZodTypeAny, {
3121
+ type: "single_line_text";
3122
+ name: string;
3123
+ template: {
3124
+ defaultValue?: string | undefined;
3125
+ };
3126
+ }, {
3127
+ type: "single_line_text";
3128
+ name: string;
3129
+ template: {
3130
+ defaultValue?: string | undefined;
3131
+ };
3132
+ }>, z.ZodObject<{
3133
+ name: z.ZodString;
3134
+ } & {
3135
+ type: z.ZodLiteral<"long_text">;
3136
+ template: z.ZodObject<{
3137
+ defaultValue: z.ZodOptional<z.ZodString>;
3138
+ }, "strip", z.ZodTypeAny, {
3139
+ defaultValue?: string | undefined;
3140
+ }, {
3141
+ defaultValue?: string | undefined;
3142
+ }>;
3143
+ }, "strip", z.ZodTypeAny, {
3144
+ type: "long_text";
3145
+ name: string;
3146
+ template: {
3147
+ defaultValue?: string | undefined;
3148
+ };
3149
+ }, {
3150
+ type: "long_text";
3151
+ name: string;
3152
+ template: {
3153
+ defaultValue?: string | undefined;
3154
+ };
3155
+ }>, z.ZodObject<{
3156
+ name: z.ZodString;
3157
+ } & {
3158
+ type: z.ZodLiteral<"rich_text">;
3159
+ template: z.ZodObject<{
3160
+ defaultValue: z.ZodOptional<z.ZodString>;
3161
+ }, "strip", z.ZodTypeAny, {
3162
+ defaultValue?: string | undefined;
3163
+ }, {
3164
+ defaultValue?: string | undefined;
3165
+ }>;
3166
+ }, "strip", z.ZodTypeAny, {
3167
+ type: "rich_text";
3168
+ name: string;
3169
+ template: {
3170
+ defaultValue?: string | undefined;
3171
+ };
3172
+ }, {
3173
+ type: "rich_text";
3174
+ name: string;
3175
+ template: {
3176
+ defaultValue?: string | undefined;
3177
+ };
3178
+ }>, z.ZodObject<{
3179
+ name: z.ZodString;
3180
+ } & {
3181
+ type: z.ZodLiteral<"number">;
3182
+ template: z.ZodObject<{
3183
+ decimalPlaces: z.ZodNumber;
3184
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
3185
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
3186
+ }, "strip", z.ZodTypeAny, {
3187
+ decimalPlaces: number;
3188
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3189
+ defaultValue?: number | null | undefined;
3190
+ }, {
3191
+ decimalPlaces: number;
3192
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3193
+ defaultValue?: number | null | undefined;
3194
+ }>;
3195
+ }, "strip", z.ZodTypeAny, {
3196
+ type: "number";
3197
+ name: string;
3198
+ template: {
3199
+ decimalPlaces: number;
3200
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3201
+ defaultValue?: number | null | undefined;
3202
+ };
3203
+ }, {
3204
+ type: "number";
3205
+ name: string;
3206
+ template: {
3207
+ decimalPlaces: number;
3208
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3209
+ defaultValue?: number | null | undefined;
3210
+ };
3211
+ }>, z.ZodObject<{
3212
+ name: z.ZodString;
3213
+ } & {
3214
+ type: z.ZodLiteral<"single_select">;
3215
+ template: z.ZodObject<{
3216
+ options: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
3217
+ value: z.ZodString;
3218
+ label: z.ZodString;
3219
+ color: z.ZodOptional<z.ZodString>;
3220
+ }, "strip", z.ZodTypeAny, {
3221
+ value: string;
3222
+ label: string;
3223
+ color?: string | undefined;
3224
+ }, {
3225
+ value: string;
3226
+ label: string;
3227
+ color?: string | undefined;
3228
+ }>, "many">>>, {
3229
+ value: string;
3230
+ label: string;
3231
+ color?: string | undefined;
3232
+ }[], {
3233
+ value: string;
3234
+ label: string;
3235
+ color?: string | undefined;
3236
+ }[] | null | undefined>;
3237
+ disableColors: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
3238
+ defaultValue: z.ZodOptional<z.ZodString>;
3239
+ }, "strip", z.ZodTypeAny, {
3240
+ options: {
3241
+ value: string;
3242
+ label: string;
3243
+ color?: string | undefined;
3244
+ }[];
3245
+ disableColors: boolean;
3246
+ defaultValue?: string | undefined;
3247
+ }, {
3248
+ options?: {
3249
+ value: string;
3250
+ label: string;
3251
+ color?: string | undefined;
3252
+ }[] | null | undefined;
3253
+ defaultValue?: string | undefined;
3254
+ disableColors?: boolean | null | undefined;
3255
+ }>;
3256
+ }, "strip", z.ZodTypeAny, {
3257
+ type: "single_select";
3258
+ name: string;
3259
+ template: {
3260
+ options: {
3261
+ value: string;
3262
+ label: string;
3263
+ color?: string | undefined;
3264
+ }[];
3265
+ disableColors: boolean;
3266
+ defaultValue?: string | undefined;
3267
+ };
3268
+ }, {
3269
+ type: "single_select";
3270
+ name: string;
3271
+ template: {
3272
+ options?: {
3273
+ value: string;
3274
+ label: string;
3275
+ color?: string | undefined;
3276
+ }[] | null | undefined;
3277
+ defaultValue?: string | undefined;
3278
+ disableColors?: boolean | null | undefined;
3279
+ };
3280
+ }>, z.ZodObject<{
3281
+ name: z.ZodString;
3282
+ } & {
3283
+ type: z.ZodLiteral<"multiple_select">;
3284
+ template: z.ZodObject<{
3285
+ options: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
3286
+ value: z.ZodString;
3287
+ label: z.ZodString;
3288
+ color: z.ZodOptional<z.ZodString>;
3289
+ }, "strip", z.ZodTypeAny, {
3290
+ value: string;
3291
+ label: string;
3292
+ color?: string | undefined;
3293
+ }, {
3294
+ value: string;
3295
+ label: string;
3296
+ color?: string | undefined;
3297
+ }>, "many">>>, {
3298
+ value: string;
3299
+ label: string;
3300
+ color?: string | undefined;
3301
+ }[], {
3302
+ value: string;
3303
+ label: string;
3304
+ color?: string | undefined;
3305
+ }[] | null | undefined>;
3306
+ disableColors: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
3307
+ defaultValue: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
3308
+ }, "strip", z.ZodTypeAny, {
3309
+ options: {
3310
+ value: string;
3311
+ label: string;
3312
+ color?: string | undefined;
3313
+ }[];
3314
+ disableColors: boolean;
3315
+ defaultValue?: string[] | undefined;
3316
+ }, {
3317
+ options?: {
3318
+ value: string;
3319
+ label: string;
3320
+ color?: string | undefined;
3321
+ }[] | null | undefined;
3322
+ defaultValue?: string[] | undefined;
3323
+ disableColors?: boolean | null | undefined;
3324
+ }>;
3325
+ }, "strip", z.ZodTypeAny, {
3326
+ type: "multiple_select";
3327
+ name: string;
3328
+ template: {
3329
+ options: {
3330
+ value: string;
3331
+ label: string;
3332
+ color?: string | undefined;
3333
+ }[];
3334
+ disableColors: boolean;
3335
+ defaultValue?: string[] | undefined;
3336
+ };
3337
+ }, {
3338
+ type: "multiple_select";
3339
+ name: string;
3340
+ template: {
3341
+ options?: {
3342
+ value: string;
3343
+ label: string;
3344
+ color?: string | undefined;
3345
+ }[] | null | undefined;
3346
+ defaultValue?: string[] | undefined;
3347
+ disableColors?: boolean | null | undefined;
3348
+ };
3349
+ }>, z.ZodObject<{
3350
+ name: z.ZodString;
3351
+ } & {
3352
+ type: z.ZodLiteral<"date">;
3353
+ template: z.ZodObject<{
3354
+ dateFormat: z.ZodEnum<["local", "long", "us", "european", "iso"]>;
3355
+ }, "strip", z.ZodTypeAny, {
3356
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3357
+ }, {
3358
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3359
+ }>;
3360
+ }, "strip", z.ZodTypeAny, {
3361
+ type: "date";
3362
+ name: string;
3363
+ template: {
3364
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3365
+ };
3366
+ }, {
3367
+ type: "date";
3368
+ name: string;
3369
+ template: {
3370
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3371
+ };
3372
+ }>, z.ZodObject<{
3373
+ name: z.ZodString;
3374
+ } & {
3375
+ type: z.ZodLiteral<"datetime">;
3376
+ template: z.ZodObject<{
3377
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
3378
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
3379
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
3380
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
3381
+ }, "strip", z.ZodTypeAny, {
3382
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3383
+ displayTimeZone: boolean;
3384
+ timeFormat: "12h" | "24h";
3385
+ timezone: string;
3386
+ }, {
3387
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
3388
+ displayTimeZone?: boolean | null | undefined;
3389
+ timeFormat?: "12h" | "24h" | null | undefined;
3390
+ timezone?: string | null | undefined;
3391
+ }>;
3392
+ }, "strip", z.ZodTypeAny, {
3393
+ type: "datetime";
3394
+ name: string;
3395
+ template: {
3396
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3397
+ displayTimeZone: boolean;
3398
+ timeFormat: "12h" | "24h";
3399
+ timezone: string;
3400
+ };
3401
+ }, {
3402
+ type: "datetime";
3403
+ name: string;
3404
+ template: {
3405
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
3406
+ displayTimeZone?: boolean | null | undefined;
3407
+ timeFormat?: "12h" | "24h" | null | undefined;
3408
+ timezone?: string | null | undefined;
3409
+ };
3410
+ }>, z.ZodObject<{
3411
+ name: z.ZodString;
3412
+ } & {
3413
+ type: z.ZodLiteral<"checkbox">;
3414
+ template: z.ZodObject<{
3415
+ defaultValue: z.ZodOptional<z.ZodBoolean>;
3416
+ }, "strip", z.ZodTypeAny, {
3417
+ defaultValue?: boolean | undefined;
3418
+ }, {
3419
+ defaultValue?: boolean | undefined;
3420
+ }>;
3421
+ }, "strip", z.ZodTypeAny, {
3422
+ type: "checkbox";
3423
+ name: string;
3424
+ template: {
3425
+ defaultValue?: boolean | undefined;
3426
+ };
3427
+ }, {
3428
+ type: "checkbox";
3429
+ name: string;
3430
+ template: {
3431
+ defaultValue?: boolean | undefined;
3432
+ };
3433
+ }>, z.ZodObject<{
3434
+ name: z.ZodString;
3435
+ } & {
3436
+ type: z.ZodLiteral<"attachments">;
3437
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
3438
+ }, "strip", z.ZodTypeAny, {
3439
+ type: "attachments";
3440
+ name: string;
3441
+ template: {};
3442
+ }, {
3443
+ type: "attachments";
3444
+ name: string;
3445
+ template: {};
3446
+ }>, z.ZodObject<{
3447
+ name: z.ZodString;
3448
+ } & {
3449
+ type: z.ZodLiteral<"email">;
3450
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
3451
+ }, "strip", z.ZodTypeAny, {
3452
+ type: "email";
3453
+ name: string;
3454
+ template: {};
3455
+ }, {
3456
+ type: "email";
3457
+ name: string;
3458
+ template: {};
3459
+ }>, z.ZodObject<{
3460
+ name: z.ZodString;
3461
+ } & {
3462
+ type: z.ZodLiteral<"url">;
3463
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
3464
+ }, "strip", z.ZodTypeAny, {
3465
+ type: "url";
3466
+ name: string;
3467
+ template: {};
3468
+ }, {
3469
+ type: "url";
3470
+ name: string;
3471
+ template: {};
3472
+ }>, z.ZodObject<{
3473
+ name: z.ZodString;
3474
+ } & {
3475
+ type: z.ZodLiteral<"phone_number">;
3476
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
3477
+ }, "strip", z.ZodTypeAny, {
3478
+ type: "phone_number";
3479
+ name: string;
3480
+ template: {};
3481
+ }, {
3482
+ type: "phone_number";
3483
+ name: string;
3484
+ template: {};
3485
+ }>, z.ZodObject<{
3486
+ name: z.ZodString;
3487
+ } & {
3488
+ type: z.ZodLiteral<"rating">;
3489
+ template: z.ZodObject<{
3490
+ maxRating: z.ZodNumber;
3491
+ defaultValue: z.ZodOptional<z.ZodNumber>;
3492
+ }, "strip", z.ZodTypeAny, {
3493
+ maxRating: number;
3494
+ defaultValue?: number | undefined;
3495
+ }, {
3496
+ maxRating: number;
3497
+ defaultValue?: number | undefined;
3498
+ }>;
3499
+ }, "strip", z.ZodTypeAny, {
3500
+ type: "rating";
3501
+ name: string;
3502
+ template: {
3503
+ maxRating: number;
3504
+ defaultValue?: number | undefined;
3505
+ };
3506
+ }, {
3507
+ type: "rating";
3508
+ name: string;
3509
+ template: {
3510
+ maxRating: number;
3511
+ defaultValue?: number | undefined;
3512
+ };
3513
+ }>, z.ZodObject<{
3514
+ name: z.ZodString;
3515
+ } & {
3516
+ type: z.ZodLiteral<"duration">;
3517
+ template: z.ZodObject<{
3518
+ format: z.ZodEnum<["h:mm", "h:mm:ss", "h:mm:ss.s", "h:mm:ss.ss", "h:mm:ss.sss"]>;
3519
+ defaultValue: z.ZodOptional<z.ZodNumber>;
3520
+ }, "strip", z.ZodTypeAny, {
3521
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
3522
+ defaultValue?: number | undefined;
3523
+ }, {
3524
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
3525
+ defaultValue?: number | undefined;
3526
+ }>;
3527
+ }, "strip", z.ZodTypeAny, {
3528
+ type: "duration";
3529
+ name: string;
3530
+ template: {
3531
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
3532
+ defaultValue?: number | undefined;
3533
+ };
3534
+ }, {
3535
+ type: "duration";
3536
+ name: string;
3537
+ template: {
3538
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
3539
+ defaultValue?: number | undefined;
3540
+ };
3541
+ }>, z.ZodObject<{
3542
+ name: z.ZodString;
3543
+ } & {
3544
+ type: z.ZodLiteral<"percent">;
3545
+ template: z.ZodObject<{
3546
+ decimalPlaces: z.ZodNumber;
3547
+ numberFormat: z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period", "no_separator"]>;
3548
+ showProgressBar: z.ZodBoolean;
3549
+ allowNegative: z.ZodBoolean;
3550
+ defaultValue: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
3551
+ }, "strip", z.ZodTypeAny, {
3552
+ decimalPlaces: number;
3553
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3554
+ showProgressBar: boolean;
3555
+ allowNegative: boolean;
3556
+ defaultValue?: number | null | undefined;
3557
+ }, {
3558
+ decimalPlaces: number;
3559
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3560
+ showProgressBar: boolean;
3561
+ allowNegative: boolean;
3562
+ defaultValue?: number | null | undefined;
3563
+ }>;
3564
+ }, "strip", z.ZodTypeAny, {
3565
+ type: "percent";
3566
+ name: string;
3567
+ template: {
3568
+ decimalPlaces: number;
3569
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3570
+ showProgressBar: boolean;
3571
+ allowNegative: boolean;
3572
+ defaultValue?: number | null | undefined;
3573
+ };
3574
+ }, {
3575
+ type: "percent";
3576
+ name: string;
3577
+ template: {
3578
+ decimalPlaces: number;
3579
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3580
+ showProgressBar: boolean;
3581
+ allowNegative: boolean;
3582
+ defaultValue?: number | null | undefined;
3583
+ };
3584
+ }>, z.ZodObject<{
3585
+ name: z.ZodString;
3586
+ } & {
3587
+ type: z.ZodLiteral<"linked_record">;
3588
+ template: z.ZodObject<{
3589
+ tableId: z.ZodString;
3590
+ allowMultiple: z.ZodOptional<z.ZodBoolean>;
3591
+ }, "strip", z.ZodTypeAny, {
3592
+ tableId: string;
3593
+ allowMultiple?: boolean | undefined;
3594
+ }, {
3595
+ tableId: string;
3596
+ allowMultiple?: boolean | undefined;
3597
+ }>;
3598
+ }, "strip", z.ZodTypeAny, {
3599
+ type: "linked_record";
3600
+ name: string;
3601
+ template: {
3602
+ tableId: string;
3603
+ allowMultiple?: boolean | undefined;
3604
+ };
3605
+ }, {
3606
+ type: "linked_record";
3607
+ name: string;
3608
+ template: {
3609
+ tableId: string;
3610
+ allowMultiple?: boolean | undefined;
3611
+ };
3612
+ }>, z.ZodObject<{
3613
+ name: z.ZodString;
3614
+ } & {
3615
+ type: z.ZodLiteral<"lookup">;
3616
+ template: z.ZodObject<{
3617
+ linkedRecordFieldId: z.ZodString;
3618
+ lookupFieldId: z.ZodString;
3619
+ formulaExpression: z.ZodOptional<z.ZodString>;
3620
+ resultType: z.ZodOptional<z.ZodEnum<["text", "number", "date", "boolean", "array"]>>;
3621
+ }, "strip", z.ZodTypeAny, {
3622
+ linkedRecordFieldId: string;
3623
+ lookupFieldId: string;
3624
+ formulaExpression?: string | undefined;
3625
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3626
+ }, {
3627
+ linkedRecordFieldId: string;
3628
+ lookupFieldId: string;
3629
+ formulaExpression?: string | undefined;
3630
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3631
+ }>;
3632
+ }, "strip", z.ZodTypeAny, {
3633
+ type: "lookup";
3634
+ name: string;
3635
+ template: {
3636
+ linkedRecordFieldId: string;
3637
+ lookupFieldId: string;
3638
+ formulaExpression?: string | undefined;
3639
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3640
+ };
3641
+ }, {
3642
+ type: "lookup";
3643
+ name: string;
3644
+ template: {
3645
+ linkedRecordFieldId: string;
3646
+ lookupFieldId: string;
3647
+ formulaExpression?: string | undefined;
3648
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3649
+ };
3650
+ }>, z.ZodObject<{
3651
+ name: z.ZodString;
3652
+ } & {
3653
+ type: z.ZodLiteral<"source">;
3654
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
3655
+ }, "strip", z.ZodTypeAny, {
3656
+ type: "source";
3657
+ name: string;
3658
+ template: {};
3659
+ }, {
3660
+ type: "source";
3661
+ name: string;
3662
+ template: {};
3663
+ }>, z.ZodObject<{
3664
+ name: z.ZodString;
3665
+ } & {
3666
+ type: z.ZodLiteral<"formula">;
3667
+ template: z.ZodObject<{
3668
+ expression: z.ZodString;
3669
+ resultType: z.ZodOptional<z.ZodEnum<["text", "number", "date", "boolean", "array"]>>;
3670
+ formatting: z.ZodOptional<z.ZodObject<{
3671
+ numberDisplayType: z.ZodOptional<z.ZodEnum<["number", "currency", "percent", "duration"]>>;
3672
+ currencyCode: z.ZodOptional<z.ZodString>;
3673
+ decimalPlaces: z.ZodOptional<z.ZodNumber>;
3674
+ numberFormat: z.ZodOptional<z.ZodEnum<["local", "comma_period", "period_comma", "space_comma", "space_period"]>>;
3675
+ }, "strip", z.ZodTypeAny, {
3676
+ decimalPlaces?: number | undefined;
3677
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
3678
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
3679
+ currencyCode?: string | undefined;
3680
+ }, {
3681
+ decimalPlaces?: number | undefined;
3682
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
3683
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
3684
+ currencyCode?: string | undefined;
3685
+ }>>;
3686
+ }, "strip", z.ZodTypeAny, {
3687
+ expression: string;
3688
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3689
+ formatting?: {
3690
+ decimalPlaces?: number | undefined;
3691
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
3692
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
3693
+ currencyCode?: string | undefined;
3694
+ } | undefined;
3695
+ }, {
3696
+ expression: string;
3697
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3698
+ formatting?: {
3699
+ decimalPlaces?: number | undefined;
3700
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
3701
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
3702
+ currencyCode?: string | undefined;
3703
+ } | undefined;
3704
+ }>;
3705
+ }, "strip", z.ZodTypeAny, {
3706
+ type: "formula";
3707
+ name: string;
3708
+ template: {
3709
+ expression: string;
3710
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3711
+ formatting?: {
3712
+ decimalPlaces?: number | undefined;
3713
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
3714
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
3715
+ currencyCode?: string | undefined;
3716
+ } | undefined;
3717
+ };
3718
+ }, {
3719
+ type: "formula";
3720
+ name: string;
3721
+ template: {
3722
+ expression: string;
3723
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3724
+ formatting?: {
3725
+ decimalPlaces?: number | undefined;
3726
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
3727
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
3728
+ currencyCode?: string | undefined;
3729
+ } | undefined;
3730
+ };
3731
+ }>, z.ZodObject<{
3732
+ name: z.ZodString;
3733
+ } & {
3734
+ type: z.ZodLiteral<"autonumber">;
3735
+ template: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
3736
+ }, "strip", z.ZodTypeAny, {
3737
+ type: "autonumber";
3738
+ name: string;
3739
+ template: {};
3740
+ }, {
3741
+ type: "autonumber";
3742
+ name: string;
3743
+ template: {};
3744
+ }>, z.ZodObject<{
3745
+ name: z.ZodString;
3746
+ } & {
3747
+ type: z.ZodLiteral<"created_at">;
3748
+ template: z.ZodObject<{
3749
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
3750
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
3751
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
3752
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
3753
+ }, "strip", z.ZodTypeAny, {
3754
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3755
+ displayTimeZone: boolean;
3756
+ timeFormat: "12h" | "24h";
3757
+ timezone: string;
3758
+ }, {
3759
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
3760
+ displayTimeZone?: boolean | null | undefined;
3761
+ timeFormat?: "12h" | "24h" | null | undefined;
3762
+ timezone?: string | null | undefined;
3763
+ }>;
3764
+ }, "strip", z.ZodTypeAny, {
3765
+ type: "created_at";
3766
+ name: string;
3767
+ template: {
3768
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3769
+ displayTimeZone: boolean;
3770
+ timeFormat: "12h" | "24h";
3771
+ timezone: string;
3772
+ };
3773
+ }, {
3774
+ type: "created_at";
3775
+ name: string;
3776
+ template: {
3777
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
3778
+ displayTimeZone?: boolean | null | undefined;
3779
+ timeFormat?: "12h" | "24h" | null | undefined;
3780
+ timezone?: string | null | undefined;
3781
+ };
3782
+ }>, z.ZodObject<{
3783
+ name: z.ZodString;
3784
+ } & {
3785
+ type: z.ZodLiteral<"updated_at">;
3786
+ template: z.ZodObject<{
3787
+ displayTimeZone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodBoolean>>, boolean, boolean | null | undefined>;
3788
+ dateFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["local", "long", "us", "european", "iso"]>>>, "local" | "long" | "us" | "european" | "iso", "local" | "long" | "us" | "european" | "iso" | null | undefined>;
3789
+ timeFormat: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodEnum<["12h", "24h"]>>>, "12h" | "24h", "12h" | "24h" | null | undefined>;
3790
+ timezone: z.ZodEffects<z.ZodOptional<z.ZodNullable<z.ZodString>>, string, string | null | undefined>;
3791
+ }, "strip", z.ZodTypeAny, {
3792
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3793
+ displayTimeZone: boolean;
3794
+ timeFormat: "12h" | "24h";
3795
+ timezone: string;
3796
+ }, {
3797
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
3798
+ displayTimeZone?: boolean | null | undefined;
3799
+ timeFormat?: "12h" | "24h" | null | undefined;
3800
+ timezone?: string | null | undefined;
3801
+ }>;
3802
+ }, "strip", z.ZodTypeAny, {
3803
+ type: "updated_at";
3804
+ name: string;
3805
+ template: {
3806
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3807
+ displayTimeZone: boolean;
3808
+ timeFormat: "12h" | "24h";
3809
+ timezone: string;
3810
+ };
3811
+ }, {
3812
+ type: "updated_at";
3813
+ name: string;
3814
+ template: {
3815
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
3816
+ displayTimeZone?: boolean | null | undefined;
3817
+ timeFormat?: "12h" | "24h" | null | undefined;
3818
+ timezone?: string | null | undefined;
3819
+ };
3820
+ }>]>>, "many">;
3821
+ views: z.ZodArray<z.ZodObject<{
3822
+ id: z.ZodString;
3823
+ name: z.ZodString;
3824
+ type: z.ZodString;
3825
+ config: z.ZodUnknown;
3826
+ }, "strip", z.ZodTypeAny, {
3827
+ id: string;
3828
+ type: string;
3829
+ name: string;
3830
+ config?: unknown;
3831
+ }, {
3832
+ id: string;
3833
+ type: string;
3834
+ name: string;
3835
+ config?: unknown;
3836
+ }>, "many">;
3837
+ url: z.ZodString;
3838
+ }, "strip", z.ZodTypeAny, {
3839
+ url: string;
3840
+ id: string;
3841
+ name: string;
3842
+ order: number;
3843
+ primaryFieldId: string;
3844
+ fields: ({
3845
+ id: string;
3846
+ order: number;
3847
+ } & ({
3848
+ type: "currency";
3849
+ name: string;
3850
+ template: {
3851
+ currencySymbol: string;
3852
+ decimalPlaces: number;
3853
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3854
+ defaultValue?: number | null | undefined;
3855
+ };
3856
+ } | {
3857
+ type: "single_line_text";
3858
+ name: string;
3859
+ template: {
3860
+ defaultValue?: string | undefined;
3861
+ };
3862
+ } | {
3863
+ type: "long_text";
3864
+ name: string;
3865
+ template: {
3866
+ defaultValue?: string | undefined;
3867
+ };
3868
+ } | {
3869
+ type: "rich_text";
3870
+ name: string;
3871
+ template: {
3872
+ defaultValue?: string | undefined;
3873
+ };
3874
+ } | {
3875
+ type: "number";
3876
+ name: string;
3877
+ template: {
3878
+ decimalPlaces: number;
3879
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3880
+ defaultValue?: number | null | undefined;
3881
+ };
3882
+ } | {
3883
+ type: "single_select";
3884
+ name: string;
3885
+ template: {
3886
+ options: {
3887
+ value: string;
3888
+ label: string;
3889
+ color?: string | undefined;
3890
+ }[];
3891
+ disableColors: boolean;
3892
+ defaultValue?: string | undefined;
3893
+ };
3894
+ } | {
3895
+ type: "multiple_select";
3896
+ name: string;
3897
+ template: {
3898
+ options: {
3899
+ value: string;
3900
+ label: string;
3901
+ color?: string | undefined;
3902
+ }[];
3903
+ disableColors: boolean;
3904
+ defaultValue?: string[] | undefined;
3905
+ };
3906
+ } | {
3907
+ type: "date";
3908
+ name: string;
3909
+ template: {
3910
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3911
+ };
3912
+ } | {
3913
+ type: "datetime";
3914
+ name: string;
3915
+ template: {
3916
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
3917
+ displayTimeZone: boolean;
3918
+ timeFormat: "12h" | "24h";
3919
+ timezone: string;
3920
+ };
3921
+ } | {
3922
+ type: "checkbox";
3923
+ name: string;
3924
+ template: {
3925
+ defaultValue?: boolean | undefined;
3926
+ };
3927
+ } | {
3928
+ type: "attachments";
3929
+ name: string;
3930
+ template: {};
3931
+ } | {
3932
+ type: "email";
3933
+ name: string;
3934
+ template: {};
3935
+ } | {
3936
+ type: "url";
3937
+ name: string;
3938
+ template: {};
3939
+ } | {
3940
+ type: "phone_number";
3941
+ name: string;
3942
+ template: {};
3943
+ } | {
3944
+ type: "rating";
3945
+ name: string;
3946
+ template: {
3947
+ maxRating: number;
3948
+ defaultValue?: number | undefined;
3949
+ };
3950
+ } | {
3951
+ type: "duration";
3952
+ name: string;
3953
+ template: {
3954
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
3955
+ defaultValue?: number | undefined;
3956
+ };
3957
+ } | {
3958
+ type: "percent";
3959
+ name: string;
3960
+ template: {
3961
+ decimalPlaces: number;
3962
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
3963
+ showProgressBar: boolean;
3964
+ allowNegative: boolean;
3965
+ defaultValue?: number | null | undefined;
3966
+ };
3967
+ } | {
3968
+ type: "linked_record";
3969
+ name: string;
3970
+ template: {
3971
+ tableId: string;
3972
+ allowMultiple?: boolean | undefined;
3973
+ };
3974
+ } | {
3975
+ type: "lookup";
3976
+ name: string;
3977
+ template: {
3978
+ linkedRecordFieldId: string;
3979
+ lookupFieldId: string;
3980
+ formulaExpression?: string | undefined;
3981
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3982
+ };
3983
+ } | {
3984
+ type: "source";
3985
+ name: string;
3986
+ template: {};
3987
+ } | {
3988
+ type: "formula";
3989
+ name: string;
3990
+ template: {
3991
+ expression: string;
3992
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
3993
+ formatting?: {
3994
+ decimalPlaces?: number | undefined;
3995
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
3996
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
3997
+ currencyCode?: string | undefined;
3998
+ } | undefined;
3999
+ };
4000
+ } | {
4001
+ type: "autonumber";
4002
+ name: string;
4003
+ template: {};
4004
+ } | {
4005
+ type: "created_at";
4006
+ name: string;
4007
+ template: {
4008
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
4009
+ displayTimeZone: boolean;
4010
+ timeFormat: "12h" | "24h";
4011
+ timezone: string;
4012
+ };
4013
+ } | {
4014
+ type: "updated_at";
4015
+ name: string;
4016
+ template: {
4017
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
4018
+ displayTimeZone: boolean;
4019
+ timeFormat: "12h" | "24h";
4020
+ timezone: string;
4021
+ };
4022
+ }))[];
4023
+ views: {
4024
+ id: string;
4025
+ type: string;
4026
+ name: string;
4027
+ config?: unknown;
4028
+ }[];
4029
+ }, {
4030
+ url: string;
4031
+ id: string;
4032
+ name: string;
4033
+ order: number;
4034
+ primaryFieldId: string;
4035
+ fields: ({
4036
+ id: string;
4037
+ order: number;
4038
+ } & ({
4039
+ type: "currency";
4040
+ name: string;
4041
+ template: {
4042
+ currencySymbol: string;
4043
+ decimalPlaces: number;
4044
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
4045
+ defaultValue?: number | null | undefined;
4046
+ };
4047
+ } | {
4048
+ type: "single_line_text";
4049
+ name: string;
4050
+ template: {
4051
+ defaultValue?: string | undefined;
4052
+ };
4053
+ } | {
4054
+ type: "long_text";
4055
+ name: string;
4056
+ template: {
4057
+ defaultValue?: string | undefined;
4058
+ };
4059
+ } | {
4060
+ type: "rich_text";
4061
+ name: string;
4062
+ template: {
4063
+ defaultValue?: string | undefined;
4064
+ };
4065
+ } | {
4066
+ type: "number";
4067
+ name: string;
4068
+ template: {
4069
+ decimalPlaces: number;
4070
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
4071
+ defaultValue?: number | null | undefined;
4072
+ };
4073
+ } | {
4074
+ type: "single_select";
4075
+ name: string;
4076
+ template: {
4077
+ options?: {
4078
+ value: string;
4079
+ label: string;
4080
+ color?: string | undefined;
4081
+ }[] | null | undefined;
4082
+ defaultValue?: string | undefined;
4083
+ disableColors?: boolean | null | undefined;
4084
+ };
4085
+ } | {
4086
+ type: "multiple_select";
4087
+ name: string;
4088
+ template: {
4089
+ options?: {
4090
+ value: string;
4091
+ label: string;
4092
+ color?: string | undefined;
4093
+ }[] | null | undefined;
4094
+ defaultValue?: string[] | undefined;
4095
+ disableColors?: boolean | null | undefined;
4096
+ };
4097
+ } | {
4098
+ type: "date";
4099
+ name: string;
4100
+ template: {
4101
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
4102
+ };
4103
+ } | {
4104
+ type: "datetime";
4105
+ name: string;
4106
+ template: {
4107
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
4108
+ displayTimeZone?: boolean | null | undefined;
4109
+ timeFormat?: "12h" | "24h" | null | undefined;
4110
+ timezone?: string | null | undefined;
4111
+ };
4112
+ } | {
4113
+ type: "checkbox";
4114
+ name: string;
4115
+ template: {
4116
+ defaultValue?: boolean | undefined;
4117
+ };
4118
+ } | {
4119
+ type: "attachments";
4120
+ name: string;
4121
+ template: {};
4122
+ } | {
4123
+ type: "email";
4124
+ name: string;
4125
+ template: {};
4126
+ } | {
4127
+ type: "url";
4128
+ name: string;
4129
+ template: {};
4130
+ } | {
4131
+ type: "phone_number";
4132
+ name: string;
4133
+ template: {};
4134
+ } | {
4135
+ type: "rating";
4136
+ name: string;
4137
+ template: {
4138
+ maxRating: number;
4139
+ defaultValue?: number | undefined;
4140
+ };
4141
+ } | {
4142
+ type: "duration";
4143
+ name: string;
4144
+ template: {
4145
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
4146
+ defaultValue?: number | undefined;
4147
+ };
4148
+ } | {
4149
+ type: "percent";
4150
+ name: string;
4151
+ template: {
4152
+ decimalPlaces: number;
4153
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
4154
+ showProgressBar: boolean;
4155
+ allowNegative: boolean;
4156
+ defaultValue?: number | null | undefined;
4157
+ };
4158
+ } | {
4159
+ type: "linked_record";
4160
+ name: string;
4161
+ template: {
4162
+ tableId: string;
4163
+ allowMultiple?: boolean | undefined;
4164
+ };
4165
+ } | {
4166
+ type: "lookup";
4167
+ name: string;
4168
+ template: {
4169
+ linkedRecordFieldId: string;
4170
+ lookupFieldId: string;
4171
+ formulaExpression?: string | undefined;
4172
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
4173
+ };
4174
+ } | {
4175
+ type: "source";
4176
+ name: string;
4177
+ template: {};
4178
+ } | {
4179
+ type: "formula";
4180
+ name: string;
4181
+ template: {
4182
+ expression: string;
4183
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
4184
+ formatting?: {
4185
+ decimalPlaces?: number | undefined;
4186
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
4187
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
4188
+ currencyCode?: string | undefined;
4189
+ } | undefined;
4190
+ };
4191
+ } | {
4192
+ type: "autonumber";
4193
+ name: string;
4194
+ template: {};
4195
+ } | {
4196
+ type: "created_at";
4197
+ name: string;
4198
+ template: {
4199
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
4200
+ displayTimeZone?: boolean | null | undefined;
4201
+ timeFormat?: "12h" | "24h" | null | undefined;
4202
+ timezone?: string | null | undefined;
4203
+ };
4204
+ } | {
4205
+ type: "updated_at";
4206
+ name: string;
4207
+ template: {
4208
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
4209
+ displayTimeZone?: boolean | null | undefined;
4210
+ timeFormat?: "12h" | "24h" | null | undefined;
4211
+ timezone?: string | null | undefined;
4212
+ };
4213
+ }))[];
4214
+ views: {
4215
+ id: string;
4216
+ type: string;
4217
+ name: string;
4218
+ config?: unknown;
4219
+ }[];
4220
+ }>, "many">;
4221
+ createdAt: z.ZodString;
4222
+ updatedAt: z.ZodString;
4223
+ url: z.ZodString;
4224
+ workspaceId: z.ZodOptional<z.ZodString>;
4225
+ }, "strip", z.ZodTypeAny, {
4226
+ url: string;
4227
+ id: string;
4228
+ name: string;
4229
+ tables: {
4230
+ url: string;
4231
+ id: string;
4232
+ name: string;
4233
+ order: number;
4234
+ primaryFieldId: string;
4235
+ fields: ({
4236
+ id: string;
4237
+ order: number;
4238
+ } & ({
4239
+ type: "currency";
4240
+ name: string;
4241
+ template: {
4242
+ currencySymbol: string;
4243
+ decimalPlaces: number;
4244
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
4245
+ defaultValue?: number | null | undefined;
4246
+ };
4247
+ } | {
4248
+ type: "single_line_text";
4249
+ name: string;
4250
+ template: {
4251
+ defaultValue?: string | undefined;
4252
+ };
4253
+ } | {
4254
+ type: "long_text";
4255
+ name: string;
4256
+ template: {
4257
+ defaultValue?: string | undefined;
4258
+ };
4259
+ } | {
4260
+ type: "rich_text";
4261
+ name: string;
4262
+ template: {
4263
+ defaultValue?: string | undefined;
4264
+ };
4265
+ } | {
4266
+ type: "number";
4267
+ name: string;
4268
+ template: {
4269
+ decimalPlaces: number;
4270
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
4271
+ defaultValue?: number | null | undefined;
4272
+ };
4273
+ } | {
4274
+ type: "single_select";
4275
+ name: string;
4276
+ template: {
4277
+ options: {
4278
+ value: string;
4279
+ label: string;
4280
+ color?: string | undefined;
4281
+ }[];
4282
+ disableColors: boolean;
4283
+ defaultValue?: string | undefined;
4284
+ };
4285
+ } | {
4286
+ type: "multiple_select";
4287
+ name: string;
4288
+ template: {
4289
+ options: {
4290
+ value: string;
4291
+ label: string;
4292
+ color?: string | undefined;
4293
+ }[];
4294
+ disableColors: boolean;
4295
+ defaultValue?: string[] | undefined;
4296
+ };
4297
+ } | {
4298
+ type: "date";
4299
+ name: string;
4300
+ template: {
4301
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
4302
+ };
4303
+ } | {
4304
+ type: "datetime";
4305
+ name: string;
4306
+ template: {
4307
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
4308
+ displayTimeZone: boolean;
4309
+ timeFormat: "12h" | "24h";
4310
+ timezone: string;
4311
+ };
4312
+ } | {
4313
+ type: "checkbox";
4314
+ name: string;
4315
+ template: {
4316
+ defaultValue?: boolean | undefined;
4317
+ };
4318
+ } | {
4319
+ type: "attachments";
4320
+ name: string;
4321
+ template: {};
4322
+ } | {
4323
+ type: "email";
4324
+ name: string;
4325
+ template: {};
4326
+ } | {
4327
+ type: "url";
4328
+ name: string;
4329
+ template: {};
4330
+ } | {
4331
+ type: "phone_number";
4332
+ name: string;
4333
+ template: {};
4334
+ } | {
4335
+ type: "rating";
4336
+ name: string;
4337
+ template: {
4338
+ maxRating: number;
4339
+ defaultValue?: number | undefined;
4340
+ };
4341
+ } | {
4342
+ type: "duration";
4343
+ name: string;
4344
+ template: {
4345
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
4346
+ defaultValue?: number | undefined;
4347
+ };
4348
+ } | {
4349
+ type: "percent";
4350
+ name: string;
4351
+ template: {
4352
+ decimalPlaces: number;
4353
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
4354
+ showProgressBar: boolean;
4355
+ allowNegative: boolean;
4356
+ defaultValue?: number | null | undefined;
4357
+ };
4358
+ } | {
4359
+ type: "linked_record";
4360
+ name: string;
4361
+ template: {
4362
+ tableId: string;
4363
+ allowMultiple?: boolean | undefined;
4364
+ };
4365
+ } | {
4366
+ type: "lookup";
4367
+ name: string;
4368
+ template: {
4369
+ linkedRecordFieldId: string;
4370
+ lookupFieldId: string;
4371
+ formulaExpression?: string | undefined;
4372
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
4373
+ };
4374
+ } | {
4375
+ type: "source";
4376
+ name: string;
4377
+ template: {};
4378
+ } | {
4379
+ type: "formula";
4380
+ name: string;
4381
+ template: {
4382
+ expression: string;
4383
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
4384
+ formatting?: {
4385
+ decimalPlaces?: number | undefined;
4386
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
4387
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
4388
+ currencyCode?: string | undefined;
4389
+ } | undefined;
4390
+ };
4391
+ } | {
4392
+ type: "autonumber";
4393
+ name: string;
4394
+ template: {};
4395
+ } | {
4396
+ type: "created_at";
4397
+ name: string;
4398
+ template: {
4399
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
4400
+ displayTimeZone: boolean;
4401
+ timeFormat: "12h" | "24h";
4402
+ timezone: string;
4403
+ };
4404
+ } | {
4405
+ type: "updated_at";
4406
+ name: string;
4407
+ template: {
4408
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
4409
+ displayTimeZone: boolean;
4410
+ timeFormat: "12h" | "24h";
4411
+ timezone: string;
4412
+ };
4413
+ }))[];
4414
+ views: {
4415
+ id: string;
4416
+ type: string;
4417
+ name: string;
4418
+ config?: unknown;
4419
+ }[];
4420
+ }[];
4421
+ createdAt: string;
4422
+ updatedAt: string;
4423
+ workspaceId?: string | undefined;
4424
+ }, {
4425
+ url: string;
4426
+ id: string;
4427
+ name: string;
4428
+ tables: {
4429
+ url: string;
4430
+ id: string;
4431
+ name: string;
4432
+ order: number;
4433
+ primaryFieldId: string;
4434
+ fields: ({
4435
+ id: string;
4436
+ order: number;
4437
+ } & ({
4438
+ type: "currency";
4439
+ name: string;
4440
+ template: {
4441
+ currencySymbol: string;
4442
+ decimalPlaces: number;
4443
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
4444
+ defaultValue?: number | null | undefined;
4445
+ };
4446
+ } | {
4447
+ type: "single_line_text";
4448
+ name: string;
4449
+ template: {
4450
+ defaultValue?: string | undefined;
4451
+ };
4452
+ } | {
4453
+ type: "long_text";
4454
+ name: string;
4455
+ template: {
4456
+ defaultValue?: string | undefined;
4457
+ };
4458
+ } | {
4459
+ type: "rich_text";
4460
+ name: string;
4461
+ template: {
4462
+ defaultValue?: string | undefined;
4463
+ };
4464
+ } | {
4465
+ type: "number";
4466
+ name: string;
4467
+ template: {
4468
+ decimalPlaces: number;
4469
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
4470
+ defaultValue?: number | null | undefined;
4471
+ };
4472
+ } | {
4473
+ type: "single_select";
4474
+ name: string;
4475
+ template: {
4476
+ options?: {
4477
+ value: string;
4478
+ label: string;
4479
+ color?: string | undefined;
4480
+ }[] | null | undefined;
4481
+ defaultValue?: string | undefined;
4482
+ disableColors?: boolean | null | undefined;
4483
+ };
4484
+ } | {
4485
+ type: "multiple_select";
4486
+ name: string;
4487
+ template: {
4488
+ options?: {
4489
+ value: string;
4490
+ label: string;
4491
+ color?: string | undefined;
4492
+ }[] | null | undefined;
4493
+ defaultValue?: string[] | undefined;
4494
+ disableColors?: boolean | null | undefined;
4495
+ };
4496
+ } | {
4497
+ type: "date";
4498
+ name: string;
4499
+ template: {
4500
+ dateFormat: "local" | "long" | "us" | "european" | "iso";
4501
+ };
4502
+ } | {
4503
+ type: "datetime";
4504
+ name: string;
4505
+ template: {
4506
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
4507
+ displayTimeZone?: boolean | null | undefined;
4508
+ timeFormat?: "12h" | "24h" | null | undefined;
4509
+ timezone?: string | null | undefined;
4510
+ };
4511
+ } | {
4512
+ type: "checkbox";
4513
+ name: string;
4514
+ template: {
4515
+ defaultValue?: boolean | undefined;
4516
+ };
4517
+ } | {
4518
+ type: "attachments";
4519
+ name: string;
4520
+ template: {};
4521
+ } | {
4522
+ type: "email";
4523
+ name: string;
4524
+ template: {};
4525
+ } | {
4526
+ type: "url";
4527
+ name: string;
4528
+ template: {};
4529
+ } | {
4530
+ type: "phone_number";
4531
+ name: string;
4532
+ template: {};
4533
+ } | {
4534
+ type: "rating";
4535
+ name: string;
4536
+ template: {
4537
+ maxRating: number;
4538
+ defaultValue?: number | undefined;
4539
+ };
4540
+ } | {
4541
+ type: "duration";
4542
+ name: string;
4543
+ template: {
4544
+ format: "h:mm" | "h:mm:ss" | "h:mm:ss.s" | "h:mm:ss.ss" | "h:mm:ss.sss";
4545
+ defaultValue?: number | undefined;
4546
+ };
4547
+ } | {
4548
+ type: "percent";
4549
+ name: string;
4550
+ template: {
4551
+ decimalPlaces: number;
4552
+ numberFormat: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | "no_separator";
4553
+ showProgressBar: boolean;
4554
+ allowNegative: boolean;
4555
+ defaultValue?: number | null | undefined;
4556
+ };
4557
+ } | {
4558
+ type: "linked_record";
4559
+ name: string;
4560
+ template: {
4561
+ tableId: string;
4562
+ allowMultiple?: boolean | undefined;
4563
+ };
4564
+ } | {
4565
+ type: "lookup";
4566
+ name: string;
4567
+ template: {
4568
+ linkedRecordFieldId: string;
4569
+ lookupFieldId: string;
4570
+ formulaExpression?: string | undefined;
4571
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
4572
+ };
4573
+ } | {
4574
+ type: "source";
4575
+ name: string;
4576
+ template: {};
4577
+ } | {
4578
+ type: "formula";
4579
+ name: string;
4580
+ template: {
4581
+ expression: string;
4582
+ resultType?: "number" | "boolean" | "date" | "text" | "array" | undefined;
4583
+ formatting?: {
4584
+ decimalPlaces?: number | undefined;
4585
+ numberFormat?: "local" | "comma_period" | "period_comma" | "space_comma" | "space_period" | undefined;
4586
+ numberDisplayType?: "number" | "currency" | "percent" | "duration" | undefined;
4587
+ currencyCode?: string | undefined;
4588
+ } | undefined;
4589
+ };
4590
+ } | {
4591
+ type: "autonumber";
4592
+ name: string;
4593
+ template: {};
4594
+ } | {
4595
+ type: "created_at";
4596
+ name: string;
4597
+ template: {
4598
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
4599
+ displayTimeZone?: boolean | null | undefined;
4600
+ timeFormat?: "12h" | "24h" | null | undefined;
4601
+ timezone?: string | null | undefined;
4602
+ };
4603
+ } | {
4604
+ type: "updated_at";
4605
+ name: string;
4606
+ template: {
4607
+ dateFormat?: "local" | "long" | "us" | "european" | "iso" | null | undefined;
4608
+ displayTimeZone?: boolean | null | undefined;
4609
+ timeFormat?: "12h" | "24h" | null | undefined;
4610
+ timezone?: string | null | undefined;
4611
+ };
4612
+ }))[];
4613
+ views: {
4614
+ id: string;
4615
+ type: string;
4616
+ name: string;
4617
+ config?: unknown;
4618
+ }[];
4619
+ }[];
4620
+ createdAt: string;
4621
+ updatedAt: string;
4622
+ workspaceId?: string | undefined;
4623
+ }>;
4624
+ export type Database = z.infer<typeof databaseSchema>;