@chift/chift-nodejs 1.0.16 → 1.0.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. package/.github/workflows/ci.yml +10 -10
  2. package/CHANGELOG.md +12 -2
  3. package/README.md +3 -3
  4. package/dist/src/modules/accounting.d.ts +3 -3
  5. package/dist/src/modules/api.d.ts +4322 -2766
  6. package/dist/src/modules/consumer.d.ts +821 -512
  7. package/dist/src/modules/consumer.js +3 -0
  8. package/dist/src/modules/consumers.d.ts +4349 -2796
  9. package/dist/src/modules/datastores.d.ts +2 -2
  10. package/dist/src/modules/ecommerce.d.ts +2 -2
  11. package/dist/src/modules/integrations.d.ts +6 -6
  12. package/dist/src/modules/invoicing.d.ts +3 -3
  13. package/dist/src/modules/payment.d.ts +14 -0
  14. package/dist/src/modules/payment.js +41 -0
  15. package/dist/src/modules/sync.d.ts +3471 -2231
  16. package/dist/src/modules/sync.js +1 -1
  17. package/dist/src/modules/webhooks.d.ts +4 -1
  18. package/dist/src/types/sync.d.ts +22 -5
  19. package/dist/test/modules/accounting.test.js +58 -50
  20. package/dist/test/modules/consumer.test.js +4 -4
  21. package/dist/test/modules/consumers.test.js +4 -4
  22. package/dist/test/modules/ecommerce.test.js +23 -19
  23. package/dist/test/modules/integrations.test.js +4 -4
  24. package/dist/test/modules/invoicing.test.js +16 -9
  25. package/dist/test/modules/payment.test.d.ts +1 -0
  26. package/dist/test/modules/payment.test.js +88 -0
  27. package/dist/test/modules/pms.test.d.ts +1 -0
  28. package/dist/test/modules/pms.test.js +90 -0
  29. package/dist/test/modules/pos.test.js +31 -34
  30. package/dist/test/modules/sync.test.js +31 -19
  31. package/dist/test/modules/syncs.test.js +4 -4
  32. package/dist/test/modules/webhooks.test.js +4 -4
  33. package/package.json +1 -1
  34. package/src/modules/accounting.ts +3 -3
  35. package/src/modules/consumer.ts +4 -1
  36. package/src/modules/ecommerce.ts +4 -2
  37. package/src/modules/invoicing.ts +7 -3
  38. package/src/modules/payment.ts +59 -0
  39. package/src/modules/sync.ts +1 -1
  40. package/src/types/public-api/schema.d.ts +4071 -850
  41. package/src/types/sync.ts +20 -5
  42. package/test/modules/accounting.test.ts +69 -50
  43. package/test/modules/consumer.test.ts +5 -5
  44. package/test/modules/consumers.test.ts +4 -4
  45. package/test/modules/ecommerce.test.ts +25 -20
  46. package/test/modules/integrations.test.ts +4 -4
  47. package/test/modules/invoicing.test.ts +20 -10
  48. package/test/modules/payment.test.ts +65 -0
  49. package/test/modules/pms.test.ts +69 -0
  50. package/test/modules/pos.test.ts +32 -34
  51. package/test/modules/sync.test.ts +33 -19
  52. package/test/modules/syncs.test.ts +4 -4
  53. package/test/modules/webhooks.test.ts +4 -4
  54. package/.eslintcache +0 -1
  55. package/coverage/clover.xml +0 -1645
  56. package/coverage/coverage-final.json +0 -19
  57. package/coverage/lcov-report/base.css +0 -224
  58. package/coverage/lcov-report/block-navigation.js +0 -87
  59. package/coverage/lcov-report/favicon.png +0 -0
  60. package/coverage/lcov-report/index.html +0 -146
  61. package/coverage/lcov-report/prettify.css +0 -1
  62. package/coverage/lcov-report/prettify.js +0 -2
  63. package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
  64. package/coverage/lcov-report/sorter.js +0 -196
  65. package/coverage/lcov-report/src/helpers/index.html +0 -131
  66. package/coverage/lcov-report/src/helpers/openapi.ts.html +0 -151
  67. package/coverage/lcov-report/src/helpers/settings.ts.html +0 -94
  68. package/coverage/lcov-report/src/index.html +0 -116
  69. package/coverage/lcov-report/src/index.ts.html +0 -88
  70. package/coverage/lcov-report/src/modules/accounting.ts.html +0 -1156
  71. package/coverage/lcov-report/src/modules/api.ts.html +0 -190
  72. package/coverage/lcov-report/src/modules/consumer.ts.html +0 -616
  73. package/coverage/lcov-report/src/modules/consumers.ts.html +0 -331
  74. package/coverage/lcov-report/src/modules/custom.ts.html +0 -193
  75. package/coverage/lcov-report/src/modules/datastores.ts.html +0 -142
  76. package/coverage/lcov-report/src/modules/ecommerce.ts.html +0 -331
  77. package/coverage/lcov-report/src/modules/flow.ts.html +0 -589
  78. package/coverage/lcov-report/src/modules/index.html +0 -326
  79. package/coverage/lcov-report/src/modules/integrations.ts.html +0 -151
  80. package/coverage/lcov-report/src/modules/internalApi.ts.html +0 -586
  81. package/coverage/lcov-report/src/modules/invoicing.ts.html +0 -391
  82. package/coverage/lcov-report/src/modules/pos.ts.html +0 -421
  83. package/coverage/lcov-report/src/modules/sync.ts.html +0 -316
  84. package/coverage/lcov-report/src/modules/syncs.ts.html +0 -169
  85. package/coverage/lcov-report/src/modules/webhooks.ts.html +0 -343
  86. package/coverage/lcov.info +0 -1976
  87. package/dist/src/types/public-api/schema.d.ts +0 -12003
  88. package/dist/src/types/public-api/schema.js +0 -6
  89. package/src/types/public-api/schema.ts +0 -12073
  90. package/test/set_envs.sh +0 -14
@@ -17,14 +17,17 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
17
17
  status: "up" | "down";
18
18
  } | undefined;
19
19
  }[]>;
20
- createConnection: (body?: components['schemas']['app__routers__connections__PostConnectionItem']) => Promise<{
20
+ createConnection: (body?: components['schemas']['backbone_api__app__routers__connections__PostConnectionItem']) => Promise<{
21
21
  url: string;
22
22
  }>;
23
23
  updateConnection: (connectionId: string, body?: components['schemas']['PatchConnectionItem']) => Promise<{
24
24
  url: string;
25
25
  }>;
26
26
  deleteConnection: (connectionId: string) => Promise<{
27
- content: never;
27
+ headers: {
28
+ [name: string]: unknown;
29
+ };
30
+ content?: undefined;
28
31
  }>;
29
32
  enableFlow: (syncId: string, flowId: string, body: components['schemas']['EnableFlowConsumer']) => Promise<SimpleResponseModel>;
30
33
  getSyncUrl: (body: components['schemas']['CreateConsumerSyncItem']) => Promise<{
@@ -63,9 +66,10 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
63
66
  device_id?: string | undefined;
64
67
  total: number;
65
68
  tax_amount: number;
66
- total_discount?: number | undefined;
67
- total_refund?: number | undefined;
68
- total_tip?: number | undefined;
69
+ total_discount: number;
70
+ total_refund: number;
71
+ total_tip: number;
72
+ delivery_fee: number;
69
73
  currency?: string | undefined;
70
74
  country?: string | undefined;
71
75
  loyalty?: number | undefined;
@@ -82,8 +86,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
82
86
  payment_method_id?: string | undefined;
83
87
  payment_method_name?: string | undefined;
84
88
  total: number;
85
- tip?: number | undefined;
86
- status?: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised" | undefined;
89
+ tip: number;
90
+ status: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised";
87
91
  currency?: string | undefined;
88
92
  date?: string | undefined;
89
93
  }[];
@@ -95,10 +99,10 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
95
99
  tax_amount: number;
96
100
  tax_rate?: number | undefined;
97
101
  description?: string | undefined;
98
- discounts?: {
102
+ discounts: {
99
103
  name?: string | undefined;
100
104
  total: number;
101
- }[] | undefined;
105
+ }[];
102
106
  product_id?: string | undefined;
103
107
  accounting_category_id?: string | undefined;
104
108
  }[];
@@ -137,9 +141,10 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
137
141
  device_id?: string | undefined;
138
142
  total: number;
139
143
  tax_amount: number;
140
- total_discount?: number | undefined;
141
- total_refund?: number | undefined;
142
- total_tip?: number | undefined;
144
+ total_discount: number;
145
+ total_refund: number;
146
+ total_tip: number;
147
+ delivery_fee: number;
143
148
  currency?: string | undefined;
144
149
  country?: string | undefined;
145
150
  loyalty?: number | undefined;
@@ -156,8 +161,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
156
161
  payment_method_id?: string | undefined;
157
162
  payment_method_name?: string | undefined;
158
163
  total: number;
159
- tip?: number | undefined;
160
- status?: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised" | undefined;
164
+ tip: number;
165
+ status: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised";
161
166
  currency?: string | undefined;
162
167
  date?: string | undefined;
163
168
  }[];
@@ -169,10 +174,10 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
169
174
  tax_amount: number;
170
175
  tax_rate?: number | undefined;
171
176
  description?: string | undefined;
172
- discounts?: {
177
+ discounts: {
173
178
  name?: string | undefined;
174
179
  total: number;
175
- }[] | undefined;
180
+ }[];
176
181
  product_id?: string | undefined;
177
182
  accounting_category_id?: string | undefined;
178
183
  }[];
@@ -256,12 +261,12 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
256
261
  location_id?: string | undefined;
257
262
  } | undefined): import("../types/api").RequestData<{
258
263
  id: string;
259
- categories?: string[] | undefined;
264
+ categories: string[];
260
265
  name: string;
261
266
  description?: string | undefined;
262
267
  prices: {
263
268
  unit_price: number;
264
- tax_rate: number;
269
+ tax_rate?: number | undefined;
265
270
  }[];
266
271
  accounting_category_ids?: string[] | undefined;
267
272
  }[]>;
@@ -292,8 +297,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
292
297
  payment_method_id?: string | undefined;
293
298
  payment_method_name?: string | undefined;
294
299
  total: number;
295
- tip?: number | undefined;
296
- status?: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised" | undefined;
300
+ tip: number;
301
+ status: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised";
297
302
  currency?: string | undefined;
298
303
  date?: string | undefined;
299
304
  }[]>;
@@ -308,9 +313,10 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
308
313
  device_id?: string | undefined;
309
314
  total: number;
310
315
  tax_amount: number;
311
- total_discount?: number | undefined;
312
- total_refund?: number | undefined;
313
- total_tip?: number | undefined;
316
+ total_discount: number;
317
+ total_refund: number;
318
+ total_tip: number;
319
+ delivery_fee: number;
314
320
  currency?: string | undefined;
315
321
  country?: string | undefined;
316
322
  loyalty?: number | undefined;
@@ -327,8 +333,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
327
333
  payment_method_id?: string | undefined;
328
334
  payment_method_name?: string | undefined;
329
335
  total: number;
330
- tip?: number | undefined;
331
- status?: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised" | undefined;
336
+ tip: number;
337
+ status: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised";
332
338
  currency?: string | undefined;
333
339
  date?: string | undefined;
334
340
  }[];
@@ -340,15 +346,17 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
340
346
  tax_amount: number;
341
347
  tax_rate?: number | undefined;
342
348
  description?: string | undefined;
343
- discounts?: {
349
+ discounts: {
344
350
  name?: string | undefined;
345
351
  total: number;
346
- }[] | undefined;
352
+ }[];
347
353
  product_id?: string | undefined;
348
354
  accounting_category_id?: string | undefined;
349
355
  }[];
350
356
  }>;
351
- getAccountingCategories(params?: {} | undefined): import("../types/api").RequestData<{
357
+ getAccountingCategories(params?: {
358
+ location_id?: string | undefined;
359
+ } | undefined): import("../types/api").RequestData<{
352
360
  id: string;
353
361
  name: string;
354
362
  id_parent?: string | undefined;
@@ -391,9 +399,10 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
391
399
  device_id?: string | undefined;
392
400
  total: number;
393
401
  tax_amount: number;
394
- total_discount?: number | undefined;
395
- total_refund?: number | undefined;
396
- total_tip?: number | undefined;
402
+ total_discount: number;
403
+ total_refund: number;
404
+ total_tip: number;
405
+ delivery_fee: number;
397
406
  currency?: string | undefined;
398
407
  country?: string | undefined;
399
408
  loyalty?: number | undefined;
@@ -417,10 +426,10 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
417
426
  tax_amount: number;
418
427
  tax_rate?: number | undefined;
419
428
  description?: string | undefined;
420
- discounts?: {
429
+ discounts: {
421
430
  name?: string | undefined;
422
431
  total: number;
423
- }[] | undefined;
432
+ }[];
424
433
  product_id?: string | undefined;
425
434
  accounting_category_id?: string | undefined;
426
435
  }[];
@@ -456,8 +465,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
456
465
  payment_method_id?: string | undefined;
457
466
  payment_method_name?: string | undefined;
458
467
  total: number;
459
- tip?: number | undefined;
460
- status?: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised" | undefined;
468
+ tip: number;
469
+ status: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised";
461
470
  currency?: string | undefined;
462
471
  date?: string | undefined;
463
472
  }[]>;
@@ -474,13 +483,96 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
474
483
  posting_account_code?: string | undefined;
475
484
  }[]>;
476
485
  }>;
486
+ payment: import("../types/api").ApiFor<{
487
+ getPayments(params: {
488
+ date_from?: string | undefined;
489
+ date_to?: string | undefined;
490
+ }): import("../types/api").RequestData<{
491
+ id: string;
492
+ source_ref: {
493
+ id?: string | undefined;
494
+ model?: string | undefined;
495
+ };
496
+ status: "unknown" | "pending" | "completed" | "canceled" | "failed" | "authorized";
497
+ description: string;
498
+ amount: number;
499
+ currency: string;
500
+ payment_date: string;
501
+ partner_id: string;
502
+ }[]>;
503
+ getBalances(params: {}): import("../types/api").RequestData<{
504
+ id: string;
505
+ source_ref: {
506
+ id?: string | undefined;
507
+ model?: string | undefined;
508
+ };
509
+ available_amount: number;
510
+ currency: string;
511
+ create_date: string;
512
+ }[]>;
513
+ getTransactions(params: {
514
+ date_from?: string | undefined;
515
+ date_to?: string | undefined;
516
+ accounting_category?: "unknown" | "all" | "payout" | "payout_cancel" | "payment" | "payment_cancel" | "fee" | "fee_cancel" | undefined;
517
+ starting_from?: string | undefined;
518
+ balance_id?: string | undefined;
519
+ }): import("../types/api").RequestData<{
520
+ id: string;
521
+ source_ref: {
522
+ id?: string | undefined;
523
+ model?: string | undefined;
524
+ };
525
+ total: number;
526
+ fee: number;
527
+ currency: string;
528
+ exchange_rate: number;
529
+ create_date: string;
530
+ application_type: string;
531
+ accounting_category: "unknown" | "all" | "payout" | "payout_cancel" | "payment" | "payment_cancel" | "fee" | "fee_cancel";
532
+ refund_id?: string | undefined;
533
+ payment_id?: string | undefined;
534
+ }[]>;
535
+ getPayment(params: {
536
+ payment_id: string;
537
+ consumer_id: string;
538
+ }): import("../types/api").RequestData<{
539
+ id: string;
540
+ source_ref: {
541
+ id?: string | undefined;
542
+ model?: string | undefined;
543
+ };
544
+ status: "unknown" | "pending" | "completed" | "canceled" | "failed" | "authorized";
545
+ description: string;
546
+ amount: number;
547
+ currency: string;
548
+ payment_date: string;
549
+ partner_id: string;
550
+ }>;
551
+ getRefunds(params: {
552
+ date_from?: string | undefined;
553
+ date_to?: string | undefined;
554
+ payment_id?: string | undefined;
555
+ }): import("../types/api").RequestData<{
556
+ id: string;
557
+ source_ref: {
558
+ id?: string | undefined;
559
+ model?: string | undefined;
560
+ };
561
+ status: "unknown" | "pending" | "completed" | "canceled" | "failed" | "authorized";
562
+ description: string;
563
+ amount: number;
564
+ currency: string;
565
+ refund_date: string;
566
+ payment_id?: string | undefined;
567
+ }[]>;
568
+ }>;
477
569
  accounting: import("../types/api").ApiFor<{
478
570
  getAnalyticPlans(params?: {
479
571
  folder_id?: string | undefined;
480
572
  } | undefined): import("../types/api").RequestData<{
481
573
  id: string;
482
574
  name: string;
483
- active?: boolean | undefined;
575
+ active: boolean;
484
576
  }[]>;
485
577
  getClients(params?: {
486
578
  folder_id?: string | undefined;
@@ -490,7 +582,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
490
582
  last_name?: string | undefined;
491
583
  name?: string | undefined;
492
584
  function?: string | undefined;
493
- is_company?: boolean | undefined;
585
+ is_company: boolean;
494
586
  company_id?: string | undefined;
495
587
  phone?: string | undefined;
496
588
  mobile?: string | undefined;
@@ -502,8 +594,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
502
594
  iban?: string | undefined;
503
595
  bank_account?: string | undefined;
504
596
  currency?: string | undefined;
505
- active?: boolean | undefined;
506
- addresses?: {
597
+ active: boolean;
598
+ addresses: {
507
599
  address_type: "main" | "delivery" | "invoice";
508
600
  name?: string | undefined;
509
601
  number?: string | undefined;
@@ -515,7 +607,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
515
607
  city?: string | undefined;
516
608
  postal_code?: string | undefined;
517
609
  country?: string | undefined;
518
- }[] | undefined;
610
+ }[];
519
611
  account_number?: string | undefined;
520
612
  company_number?: string | undefined;
521
613
  id?: string | undefined;
@@ -526,7 +618,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
526
618
  last_name?: string | undefined;
527
619
  name: string;
528
620
  function?: string | undefined;
529
- is_company?: boolean | undefined;
621
+ is_company: boolean;
530
622
  company_id?: string | undefined;
531
623
  phone?: string | undefined;
532
624
  mobile?: string | undefined;
@@ -538,7 +630,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
538
630
  iban?: string | undefined;
539
631
  bank_account?: string | undefined;
540
632
  currency?: string | undefined;
541
- active?: boolean | undefined;
633
+ active: boolean;
542
634
  addresses: {
543
635
  address_type: "main" | "delivery" | "invoice";
544
636
  name?: string | undefined;
@@ -562,7 +654,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
562
654
  last_name?: string | undefined;
563
655
  name?: string | undefined;
564
656
  function?: string | undefined;
565
- is_company?: boolean | undefined;
657
+ is_company: boolean;
566
658
  company_id?: string | undefined;
567
659
  phone?: string | undefined;
568
660
  mobile?: string | undefined;
@@ -574,8 +666,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
574
666
  iban?: string | undefined;
575
667
  bank_account?: string | undefined;
576
668
  currency?: string | undefined;
577
- active?: boolean | undefined;
578
- addresses?: {
669
+ active: boolean;
670
+ addresses: {
579
671
  address_type: "main" | "delivery" | "invoice";
580
672
  name?: string | undefined;
581
673
  number?: string | undefined;
@@ -587,7 +679,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
587
679
  city?: string | undefined;
588
680
  postal_code?: string | undefined;
589
681
  country?: string | undefined;
590
- }[] | undefined;
682
+ }[];
591
683
  account_number?: string | undefined;
592
684
  company_number?: string | undefined;
593
685
  id?: string | undefined;
@@ -600,7 +692,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
600
692
  last_name?: string | undefined;
601
693
  name?: string | undefined;
602
694
  function?: string | undefined;
603
- is_company?: boolean | undefined;
695
+ is_company: boolean;
604
696
  company_id?: string | undefined;
605
697
  phone?: string | undefined;
606
698
  mobile?: string | undefined;
@@ -612,8 +704,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
612
704
  iban?: string | undefined;
613
705
  bank_account?: string | undefined;
614
706
  currency?: string | undefined;
615
- active?: boolean | undefined;
616
- addresses?: {
707
+ active: boolean;
708
+ addresses: {
617
709
  address_type: "main" | "delivery" | "invoice";
618
710
  name?: string | undefined;
619
711
  number?: string | undefined;
@@ -625,7 +717,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
625
717
  city?: string | undefined;
626
718
  postal_code?: string | undefined;
627
719
  country?: string | undefined;
628
- }[] | undefined;
720
+ }[];
629
721
  account_number?: string | undefined;
630
722
  company_number?: string | undefined;
631
723
  id?: string | undefined;
@@ -636,7 +728,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
636
728
  last_name?: string | undefined;
637
729
  name?: string | undefined;
638
730
  function?: string | undefined;
639
- is_company?: boolean | undefined;
731
+ is_company: boolean;
640
732
  company_id?: string | undefined;
641
733
  phone?: string | undefined;
642
734
  mobile?: string | undefined;
@@ -648,8 +740,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
648
740
  iban?: string | undefined;
649
741
  bank_account?: string | undefined;
650
742
  currency?: string | undefined;
651
- active?: boolean | undefined;
652
- addresses?: {
743
+ active: boolean;
744
+ addresses: {
653
745
  address_type: "main" | "delivery" | "invoice";
654
746
  name?: string | undefined;
655
747
  number?: string | undefined;
@@ -661,7 +753,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
661
753
  city?: string | undefined;
662
754
  postal_code?: string | undefined;
663
755
  country?: string | undefined;
664
- }[] | undefined;
756
+ }[];
665
757
  }, params?: {
666
758
  folder_id?: string | undefined;
667
759
  } | undefined): import("../types/api").RequestData<{
@@ -670,7 +762,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
670
762
  last_name?: string | undefined;
671
763
  name?: string | undefined;
672
764
  function?: string | undefined;
673
- is_company?: boolean | undefined;
765
+ is_company: boolean;
674
766
  company_id?: string | undefined;
675
767
  phone?: string | undefined;
676
768
  mobile?: string | undefined;
@@ -682,8 +774,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
682
774
  iban?: string | undefined;
683
775
  bank_account?: string | undefined;
684
776
  currency?: string | undefined;
685
- active?: boolean | undefined;
686
- addresses?: {
777
+ active: boolean;
778
+ addresses: {
687
779
  address_type: "main" | "delivery" | "invoice";
688
780
  name?: string | undefined;
689
781
  number?: string | undefined;
@@ -695,7 +787,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
695
787
  city?: string | undefined;
696
788
  postal_code?: string | undefined;
697
789
  country?: string | undefined;
698
- }[] | undefined;
790
+ }[];
699
791
  account_number?: string | undefined;
700
792
  company_number?: string | undefined;
701
793
  id?: string | undefined;
@@ -708,7 +800,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
708
800
  last_name?: string | undefined;
709
801
  name?: string | undefined;
710
802
  function?: string | undefined;
711
- is_company?: boolean | undefined;
803
+ is_company: boolean;
712
804
  company_id?: string | undefined;
713
805
  phone?: string | undefined;
714
806
  mobile?: string | undefined;
@@ -720,8 +812,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
720
812
  iban?: string | undefined;
721
813
  bank_account?: string | undefined;
722
814
  currency?: string | undefined;
723
- active?: boolean | undefined;
724
- addresses?: {
815
+ active: boolean;
816
+ addresses: {
725
817
  address_type: "main" | "delivery" | "invoice";
726
818
  name?: string | undefined;
727
819
  number?: string | undefined;
@@ -733,7 +825,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
733
825
  city?: string | undefined;
734
826
  postal_code?: string | undefined;
735
827
  country?: string | undefined;
736
- }[] | undefined;
828
+ }[];
737
829
  account_number?: string | undefined;
738
830
  company_number?: string | undefined;
739
831
  id?: string | undefined;
@@ -744,7 +836,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
744
836
  last_name?: string | undefined;
745
837
  name: string;
746
838
  function?: string | undefined;
747
- is_company?: boolean | undefined;
839
+ is_company: boolean;
748
840
  company_id?: string | undefined;
749
841
  phone?: string | undefined;
750
842
  mobile?: string | undefined;
@@ -756,7 +848,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
756
848
  iban?: string | undefined;
757
849
  bank_account?: string | undefined;
758
850
  currency?: string | undefined;
759
- active?: boolean | undefined;
851
+ active: boolean;
760
852
  addresses: {
761
853
  address_type: "main" | "delivery" | "invoice";
762
854
  name?: string | undefined;
@@ -780,7 +872,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
780
872
  last_name?: string | undefined;
781
873
  name?: string | undefined;
782
874
  function?: string | undefined;
783
- is_company?: boolean | undefined;
875
+ is_company: boolean;
784
876
  company_id?: string | undefined;
785
877
  phone?: string | undefined;
786
878
  mobile?: string | undefined;
@@ -792,8 +884,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
792
884
  iban?: string | undefined;
793
885
  bank_account?: string | undefined;
794
886
  currency?: string | undefined;
795
- active?: boolean | undefined;
796
- addresses?: {
887
+ active: boolean;
888
+ addresses: {
797
889
  address_type: "main" | "delivery" | "invoice";
798
890
  name?: string | undefined;
799
891
  number?: string | undefined;
@@ -805,7 +897,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
805
897
  city?: string | undefined;
806
898
  postal_code?: string | undefined;
807
899
  country?: string | undefined;
808
- }[] | undefined;
900
+ }[];
809
901
  account_number?: string | undefined;
810
902
  company_number?: string | undefined;
811
903
  id?: string | undefined;
@@ -818,7 +910,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
818
910
  last_name?: string | undefined;
819
911
  name?: string | undefined;
820
912
  function?: string | undefined;
821
- is_company?: boolean | undefined;
913
+ is_company: boolean;
822
914
  company_id?: string | undefined;
823
915
  phone?: string | undefined;
824
916
  mobile?: string | undefined;
@@ -830,8 +922,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
830
922
  iban?: string | undefined;
831
923
  bank_account?: string | undefined;
832
924
  currency?: string | undefined;
833
- active?: boolean | undefined;
834
- addresses?: {
925
+ active: boolean;
926
+ addresses: {
835
927
  address_type: "main" | "delivery" | "invoice";
836
928
  name?: string | undefined;
837
929
  number?: string | undefined;
@@ -843,7 +935,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
843
935
  city?: string | undefined;
844
936
  postal_code?: string | undefined;
845
937
  country?: string | undefined;
846
- }[] | undefined;
938
+ }[];
847
939
  account_number?: string | undefined;
848
940
  company_number?: string | undefined;
849
941
  id?: string | undefined;
@@ -854,7 +946,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
854
946
  last_name?: string | undefined;
855
947
  name?: string | undefined;
856
948
  function?: string | undefined;
857
- is_company?: boolean | undefined;
949
+ is_company: boolean;
858
950
  company_id?: string | undefined;
859
951
  phone?: string | undefined;
860
952
  mobile?: string | undefined;
@@ -866,8 +958,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
866
958
  iban?: string | undefined;
867
959
  bank_account?: string | undefined;
868
960
  currency?: string | undefined;
869
- active?: boolean | undefined;
870
- addresses?: {
961
+ active: boolean;
962
+ addresses: {
871
963
  address_type: "main" | "delivery" | "invoice";
872
964
  name?: string | undefined;
873
965
  number?: string | undefined;
@@ -879,7 +971,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
879
971
  city?: string | undefined;
880
972
  postal_code?: string | undefined;
881
973
  country?: string | undefined;
882
- }[] | undefined;
974
+ }[];
883
975
  }, params?: {
884
976
  folder_id?: string | undefined;
885
977
  } | undefined): import("../types/api").RequestData<{
@@ -888,7 +980,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
888
980
  last_name?: string | undefined;
889
981
  name?: string | undefined;
890
982
  function?: string | undefined;
891
- is_company?: boolean | undefined;
983
+ is_company: boolean;
892
984
  company_id?: string | undefined;
893
985
  phone?: string | undefined;
894
986
  mobile?: string | undefined;
@@ -900,8 +992,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
900
992
  iban?: string | undefined;
901
993
  bank_account?: string | undefined;
902
994
  currency?: string | undefined;
903
- active?: boolean | undefined;
904
- addresses?: {
995
+ active: boolean;
996
+ addresses: {
905
997
  address_type: "main" | "delivery" | "invoice";
906
998
  name?: string | undefined;
907
999
  number?: string | undefined;
@@ -913,7 +1005,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
913
1005
  city?: string | undefined;
914
1006
  postal_code?: string | undefined;
915
1007
  country?: string | undefined;
916
- }[] | undefined;
1008
+ }[];
917
1009
  account_number?: string | undefined;
918
1010
  company_number?: string | undefined;
919
1011
  id?: string | undefined;
@@ -932,9 +1024,9 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
932
1024
  due_date: string;
933
1025
  partner_id: string;
934
1026
  journal_id?: string | undefined;
935
- status?: "draft" | "posted" | undefined;
1027
+ status: "draft" | "posted";
936
1028
  pdf?: string | undefined;
937
- currency_exchange_rate?: number | undefined;
1029
+ currency_exchange_rate: number;
938
1030
  invoice_correction?: {
939
1031
  sale_invoice_correction_tax_code?: string | undefined;
940
1032
  purchase_invoice_correction_tax_code?: string | undefined;
@@ -953,7 +1045,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
953
1045
  } | undefined;
954
1046
  shipping_country?: string | undefined;
955
1047
  lines: {
956
- line_number?: number | undefined;
1048
+ line_number: number;
957
1049
  description: string;
958
1050
  unit_price: number;
959
1051
  unit_of_measure?: string | undefined;
@@ -990,18 +1082,18 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
990
1082
  name: string;
991
1083
  currency: string;
992
1084
  amount: number;
993
- dedicated_amount?: number | undefined;
1085
+ dedicated_amount: number;
994
1086
  payment_date: string;
995
1087
  journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation" | "unknown";
996
1088
  journal_id: string;
997
1089
  journal_name: string;
998
- reconciled?: boolean | undefined;
1090
+ reconciled: boolean;
999
1091
  communication?: string | undefined;
1000
1092
  matching_number?: string | undefined;
1001
1093
  }[] | undefined;
1002
- status?: "cancelled" | "draft" | "posted" | "paid" | undefined;
1094
+ status: "draft" | "posted" | "cancelled" | "paid";
1003
1095
  lines: {
1004
- line_number?: number | undefined;
1096
+ line_number: number;
1005
1097
  description: string;
1006
1098
  unit_price: number;
1007
1099
  unit_of_measure?: string | undefined;
@@ -1029,9 +1121,9 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1029
1121
  due_date: string;
1030
1122
  partner_id: string;
1031
1123
  journal_id?: string | undefined;
1032
- status?: "draft" | "posted" | undefined;
1124
+ status: "draft" | "posted";
1033
1125
  pdf?: string | undefined;
1034
- currency_exchange_rate?: number | undefined;
1126
+ currency_exchange_rate: number;
1035
1127
  invoice_correction?: {
1036
1128
  sale_invoice_correction_tax_code?: string | undefined;
1037
1129
  purchase_invoice_correction_tax_code?: string | undefined;
@@ -1050,7 +1142,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1050
1142
  } | undefined;
1051
1143
  shipping_country?: string | undefined;
1052
1144
  lines: {
1053
- line_number?: number | undefined;
1145
+ line_number: number;
1054
1146
  description: string;
1055
1147
  unit_price: number;
1056
1148
  unit_of_measure?: string | undefined;
@@ -1061,13 +1153,13 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1061
1153
  total: number;
1062
1154
  account_number: string;
1063
1155
  tax_code: string;
1064
- analytic_distribution?: {
1156
+ analytic_distribution: {
1065
1157
  analytic_plan: string;
1066
1158
  analytic_accounts: {
1067
1159
  analytic_account: string;
1068
1160
  percentage: number;
1069
1161
  }[];
1070
- }[] | undefined;
1162
+ }[];
1071
1163
  }[];
1072
1164
  }, params?: {
1073
1165
  force_financial_period?: string | undefined;
@@ -1093,18 +1185,18 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1093
1185
  name: string;
1094
1186
  currency: string;
1095
1187
  amount: number;
1096
- dedicated_amount?: number | undefined;
1188
+ dedicated_amount: number;
1097
1189
  payment_date: string;
1098
1190
  journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation" | "unknown";
1099
1191
  journal_id: string;
1100
1192
  journal_name: string;
1101
- reconciled?: boolean | undefined;
1193
+ reconciled: boolean;
1102
1194
  communication?: string | undefined;
1103
1195
  matching_number?: string | undefined;
1104
1196
  }[] | undefined;
1105
- status?: "cancelled" | "draft" | "posted" | "paid" | undefined;
1197
+ status: "draft" | "posted" | "cancelled" | "paid";
1106
1198
  lines: {
1107
- line_number?: number | undefined;
1199
+ line_number: number;
1108
1200
  description: string;
1109
1201
  unit_price: number;
1110
1202
  unit_of_measure?: string | undefined;
@@ -1115,13 +1207,13 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1115
1207
  total: number;
1116
1208
  account_number: string;
1117
1209
  tax_code?: string | undefined;
1118
- analytic_distribution?: {
1210
+ analytic_distribution: {
1119
1211
  analytic_plan: string;
1120
1212
  analytic_accounts: {
1121
1213
  analytic_account: string;
1122
1214
  percentage: number;
1123
1215
  }[];
1124
- }[] | undefined;
1216
+ }[];
1125
1217
  }[];
1126
1218
  }>;
1127
1219
  getInvoicesByType(invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund", params?: {
@@ -1151,18 +1243,18 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1151
1243
  name: string;
1152
1244
  currency: string;
1153
1245
  amount: number;
1154
- dedicated_amount?: number | undefined;
1246
+ dedicated_amount: number;
1155
1247
  payment_date: string;
1156
1248
  journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation" | "unknown";
1157
1249
  journal_id: string;
1158
1250
  journal_name: string;
1159
- reconciled?: boolean | undefined;
1251
+ reconciled: boolean;
1160
1252
  communication?: string | undefined;
1161
1253
  matching_number?: string | undefined;
1162
1254
  }[] | undefined;
1163
- status?: "cancelled" | "draft" | "posted" | "paid" | undefined;
1255
+ status: "draft" | "posted" | "cancelled" | "paid";
1164
1256
  lines: {
1165
- line_number?: number | undefined;
1257
+ line_number: number;
1166
1258
  description: string;
1167
1259
  unit_price: number;
1168
1260
  unit_of_measure?: string | undefined;
@@ -1199,18 +1291,18 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1199
1291
  name: string;
1200
1292
  currency: string;
1201
1293
  amount: number;
1202
- dedicated_amount?: number | undefined;
1294
+ dedicated_amount: number;
1203
1295
  payment_date: string;
1204
1296
  journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation" | "unknown";
1205
1297
  journal_id: string;
1206
1298
  journal_name: string;
1207
- reconciled?: boolean | undefined;
1299
+ reconciled: boolean;
1208
1300
  communication?: string | undefined;
1209
1301
  matching_number?: string | undefined;
1210
1302
  }[] | undefined;
1211
- status?: "cancelled" | "draft" | "posted" | "paid" | undefined;
1303
+ status: "draft" | "posted" | "cancelled" | "paid";
1212
1304
  lines: {
1213
- line_number?: number | undefined;
1305
+ line_number: number;
1214
1306
  description: string;
1215
1307
  unit_price: number;
1216
1308
  unit_of_measure?: string | undefined;
@@ -1247,18 +1339,18 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1247
1339
  name: string;
1248
1340
  currency: string;
1249
1341
  amount: number;
1250
- dedicated_amount?: number | undefined;
1342
+ dedicated_amount: number;
1251
1343
  payment_date: string;
1252
1344
  journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation" | "unknown";
1253
1345
  journal_id: string;
1254
1346
  journal_name: string;
1255
- reconciled?: boolean | undefined;
1347
+ reconciled: boolean;
1256
1348
  communication?: string | undefined;
1257
1349
  matching_number?: string | undefined;
1258
1350
  }[] | undefined;
1259
- status?: "cancelled" | "draft" | "posted" | "paid" | undefined;
1351
+ status: "draft" | "posted" | "cancelled" | "paid";
1260
1352
  lines: {
1261
- line_number?: number | undefined;
1353
+ line_number: number;
1262
1354
  description: string;
1263
1355
  unit_price: number;
1264
1356
  unit_of_measure?: string | undefined;
@@ -1269,13 +1361,13 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1269
1361
  total: number;
1270
1362
  account_number: string;
1271
1363
  tax_code?: string | undefined;
1272
- analytic_distribution?: {
1364
+ analytic_distribution: {
1273
1365
  analytic_plan: string;
1274
1366
  analytic_accounts: {
1275
1367
  analytic_account: string;
1276
1368
  percentage: number;
1277
1369
  }[];
1278
- }[] | undefined;
1370
+ }[];
1279
1371
  }[];
1280
1372
  }>;
1281
1373
  getInvoicesByTypeWithMultiplePlans(invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund", params?: {
@@ -1305,18 +1397,18 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1305
1397
  name: string;
1306
1398
  currency: string;
1307
1399
  amount: number;
1308
- dedicated_amount?: number | undefined;
1400
+ dedicated_amount: number;
1309
1401
  payment_date: string;
1310
1402
  journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation" | "unknown";
1311
1403
  journal_id: string;
1312
1404
  journal_name: string;
1313
- reconciled?: boolean | undefined;
1405
+ reconciled: boolean;
1314
1406
  communication?: string | undefined;
1315
1407
  matching_number?: string | undefined;
1316
1408
  }[] | undefined;
1317
- status?: "cancelled" | "draft" | "posted" | "paid" | undefined;
1409
+ status: "draft" | "posted" | "cancelled" | "paid";
1318
1410
  lines: {
1319
- line_number?: number | undefined;
1411
+ line_number: number;
1320
1412
  description: string;
1321
1413
  unit_price: number;
1322
1414
  unit_of_measure?: string | undefined;
@@ -1327,17 +1419,17 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1327
1419
  total: number;
1328
1420
  account_number: string;
1329
1421
  tax_code?: string | undefined;
1330
- analytic_distribution?: {
1422
+ analytic_distribution: {
1331
1423
  analytic_plan: string;
1332
1424
  analytic_accounts: {
1333
1425
  analytic_account: string;
1334
1426
  percentage: number;
1335
1427
  }[];
1336
- }[] | undefined;
1428
+ }[];
1337
1429
  }[];
1338
1430
  }[]>;
1339
1431
  createAnalyticAccount(analyticAccount: {
1340
- active?: boolean | undefined;
1432
+ active: boolean;
1341
1433
  code: string;
1342
1434
  name: string;
1343
1435
  currency: string;
@@ -1349,9 +1441,9 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1349
1441
  code?: string | undefined;
1350
1442
  name: string;
1351
1443
  currency?: string | undefined;
1352
- balance?: number | undefined;
1353
- credit?: number | undefined;
1354
- debit?: number | undefined;
1444
+ balance: number;
1445
+ credit: number;
1446
+ debit: number;
1355
1447
  }>;
1356
1448
  getAnalyticAccounts(params?: {
1357
1449
  folder_id?: string | undefined;
@@ -1361,12 +1453,12 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1361
1453
  code?: string | undefined;
1362
1454
  name: string;
1363
1455
  currency?: string | undefined;
1364
- balance?: number | undefined;
1365
- credit?: number | undefined;
1366
- debit?: number | undefined;
1456
+ balance: number;
1457
+ credit: number;
1458
+ debit: number;
1367
1459
  }[]>;
1368
1460
  createAnalyticAccountWithMultiplePlans(analytic_plan: string, analyticAccount: {
1369
- active?: boolean | undefined;
1461
+ active: boolean;
1370
1462
  code: string;
1371
1463
  name: string;
1372
1464
  currency: string;
@@ -1378,9 +1470,9 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1378
1470
  code?: string | undefined;
1379
1471
  name: string;
1380
1472
  currency?: string | undefined;
1381
- balance?: number | undefined;
1382
- credit?: number | undefined;
1383
- debit?: number | undefined;
1473
+ balance: number;
1474
+ credit: number;
1475
+ debit: number;
1384
1476
  analytic_plan: string;
1385
1477
  }>;
1386
1478
  getAnalyticAccount(analytic_account_id: string, params?: {
@@ -1391,12 +1483,12 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1391
1483
  code?: string | undefined;
1392
1484
  name: string;
1393
1485
  currency?: string | undefined;
1394
- balance?: number | undefined;
1395
- credit?: number | undefined;
1396
- debit?: number | undefined;
1486
+ balance: number;
1487
+ credit: number;
1488
+ debit: number;
1397
1489
  }>;
1398
1490
  updateAnalyticAccount(analytic_account_id: string, analyticAccount: {
1399
- active?: boolean | undefined;
1491
+ active: boolean;
1400
1492
  code?: string | undefined;
1401
1493
  name?: string | undefined;
1402
1494
  currency?: string | undefined;
@@ -1408,9 +1500,9 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1408
1500
  code?: string | undefined;
1409
1501
  name: string;
1410
1502
  currency?: string | undefined;
1411
- balance?: number | undefined;
1412
- credit?: number | undefined;
1413
- debit?: number | undefined;
1503
+ balance: number;
1504
+ credit: number;
1505
+ debit: number;
1414
1506
  }>;
1415
1507
  getAnalyticAccountWithMultiplePlans(analytic_account_id: string, analytic_plan: string, params?: {
1416
1508
  folder_id?: string | undefined;
@@ -1420,13 +1512,13 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1420
1512
  code?: string | undefined;
1421
1513
  name: string;
1422
1514
  currency?: string | undefined;
1423
- balance?: number | undefined;
1424
- credit?: number | undefined;
1425
- debit?: number | undefined;
1515
+ balance: number;
1516
+ credit: number;
1517
+ debit: number;
1426
1518
  analytic_plan: string;
1427
1519
  }>;
1428
1520
  updateAnalyticAccountWithMultiplePlans(analytic_account_id: string, analytic_plan: string, analyticAccount: {
1429
- active?: boolean | undefined;
1521
+ active: boolean;
1430
1522
  code?: string | undefined;
1431
1523
  name?: string | undefined;
1432
1524
  currency?: string | undefined;
@@ -1438,9 +1530,9 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1438
1530
  code?: string | undefined;
1439
1531
  name: string;
1440
1532
  currency?: string | undefined;
1441
- balance?: number | undefined;
1442
- credit?: number | undefined;
1443
- debit?: number | undefined;
1533
+ balance: number;
1534
+ credit: number;
1535
+ debit: number;
1444
1536
  analytic_plan: string;
1445
1537
  }>;
1446
1538
  getAnalyticAccountsWithMultiplePlans(params?: {
@@ -1451,9 +1543,9 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1451
1543
  code?: string | undefined;
1452
1544
  name: string;
1453
1545
  currency?: string | undefined;
1454
- balance?: number | undefined;
1455
- credit?: number | undefined;
1456
- debit?: number | undefined;
1546
+ balance: number;
1547
+ credit: number;
1548
+ debit: number;
1457
1549
  analytic_plan: string;
1458
1550
  }[]>;
1459
1551
  getJournalEntries(params: {
@@ -1469,24 +1561,24 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1469
1561
  journal_id: string;
1470
1562
  name?: string | undefined;
1471
1563
  journal_name: string;
1472
- date?: string | undefined;
1473
- posted?: boolean | undefined;
1564
+ date: string;
1565
+ posted: boolean;
1474
1566
  id: string;
1475
- items?: {
1567
+ items: {
1476
1568
  account_number: string;
1477
1569
  partner_id?: string | undefined;
1478
1570
  description?: string | undefined;
1479
1571
  debit: number;
1480
1572
  credit: number;
1481
1573
  currency: string;
1482
- currency_exchange_rate?: number | undefined;
1574
+ currency_exchange_rate: number;
1483
1575
  id: string;
1484
1576
  partner_name?: string | undefined;
1485
1577
  account_name: string;
1486
- matching_numbers?: string[] | undefined;
1578
+ matching_numbers: string[];
1487
1579
  analytic_account?: string | undefined;
1488
1580
  analytic_account_name?: string | undefined;
1489
- }[] | undefined;
1581
+ }[];
1490
1582
  }[]>;
1491
1583
  getJournalEntriesWithMultiplePlans(params: {
1492
1584
  date_from: string;
@@ -1501,29 +1593,29 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1501
1593
  journal_id: string;
1502
1594
  name?: string | undefined;
1503
1595
  journal_name: string;
1504
- date?: string | undefined;
1505
- posted?: boolean | undefined;
1596
+ date: string;
1597
+ posted: boolean;
1506
1598
  id: string;
1507
- items?: {
1599
+ items: {
1508
1600
  account_number: string;
1509
1601
  partner_id?: string | undefined;
1510
1602
  description?: string | undefined;
1511
1603
  debit: number;
1512
1604
  credit: number;
1513
1605
  currency: string;
1514
- currency_exchange_rate?: number | undefined;
1606
+ currency_exchange_rate: number;
1515
1607
  id: string;
1516
1608
  partner_name?: string | undefined;
1517
1609
  account_name: string;
1518
- matching_numbers?: string[] | undefined;
1519
- analytic_distribution?: {
1610
+ matching_numbers: string[];
1611
+ analytic_distribution: {
1520
1612
  analytic_plan: string;
1521
1613
  analytic_accounts: {
1522
1614
  analytic_account: string;
1523
1615
  percentage: number;
1524
1616
  }[];
1525
- }[] | undefined;
1526
- }[] | undefined;
1617
+ }[];
1618
+ }[];
1527
1619
  }[]>;
1528
1620
  getPaymentsByInvoiceId(invoice_id: string, params?: {
1529
1621
  folder_id?: string | undefined;
@@ -1534,12 +1626,12 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1534
1626
  name: string;
1535
1627
  currency: string;
1536
1628
  amount: number;
1537
- dedicated_amount?: number | undefined;
1629
+ dedicated_amount: number;
1538
1630
  payment_date: string;
1539
1631
  journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation" | "unknown";
1540
1632
  journal_id: string;
1541
1633
  journal_name: string;
1542
- reconciled?: boolean | undefined;
1634
+ reconciled: boolean;
1543
1635
  communication?: string | undefined;
1544
1636
  matching_number?: string | undefined;
1545
1637
  }[]>;
@@ -1550,6 +1642,13 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1550
1642
  code?: string | undefined;
1551
1643
  name: string;
1552
1644
  journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation" | "unknown";
1645
+ counterpart_account?: string | undefined;
1646
+ next_document_numbers: {
1647
+ bookyear_name?: string | undefined;
1648
+ next_document_number?: string | undefined;
1649
+ start_date?: string | undefined;
1650
+ end_date?: string | undefined;
1651
+ }[];
1553
1652
  }[]>;
1554
1653
  getVatCodes(params?: {
1555
1654
  folder_id?: string | undefined;
@@ -1557,7 +1656,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1557
1656
  id: string;
1558
1657
  code?: string | undefined;
1559
1658
  label: string;
1560
- scope?: "unknown" | "nat" | "eu" | "int" | undefined;
1659
+ scope: "unknown" | "nat" | "eu" | "int";
1561
1660
  rate: number;
1562
1661
  type: "unknown" | "sale" | "purchase" | "both";
1563
1662
  deductible_account?: string | undefined;
@@ -1571,55 +1670,55 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1571
1670
  } | undefined): import("../types/api").RequestData<{
1572
1671
  operation_number?: string | undefined;
1573
1672
  currency: string;
1574
- currency_exchange_rate?: number | undefined;
1673
+ currency_exchange_rate: number;
1575
1674
  lines: {
1576
- line_number?: number | undefined;
1675
+ line_number: number;
1577
1676
  description?: string | undefined;
1578
1677
  amount: number;
1579
- type: "customer_account" | "supplier_account" | "general_account";
1678
+ type: "customer_account" | "general_account" | "supplier_account";
1580
1679
  account_number: string;
1581
1680
  partner_id?: string | undefined;
1582
1681
  analytic_account?: string | undefined;
1583
1682
  }[];
1584
- operation_date?: string | undefined;
1683
+ operation_date: string;
1585
1684
  journal_id: string;
1586
- status: "cancelled" | "draft" | "posted" | "matched";
1685
+ status: "draft" | "posted" | "cancelled" | "matched";
1587
1686
  id: string;
1588
1687
  }[]>;
1589
1688
  createMiscOperation(operation: {
1590
1689
  operation_number?: string | undefined;
1591
1690
  currency: string;
1592
- currency_exchange_rate?: number | undefined;
1691
+ currency_exchange_rate: number;
1593
1692
  lines: {
1594
- line_number?: number | undefined;
1693
+ line_number: number;
1595
1694
  description?: string | undefined;
1596
1695
  amount: number;
1597
- type: "customer_account" | "supplier_account" | "general_account";
1696
+ type: "customer_account" | "general_account" | "supplier_account";
1598
1697
  account_number: string;
1599
1698
  partner_id?: string | undefined;
1600
1699
  analytic_account?: string | undefined;
1601
1700
  }[];
1602
1701
  operation_date: string;
1603
1702
  journal_id?: string | undefined;
1604
- status?: "draft" | "posted" | undefined;
1703
+ status: "draft" | "posted";
1605
1704
  }, params?: {
1606
1705
  folder_id?: string | undefined;
1607
1706
  } | undefined): import("../types/api").RequestData<{
1608
1707
  operation_number?: string | undefined;
1609
1708
  currency: string;
1610
- currency_exchange_rate?: number | undefined;
1709
+ currency_exchange_rate: number;
1611
1710
  lines: {
1612
- line_number?: number | undefined;
1711
+ line_number: number;
1613
1712
  description?: string | undefined;
1614
1713
  amount: number;
1615
- type: "customer_account" | "supplier_account" | "general_account";
1714
+ type: "customer_account" | "general_account" | "supplier_account";
1616
1715
  account_number: string;
1617
1716
  partner_id?: string | undefined;
1618
1717
  analytic_account?: string | undefined;
1619
1718
  }[];
1620
- operation_date?: string | undefined;
1719
+ operation_date: string;
1621
1720
  journal_id: string;
1622
- status: "cancelled" | "draft" | "posted" | "matched";
1721
+ status: "draft" | "posted" | "cancelled" | "matched";
1623
1722
  id: string;
1624
1723
  }>;
1625
1724
  getMiscOperation(operation_id: string, params?: {
@@ -1627,19 +1726,19 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1627
1726
  } | undefined): import("../types/api").RequestData<{
1628
1727
  operation_number?: string | undefined;
1629
1728
  currency: string;
1630
- currency_exchange_rate?: number | undefined;
1729
+ currency_exchange_rate: number;
1631
1730
  lines: {
1632
- line_number?: number | undefined;
1731
+ line_number: number;
1633
1732
  description?: string | undefined;
1634
1733
  amount: number;
1635
- type: "customer_account" | "supplier_account" | "general_account";
1734
+ type: "customer_account" | "general_account" | "supplier_account";
1636
1735
  account_number: string;
1637
1736
  partner_id?: string | undefined;
1638
1737
  analytic_account?: string | undefined;
1639
1738
  }[];
1640
- operation_date?: string | undefined;
1739
+ operation_date: string;
1641
1740
  journal_id: string;
1642
- status: "cancelled" | "draft" | "posted" | "matched";
1741
+ status: "draft" | "posted" | "cancelled" | "matched";
1643
1742
  id: string;
1644
1743
  }>;
1645
1744
  attachPDF(invoice_id: string, attachment: {
@@ -1648,6 +1747,9 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1648
1747
  overwrite_existing?: "true" | "false" | undefined;
1649
1748
  folder_id?: string | undefined;
1650
1749
  } | undefined): import("../types/api").RequestData<{
1750
+ headers: {
1751
+ [name: string]: unknown;
1752
+ };
1651
1753
  content: {
1652
1754
  'application/json': unknown;
1653
1755
  };
@@ -1665,8 +1767,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1665
1767
  } | undefined): import("../types/api").RequestData<{
1666
1768
  number: string;
1667
1769
  name: string;
1668
- active?: boolean | undefined;
1669
- type?: "bank" | "cash" | "other_financial" | "receivable" | "payable" | "income" | "expense" | "vat" | "other" | undefined;
1770
+ active: boolean;
1771
+ type?: "vat" | "bank" | "cash" | "other_financial" | "receivable" | "payable" | "income" | "expense" | "other" | undefined;
1670
1772
  }[]>;
1671
1773
  getBalanceOfAccounts(filter: {
1672
1774
  accounts: string[];
@@ -1680,6 +1782,9 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1680
1782
  debit: number;
1681
1783
  credit: number;
1682
1784
  balance: number;
1785
+ period_debit: number;
1786
+ period_credit: number;
1787
+ period_balance: number;
1683
1788
  }[]>;
1684
1789
  getEmployees(params?: {
1685
1790
  folder_id?: string | undefined;
@@ -1692,13 +1797,13 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1692
1797
  phone?: string | undefined;
1693
1798
  mobile?: string | undefined;
1694
1799
  email?: string | undefined;
1695
- active?: boolean | undefined;
1800
+ active: boolean;
1696
1801
  reference?: string | undefined;
1697
1802
  account_number?: string | undefined;
1698
1803
  }[]>;
1699
1804
  getOutstandings(params: {
1700
1805
  folder_id?: string | undefined;
1701
- type: "supplier" | "client";
1806
+ type: "client" | "supplier";
1702
1807
  unposted_allowed: "true" | "false";
1703
1808
  }): import("../types/api").RequestData<{
1704
1809
  id: string;
@@ -1721,11 +1826,11 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1721
1826
  date: string;
1722
1827
  journal_id: string;
1723
1828
  currency: string;
1724
- currency_exchange_rate?: number | undefined;
1829
+ currency_exchange_rate: number;
1725
1830
  reference?: string | undefined;
1726
1831
  number?: string | undefined;
1727
1832
  items: {
1728
- type: "customer_account" | "supplier_account" | "employee_account" | "general_account";
1833
+ type: "customer_account" | "general_account" | "supplier_account" | "employee_account";
1729
1834
  account_number: string;
1730
1835
  partner_id?: string | undefined;
1731
1836
  amount: number;
@@ -1739,12 +1844,12 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1739
1844
  date: string;
1740
1845
  journal_id: string;
1741
1846
  currency: string;
1742
- currency_exchange_rate?: number | undefined;
1847
+ currency_exchange_rate: number;
1743
1848
  reference?: string | undefined;
1744
1849
  id: string;
1745
1850
  number: string;
1746
1851
  items: {
1747
- type: "customer_account" | "supplier_account" | "employee_account" | "general_account";
1852
+ type: "customer_account" | "general_account" | "supplier_account" | "employee_account";
1748
1853
  account_number: string;
1749
1854
  partner_id?: string | undefined;
1750
1855
  amount: number;
@@ -1756,11 +1861,11 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1756
1861
  date: string;
1757
1862
  journal_id: string;
1758
1863
  currency: string;
1759
- currency_exchange_rate?: number | undefined;
1864
+ currency_exchange_rate: number;
1760
1865
  reference?: string | undefined;
1761
1866
  number?: string | undefined;
1762
1867
  items: {
1763
- account_type: "customer_account" | "supplier_account" | "employee_account" | "general_account";
1868
+ account_type: "customer_account" | "general_account" | "supplier_account" | "employee_account";
1764
1869
  account: string;
1765
1870
  amount: number;
1766
1871
  description?: string | undefined;
@@ -1773,12 +1878,12 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1773
1878
  date: string;
1774
1879
  journal_id: string;
1775
1880
  currency: string;
1776
- currency_exchange_rate?: number | undefined;
1881
+ currency_exchange_rate: number;
1777
1882
  reference?: string | undefined;
1778
1883
  id: string;
1779
1884
  number: string;
1780
1885
  items: {
1781
- account_type: "customer_account" | "supplier_account" | "employee_account" | "general_account";
1886
+ account_type: "customer_account" | "general_account" | "supplier_account" | "employee_account";
1782
1887
  account: string;
1783
1888
  amount: number;
1784
1889
  description?: string | undefined;
@@ -1798,14 +1903,14 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1798
1903
  debit: number;
1799
1904
  credit: number;
1800
1905
  currency: string;
1801
- currency_exchange_rate?: number | undefined;
1802
- analytic_distribution?: {
1906
+ currency_exchange_rate: number;
1907
+ analytic_distribution: {
1803
1908
  analytic_plan: string;
1804
1909
  analytic_accounts: {
1805
1910
  analytic_account: string;
1806
1911
  percentage: number;
1807
1912
  }[];
1808
- }[] | undefined;
1913
+ }[];
1809
1914
  }[];
1810
1915
  pdf?: string | undefined;
1811
1916
  }): import("../types/api").RequestData<{
@@ -1814,29 +1919,29 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1814
1919
  journal_id: string;
1815
1920
  name?: string | undefined;
1816
1921
  journal_name: string;
1817
- date?: string | undefined;
1818
- posted?: boolean | undefined;
1922
+ date: string;
1923
+ posted: boolean;
1819
1924
  id: string;
1820
- items?: {
1925
+ items: {
1821
1926
  account_number: string;
1822
1927
  partner_id?: string | undefined;
1823
1928
  description?: string | undefined;
1824
1929
  debit: number;
1825
1930
  credit: number;
1826
1931
  currency: string;
1827
- currency_exchange_rate?: number | undefined;
1932
+ currency_exchange_rate: number;
1828
1933
  id: string;
1829
1934
  partner_name?: string | undefined;
1830
1935
  account_name: string;
1831
- matching_numbers?: string[] | undefined;
1832
- analytic_distribution?: {
1936
+ matching_numbers: string[];
1937
+ analytic_distribution: {
1833
1938
  analytic_plan: string;
1834
1939
  analytic_accounts: {
1835
1940
  analytic_account: string;
1836
1941
  percentage: number;
1837
1942
  }[];
1838
- }[] | undefined;
1839
- }[] | undefined;
1943
+ }[];
1944
+ }[];
1840
1945
  }>;
1841
1946
  createJournalEntry(journal_entry: {
1842
1947
  reference?: string | undefined;
@@ -1844,28 +1949,29 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1844
1949
  journal_id: string;
1845
1950
  number: string;
1846
1951
  currency: string;
1847
- currency_exchange_rate?: number | undefined;
1952
+ currency_exchange_rate: number;
1848
1953
  date: string;
1849
1954
  items: {
1850
- account_type: "customer_account" | "supplier_account" | "employee_account" | "general_account";
1955
+ account_type: "customer_account" | "general_account" | "supplier_account" | "employee_account";
1851
1956
  account: string;
1852
1957
  force_general_account?: string | undefined;
1853
- prioritise_thirdparty_account?: boolean | undefined;
1958
+ prioritise_thirdparty_account: boolean;
1854
1959
  description?: string | undefined;
1855
1960
  debit: number;
1856
1961
  credit: number;
1857
- analytic_distribution?: {
1962
+ analytic_distribution: {
1858
1963
  analytic_plan: string;
1859
1964
  analytic_accounts: {
1860
1965
  analytic_account: string;
1861
1966
  percentage: number;
1862
1967
  }[];
1863
- }[] | undefined;
1968
+ }[];
1864
1969
  tax_code?: string | undefined;
1865
1970
  }[];
1866
1971
  pdf?: string | undefined;
1867
- posted?: boolean | undefined;
1972
+ posted: boolean;
1868
1973
  }, params?: {
1974
+ force_currency_exchange?: "true" | "false" | undefined;
1869
1975
  folder_id?: string | undefined;
1870
1976
  } | undefined): import("../types/api").RequestData<{
1871
1977
  reference?: string | undefined;
@@ -1873,29 +1979,29 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1873
1979
  journal_id: string;
1874
1980
  name?: string | undefined;
1875
1981
  journal_name: string;
1876
- date?: string | undefined;
1877
- posted?: boolean | undefined;
1982
+ date: string;
1983
+ posted: boolean;
1878
1984
  id: string;
1879
- items?: {
1985
+ items: {
1880
1986
  account_number: string;
1881
1987
  partner_id?: string | undefined;
1882
1988
  description?: string | undefined;
1883
1989
  debit: number;
1884
1990
  credit: number;
1885
1991
  currency: string;
1886
- currency_exchange_rate?: number | undefined;
1992
+ currency_exchange_rate: number;
1887
1993
  id: string;
1888
1994
  partner_name?: string | undefined;
1889
1995
  account_name: string;
1890
- matching_numbers?: string[] | undefined;
1891
- analytic_distribution?: {
1996
+ matching_numbers: string[];
1997
+ analytic_distribution: {
1892
1998
  analytic_plan: string;
1893
1999
  analytic_accounts: {
1894
2000
  analytic_account: string;
1895
2001
  percentage: number;
1896
2002
  }[];
1897
- }[] | undefined;
1898
- }[] | undefined;
2003
+ }[];
2004
+ }[];
1899
2005
  }>;
1900
2006
  matchEntries(body: {
1901
2007
  entries: string[];
@@ -1909,7 +2015,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1909
2015
  getFolders(): import("../types/api").RequestData<{
1910
2016
  id: string;
1911
2017
  name: string;
1912
- selected?: boolean | undefined;
2018
+ selected: boolean;
1913
2019
  vat?: string | undefined;
1914
2020
  company_number?: string | undefined;
1915
2021
  }[]>;
@@ -1919,7 +2025,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1919
2025
  date_from?: string | undefined;
1920
2026
  date_to?: string | undefined;
1921
2027
  payment_status?: "all" | "paid" | "unpaid" | undefined;
1922
- invoice_type?: "all" | "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | undefined;
2028
+ invoice_type?: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "all" | undefined;
1923
2029
  updated_after?: string | undefined;
1924
2030
  } | undefined): import("../types/api").RequestData<{
1925
2031
  id: string;
@@ -1929,16 +2035,16 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1929
2035
  };
1930
2036
  currency: string;
1931
2037
  invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
1932
- status: "cancelled" | "draft" | "posted" | "paid";
2038
+ status: "draft" | "posted" | "cancelled" | "paid";
1933
2039
  invoice_date: string;
1934
2040
  tax_amount: number;
1935
2041
  untaxed_amount: number;
1936
2042
  total: number;
1937
- lines?: {
2043
+ lines: {
1938
2044
  description?: string | undefined;
1939
2045
  unit_price: number;
1940
2046
  quantity: number;
1941
- discount_amount?: number | undefined;
2047
+ discount_amount: number;
1942
2048
  tax_amount: number;
1943
2049
  untaxed_amount: number;
1944
2050
  total: number;
@@ -1949,7 +2055,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1949
2055
  product_id?: string | undefined;
1950
2056
  product_code?: string | undefined;
1951
2057
  product_name?: string | undefined;
1952
- }[] | undefined;
2058
+ }[];
1953
2059
  partner_id?: string | undefined;
1954
2060
  invoice_number?: string | undefined;
1955
2061
  due_date?: string | undefined;
@@ -1961,8 +2067,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1961
2067
  model?: string | undefined;
1962
2068
  name?: string | undefined;
1963
2069
  } | undefined;
1964
- outstanding_amount?: number | undefined;
1965
2070
  last_updated_on?: string | undefined;
2071
+ outstanding_amount?: number | undefined;
1966
2072
  }[]>;
1967
2073
  getInvoiceById(invoiceId: string, params?: {
1968
2074
  include_pdf?: "true" | "false" | undefined;
@@ -1974,16 +2080,16 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1974
2080
  };
1975
2081
  currency: string;
1976
2082
  invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
1977
- status: "cancelled" | "draft" | "posted" | "paid";
2083
+ status: "draft" | "posted" | "cancelled" | "paid";
1978
2084
  invoice_date: string;
1979
2085
  tax_amount: number;
1980
2086
  untaxed_amount: number;
1981
2087
  total: number;
1982
- lines?: {
2088
+ lines: {
1983
2089
  description?: string | undefined;
1984
2090
  unit_price: number;
1985
2091
  quantity: number;
1986
- discount_amount?: number | undefined;
2092
+ discount_amount: number;
1987
2093
  tax_amount: number;
1988
2094
  untaxed_amount: number;
1989
2095
  total: number;
@@ -1994,7 +2100,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
1994
2100
  product_id?: string | undefined;
1995
2101
  product_code?: string | undefined;
1996
2102
  product_name?: string | undefined;
1997
- }[] | undefined;
2103
+ }[];
1998
2104
  partner_id?: string | undefined;
1999
2105
  invoice_number?: string | undefined;
2000
2106
  due_date?: string | undefined;
@@ -2006,22 +2112,22 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2006
2112
  model?: string | undefined;
2007
2113
  name?: string | undefined;
2008
2114
  } | undefined;
2009
- outstanding_amount?: number | undefined;
2010
2115
  last_updated_on?: string | undefined;
2116
+ outstanding_amount?: number | undefined;
2011
2117
  }>;
2012
2118
  createInvoice(invoice: {
2013
2119
  currency: string;
2014
2120
  invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
2015
- status: "cancelled" | "draft" | "posted" | "paid";
2121
+ status: "draft" | "posted" | "cancelled" | "paid";
2016
2122
  invoice_date: string;
2017
2123
  tax_amount: number;
2018
2124
  untaxed_amount: number;
2019
2125
  total: number;
2020
- lines?: {
2126
+ lines: {
2021
2127
  description?: string | undefined;
2022
2128
  unit_price: number;
2023
2129
  quantity: number;
2024
- discount_amount?: number | undefined;
2130
+ discount_amount: number;
2025
2131
  tax_amount: number;
2026
2132
  untaxed_amount: number;
2027
2133
  total: number;
@@ -2032,7 +2138,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2032
2138
  product_id?: string | undefined;
2033
2139
  product_code?: string | undefined;
2034
2140
  product_name?: string | undefined;
2035
- }[] | undefined;
2141
+ }[];
2036
2142
  partner_id?: string | undefined;
2037
2143
  invoice_number?: string | undefined;
2038
2144
  due_date?: string | undefined;
@@ -2044,7 +2150,6 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2044
2150
  model?: string | undefined;
2045
2151
  name?: string | undefined;
2046
2152
  } | undefined;
2047
- outstanding_amount?: number | undefined;
2048
2153
  }): import("../types/api").RequestData<{
2049
2154
  id: string;
2050
2155
  source_ref: {
@@ -2053,16 +2158,16 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2053
2158
  };
2054
2159
  currency: string;
2055
2160
  invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
2056
- status: "cancelled" | "draft" | "posted" | "paid";
2161
+ status: "draft" | "posted" | "cancelled" | "paid";
2057
2162
  invoice_date: string;
2058
2163
  tax_amount: number;
2059
2164
  untaxed_amount: number;
2060
2165
  total: number;
2061
- lines?: {
2166
+ lines: {
2062
2167
  description?: string | undefined;
2063
2168
  unit_price: number;
2064
2169
  quantity: number;
2065
- discount_amount?: number | undefined;
2170
+ discount_amount: number;
2066
2171
  tax_amount: number;
2067
2172
  untaxed_amount: number;
2068
2173
  total: number;
@@ -2073,7 +2178,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2073
2178
  product_id?: string | undefined;
2074
2179
  product_code?: string | undefined;
2075
2180
  product_name?: string | undefined;
2076
- }[] | undefined;
2181
+ }[];
2077
2182
  partner_id?: string | undefined;
2078
2183
  invoice_number?: string | undefined;
2079
2184
  due_date?: string | undefined;
@@ -2085,8 +2190,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2085
2190
  model?: string | undefined;
2086
2191
  name?: string | undefined;
2087
2192
  } | undefined;
2088
- outstanding_amount?: number | undefined;
2089
2193
  last_updated_on?: string | undefined;
2194
+ outstanding_amount?: number | undefined;
2090
2195
  }>;
2091
2196
  getProducts(): import("../types/api").RequestData<{
2092
2197
  id: string;
@@ -2102,8 +2207,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2102
2207
  category?: string | undefined;
2103
2208
  currency?: string | undefined;
2104
2209
  description?: string | undefined;
2105
- available_quantity?: number | undefined;
2106
- cost?: number | undefined;
2210
+ available_quantity: number;
2211
+ cost: number;
2107
2212
  }[]>;
2108
2213
  getProductById(productId: string): import("../types/api").RequestData<{
2109
2214
  id: string;
@@ -2119,8 +2224,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2119
2224
  category?: string | undefined;
2120
2225
  currency?: string | undefined;
2121
2226
  description?: string | undefined;
2122
- available_quantity?: number | undefined;
2123
- cost?: number | undefined;
2227
+ available_quantity: number;
2228
+ cost: number;
2124
2229
  }>;
2125
2230
  createProduct(product: {
2126
2231
  name: string;
@@ -2145,8 +2250,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2145
2250
  category?: string | undefined;
2146
2251
  currency?: string | undefined;
2147
2252
  description?: string | undefined;
2148
- available_quantity?: number | undefined;
2149
- cost?: number | undefined;
2253
+ available_quantity: number;
2254
+ cost: number;
2150
2255
  }>;
2151
2256
  getTaxes(): import("../types/api").RequestData<{
2152
2257
  id: string;
@@ -2158,7 +2263,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2158
2263
  rate: number;
2159
2264
  type: "unknown" | "sale" | "purchase" | "both";
2160
2265
  code?: string | undefined;
2161
- scope?: "unknown" | "nat" | "eu" | "int" | undefined;
2266
+ scope: "unknown" | "nat" | "eu" | "int";
2162
2267
  }[]>;
2163
2268
  getTaxById(taxId: string): import("../types/api").RequestData<{
2164
2269
  id: string;
@@ -2170,7 +2275,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2170
2275
  rate: number;
2171
2276
  type: "unknown" | "sale" | "purchase" | "both";
2172
2277
  code?: string | undefined;
2173
- scope?: "unknown" | "nat" | "eu" | "int" | undefined;
2278
+ scope: "unknown" | "nat" | "eu" | "int";
2174
2279
  }>;
2175
2280
  getOpportunities(): import("../types/api").RequestData<{
2176
2281
  id: string;
@@ -2225,7 +2330,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2225
2330
  } | undefined;
2226
2331
  }>;
2227
2332
  getContacts(params?: {
2228
- contact_type?: "prospect" | "customer" | "supplier" | "all" | undefined;
2333
+ contact_type?: "all" | "supplier" | "prospect" | "customer" | undefined;
2229
2334
  } | undefined): import("../types/api").RequestData<{
2230
2335
  id: string;
2231
2336
  source_ref: {
@@ -2252,8 +2357,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2252
2357
  supplier_account_number?: string | undefined;
2253
2358
  birthdate?: string | undefined;
2254
2359
  gender?: "H" | "F" | "N/A" | undefined;
2255
- addresses?: {
2256
- address_type: "other" | "main" | "delivery" | "invoice";
2360
+ addresses: {
2361
+ address_type: "main" | "delivery" | "invoice" | "other";
2257
2362
  name?: string | undefined;
2258
2363
  number?: string | undefined;
2259
2364
  box?: string | undefined;
@@ -2264,7 +2369,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2264
2369
  city?: string | undefined;
2265
2370
  postal_code?: string | undefined;
2266
2371
  country?: string | undefined;
2267
- }[] | undefined;
2372
+ }[];
2373
+ external_reference?: string | undefined;
2268
2374
  }[]>;
2269
2375
  getContactById(contactId: string): import("../types/api").RequestData<{
2270
2376
  id: string;
@@ -2292,8 +2398,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2292
2398
  supplier_account_number?: string | undefined;
2293
2399
  birthdate?: string | undefined;
2294
2400
  gender?: "H" | "F" | "N/A" | undefined;
2295
- addresses?: {
2296
- address_type: "other" | "main" | "delivery" | "invoice";
2401
+ addresses: {
2402
+ address_type: "main" | "delivery" | "invoice" | "other";
2297
2403
  name?: string | undefined;
2298
2404
  number?: string | undefined;
2299
2405
  box?: string | undefined;
@@ -2304,7 +2410,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2304
2410
  city?: string | undefined;
2305
2411
  postal_code?: string | undefined;
2306
2412
  country?: string | undefined;
2307
- }[] | undefined;
2413
+ }[];
2414
+ external_reference?: string | undefined;
2308
2415
  }>;
2309
2416
  createContact(contact: {
2310
2417
  is_prospect?: boolean | undefined;
@@ -2327,8 +2434,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2327
2434
  supplier_account_number?: string | undefined;
2328
2435
  birthdate?: string | undefined;
2329
2436
  gender?: "H" | "F" | "N/A" | undefined;
2330
- addresses?: {
2331
- address_type: "other" | "main" | "delivery" | "invoice";
2437
+ addresses: {
2438
+ address_type: "main" | "delivery" | "invoice" | "other";
2332
2439
  name?: string | undefined;
2333
2440
  number?: string | undefined;
2334
2441
  box?: string | undefined;
@@ -2339,7 +2446,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2339
2446
  city: string;
2340
2447
  postal_code: string;
2341
2448
  country: string;
2342
- }[] | undefined;
2449
+ }[];
2343
2450
  }): import("../types/api").RequestData<{
2344
2451
  id: string;
2345
2452
  source_ref: {
@@ -2366,8 +2473,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2366
2473
  supplier_account_number?: string | undefined;
2367
2474
  birthdate?: string | undefined;
2368
2475
  gender?: "H" | "F" | "N/A" | undefined;
2369
- addresses?: {
2370
- address_type: "other" | "main" | "delivery" | "invoice";
2476
+ addresses: {
2477
+ address_type: "main" | "delivery" | "invoice" | "other";
2371
2478
  name?: string | undefined;
2372
2479
  number?: string | undefined;
2373
2480
  box?: string | undefined;
@@ -2378,7 +2485,8 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2378
2485
  city?: string | undefined;
2379
2486
  postal_code?: string | undefined;
2380
2487
  country?: string | undefined;
2381
- }[] | undefined;
2488
+ }[];
2489
+ external_reference?: string | undefined;
2382
2490
  }>;
2383
2491
  }>;
2384
2492
  ecommerce: import("../types/api").ApiFor<{
@@ -2395,7 +2503,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2395
2503
  language?: string | undefined;
2396
2504
  internal_notes?: string | undefined;
2397
2505
  currency?: string | undefined;
2398
- addresses?: {
2506
+ addresses: {
2399
2507
  address_type: "main" | "delivery" | "invoice";
2400
2508
  company_name?: string | undefined;
2401
2509
  first_name?: string | undefined;
@@ -2408,7 +2516,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2408
2516
  country?: string | undefined;
2409
2517
  phone?: string | undefined;
2410
2518
  email?: string | undefined;
2411
- }[] | undefined;
2519
+ }[];
2412
2520
  created_on?: string | undefined;
2413
2521
  }[]>;
2414
2522
  getProducts(): import("../types/api").RequestData<{
@@ -2420,12 +2528,12 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2420
2528
  name: string;
2421
2529
  description?: string | undefined;
2422
2530
  description_html?: string | undefined;
2423
- categories?: {
2531
+ categories: {
2424
2532
  id: string;
2425
2533
  name: string;
2426
- }[] | undefined;
2534
+ }[];
2427
2535
  created_on?: string | undefined;
2428
- variants?: {
2536
+ variants: {
2429
2537
  id: string;
2430
2538
  source_ref: {
2431
2539
  id?: string | undefined;
@@ -2435,46 +2543,46 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2435
2543
  name: string;
2436
2544
  description?: string | undefined;
2437
2545
  description_html?: string | undefined;
2438
- categories?: {
2546
+ categories: {
2439
2547
  id: string;
2440
2548
  name: string;
2441
- }[] | undefined;
2549
+ }[];
2442
2550
  created_on?: string | undefined;
2443
2551
  sku?: string | undefined;
2444
2552
  barcode?: string | undefined;
2445
- available_quantity?: number | undefined;
2446
- prices?: {
2553
+ available_quantity: number;
2554
+ prices: {
2447
2555
  currency: string;
2448
- price?: number | undefined;
2449
- }[] | undefined;
2556
+ price: number;
2557
+ }[];
2450
2558
  unit_of_measure?: string | undefined;
2451
- weight?: number | undefined;
2559
+ weight: number;
2452
2560
  weight_unit?: string | undefined;
2453
2561
  status?: "unknown" | "archived" | "unpublished" | "published" | undefined;
2454
- variant_attributes?: {
2562
+ variant_attributes: {
2455
2563
  name: string;
2456
2564
  value: string;
2457
- }[] | undefined;
2458
- variant_images?: {
2565
+ }[];
2566
+ variant_images: {
2459
2567
  id: string;
2460
2568
  main_image: boolean;
2461
2569
  url: string;
2462
- }[] | undefined;
2463
- }[] | undefined;
2570
+ }[];
2571
+ }[];
2464
2572
  status?: "unknown" | "archived" | "unpublished" | "published" | undefined;
2465
- common_attributes?: {
2573
+ common_attributes: {
2466
2574
  name: string;
2467
2575
  values: string[];
2468
- }[] | undefined;
2469
- variant_attributes_options?: {
2576
+ }[];
2577
+ variant_attributes_options: {
2470
2578
  name: string;
2471
2579
  values: string[];
2472
- }[] | undefined;
2473
- common_images?: {
2580
+ }[];
2581
+ common_images: {
2474
2582
  id: string;
2475
2583
  main_image: boolean;
2476
2584
  url: string;
2477
- }[] | undefined;
2585
+ }[];
2478
2586
  }[]>;
2479
2587
  getCustomer(customerId: string): import("../types/api").RequestData<{
2480
2588
  id: string;
@@ -2489,7 +2597,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2489
2597
  language?: string | undefined;
2490
2598
  internal_notes?: string | undefined;
2491
2599
  currency?: string | undefined;
2492
- addresses?: {
2600
+ addresses: {
2493
2601
  address_type: "main" | "delivery" | "invoice";
2494
2602
  company_name?: string | undefined;
2495
2603
  first_name?: string | undefined;
@@ -2502,7 +2610,7 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2502
2610
  country?: string | undefined;
2503
2611
  phone?: string | undefined;
2504
2612
  email?: string | undefined;
2505
- }[] | undefined;
2613
+ }[];
2506
2614
  created_on?: string | undefined;
2507
2615
  }>;
2508
2616
  getProduct(productId: string): import("../types/api").RequestData<{
@@ -2514,12 +2622,12 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2514
2622
  name: string;
2515
2623
  description?: string | undefined;
2516
2624
  description_html?: string | undefined;
2517
- categories?: {
2625
+ categories: {
2518
2626
  id: string;
2519
2627
  name: string;
2520
- }[] | undefined;
2628
+ }[];
2521
2629
  created_on?: string | undefined;
2522
- variants?: {
2630
+ variants: {
2523
2631
  id: string;
2524
2632
  source_ref: {
2525
2633
  id?: string | undefined;
@@ -2529,46 +2637,46 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2529
2637
  name: string;
2530
2638
  description?: string | undefined;
2531
2639
  description_html?: string | undefined;
2532
- categories?: {
2640
+ categories: {
2533
2641
  id: string;
2534
2642
  name: string;
2535
- }[] | undefined;
2643
+ }[];
2536
2644
  created_on?: string | undefined;
2537
2645
  sku?: string | undefined;
2538
2646
  barcode?: string | undefined;
2539
- available_quantity?: number | undefined;
2540
- prices?: {
2647
+ available_quantity: number;
2648
+ prices: {
2541
2649
  currency: string;
2542
- price?: number | undefined;
2543
- }[] | undefined;
2650
+ price: number;
2651
+ }[];
2544
2652
  unit_of_measure?: string | undefined;
2545
- weight?: number | undefined;
2653
+ weight: number;
2546
2654
  weight_unit?: string | undefined;
2547
2655
  status?: "unknown" | "archived" | "unpublished" | "published" | undefined;
2548
- variant_attributes?: {
2656
+ variant_attributes: {
2549
2657
  name: string;
2550
2658
  value: string;
2551
- }[] | undefined;
2552
- variant_images?: {
2659
+ }[];
2660
+ variant_images: {
2553
2661
  id: string;
2554
2662
  main_image: boolean;
2555
2663
  url: string;
2556
- }[] | undefined;
2557
- }[] | undefined;
2664
+ }[];
2665
+ }[];
2558
2666
  status?: "unknown" | "archived" | "unpublished" | "published" | undefined;
2559
- common_attributes?: {
2667
+ common_attributes: {
2560
2668
  name: string;
2561
2669
  values: string[];
2562
- }[] | undefined;
2563
- variant_attributes_options?: {
2670
+ }[];
2671
+ variant_attributes_options: {
2564
2672
  name: string;
2565
2673
  values: string[];
2566
- }[] | undefined;
2567
- common_images?: {
2674
+ }[];
2675
+ common_images: {
2568
2676
  id: string;
2569
2677
  main_image: boolean;
2570
2678
  url: string;
2571
- }[] | undefined;
2679
+ }[];
2572
2680
  }>;
2573
2681
  getProductVariantById(variantId: string): import("../types/api").RequestData<{
2574
2682
  id: string;
@@ -2580,47 +2688,47 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2580
2688
  name: string;
2581
2689
  description?: string | undefined;
2582
2690
  description_html?: string | undefined;
2583
- categories?: {
2691
+ categories: {
2584
2692
  id: string;
2585
2693
  name: string;
2586
- }[] | undefined;
2694
+ }[];
2587
2695
  created_on?: string | undefined;
2588
2696
  sku?: string | undefined;
2589
2697
  barcode?: string | undefined;
2590
- available_quantity?: number | undefined;
2591
- prices?: {
2698
+ available_quantity: number;
2699
+ prices: {
2592
2700
  currency: string;
2593
- price?: number | undefined;
2594
- }[] | undefined;
2701
+ price: number;
2702
+ }[];
2595
2703
  unit_of_measure?: string | undefined;
2596
- weight?: number | undefined;
2704
+ weight: number;
2597
2705
  weight_unit?: string | undefined;
2598
2706
  status?: "unknown" | "archived" | "unpublished" | "published" | undefined;
2599
- inventory_details?: {
2707
+ inventory_details: {
2600
2708
  location: {
2601
2709
  id: string;
2602
2710
  name: string;
2603
2711
  };
2604
2712
  available_quantity: number;
2605
- }[] | undefined;
2606
- common_attributes?: {
2713
+ }[];
2714
+ common_attributes: {
2607
2715
  name: string;
2608
2716
  values: string[];
2609
- }[] | undefined;
2610
- variant_attributes?: {
2717
+ }[];
2718
+ variant_attributes: {
2611
2719
  name: string;
2612
2720
  value: string;
2613
- }[] | undefined;
2614
- common_images?: {
2721
+ }[];
2722
+ common_images: {
2615
2723
  id: string;
2616
2724
  main_image: boolean;
2617
2725
  url: string;
2618
- }[] | undefined;
2619
- variant_images?: {
2726
+ }[];
2727
+ variant_images: {
2620
2728
  id: string;
2621
2729
  main_image: boolean;
2622
2730
  url: string;
2623
- }[] | undefined;
2731
+ }[];
2624
2732
  }>;
2625
2733
  updateAvailableQuantity(variantId: string, inventoryDetails: {
2626
2734
  location_id: string;
@@ -2691,60 +2799,18 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2691
2799
  confirmed_on?: string | undefined;
2692
2800
  delivery_date?: string | undefined;
2693
2801
  cancelled_on?: string | undefined;
2694
- status: "cancelled" | "draft" | "cancelled_unpaid" | "confirmed" | "shipped" | "refunded";
2802
+ status: "draft" | "cancelled" | "cancelled_unpaid" | "confirmed" | "shipped" | "refunded";
2695
2803
  discount_amount: number;
2696
2804
  untaxed_amount_without_fees: number;
2697
2805
  tax_amount_without_fees: number;
2698
2806
  total_without_fees: number;
2807
+ current_untaxed_amount: number;
2808
+ current_tax_amount: number;
2809
+ current_total: number;
2699
2810
  untaxed_amount: number;
2700
2811
  tax_amount: number;
2701
2812
  total: number;
2702
- refunded_amount?: number | undefined;
2703
- detailed_refunds?: {
2704
- id: string;
2705
- source_ref: {
2706
- id?: string | undefined;
2707
- model?: string | undefined;
2708
- };
2709
- created_on?: string | undefined;
2710
- total: number;
2711
- reason?: string | undefined;
2712
- order_lines?: {
2713
- id: string;
2714
- variant?: {
2715
- id: string;
2716
- sku?: string | undefined;
2717
- name: string;
2718
- categories?: {
2719
- id: string;
2720
- name: string;
2721
- }[] | undefined;
2722
- } | undefined;
2723
- quantity: number;
2724
- untaxed_amount: number;
2725
- tax_amount: number;
2726
- total: number;
2727
- }[] | undefined;
2728
- other?: number | undefined;
2729
- shipping_refunds?: {
2730
- id: string;
2731
- source_ref: {
2732
- id?: string | undefined;
2733
- model?: string | undefined;
2734
- };
2735
- untaxed_amount: number;
2736
- tax_amount: number;
2737
- total: number;
2738
- }[] | undefined;
2739
- transactions?: {
2740
- id: string;
2741
- created_on?: string | undefined;
2742
- payment_method_id?: string | undefined;
2743
- payment_method_name?: string | undefined;
2744
- amount: number;
2745
- status: "failed" | "pending" | "success";
2746
- }[] | undefined;
2747
- }[] | undefined;
2813
+ refunded_amount: number;
2748
2814
  currency: string;
2749
2815
  note?: string | undefined;
2750
2816
  lines: {
@@ -2758,12 +2824,13 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2758
2824
  id: string;
2759
2825
  sku?: string | undefined;
2760
2826
  name: string;
2761
- categories?: {
2827
+ categories: {
2762
2828
  id: string;
2763
2829
  name: string;
2764
- }[] | undefined;
2830
+ }[];
2765
2831
  } | undefined;
2766
2832
  quantity: number;
2833
+ current_quantity: number;
2767
2834
  unit_price: number;
2768
2835
  description: string;
2769
2836
  tax_id?: string | undefined;
@@ -2771,14 +2838,14 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2771
2838
  untaxed_amount: number;
2772
2839
  tax_amount: number;
2773
2840
  total: number;
2774
- discounts?: {
2841
+ discounts: {
2775
2842
  name: string;
2776
2843
  description: string;
2777
2844
  amount: number;
2778
- }[] | undefined;
2779
- gift_card?: boolean | undefined;
2845
+ }[];
2846
+ gift_card: boolean;
2780
2847
  }[];
2781
- other_fees?: {
2848
+ other_fees: {
2782
2849
  id: string;
2783
2850
  source_ref: {
2784
2851
  id?: string | undefined;
@@ -2786,30 +2853,138 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2786
2853
  };
2787
2854
  created_on?: string | undefined;
2788
2855
  type: "other" | "shipping";
2856
+ removed: boolean;
2789
2857
  tax_rate: number;
2790
2858
  tax_id?: string | undefined;
2791
- discounts?: {
2859
+ discounts: {
2792
2860
  name: string;
2793
2861
  description: string;
2794
2862
  amount: number;
2795
- }[] | undefined;
2863
+ }[];
2796
2864
  untaxed_amount: number;
2797
2865
  tax_amount: number;
2798
2866
  total: number;
2799
- }[] | undefined;
2867
+ }[];
2800
2868
  payment_method_id?: string | undefined;
2801
- transactions?: {
2869
+ transactions: {
2802
2870
  id: string;
2803
2871
  created_on?: string | undefined;
2804
2872
  payment_method_id?: string | undefined;
2805
2873
  payment_method_name?: string | undefined;
2806
2874
  amount: number;
2807
- status: "failed" | "pending" | "success";
2808
- }[] | undefined;
2809
- payment_methods?: {
2875
+ status: "pending" | "failed" | "success";
2876
+ }[];
2877
+ payment_methods: {
2810
2878
  id: string;
2811
2879
  name?: string | undefined;
2880
+ }[];
2881
+ detailed_refunds?: {
2882
+ id: string;
2883
+ source_ref: {
2884
+ id?: string | undefined;
2885
+ model?: string | undefined;
2886
+ };
2887
+ created_on?: string | undefined;
2888
+ total: number;
2889
+ reason?: string | undefined;
2890
+ order_lines: {
2891
+ id: string;
2892
+ variant?: {
2893
+ id: string;
2894
+ sku?: string | undefined;
2895
+ name: string;
2896
+ categories: {
2897
+ id: string;
2898
+ name: string;
2899
+ }[];
2900
+ } | undefined;
2901
+ quantity: number;
2902
+ untaxed_amount: number;
2903
+ tax_amount: number;
2904
+ total: number;
2905
+ }[];
2906
+ other: number;
2907
+ shipping_refunds: {
2908
+ id: string;
2909
+ source_ref: {
2910
+ id?: string | undefined;
2911
+ model?: string | undefined;
2912
+ };
2913
+ untaxed_amount: number;
2914
+ tax_amount: number;
2915
+ total: number;
2916
+ }[];
2917
+ other_fees: {
2918
+ id: string;
2919
+ source_ref: {
2920
+ id?: string | undefined;
2921
+ model?: string | undefined;
2922
+ };
2923
+ type: "other" | "shipping";
2924
+ untaxed_amount: number;
2925
+ tax_amount: number;
2926
+ total: number;
2927
+ }[];
2928
+ transactions: {
2929
+ id: string;
2930
+ created_on?: string | undefined;
2931
+ payment_method_id?: string | undefined;
2932
+ payment_method_name?: string | undefined;
2933
+ amount: number;
2934
+ status: "pending" | "failed" | "success";
2935
+ }[];
2812
2936
  }[] | undefined;
2937
+ returns: {
2938
+ id: string;
2939
+ source_ref: {
2940
+ id?: string | undefined;
2941
+ model?: string | undefined;
2942
+ };
2943
+ created_on?: string | undefined;
2944
+ order_lines: {
2945
+ id: string;
2946
+ variant?: {
2947
+ id: string;
2948
+ sku?: string | undefined;
2949
+ name: string;
2950
+ categories: {
2951
+ id: string;
2952
+ name: string;
2953
+ }[];
2954
+ } | undefined;
2955
+ quantity: number;
2956
+ untaxed_amount: number;
2957
+ tax_amount: number;
2958
+ total: number;
2959
+ }[];
2960
+ new_lines: {
2961
+ id: string;
2962
+ variant?: {
2963
+ id: string;
2964
+ sku?: string | undefined;
2965
+ name: string;
2966
+ categories: {
2967
+ id: string;
2968
+ name: string;
2969
+ }[];
2970
+ } | undefined;
2971
+ quantity: number;
2972
+ untaxed_amount: number;
2973
+ tax_amount: number;
2974
+ total: number;
2975
+ }[];
2976
+ linked_fees: {
2977
+ id: string;
2978
+ source_ref: {
2979
+ id?: string | undefined;
2980
+ model?: string | undefined;
2981
+ };
2982
+ type: "other" | "shipping";
2983
+ untaxed_amount: number;
2984
+ tax_amount: number;
2985
+ total: number;
2986
+ }[];
2987
+ }[];
2813
2988
  }[]>;
2814
2989
  createOrder(order: {
2815
2990
  customer: {
@@ -2900,60 +3075,18 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2900
3075
  confirmed_on?: string | undefined;
2901
3076
  delivery_date?: string | undefined;
2902
3077
  cancelled_on?: string | undefined;
2903
- status: "cancelled" | "draft" | "cancelled_unpaid" | "confirmed" | "shipped" | "refunded";
3078
+ status: "draft" | "cancelled" | "cancelled_unpaid" | "confirmed" | "shipped" | "refunded";
2904
3079
  discount_amount: number;
2905
3080
  untaxed_amount_without_fees: number;
2906
3081
  tax_amount_without_fees: number;
2907
3082
  total_without_fees: number;
3083
+ current_untaxed_amount: number;
3084
+ current_tax_amount: number;
3085
+ current_total: number;
2908
3086
  untaxed_amount: number;
2909
3087
  tax_amount: number;
2910
3088
  total: number;
2911
- refunded_amount?: number | undefined;
2912
- detailed_refunds?: {
2913
- id: string;
2914
- source_ref: {
2915
- id?: string | undefined;
2916
- model?: string | undefined;
2917
- };
2918
- created_on?: string | undefined;
2919
- total: number;
2920
- reason?: string | undefined;
2921
- order_lines?: {
2922
- id: string;
2923
- variant?: {
2924
- id: string;
2925
- sku?: string | undefined;
2926
- name: string;
2927
- categories?: {
2928
- id: string;
2929
- name: string;
2930
- }[] | undefined;
2931
- } | undefined;
2932
- quantity: number;
2933
- untaxed_amount: number;
2934
- tax_amount: number;
2935
- total: number;
2936
- }[] | undefined;
2937
- other?: number | undefined;
2938
- shipping_refunds?: {
2939
- id: string;
2940
- source_ref: {
2941
- id?: string | undefined;
2942
- model?: string | undefined;
2943
- };
2944
- untaxed_amount: number;
2945
- tax_amount: number;
2946
- total: number;
2947
- }[] | undefined;
2948
- transactions?: {
2949
- id: string;
2950
- created_on?: string | undefined;
2951
- payment_method_id?: string | undefined;
2952
- payment_method_name?: string | undefined;
2953
- amount: number;
2954
- status: "failed" | "pending" | "success";
2955
- }[] | undefined;
2956
- }[] | undefined;
3089
+ refunded_amount: number;
2957
3090
  currency: string;
2958
3091
  note?: string | undefined;
2959
3092
  lines: {
@@ -2967,12 +3100,13 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2967
3100
  id: string;
2968
3101
  sku?: string | undefined;
2969
3102
  name: string;
2970
- categories?: {
3103
+ categories: {
2971
3104
  id: string;
2972
3105
  name: string;
2973
- }[] | undefined;
3106
+ }[];
2974
3107
  } | undefined;
2975
3108
  quantity: number;
3109
+ current_quantity: number;
2976
3110
  unit_price: number;
2977
3111
  description: string;
2978
3112
  tax_id?: string | undefined;
@@ -2980,14 +3114,14 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2980
3114
  untaxed_amount: number;
2981
3115
  tax_amount: number;
2982
3116
  total: number;
2983
- discounts?: {
3117
+ discounts: {
2984
3118
  name: string;
2985
3119
  description: string;
2986
3120
  amount: number;
2987
- }[] | undefined;
2988
- gift_card?: boolean | undefined;
3121
+ }[];
3122
+ gift_card: boolean;
2989
3123
  }[];
2990
- other_fees?: {
3124
+ other_fees: {
2991
3125
  id: string;
2992
3126
  source_ref: {
2993
3127
  id?: string | undefined;
@@ -2995,30 +3129,138 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
2995
3129
  };
2996
3130
  created_on?: string | undefined;
2997
3131
  type: "other" | "shipping";
3132
+ removed: boolean;
2998
3133
  tax_rate: number;
2999
3134
  tax_id?: string | undefined;
3000
- discounts?: {
3135
+ discounts: {
3001
3136
  name: string;
3002
3137
  description: string;
3003
3138
  amount: number;
3004
- }[] | undefined;
3139
+ }[];
3005
3140
  untaxed_amount: number;
3006
3141
  tax_amount: number;
3007
3142
  total: number;
3008
- }[] | undefined;
3143
+ }[];
3009
3144
  payment_method_id?: string | undefined;
3010
- transactions?: {
3145
+ transactions: {
3011
3146
  id: string;
3012
3147
  created_on?: string | undefined;
3013
3148
  payment_method_id?: string | undefined;
3014
3149
  payment_method_name?: string | undefined;
3015
3150
  amount: number;
3016
- status: "failed" | "pending" | "success";
3017
- }[] | undefined;
3018
- payment_methods?: {
3151
+ status: "pending" | "failed" | "success";
3152
+ }[];
3153
+ payment_methods: {
3019
3154
  id: string;
3020
3155
  name?: string | undefined;
3156
+ }[];
3157
+ detailed_refunds?: {
3158
+ id: string;
3159
+ source_ref: {
3160
+ id?: string | undefined;
3161
+ model?: string | undefined;
3162
+ };
3163
+ created_on?: string | undefined;
3164
+ total: number;
3165
+ reason?: string | undefined;
3166
+ order_lines: {
3167
+ id: string;
3168
+ variant?: {
3169
+ id: string;
3170
+ sku?: string | undefined;
3171
+ name: string;
3172
+ categories: {
3173
+ id: string;
3174
+ name: string;
3175
+ }[];
3176
+ } | undefined;
3177
+ quantity: number;
3178
+ untaxed_amount: number;
3179
+ tax_amount: number;
3180
+ total: number;
3181
+ }[];
3182
+ other: number;
3183
+ shipping_refunds: {
3184
+ id: string;
3185
+ source_ref: {
3186
+ id?: string | undefined;
3187
+ model?: string | undefined;
3188
+ };
3189
+ untaxed_amount: number;
3190
+ tax_amount: number;
3191
+ total: number;
3192
+ }[];
3193
+ other_fees: {
3194
+ id: string;
3195
+ source_ref: {
3196
+ id?: string | undefined;
3197
+ model?: string | undefined;
3198
+ };
3199
+ type: "other" | "shipping";
3200
+ untaxed_amount: number;
3201
+ tax_amount: number;
3202
+ total: number;
3203
+ }[];
3204
+ transactions: {
3205
+ id: string;
3206
+ created_on?: string | undefined;
3207
+ payment_method_id?: string | undefined;
3208
+ payment_method_name?: string | undefined;
3209
+ amount: number;
3210
+ status: "pending" | "failed" | "success";
3211
+ }[];
3021
3212
  }[] | undefined;
3213
+ returns: {
3214
+ id: string;
3215
+ source_ref: {
3216
+ id?: string | undefined;
3217
+ model?: string | undefined;
3218
+ };
3219
+ created_on?: string | undefined;
3220
+ order_lines: {
3221
+ id: string;
3222
+ variant?: {
3223
+ id: string;
3224
+ sku?: string | undefined;
3225
+ name: string;
3226
+ categories: {
3227
+ id: string;
3228
+ name: string;
3229
+ }[];
3230
+ } | undefined;
3231
+ quantity: number;
3232
+ untaxed_amount: number;
3233
+ tax_amount: number;
3234
+ total: number;
3235
+ }[];
3236
+ new_lines: {
3237
+ id: string;
3238
+ variant?: {
3239
+ id: string;
3240
+ sku?: string | undefined;
3241
+ name: string;
3242
+ categories: {
3243
+ id: string;
3244
+ name: string;
3245
+ }[];
3246
+ } | undefined;
3247
+ quantity: number;
3248
+ untaxed_amount: number;
3249
+ tax_amount: number;
3250
+ total: number;
3251
+ }[];
3252
+ linked_fees: {
3253
+ id: string;
3254
+ source_ref: {
3255
+ id?: string | undefined;
3256
+ model?: string | undefined;
3257
+ };
3258
+ type: "other" | "shipping";
3259
+ untaxed_amount: number;
3260
+ tax_amount: number;
3261
+ total: number;
3262
+ }[];
3263
+ }[];
3022
3264
  }>;
3023
3265
  getOrder(orderId: string): import("../types/api").RequestData<{
3024
3266
  id: string;
@@ -3068,60 +3310,18 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
3068
3310
  confirmed_on?: string | undefined;
3069
3311
  delivery_date?: string | undefined;
3070
3312
  cancelled_on?: string | undefined;
3071
- status: "cancelled" | "draft" | "cancelled_unpaid" | "confirmed" | "shipped" | "refunded";
3313
+ status: "draft" | "cancelled" | "cancelled_unpaid" | "confirmed" | "shipped" | "refunded";
3072
3314
  discount_amount: number;
3073
3315
  untaxed_amount_without_fees: number;
3074
3316
  tax_amount_without_fees: number;
3075
3317
  total_without_fees: number;
3318
+ current_untaxed_amount: number;
3319
+ current_tax_amount: number;
3320
+ current_total: number;
3076
3321
  untaxed_amount: number;
3077
3322
  tax_amount: number;
3078
3323
  total: number;
3079
- refunded_amount?: number | undefined;
3080
- detailed_refunds?: {
3081
- id: string;
3082
- source_ref: {
3083
- id?: string | undefined;
3084
- model?: string | undefined;
3085
- };
3086
- created_on?: string | undefined;
3087
- total: number;
3088
- reason?: string | undefined;
3089
- order_lines?: {
3090
- id: string;
3091
- variant?: {
3092
- id: string;
3093
- sku?: string | undefined;
3094
- name: string;
3095
- categories?: {
3096
- id: string;
3097
- name: string;
3098
- }[] | undefined;
3099
- } | undefined;
3100
- quantity: number;
3101
- untaxed_amount: number;
3102
- tax_amount: number;
3103
- total: number;
3104
- }[] | undefined;
3105
- other?: number | undefined;
3106
- shipping_refunds?: {
3107
- id: string;
3108
- source_ref: {
3109
- id?: string | undefined;
3110
- model?: string | undefined;
3111
- };
3112
- untaxed_amount: number;
3113
- tax_amount: number;
3114
- total: number;
3115
- }[] | undefined;
3116
- transactions?: {
3117
- id: string;
3118
- created_on?: string | undefined;
3119
- payment_method_id?: string | undefined;
3120
- payment_method_name?: string | undefined;
3121
- amount: number;
3122
- status: "failed" | "pending" | "success";
3123
- }[] | undefined;
3124
- }[] | undefined;
3324
+ refunded_amount: number;
3125
3325
  currency: string;
3126
3326
  note?: string | undefined;
3127
3327
  lines: {
@@ -3135,12 +3335,13 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
3135
3335
  id: string;
3136
3336
  sku?: string | undefined;
3137
3337
  name: string;
3138
- categories?: {
3338
+ categories: {
3139
3339
  id: string;
3140
3340
  name: string;
3141
- }[] | undefined;
3341
+ }[];
3142
3342
  } | undefined;
3143
3343
  quantity: number;
3344
+ current_quantity: number;
3144
3345
  unit_price: number;
3145
3346
  description: string;
3146
3347
  tax_id?: string | undefined;
@@ -3148,14 +3349,14 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
3148
3349
  untaxed_amount: number;
3149
3350
  tax_amount: number;
3150
3351
  total: number;
3151
- discounts?: {
3352
+ discounts: {
3152
3353
  name: string;
3153
3354
  description: string;
3154
3355
  amount: number;
3155
- }[] | undefined;
3156
- gift_card?: boolean | undefined;
3356
+ }[];
3357
+ gift_card: boolean;
3157
3358
  }[];
3158
- other_fees?: {
3359
+ other_fees: {
3159
3360
  id: string;
3160
3361
  source_ref: {
3161
3362
  id?: string | undefined;
@@ -3163,30 +3364,138 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
3163
3364
  };
3164
3365
  created_on?: string | undefined;
3165
3366
  type: "other" | "shipping";
3367
+ removed: boolean;
3166
3368
  tax_rate: number;
3167
3369
  tax_id?: string | undefined;
3168
- discounts?: {
3370
+ discounts: {
3169
3371
  name: string;
3170
3372
  description: string;
3171
3373
  amount: number;
3172
- }[] | undefined;
3374
+ }[];
3173
3375
  untaxed_amount: number;
3174
3376
  tax_amount: number;
3175
3377
  total: number;
3176
- }[] | undefined;
3378
+ }[];
3177
3379
  payment_method_id?: string | undefined;
3178
- transactions?: {
3380
+ transactions: {
3179
3381
  id: string;
3180
3382
  created_on?: string | undefined;
3181
3383
  payment_method_id?: string | undefined;
3182
3384
  payment_method_name?: string | undefined;
3183
3385
  amount: number;
3184
- status: "failed" | "pending" | "success";
3185
- }[] | undefined;
3186
- payment_methods?: {
3386
+ status: "pending" | "failed" | "success";
3387
+ }[];
3388
+ payment_methods: {
3187
3389
  id: string;
3188
3390
  name?: string | undefined;
3391
+ }[];
3392
+ detailed_refunds?: {
3393
+ id: string;
3394
+ source_ref: {
3395
+ id?: string | undefined;
3396
+ model?: string | undefined;
3397
+ };
3398
+ created_on?: string | undefined;
3399
+ total: number;
3400
+ reason?: string | undefined;
3401
+ order_lines: {
3402
+ id: string;
3403
+ variant?: {
3404
+ id: string;
3405
+ sku?: string | undefined;
3406
+ name: string;
3407
+ categories: {
3408
+ id: string;
3409
+ name: string;
3410
+ }[];
3411
+ } | undefined;
3412
+ quantity: number;
3413
+ untaxed_amount: number;
3414
+ tax_amount: number;
3415
+ total: number;
3416
+ }[];
3417
+ other: number;
3418
+ shipping_refunds: {
3419
+ id: string;
3420
+ source_ref: {
3421
+ id?: string | undefined;
3422
+ model?: string | undefined;
3423
+ };
3424
+ untaxed_amount: number;
3425
+ tax_amount: number;
3426
+ total: number;
3427
+ }[];
3428
+ other_fees: {
3429
+ id: string;
3430
+ source_ref: {
3431
+ id?: string | undefined;
3432
+ model?: string | undefined;
3433
+ };
3434
+ type: "other" | "shipping";
3435
+ untaxed_amount: number;
3436
+ tax_amount: number;
3437
+ total: number;
3438
+ }[];
3439
+ transactions: {
3440
+ id: string;
3441
+ created_on?: string | undefined;
3442
+ payment_method_id?: string | undefined;
3443
+ payment_method_name?: string | undefined;
3444
+ amount: number;
3445
+ status: "pending" | "failed" | "success";
3446
+ }[];
3189
3447
  }[] | undefined;
3448
+ returns: {
3449
+ id: string;
3450
+ source_ref: {
3451
+ id?: string | undefined;
3452
+ model?: string | undefined;
3453
+ };
3454
+ created_on?: string | undefined;
3455
+ order_lines: {
3456
+ id: string;
3457
+ variant?: {
3458
+ id: string;
3459
+ sku?: string | undefined;
3460
+ name: string;
3461
+ categories: {
3462
+ id: string;
3463
+ name: string;
3464
+ }[];
3465
+ } | undefined;
3466
+ quantity: number;
3467
+ untaxed_amount: number;
3468
+ tax_amount: number;
3469
+ total: number;
3470
+ }[];
3471
+ new_lines: {
3472
+ id: string;
3473
+ variant?: {
3474
+ id: string;
3475
+ sku?: string | undefined;
3476
+ name: string;
3477
+ categories: {
3478
+ id: string;
3479
+ name: string;
3480
+ }[];
3481
+ } | undefined;
3482
+ quantity: number;
3483
+ untaxed_amount: number;
3484
+ tax_amount: number;
3485
+ total: number;
3486
+ }[];
3487
+ linked_fees: {
3488
+ id: string;
3489
+ source_ref: {
3490
+ id?: string | undefined;
3491
+ model?: string | undefined;
3492
+ };
3493
+ type: "other" | "shipping";
3494
+ untaxed_amount: number;
3495
+ tax_amount: number;
3496
+ total: number;
3497
+ }[];
3498
+ }[];
3190
3499
  }>;
3191
3500
  getPaymentMethods(params?: {} | undefined): import("../types/api").RequestData<{
3192
3501
  id: string;
@@ -3242,13 +3551,13 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
3242
3551
  getSyncData: (syncId: string) => Promise<{
3243
3552
  syncid: string;
3244
3553
  sync_name: string;
3245
- status?: "active" | "inactive" | undefined;
3554
+ status: "active" | "inactive";
3246
3555
  status_details?: string | undefined;
3247
3556
  link_createdon: string;
3248
3557
  link_mappings?: {
3249
3558
  name: string;
3250
3559
  description?: string | undefined;
3251
- display_order?: number | undefined;
3560
+ display_order: number;
3252
3561
  challenge_question?: string | undefined;
3253
3562
  values: {
3254
3563
  source_id: string;
@@ -3266,26 +3575,26 @@ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperati
3266
3575
  definitionFields?: Record<string, never>[] | undefined;
3267
3576
  doorkeyFields?: Record<string, never>[] | undefined;
3268
3577
  customFields?: Record<string, never>[] | undefined;
3269
- datastores?: {
3578
+ datastores: {
3270
3579
  id?: string | undefined;
3271
3580
  name: string;
3272
- status?: "active" | "inactive" | undefined;
3581
+ status: "active" | "inactive";
3273
3582
  definition: {
3274
3583
  columns: {
3275
3584
  name: string;
3276
3585
  title: string;
3277
3586
  type: string;
3278
- optional?: boolean | undefined;
3587
+ optional: boolean;
3279
3588
  }[];
3280
3589
  search_column?: string | undefined;
3281
3590
  };
3282
- }[] | undefined;
3591
+ }[];
3283
3592
  } | undefined;
3284
3593
  values: Record<string, never>;
3285
3594
  enabled_on?: string | undefined;
3286
3595
  trigger: {
3287
3596
  id: string;
3288
- type: "timer" | "event";
3597
+ type: "event" | "timer";
3289
3598
  cronschedule?: string | undefined;
3290
3599
  };
3291
3600
  }[] | undefined;