@renterra/sdk 0.2.0 → 0.2.1

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