@chift/chift-nodejs 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (146) hide show
  1. package/.eslintcache +1 -0
  2. package/.eslintignore +1 -0
  3. package/.eslintrc.json +25 -0
  4. package/.github/workflows/ci.yml +73 -0
  5. package/.husky/pre-commit +4 -0
  6. package/.prettierignore +1 -0
  7. package/.prettierrc.json +7 -0
  8. package/CHANGELOG.md +4 -0
  9. package/LICENSE +201 -0
  10. package/README.md +48 -0
  11. package/coverage/clover.xml +1645 -0
  12. package/coverage/coverage-final.json +19 -0
  13. package/coverage/lcov-report/base.css +224 -0
  14. package/coverage/lcov-report/block-navigation.js +87 -0
  15. package/coverage/lcov-report/favicon.png +0 -0
  16. package/coverage/lcov-report/index.html +146 -0
  17. package/coverage/lcov-report/prettify.css +1 -0
  18. package/coverage/lcov-report/prettify.js +2 -0
  19. package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
  20. package/coverage/lcov-report/sorter.js +196 -0
  21. package/coverage/lcov-report/src/helpers/index.html +131 -0
  22. package/coverage/lcov-report/src/helpers/openapi.ts.html +151 -0
  23. package/coverage/lcov-report/src/helpers/settings.ts.html +94 -0
  24. package/coverage/lcov-report/src/index.html +116 -0
  25. package/coverage/lcov-report/src/index.ts.html +88 -0
  26. package/coverage/lcov-report/src/modules/accounting.ts.html +1156 -0
  27. package/coverage/lcov-report/src/modules/api.ts.html +190 -0
  28. package/coverage/lcov-report/src/modules/consumer.ts.html +616 -0
  29. package/coverage/lcov-report/src/modules/consumers.ts.html +331 -0
  30. package/coverage/lcov-report/src/modules/custom.ts.html +193 -0
  31. package/coverage/lcov-report/src/modules/datastores.ts.html +142 -0
  32. package/coverage/lcov-report/src/modules/ecommerce.ts.html +331 -0
  33. package/coverage/lcov-report/src/modules/flow.ts.html +589 -0
  34. package/coverage/lcov-report/src/modules/index.html +326 -0
  35. package/coverage/lcov-report/src/modules/integrations.ts.html +151 -0
  36. package/coverage/lcov-report/src/modules/internalApi.ts.html +586 -0
  37. package/coverage/lcov-report/src/modules/invoicing.ts.html +391 -0
  38. package/coverage/lcov-report/src/modules/pos.ts.html +421 -0
  39. package/coverage/lcov-report/src/modules/sync.ts.html +316 -0
  40. package/coverage/lcov-report/src/modules/syncs.ts.html +169 -0
  41. package/coverage/lcov-report/src/modules/webhooks.ts.html +343 -0
  42. package/coverage/lcov.info +1976 -0
  43. package/dist/src/helpers/openapi.d.ts +3 -0
  44. package/dist/src/helpers/openapi.js +18 -0
  45. package/dist/src/helpers/settings.d.ts +4 -0
  46. package/dist/src/helpers/settings.js +5 -0
  47. package/dist/src/index.d.ts +1 -0
  48. package/dist/src/index.js +17 -0
  49. package/dist/src/modules/accounting.d.ts +48 -0
  50. package/dist/src/modules/accounting.js +255 -0
  51. package/dist/src/modules/api.d.ts +39333 -0
  52. package/dist/src/modules/api.js +36 -0
  53. package/dist/src/modules/consumer.d.ts +2588 -0
  54. package/dist/src/modules/consumer.js +118 -0
  55. package/dist/src/modules/consumers.d.ts +13034 -0
  56. package/dist/src/modules/consumers.js +51 -0
  57. package/dist/src/modules/custom.d.ts +8 -0
  58. package/dist/src/modules/custom.js +36 -0
  59. package/dist/src/modules/datastores.d.ts +18 -0
  60. package/dist/src/modules/datastores.js +23 -0
  61. package/dist/src/modules/ecommerce.d.ts +16 -0
  62. package/dist/src/modules/ecommerce.js +69 -0
  63. package/dist/src/modules/flow.d.ts +15 -0
  64. package/dist/src/modules/flow.js +156 -0
  65. package/dist/src/modules/integrations.d.ts +14 -0
  66. package/dist/src/modules/integrations.js +23 -0
  67. package/dist/src/modules/internalApi.d.ts +22 -0
  68. package/dist/src/modules/internalApi.js +160 -0
  69. package/dist/src/modules/invoicing.d.ts +18 -0
  70. package/dist/src/modules/invoicing.js +90 -0
  71. package/dist/src/modules/pos.d.ts +20 -0
  72. package/dist/src/modules/pos.js +80 -0
  73. package/dist/src/modules/sync.d.ts +10494 -0
  74. package/dist/src/modules/sync.js +75 -0
  75. package/dist/src/modules/syncs.d.ts +26200 -0
  76. package/dist/src/modules/syncs.js +29 -0
  77. package/dist/src/modules/webhooks.d.ts +55 -0
  78. package/dist/src/modules/webhooks.js +53 -0
  79. package/dist/src/types/api.d.ts +28 -0
  80. package/dist/src/types/api.js +2 -0
  81. package/dist/src/types/consumers.d.ts +8 -0
  82. package/dist/src/types/consumers.js +2 -0
  83. package/dist/src/types/public-api/mappings.d.ts +21 -0
  84. package/dist/src/types/public-api/mappings.js +2 -0
  85. package/dist/src/types/sync.d.ts +20 -0
  86. package/dist/src/types/sync.js +2 -0
  87. package/dist/test/modules/accounting.test.d.ts +1 -0
  88. package/dist/test/modules/accounting.test.js +453 -0
  89. package/dist/test/modules/consumer.test.d.ts +1 -0
  90. package/dist/test/modules/consumer.test.js +89 -0
  91. package/dist/test/modules/consumers.test.d.ts +1 -0
  92. package/dist/test/modules/consumers.test.js +109 -0
  93. package/dist/test/modules/ecommerce.test.d.ts +1 -0
  94. package/dist/test/modules/ecommerce.test.js +193 -0
  95. package/dist/test/modules/flow.test.d.ts +1 -0
  96. package/dist/test/modules/flow.test.js +69 -0
  97. package/dist/test/modules/integrations.test.d.ts +1 -0
  98. package/dist/test/modules/integrations.test.js +54 -0
  99. package/dist/test/modules/invoicing.test.d.ts +1 -0
  100. package/dist/test/modules/invoicing.test.js +108 -0
  101. package/dist/test/modules/pos.test.d.ts +1 -0
  102. package/dist/test/modules/pos.test.js +164 -0
  103. package/dist/test/modules/sync.test.d.ts +1 -0
  104. package/dist/test/modules/sync.test.js +81 -0
  105. package/dist/test/modules/syncs.test.d.ts +1 -0
  106. package/dist/test/modules/syncs.test.js +53 -0
  107. package/dist/test/modules/webhooks.test.d.ts +1 -0
  108. package/dist/test/modules/webhooks.test.js +120 -0
  109. package/jest.config.ts +195 -0
  110. package/package.json +47 -0
  111. package/src/helpers/openapi.ts +22 -0
  112. package/src/helpers/settings.ts +3 -0
  113. package/src/index.ts +1 -0
  114. package/src/modules/accounting.ts +357 -0
  115. package/src/modules/api.ts +35 -0
  116. package/src/modules/consumer.ts +177 -0
  117. package/src/modules/consumers.ts +82 -0
  118. package/src/modules/custom.ts +36 -0
  119. package/src/modules/datastores.ts +19 -0
  120. package/src/modules/ecommerce.ts +82 -0
  121. package/src/modules/flow.ts +168 -0
  122. package/src/modules/integrations.ts +22 -0
  123. package/src/modules/internalApi.ts +162 -0
  124. package/src/modules/invoicing.ts +106 -0
  125. package/src/modules/pos.ts +112 -0
  126. package/src/modules/sync.ts +77 -0
  127. package/src/modules/syncs.ts +28 -0
  128. package/src/modules/webhooks.ts +86 -0
  129. package/src/types/api.ts +35 -0
  130. package/src/types/consumers.ts +9 -0
  131. package/src/types/public-api/mappings.ts +21 -0
  132. package/src/types/public-api/schema.d.ts +9436 -0
  133. package/src/types/sync.ts +23 -0
  134. package/test/data/accounting_invoice.pdf +0 -0
  135. package/test/modules/accounting.test.ts +483 -0
  136. package/test/modules/consumer.test.ts +68 -0
  137. package/test/modules/consumers.test.ts +83 -0
  138. package/test/modules/ecommerce.test.ts +177 -0
  139. package/test/modules/integrations.test.ts +22 -0
  140. package/test/modules/invoicing.test.ts +88 -0
  141. package/test/modules/pos.test.ts +145 -0
  142. package/test/modules/sync.test.ts +60 -0
  143. package/test/modules/syncs.test.ts +23 -0
  144. package/test/modules/webhooks.test.ts +92 -0
  145. package/test/set_envs.sh +14 -0
  146. package/tsconfig.json +107 -0
@@ -0,0 +1,2588 @@
1
+ import { operations, components } from '../types/public-api/schema';
2
+ import { InternalAPI } from './internalApi';
3
+ import { chiftOperations } from '../types/public-api/mappings';
4
+ import { SimpleResponseModel } from '../types/sync';
5
+ import { ConsumerLog } from '../types/consumers';
6
+ declare const Consumer: (internalApi: InternalAPI, body: operations[chiftOperations['getConsumerById']]['responses'][200]['content']['application/json']) => {
7
+ consumerId: string;
8
+ getConnections: () => Promise<{
9
+ connectionid: string;
10
+ name: string;
11
+ integration: string;
12
+ integrationid: number;
13
+ api: string;
14
+ data?: Record<string, never> | undefined;
15
+ status: "active" | "inactive";
16
+ }[]>;
17
+ createConnection: (body?: components['schemas']['PostConnectionItem']) => Promise<{
18
+ url: string;
19
+ }>;
20
+ updateConnection: (connectionId: string, body?: components['schemas']['PatchConnectionItem']) => Promise<{
21
+ url: string;
22
+ }>;
23
+ deleteConnection: (connectionId: string) => Promise<{
24
+ content: never;
25
+ }>;
26
+ getSyncUrl: (body: components['schemas']['CreateConsumerSyncItem']) => Promise<{
27
+ url: string;
28
+ }>;
29
+ name: string;
30
+ redirect_url: string | undefined;
31
+ email: string | undefined;
32
+ pos: import("../types/api").ApiFor<{
33
+ getLocations(): import("../types/api").RequestData<{
34
+ id: string;
35
+ name: string;
36
+ timezone?: string | undefined;
37
+ address?: {
38
+ address_type?: string | undefined;
39
+ name?: string | undefined;
40
+ street?: string | undefined;
41
+ number?: string | undefined;
42
+ box?: string | undefined;
43
+ city?: string | undefined;
44
+ postal_code?: string | undefined;
45
+ country?: string | undefined;
46
+ } | undefined;
47
+ }[]>;
48
+ getOrders(params: {
49
+ date_from: string;
50
+ date_to: string;
51
+ location_id?: string | undefined;
52
+ state?: "open" | "closed" | "all" | undefined;
53
+ }): import("../types/api").RequestData<{
54
+ id: string;
55
+ order_number?: string | undefined;
56
+ creation_date: string;
57
+ closing_date?: string | undefined;
58
+ service_date?: string | undefined;
59
+ device_id?: string | undefined;
60
+ total: number;
61
+ tax_amount: number;
62
+ total_discount?: number | undefined;
63
+ total_refund?: number | undefined;
64
+ total_tip?: number | undefined;
65
+ items: {
66
+ id: string;
67
+ quantity: number;
68
+ unit_price: number;
69
+ total: number;
70
+ tax_amount: number;
71
+ tax_rate?: number | undefined;
72
+ description: string;
73
+ discounts?: {
74
+ name?: string | undefined;
75
+ total: number;
76
+ }[] | undefined;
77
+ }[];
78
+ payments: {
79
+ id?: string | undefined;
80
+ payment_method_id?: string | undefined;
81
+ payment_method_name?: string | undefined;
82
+ total: number;
83
+ tip?: number | undefined;
84
+ status?: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised" | undefined;
85
+ currency?: string | undefined;
86
+ date?: string | undefined;
87
+ }[];
88
+ currency?: string | undefined;
89
+ country?: string | undefined;
90
+ loyalty?: number | undefined;
91
+ customer_id?: string | undefined;
92
+ location_id?: string | undefined;
93
+ taxes?: {
94
+ tax_rate: number;
95
+ tax_amount: number;
96
+ total: number;
97
+ }[] | undefined;
98
+ }[]>;
99
+ getCustomers(params: {}): import("../types/api").RequestData<{
100
+ id: string;
101
+ first_name?: string | undefined;
102
+ last_name?: string | undefined;
103
+ name: string;
104
+ phone?: string | undefined;
105
+ email?: string | undefined;
106
+ created_on?: string | undefined;
107
+ addresses?: {
108
+ address_type?: string | undefined;
109
+ name?: string | undefined;
110
+ street?: string | undefined;
111
+ number?: string | undefined;
112
+ box?: string | undefined;
113
+ city?: string | undefined;
114
+ postal_code?: string | undefined;
115
+ country?: string | undefined;
116
+ }[] | undefined;
117
+ loyalty?: number | undefined;
118
+ }[]>;
119
+ getOrder(orderId: string): import("../types/api").RequestData<{
120
+ id: string;
121
+ order_number?: string | undefined;
122
+ creation_date: string;
123
+ closing_date?: string | undefined;
124
+ service_date?: string | undefined;
125
+ device_id?: string | undefined;
126
+ total: number;
127
+ tax_amount: number;
128
+ total_discount?: number | undefined;
129
+ total_refund?: number | undefined;
130
+ total_tip?: number | undefined;
131
+ items: {
132
+ id: string;
133
+ quantity: number;
134
+ unit_price: number;
135
+ total: number;
136
+ tax_amount: number;
137
+ tax_rate?: number | undefined;
138
+ description: string;
139
+ discounts?: {
140
+ name?: string | undefined;
141
+ total: number;
142
+ }[] | undefined;
143
+ }[];
144
+ payments: {
145
+ id?: string | undefined;
146
+ payment_method_id?: string | undefined;
147
+ payment_method_name?: string | undefined;
148
+ total: number;
149
+ tip?: number | undefined;
150
+ status?: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised" | undefined;
151
+ currency?: string | undefined;
152
+ date?: string | undefined;
153
+ }[];
154
+ currency?: string | undefined;
155
+ country?: string | undefined;
156
+ loyalty?: number | undefined;
157
+ customer_id?: string | undefined;
158
+ location_id?: string | undefined;
159
+ taxes?: {
160
+ tax_rate: number;
161
+ tax_amount: number;
162
+ total: number;
163
+ }[] | undefined;
164
+ }>;
165
+ getCustomer(customerId: string): import("../types/api").RequestData<{
166
+ id: string;
167
+ first_name?: string | undefined;
168
+ last_name?: string | undefined;
169
+ name: string;
170
+ phone?: string | undefined;
171
+ email?: string | undefined;
172
+ created_on?: string | undefined;
173
+ addresses?: {
174
+ address_type?: string | undefined;
175
+ name?: string | undefined;
176
+ street?: string | undefined;
177
+ number?: string | undefined;
178
+ box?: string | undefined;
179
+ city?: string | undefined;
180
+ postal_code?: string | undefined;
181
+ country?: string | undefined;
182
+ }[] | undefined;
183
+ loyalty?: number | undefined;
184
+ }>;
185
+ createCustomer(customer: {
186
+ first_name: string;
187
+ last_name: string;
188
+ phone?: string | undefined;
189
+ email?: string | undefined;
190
+ address?: {
191
+ name: string;
192
+ street?: string | undefined;
193
+ number?: string | undefined;
194
+ box?: string | undefined;
195
+ city: string;
196
+ postal_code: string;
197
+ country?: string | undefined;
198
+ } | undefined;
199
+ }): import("../types/api").RequestData<{
200
+ id: string;
201
+ first_name?: string | undefined;
202
+ last_name?: string | undefined;
203
+ name: string;
204
+ phone?: string | undefined;
205
+ email?: string | undefined;
206
+ created_on?: string | undefined;
207
+ addresses?: {
208
+ address_type?: string | undefined;
209
+ name?: string | undefined;
210
+ street?: string | undefined;
211
+ number?: string | undefined;
212
+ box?: string | undefined;
213
+ city?: string | undefined;
214
+ postal_code?: string | undefined;
215
+ country?: string | undefined;
216
+ }[] | undefined;
217
+ loyalty?: number | undefined;
218
+ }>;
219
+ getPaymentMethods(params: {}): import("../types/api").RequestData<{
220
+ id: string;
221
+ name: string;
222
+ extra?: string | undefined;
223
+ }[]>;
224
+ getSales(params: {
225
+ date_from: string;
226
+ date_to: string;
227
+ location_id?: string | undefined;
228
+ }): import("../types/api").RequestData<{
229
+ total: number;
230
+ tax_amount: number;
231
+ taxes?: {
232
+ tax_rate: number;
233
+ tax_amount: number;
234
+ total: number;
235
+ }[] | undefined;
236
+ }>;
237
+ getClosure(date: string, params: {
238
+ location_id?: string | undefined;
239
+ } | undefined): import("../types/api").RequestData<{
240
+ date: string;
241
+ status: "open" | "closed";
242
+ }>;
243
+ getPayments(params: {
244
+ date_from: string;
245
+ date_to: string;
246
+ }): import("../types/api").RequestData<{
247
+ id?: string | undefined;
248
+ payment_method_id?: string | undefined;
249
+ payment_method_name?: string | undefined;
250
+ total: number;
251
+ tip?: number | undefined;
252
+ status?: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised" | undefined;
253
+ currency?: string | undefined;
254
+ date?: string | undefined;
255
+ }[]>;
256
+ updateOrder(orderId: string, order: {
257
+ customer_id?: string | undefined;
258
+ }): import("../types/api").RequestData<{
259
+ id: string;
260
+ order_number?: string | undefined;
261
+ creation_date: string;
262
+ closing_date?: string | undefined;
263
+ service_date?: string | undefined;
264
+ device_id?: string | undefined;
265
+ total: number;
266
+ tax_amount: number;
267
+ total_discount?: number | undefined;
268
+ total_refund?: number | undefined;
269
+ total_tip?: number | undefined;
270
+ items: {
271
+ id: string;
272
+ quantity: number;
273
+ unit_price: number;
274
+ total: number;
275
+ tax_amount: number;
276
+ tax_rate?: number | undefined;
277
+ description: string;
278
+ discounts?: {
279
+ name?: string | undefined;
280
+ total: number;
281
+ }[] | undefined;
282
+ }[];
283
+ payments: {
284
+ id?: string | undefined;
285
+ payment_method_id?: string | undefined;
286
+ payment_method_name?: string | undefined;
287
+ total: number;
288
+ tip?: number | undefined;
289
+ status?: "Pending" | "Completed" | "Canceled" | "Failed" | "Unknown" | "Authorised" | undefined;
290
+ currency?: string | undefined;
291
+ date?: string | undefined;
292
+ }[];
293
+ currency?: string | undefined;
294
+ country?: string | undefined;
295
+ loyalty?: number | undefined;
296
+ customer_id?: string | undefined;
297
+ location_id?: string | undefined;
298
+ taxes?: {
299
+ tax_rate: number;
300
+ tax_amount: number;
301
+ total: number;
302
+ }[] | undefined;
303
+ }>;
304
+ }>;
305
+ accounting: import("../types/api").ApiFor<{
306
+ getAnalyticPlans(): import("../types/api").RequestData<{
307
+ id: string;
308
+ name: string;
309
+ active?: boolean | undefined;
310
+ }[]>;
311
+ getClients(): import("../types/api").RequestData<{
312
+ external_reference?: string | undefined;
313
+ first_name?: string | undefined;
314
+ last_name?: string | undefined;
315
+ name?: string | undefined;
316
+ function?: string | undefined;
317
+ is_company?: boolean | undefined;
318
+ company_id?: string | undefined;
319
+ phone?: string | undefined;
320
+ mobile?: string | undefined;
321
+ email?: string | undefined;
322
+ language?: string | undefined;
323
+ internal_notes?: string | undefined;
324
+ website?: string | undefined;
325
+ vat?: string | undefined;
326
+ iban?: string | undefined;
327
+ bank_account?: string | undefined;
328
+ currency?: string | undefined;
329
+ active?: boolean | undefined;
330
+ addresses?: {
331
+ address_type: "main" | "delivery" | "invoice";
332
+ name?: string | undefined;
333
+ number?: string | undefined;
334
+ box?: string | undefined;
335
+ phone?: string | undefined;
336
+ mobile?: string | undefined;
337
+ email?: string | undefined;
338
+ street?: string | undefined;
339
+ city?: string | undefined;
340
+ postal_code?: string | undefined;
341
+ country?: string | undefined;
342
+ }[] | undefined;
343
+ account_number?: string | undefined;
344
+ id?: string | undefined;
345
+ }[]>;
346
+ createClient(client: {
347
+ external_reference?: string | undefined;
348
+ first_name?: string | undefined;
349
+ last_name?: string | undefined;
350
+ name: string;
351
+ function?: string | undefined;
352
+ is_company?: boolean | undefined;
353
+ company_id?: string | undefined;
354
+ phone?: string | undefined;
355
+ mobile?: string | undefined;
356
+ email?: string | undefined;
357
+ language?: string | undefined;
358
+ internal_notes?: string | undefined;
359
+ website?: string | undefined;
360
+ vat?: string | undefined;
361
+ iban?: string | undefined;
362
+ bank_account?: string | undefined;
363
+ currency?: string | undefined;
364
+ active?: boolean | undefined;
365
+ addresses: {
366
+ address_type: "main" | "delivery" | "invoice";
367
+ name?: string | undefined;
368
+ number?: string | undefined;
369
+ box?: string | undefined;
370
+ phone?: string | undefined;
371
+ mobile?: string | undefined;
372
+ email?: string | undefined;
373
+ street: string;
374
+ city: string;
375
+ postal_code: string;
376
+ country: string;
377
+ }[];
378
+ account_number?: string | undefined;
379
+ }, params: {
380
+ force_merge?: string | undefined;
381
+ } | undefined): import("../types/api").RequestData<{
382
+ external_reference?: string | undefined;
383
+ first_name?: string | undefined;
384
+ last_name?: string | undefined;
385
+ name?: string | undefined;
386
+ function?: string | undefined;
387
+ is_company?: boolean | undefined;
388
+ company_id?: string | undefined;
389
+ phone?: string | undefined;
390
+ mobile?: string | undefined;
391
+ email?: string | undefined;
392
+ language?: string | undefined;
393
+ internal_notes?: string | undefined;
394
+ website?: string | undefined;
395
+ vat?: string | undefined;
396
+ iban?: string | undefined;
397
+ bank_account?: string | undefined;
398
+ currency?: string | undefined;
399
+ active?: boolean | undefined;
400
+ addresses?: {
401
+ address_type: "main" | "delivery" | "invoice";
402
+ name?: string | undefined;
403
+ number?: string | undefined;
404
+ box?: string | undefined;
405
+ phone?: string | undefined;
406
+ mobile?: string | undefined;
407
+ email?: string | undefined;
408
+ street?: string | undefined;
409
+ city?: string | undefined;
410
+ postal_code?: string | undefined;
411
+ country?: string | undefined;
412
+ }[] | undefined;
413
+ account_number?: string | undefined;
414
+ id?: string | undefined;
415
+ }>;
416
+ getClient(clientId: string): import("../types/api").RequestData<{
417
+ external_reference?: string | undefined;
418
+ first_name?: string | undefined;
419
+ last_name?: string | undefined;
420
+ name?: string | undefined;
421
+ function?: string | undefined;
422
+ is_company?: boolean | undefined;
423
+ company_id?: string | undefined;
424
+ phone?: string | undefined;
425
+ mobile?: string | undefined;
426
+ email?: string | undefined;
427
+ language?: string | undefined;
428
+ internal_notes?: string | undefined;
429
+ website?: string | undefined;
430
+ vat?: string | undefined;
431
+ iban?: string | undefined;
432
+ bank_account?: string | undefined;
433
+ currency?: string | undefined;
434
+ active?: boolean | undefined;
435
+ addresses?: {
436
+ address_type: "main" | "delivery" | "invoice";
437
+ name?: string | undefined;
438
+ number?: string | undefined;
439
+ box?: string | undefined;
440
+ phone?: string | undefined;
441
+ mobile?: string | undefined;
442
+ email?: string | undefined;
443
+ street?: string | undefined;
444
+ city?: string | undefined;
445
+ postal_code?: string | undefined;
446
+ country?: string | undefined;
447
+ }[] | undefined;
448
+ account_number?: string | undefined;
449
+ id?: string | undefined;
450
+ }>;
451
+ updateClient(clientId: string, client: {
452
+ external_reference?: string | undefined;
453
+ first_name?: string | undefined;
454
+ last_name?: string | undefined;
455
+ name?: string | undefined;
456
+ function?: string | undefined;
457
+ is_company?: boolean | undefined;
458
+ company_id?: string | undefined;
459
+ phone?: string | undefined;
460
+ mobile?: string | undefined;
461
+ email?: string | undefined;
462
+ language?: string | undefined;
463
+ internal_notes?: string | undefined;
464
+ website?: string | undefined;
465
+ vat?: string | undefined;
466
+ iban?: string | undefined;
467
+ bank_account?: string | undefined;
468
+ currency?: string | undefined;
469
+ active?: boolean | undefined;
470
+ addresses?: {
471
+ address_type: "main" | "delivery" | "invoice";
472
+ name?: string | undefined;
473
+ number?: string | undefined;
474
+ box?: string | undefined;
475
+ phone?: string | undefined;
476
+ mobile?: string | undefined;
477
+ email?: string | undefined;
478
+ street?: string | undefined;
479
+ city?: string | undefined;
480
+ postal_code?: string | undefined;
481
+ country?: string | undefined;
482
+ }[] | undefined;
483
+ }): import("../types/api").RequestData<{
484
+ external_reference?: string | undefined;
485
+ first_name?: string | undefined;
486
+ last_name?: string | undefined;
487
+ name?: string | undefined;
488
+ function?: string | undefined;
489
+ is_company?: boolean | undefined;
490
+ company_id?: string | undefined;
491
+ phone?: string | undefined;
492
+ mobile?: string | undefined;
493
+ email?: string | undefined;
494
+ language?: string | undefined;
495
+ internal_notes?: string | undefined;
496
+ website?: string | undefined;
497
+ vat?: string | undefined;
498
+ iban?: string | undefined;
499
+ bank_account?: string | undefined;
500
+ currency?: string | undefined;
501
+ active?: boolean | undefined;
502
+ addresses?: {
503
+ address_type: "main" | "delivery" | "invoice";
504
+ name?: string | undefined;
505
+ number?: string | undefined;
506
+ box?: string | undefined;
507
+ phone?: string | undefined;
508
+ mobile?: string | undefined;
509
+ email?: string | undefined;
510
+ street?: string | undefined;
511
+ city?: string | undefined;
512
+ postal_code?: string | undefined;
513
+ country?: string | undefined;
514
+ }[] | undefined;
515
+ account_number?: string | undefined;
516
+ id?: string | undefined;
517
+ }>;
518
+ getSuppliers(): import("../types/api").RequestData<{
519
+ external_reference?: string | undefined;
520
+ first_name?: string | undefined;
521
+ last_name?: string | undefined;
522
+ name?: string | undefined;
523
+ function?: string | undefined;
524
+ is_company?: boolean | undefined;
525
+ company_id?: string | undefined;
526
+ phone?: string | undefined;
527
+ mobile?: string | undefined;
528
+ email?: string | undefined;
529
+ language?: string | undefined;
530
+ internal_notes?: string | undefined;
531
+ website?: string | undefined;
532
+ vat?: string | undefined;
533
+ iban?: string | undefined;
534
+ bank_account?: string | undefined;
535
+ currency?: string | undefined;
536
+ active?: boolean | undefined;
537
+ addresses?: {
538
+ address_type: "main" | "delivery" | "invoice";
539
+ name?: string | undefined;
540
+ number?: string | undefined;
541
+ box?: string | undefined;
542
+ phone?: string | undefined;
543
+ mobile?: string | undefined;
544
+ email?: string | undefined;
545
+ street?: string | undefined;
546
+ city?: string | undefined;
547
+ postal_code?: string | undefined;
548
+ country?: string | undefined;
549
+ }[] | undefined;
550
+ account_number?: string | undefined;
551
+ id?: string | undefined;
552
+ }[]>;
553
+ createSupplier(supplier: {
554
+ external_reference?: string | undefined;
555
+ first_name?: string | undefined;
556
+ last_name?: string | undefined;
557
+ name: string;
558
+ function?: string | undefined;
559
+ is_company?: boolean | undefined;
560
+ company_id?: string | undefined;
561
+ phone?: string | undefined;
562
+ mobile?: string | undefined;
563
+ email?: string | undefined;
564
+ language?: string | undefined;
565
+ internal_notes?: string | undefined;
566
+ website?: string | undefined;
567
+ vat?: string | undefined;
568
+ iban?: string | undefined;
569
+ bank_account?: string | undefined;
570
+ currency?: string | undefined;
571
+ active?: boolean | undefined;
572
+ addresses: {
573
+ address_type: "main" | "delivery" | "invoice";
574
+ name?: string | undefined;
575
+ number?: string | undefined;
576
+ box?: string | undefined;
577
+ phone?: string | undefined;
578
+ mobile?: string | undefined;
579
+ email?: string | undefined;
580
+ street: string;
581
+ city: string;
582
+ postal_code: string;
583
+ country: string;
584
+ }[];
585
+ account_number?: string | undefined;
586
+ }, params: {
587
+ force_merge?: string | undefined;
588
+ } | undefined): import("../types/api").RequestData<{
589
+ external_reference?: string | undefined;
590
+ first_name?: string | undefined;
591
+ last_name?: string | undefined;
592
+ name?: string | undefined;
593
+ function?: string | undefined;
594
+ is_company?: boolean | undefined;
595
+ company_id?: string | undefined;
596
+ phone?: string | undefined;
597
+ mobile?: string | undefined;
598
+ email?: string | undefined;
599
+ language?: string | undefined;
600
+ internal_notes?: string | undefined;
601
+ website?: string | undefined;
602
+ vat?: string | undefined;
603
+ iban?: string | undefined;
604
+ bank_account?: string | undefined;
605
+ currency?: string | undefined;
606
+ active?: boolean | undefined;
607
+ addresses?: {
608
+ address_type: "main" | "delivery" | "invoice";
609
+ name?: string | undefined;
610
+ number?: string | undefined;
611
+ box?: string | undefined;
612
+ phone?: string | undefined;
613
+ mobile?: string | undefined;
614
+ email?: string | undefined;
615
+ street?: string | undefined;
616
+ city?: string | undefined;
617
+ postal_code?: string | undefined;
618
+ country?: string | undefined;
619
+ }[] | undefined;
620
+ account_number?: string | undefined;
621
+ id?: string | undefined;
622
+ }>;
623
+ getSupplier(supplierId: string): import("../types/api").RequestData<{
624
+ external_reference?: string | undefined;
625
+ first_name?: string | undefined;
626
+ last_name?: string | undefined;
627
+ name?: string | undefined;
628
+ function?: string | undefined;
629
+ is_company?: boolean | undefined;
630
+ company_id?: string | undefined;
631
+ phone?: string | undefined;
632
+ mobile?: string | undefined;
633
+ email?: string | undefined;
634
+ language?: string | undefined;
635
+ internal_notes?: string | undefined;
636
+ website?: string | undefined;
637
+ vat?: string | undefined;
638
+ iban?: string | undefined;
639
+ bank_account?: string | undefined;
640
+ currency?: string | undefined;
641
+ active?: boolean | undefined;
642
+ addresses?: {
643
+ address_type: "main" | "delivery" | "invoice";
644
+ name?: string | undefined;
645
+ number?: string | undefined;
646
+ box?: string | undefined;
647
+ phone?: string | undefined;
648
+ mobile?: string | undefined;
649
+ email?: string | undefined;
650
+ street?: string | undefined;
651
+ city?: string | undefined;
652
+ postal_code?: string | undefined;
653
+ country?: string | undefined;
654
+ }[] | undefined;
655
+ account_number?: string | undefined;
656
+ id?: string | undefined;
657
+ }>;
658
+ updateSupplier(supplierId: string, supplier: {
659
+ external_reference?: string | undefined;
660
+ first_name?: string | undefined;
661
+ last_name?: string | undefined;
662
+ name?: string | undefined;
663
+ function?: string | undefined;
664
+ is_company?: boolean | undefined;
665
+ company_id?: string | undefined;
666
+ phone?: string | undefined;
667
+ mobile?: string | undefined;
668
+ email?: string | undefined;
669
+ language?: string | undefined;
670
+ internal_notes?: string | undefined;
671
+ website?: string | undefined;
672
+ vat?: string | undefined;
673
+ iban?: string | undefined;
674
+ bank_account?: string | undefined;
675
+ currency?: string | undefined;
676
+ active?: boolean | undefined;
677
+ addresses?: {
678
+ address_type: "main" | "delivery" | "invoice";
679
+ name?: string | undefined;
680
+ number?: string | undefined;
681
+ box?: string | undefined;
682
+ phone?: string | undefined;
683
+ mobile?: string | undefined;
684
+ email?: string | undefined;
685
+ street?: string | undefined;
686
+ city?: string | undefined;
687
+ postal_code?: string | undefined;
688
+ country?: string | undefined;
689
+ }[] | undefined;
690
+ }): import("../types/api").RequestData<{
691
+ external_reference?: string | undefined;
692
+ first_name?: string | undefined;
693
+ last_name?: string | undefined;
694
+ name?: string | undefined;
695
+ function?: string | undefined;
696
+ is_company?: boolean | undefined;
697
+ company_id?: string | undefined;
698
+ phone?: string | undefined;
699
+ mobile?: string | undefined;
700
+ email?: string | undefined;
701
+ language?: string | undefined;
702
+ internal_notes?: string | undefined;
703
+ website?: string | undefined;
704
+ vat?: string | undefined;
705
+ iban?: string | undefined;
706
+ bank_account?: string | undefined;
707
+ currency?: string | undefined;
708
+ active?: boolean | undefined;
709
+ addresses?: {
710
+ address_type: "main" | "delivery" | "invoice";
711
+ name?: string | undefined;
712
+ number?: string | undefined;
713
+ box?: string | undefined;
714
+ phone?: string | undefined;
715
+ mobile?: string | undefined;
716
+ email?: string | undefined;
717
+ street?: string | undefined;
718
+ city?: string | undefined;
719
+ postal_code?: string | undefined;
720
+ country?: string | undefined;
721
+ }[] | undefined;
722
+ account_number?: string | undefined;
723
+ id?: string | undefined;
724
+ }>;
725
+ createInvoice(invoice: {
726
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
727
+ invoice_number?: string | undefined;
728
+ invoice_date: string;
729
+ due_date: string;
730
+ currency: string;
731
+ untaxed_amount: number;
732
+ tax_amount: number;
733
+ total: number;
734
+ reference?: string | undefined;
735
+ payment_communication?: string | undefined;
736
+ customer_memo?: string | undefined;
737
+ partner_id: string;
738
+ journal_id?: string | undefined;
739
+ status?: "draft" | "posted" | undefined;
740
+ pdf?: string | undefined;
741
+ currency_exchange_rate?: number | undefined;
742
+ invoice_correction?: {
743
+ sale_invoice_correction_tax_code?: string | undefined;
744
+ purchase_invoice_correction_tax_code?: string | undefined;
745
+ invoice_correction_credit_account_number?: string | undefined;
746
+ invoice_correction_debit_account_number?: string | undefined;
747
+ } | undefined;
748
+ lines: {
749
+ line_number?: number | undefined;
750
+ description: string;
751
+ unit_price: number;
752
+ unit_of_measure?: string | undefined;
753
+ quantity: number;
754
+ untaxed_amount: number;
755
+ tax_rate: number;
756
+ tax_amount: number;
757
+ total: number;
758
+ account_number: string;
759
+ tax_code: string;
760
+ analytic_account?: string | undefined;
761
+ }[];
762
+ }, params: {
763
+ force_financial_period?: string | undefined;
764
+ regroup_lines?: "true" | "false" | undefined;
765
+ } | undefined): import("../types/api").RequestData<{
766
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
767
+ invoice_number?: string | undefined;
768
+ invoice_date: string;
769
+ due_date: string;
770
+ currency: string;
771
+ untaxed_amount: number;
772
+ tax_amount: number;
773
+ total: number;
774
+ reference?: string | undefined;
775
+ payment_communication?: string | undefined;
776
+ customer_memo?: string | undefined;
777
+ id?: string | undefined;
778
+ partner_id: string;
779
+ journal_id: string;
780
+ payments?: {
781
+ id: string;
782
+ name: string;
783
+ currency: string;
784
+ amount: number;
785
+ dedicated_amount?: number | undefined;
786
+ payment_date: string;
787
+ journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation";
788
+ journal_id: string;
789
+ journal_name: string;
790
+ reconciled?: boolean | undefined;
791
+ communication?: string | undefined;
792
+ matching_number?: string | undefined;
793
+ }[] | undefined;
794
+ status?: "draft" | "posted" | "cancelled" | "paid" | undefined;
795
+ lines: {
796
+ line_number?: number | undefined;
797
+ description: string;
798
+ unit_price: number;
799
+ unit_of_measure?: string | undefined;
800
+ quantity: number;
801
+ untaxed_amount: number;
802
+ tax_rate: number;
803
+ tax_amount: number;
804
+ total: number;
805
+ account_number: string;
806
+ tax_code?: string | undefined;
807
+ analytic_account?: string | undefined;
808
+ }[];
809
+ }>;
810
+ createInvoiceWithMultiplePlans(invoice: {
811
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
812
+ invoice_number?: string | undefined;
813
+ invoice_date: string;
814
+ due_date: string;
815
+ currency: string;
816
+ untaxed_amount: number;
817
+ tax_amount: number;
818
+ total: number;
819
+ reference?: string | undefined;
820
+ payment_communication?: string | undefined;
821
+ customer_memo?: string | undefined;
822
+ partner_id: string;
823
+ journal_id?: string | undefined;
824
+ status?: "draft" | "posted" | undefined;
825
+ pdf?: string | undefined;
826
+ currency_exchange_rate?: number | undefined;
827
+ invoice_correction?: {
828
+ sale_invoice_correction_tax_code?: string | undefined;
829
+ purchase_invoice_correction_tax_code?: string | undefined;
830
+ invoice_correction_credit_account_number?: string | undefined;
831
+ invoice_correction_debit_account_number?: string | undefined;
832
+ } | undefined;
833
+ lines: {
834
+ line_number?: number | undefined;
835
+ description: string;
836
+ unit_price: number;
837
+ unit_of_measure?: string | undefined;
838
+ quantity: number;
839
+ untaxed_amount: number;
840
+ tax_rate: number;
841
+ tax_amount: number;
842
+ total: number;
843
+ account_number: string;
844
+ tax_code: string;
845
+ analytic_distribution?: {
846
+ analytic_plan: string;
847
+ analytic_accounts: {
848
+ analytic_account: string;
849
+ percentage: number;
850
+ }[];
851
+ }[] | undefined;
852
+ }[];
853
+ }, params: {
854
+ force_financial_period?: string | undefined;
855
+ regroup_lines?: "true" | "false" | undefined;
856
+ } | undefined): import("../types/api").RequestData<{
857
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
858
+ invoice_number?: string | undefined;
859
+ invoice_date: string;
860
+ due_date: string;
861
+ currency: string;
862
+ untaxed_amount: number;
863
+ tax_amount: number;
864
+ total: number;
865
+ reference?: string | undefined;
866
+ payment_communication?: string | undefined;
867
+ customer_memo?: string | undefined;
868
+ id?: string | undefined;
869
+ partner_id: string;
870
+ journal_id: string;
871
+ payments?: {
872
+ id: string;
873
+ name: string;
874
+ currency: string;
875
+ amount: number;
876
+ dedicated_amount?: number | undefined;
877
+ payment_date: string;
878
+ journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation";
879
+ journal_id: string;
880
+ journal_name: string;
881
+ reconciled?: boolean | undefined;
882
+ communication?: string | undefined;
883
+ matching_number?: string | undefined;
884
+ }[] | undefined;
885
+ status?: "draft" | "posted" | "cancelled" | "paid" | undefined;
886
+ lines: {
887
+ line_number?: number | undefined;
888
+ description: string;
889
+ unit_price: number;
890
+ unit_of_measure?: string | undefined;
891
+ quantity: number;
892
+ untaxed_amount: number;
893
+ tax_rate: number;
894
+ tax_amount: number;
895
+ total: number;
896
+ account_number: string;
897
+ tax_code?: string | undefined;
898
+ analytic_distribution?: {
899
+ analytic_plan: string;
900
+ analytic_accounts: {
901
+ analytic_account: string;
902
+ percentage: number;
903
+ }[];
904
+ }[] | undefined;
905
+ }[];
906
+ }>;
907
+ getInvoicesByType(invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund", params: {}): import("../types/api").RequestData<{
908
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
909
+ invoice_number?: string | undefined;
910
+ invoice_date: string;
911
+ due_date: string;
912
+ currency: string;
913
+ untaxed_amount: number;
914
+ tax_amount: number;
915
+ total: number;
916
+ reference?: string | undefined;
917
+ payment_communication?: string | undefined;
918
+ customer_memo?: string | undefined;
919
+ id?: string | undefined;
920
+ partner_id: string;
921
+ journal_id: string;
922
+ payments?: {
923
+ id: string;
924
+ name: string;
925
+ currency: string;
926
+ amount: number;
927
+ dedicated_amount?: number | undefined;
928
+ payment_date: string;
929
+ journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation";
930
+ journal_id: string;
931
+ journal_name: string;
932
+ reconciled?: boolean | undefined;
933
+ communication?: string | undefined;
934
+ matching_number?: string | undefined;
935
+ }[] | undefined;
936
+ status?: "draft" | "posted" | "cancelled" | "paid" | undefined;
937
+ lines: {
938
+ line_number?: number | undefined;
939
+ description: string;
940
+ unit_price: number;
941
+ unit_of_measure?: string | undefined;
942
+ quantity: number;
943
+ untaxed_amount: number;
944
+ tax_rate: number;
945
+ tax_amount: number;
946
+ total: number;
947
+ account_number: string;
948
+ tax_code?: string | undefined;
949
+ analytic_account?: string | undefined;
950
+ }[];
951
+ }[]>;
952
+ getInvoice(invoiceId: string, params: {
953
+ include_payments?: "true" | "false" | undefined;
954
+ } | undefined): import("../types/api").RequestData<{
955
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
956
+ invoice_number?: string | undefined;
957
+ invoice_date: string;
958
+ due_date: string;
959
+ currency: string;
960
+ untaxed_amount: number;
961
+ tax_amount: number;
962
+ total: number;
963
+ reference?: string | undefined;
964
+ payment_communication?: string | undefined;
965
+ customer_memo?: string | undefined;
966
+ id?: string | undefined;
967
+ partner_id: string;
968
+ journal_id: string;
969
+ payments?: {
970
+ id: string;
971
+ name: string;
972
+ currency: string;
973
+ amount: number;
974
+ dedicated_amount?: number | undefined;
975
+ payment_date: string;
976
+ journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation";
977
+ journal_id: string;
978
+ journal_name: string;
979
+ reconciled?: boolean | undefined;
980
+ communication?: string | undefined;
981
+ matching_number?: string | undefined;
982
+ }[] | undefined;
983
+ status?: "draft" | "posted" | "cancelled" | "paid" | undefined;
984
+ lines: {
985
+ line_number?: number | undefined;
986
+ description: string;
987
+ unit_price: number;
988
+ unit_of_measure?: string | undefined;
989
+ quantity: number;
990
+ untaxed_amount: number;
991
+ tax_rate: number;
992
+ tax_amount: number;
993
+ total: number;
994
+ account_number: string;
995
+ tax_code?: string | undefined;
996
+ analytic_account?: string | undefined;
997
+ }[];
998
+ }>;
999
+ getInvoiceWithMultiplePlans(invoiceId: string, params: {
1000
+ include_payments?: "true" | "false" | undefined;
1001
+ } | undefined): import("../types/api").RequestData<{
1002
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
1003
+ invoice_number?: string | undefined;
1004
+ invoice_date: string;
1005
+ due_date: string;
1006
+ currency: string;
1007
+ untaxed_amount: number;
1008
+ tax_amount: number;
1009
+ total: number;
1010
+ reference?: string | undefined;
1011
+ payment_communication?: string | undefined;
1012
+ customer_memo?: string | undefined;
1013
+ id?: string | undefined;
1014
+ partner_id: string;
1015
+ journal_id: string;
1016
+ payments?: {
1017
+ id: string;
1018
+ name: string;
1019
+ currency: string;
1020
+ amount: number;
1021
+ dedicated_amount?: number | undefined;
1022
+ payment_date: string;
1023
+ journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation";
1024
+ journal_id: string;
1025
+ journal_name: string;
1026
+ reconciled?: boolean | undefined;
1027
+ communication?: string | undefined;
1028
+ matching_number?: string | undefined;
1029
+ }[] | undefined;
1030
+ status?: "draft" | "posted" | "cancelled" | "paid" | undefined;
1031
+ lines: {
1032
+ line_number?: number | undefined;
1033
+ description: string;
1034
+ unit_price: number;
1035
+ unit_of_measure?: string | undefined;
1036
+ quantity: number;
1037
+ untaxed_amount: number;
1038
+ tax_rate: number;
1039
+ tax_amount: number;
1040
+ total: number;
1041
+ account_number: string;
1042
+ tax_code?: string | undefined;
1043
+ analytic_distribution?: {
1044
+ analytic_plan: string;
1045
+ analytic_accounts: {
1046
+ analytic_account: string;
1047
+ percentage: number;
1048
+ }[];
1049
+ }[] | undefined;
1050
+ }[];
1051
+ }>;
1052
+ getInvoicesByTypeWithMultiplePlans(invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund", params: {}): import("../types/api").RequestData<{
1053
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
1054
+ invoice_number?: string | undefined;
1055
+ invoice_date: string;
1056
+ due_date: string;
1057
+ currency: string;
1058
+ untaxed_amount: number;
1059
+ tax_amount: number;
1060
+ total: number;
1061
+ reference?: string | undefined;
1062
+ payment_communication?: string | undefined;
1063
+ customer_memo?: string | undefined;
1064
+ id?: string | undefined;
1065
+ partner_id: string;
1066
+ journal_id: string;
1067
+ payments?: {
1068
+ id: string;
1069
+ name: string;
1070
+ currency: string;
1071
+ amount: number;
1072
+ dedicated_amount?: number | undefined;
1073
+ payment_date: string;
1074
+ journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation";
1075
+ journal_id: string;
1076
+ journal_name: string;
1077
+ reconciled?: boolean | undefined;
1078
+ communication?: string | undefined;
1079
+ matching_number?: string | undefined;
1080
+ }[] | undefined;
1081
+ status?: "draft" | "posted" | "cancelled" | "paid" | undefined;
1082
+ lines: {
1083
+ line_number?: number | undefined;
1084
+ description: string;
1085
+ unit_price: number;
1086
+ unit_of_measure?: string | undefined;
1087
+ quantity: number;
1088
+ untaxed_amount: number;
1089
+ tax_rate: number;
1090
+ tax_amount: number;
1091
+ total: number;
1092
+ account_number: string;
1093
+ tax_code?: string | undefined;
1094
+ analytic_distribution?: {
1095
+ analytic_plan: string;
1096
+ analytic_accounts: {
1097
+ analytic_account: string;
1098
+ percentage: number;
1099
+ }[];
1100
+ }[] | undefined;
1101
+ }[];
1102
+ }[]>;
1103
+ createAnalyticAccount(analyticAccount: {
1104
+ active?: boolean | undefined;
1105
+ code: string;
1106
+ name: string;
1107
+ currency: string;
1108
+ }): import("../types/api").RequestData<{
1109
+ active?: boolean | undefined;
1110
+ code?: string | undefined;
1111
+ name?: string | undefined;
1112
+ currency?: string | undefined;
1113
+ id?: string | undefined;
1114
+ balance?: number | undefined;
1115
+ credit?: number | undefined;
1116
+ debit?: number | undefined;
1117
+ }>;
1118
+ getAnalyticAccounts(): import("../types/api").RequestData<{
1119
+ active?: boolean | undefined;
1120
+ code?: string | undefined;
1121
+ name?: string | undefined;
1122
+ currency?: string | undefined;
1123
+ id?: string | undefined;
1124
+ balance?: number | undefined;
1125
+ credit?: number | undefined;
1126
+ debit?: number | undefined;
1127
+ }[]>;
1128
+ createAnalyticAccountWithMultiplePlans(analytic_plan: string, analyticAccount: {
1129
+ active?: boolean | undefined;
1130
+ code: string;
1131
+ name: string;
1132
+ currency: string;
1133
+ }): import("../types/api").RequestData<{
1134
+ active?: boolean | undefined;
1135
+ code?: string | undefined;
1136
+ name?: string | undefined;
1137
+ currency?: string | undefined;
1138
+ id?: string | undefined;
1139
+ balance?: number | undefined;
1140
+ credit?: number | undefined;
1141
+ debit?: number | undefined;
1142
+ analytic_plan: string;
1143
+ }>;
1144
+ getAnalyticAccount(analytic_account_id: string): import("../types/api").RequestData<{
1145
+ active?: boolean | undefined;
1146
+ code?: string | undefined;
1147
+ name?: string | undefined;
1148
+ currency?: string | undefined;
1149
+ id?: string | undefined;
1150
+ balance?: number | undefined;
1151
+ credit?: number | undefined;
1152
+ debit?: number | undefined;
1153
+ }>;
1154
+ updateAnalyticAccount(analytic_account_id: string, analyticAccount: {
1155
+ active?: boolean | undefined;
1156
+ code?: string | undefined;
1157
+ name?: string | undefined;
1158
+ currency?: string | undefined;
1159
+ }): import("../types/api").RequestData<{
1160
+ active?: boolean | undefined;
1161
+ code?: string | undefined;
1162
+ name?: string | undefined;
1163
+ currency?: string | undefined;
1164
+ id?: string | undefined;
1165
+ balance?: number | undefined;
1166
+ credit?: number | undefined;
1167
+ debit?: number | undefined;
1168
+ }>;
1169
+ getAnalyticAccountWithMultiplePlans(analytic_account_id: string, analytic_plan: string): import("../types/api").RequestData<{
1170
+ active?: boolean | undefined;
1171
+ code?: string | undefined;
1172
+ name?: string | undefined;
1173
+ currency?: string | undefined;
1174
+ id?: string | undefined;
1175
+ balance?: number | undefined;
1176
+ credit?: number | undefined;
1177
+ debit?: number | undefined;
1178
+ analytic_plan: string;
1179
+ }>;
1180
+ updateAnalyticAccountWithMultiplePlans(analytic_account_id: string, analytic_plan: string, analyticAccount: {
1181
+ active?: boolean | undefined;
1182
+ code?: string | undefined;
1183
+ name?: string | undefined;
1184
+ currency?: string | undefined;
1185
+ }): import("../types/api").RequestData<{
1186
+ active?: boolean | undefined;
1187
+ code?: string | undefined;
1188
+ name?: string | undefined;
1189
+ currency?: string | undefined;
1190
+ id?: string | undefined;
1191
+ balance?: number | undefined;
1192
+ credit?: number | undefined;
1193
+ debit?: number | undefined;
1194
+ analytic_plan: string;
1195
+ }>;
1196
+ getAnalyticAccountsWithMultiplePlans(): import("../types/api").RequestData<{
1197
+ active?: boolean | undefined;
1198
+ code?: string | undefined;
1199
+ name?: string | undefined;
1200
+ currency?: string | undefined;
1201
+ id?: string | undefined;
1202
+ balance?: number | undefined;
1203
+ credit?: number | undefined;
1204
+ debit?: number | undefined;
1205
+ analytic_plan: string;
1206
+ }[]>;
1207
+ getAnalyticLinesOfAccount(analytic_account_id: string): import("../types/api").RequestData<{
1208
+ account_id: string;
1209
+ description: string;
1210
+ amount: number;
1211
+ date: string;
1212
+ id?: string | undefined;
1213
+ }[]>;
1214
+ getJournalEntries(params: {
1215
+ date_from: string;
1216
+ date_to: string;
1217
+ unposted_allowed: "true" | "false";
1218
+ journal_id: string;
1219
+ partner_id?: string | undefined;
1220
+ }): import("../types/api").RequestData<{
1221
+ reference?: string | undefined;
1222
+ due_date?: string | undefined;
1223
+ journal_id: string;
1224
+ name?: string | undefined;
1225
+ journal_name: string;
1226
+ date?: string | undefined;
1227
+ posted?: boolean | undefined;
1228
+ id: string;
1229
+ items?: {
1230
+ account_number: string;
1231
+ partner_id?: string | undefined;
1232
+ description?: string | undefined;
1233
+ debit: number;
1234
+ credit: number;
1235
+ currency: string;
1236
+ currency_exchange_rate?: number | undefined;
1237
+ id: string;
1238
+ partner_name?: string | undefined;
1239
+ account_name: string;
1240
+ matching_numbers?: string[] | undefined;
1241
+ analytic_account?: string | undefined;
1242
+ analytic_account_name?: string | undefined;
1243
+ }[] | undefined;
1244
+ }[]>;
1245
+ getJournalEntriesWithMultiplePlans(params: {
1246
+ date_from: string;
1247
+ date_to: string;
1248
+ unposted_allowed: "true" | "false";
1249
+ journal_id: string;
1250
+ partner_id?: string | undefined;
1251
+ }): import("../types/api").RequestData<{
1252
+ reference?: string | undefined;
1253
+ due_date?: string | undefined;
1254
+ journal_id: string;
1255
+ name?: string | undefined;
1256
+ journal_name: string;
1257
+ date?: string | undefined;
1258
+ posted?: boolean | undefined;
1259
+ id: string;
1260
+ items?: {
1261
+ account_number: string;
1262
+ partner_id?: string | undefined;
1263
+ description?: string | undefined;
1264
+ debit: number;
1265
+ credit: number;
1266
+ currency: string;
1267
+ currency_exchange_rate?: number | undefined;
1268
+ id: string;
1269
+ partner_name?: string | undefined;
1270
+ account_name: string;
1271
+ matching_numbers?: string[] | undefined;
1272
+ analytic_distribution?: {
1273
+ analytic_plan: string;
1274
+ analytic_accounts: {
1275
+ analytic_account: string;
1276
+ percentage: number;
1277
+ }[];
1278
+ }[] | undefined;
1279
+ }[] | undefined;
1280
+ }[]>;
1281
+ getPaymentsByInvoiceId(invoice_id: string): import("../types/api").RequestData<{
1282
+ id: string;
1283
+ name: string;
1284
+ currency: string;
1285
+ amount: number;
1286
+ dedicated_amount?: number | undefined;
1287
+ payment_date: string;
1288
+ journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation";
1289
+ journal_id: string;
1290
+ journal_name: string;
1291
+ reconciled?: boolean | undefined;
1292
+ communication?: string | undefined;
1293
+ matching_number?: string | undefined;
1294
+ }[]>;
1295
+ getJournals(): import("../types/api").RequestData<{
1296
+ id: string;
1297
+ code: string;
1298
+ name: string;
1299
+ journal_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "financial_operation" | "miscellaneous_operation";
1300
+ }[]>;
1301
+ getVatCodes(): import("../types/api").RequestData<{
1302
+ id: string;
1303
+ code?: string | undefined;
1304
+ label: string;
1305
+ scope?: "nat" | "eu" | "int" | "unknown" | undefined;
1306
+ rate: number;
1307
+ type: "unknown" | "sale" | "purchase" | "both";
1308
+ }[]>;
1309
+ getMiscOperations(params: {}): import("../types/api").RequestData<{
1310
+ operation_number?: string | undefined;
1311
+ operation_date: string;
1312
+ currency: string;
1313
+ currency_exchange_rate?: number | undefined;
1314
+ lines: {
1315
+ line_number?: number | undefined;
1316
+ description?: string | undefined;
1317
+ amount: number;
1318
+ type: "general_account" | "customer_account" | "supplier_account";
1319
+ account_number: string;
1320
+ partner_id?: string | undefined;
1321
+ analytic_account?: string | undefined;
1322
+ }[];
1323
+ journal_id: string;
1324
+ status: "draft" | "posted" | "cancelled" | "matched";
1325
+ id: string;
1326
+ }[]>;
1327
+ createMiscOperation(operation: {
1328
+ operation_number?: string | undefined;
1329
+ operation_date: string;
1330
+ currency: string;
1331
+ currency_exchange_rate?: number | undefined;
1332
+ lines: {
1333
+ line_number?: number | undefined;
1334
+ description?: string | undefined;
1335
+ amount: number;
1336
+ type: "general_account" | "customer_account" | "supplier_account";
1337
+ account_number: string;
1338
+ partner_id?: string | undefined;
1339
+ analytic_account?: string | undefined;
1340
+ }[];
1341
+ journal_id?: string | undefined;
1342
+ status?: "draft" | "posted" | undefined;
1343
+ }): import("../types/api").RequestData<{
1344
+ operation_number?: string | undefined;
1345
+ operation_date: string;
1346
+ currency: string;
1347
+ currency_exchange_rate?: number | undefined;
1348
+ lines: {
1349
+ line_number?: number | undefined;
1350
+ description?: string | undefined;
1351
+ amount: number;
1352
+ type: "general_account" | "customer_account" | "supplier_account";
1353
+ account_number: string;
1354
+ partner_id?: string | undefined;
1355
+ analytic_account?: string | undefined;
1356
+ }[];
1357
+ journal_id: string;
1358
+ status: "draft" | "posted" | "cancelled" | "matched";
1359
+ id: string;
1360
+ }>;
1361
+ getMiscOperation(operation_id: string): import("../types/api").RequestData<{
1362
+ operation_number?: string | undefined;
1363
+ operation_date: string;
1364
+ currency: string;
1365
+ currency_exchange_rate?: number | undefined;
1366
+ lines: {
1367
+ line_number?: number | undefined;
1368
+ description?: string | undefined;
1369
+ amount: number;
1370
+ type: "general_account" | "customer_account" | "supplier_account";
1371
+ account_number: string;
1372
+ partner_id?: string | undefined;
1373
+ analytic_account?: string | undefined;
1374
+ }[];
1375
+ journal_id: string;
1376
+ status: "draft" | "posted" | "cancelled" | "matched";
1377
+ id: string;
1378
+ }>;
1379
+ attachPDF(invoice_id: string, attachment: {
1380
+ base64_string: string;
1381
+ }, params: {
1382
+ overwrite_existing?: "true" | "false" | undefined;
1383
+ } | undefined): import("../types/api").RequestData<{
1384
+ content: {
1385
+ 'application/json': unknown;
1386
+ };
1387
+ }>;
1388
+ getChartOfAccounts(params: {}): import("../types/api").RequestData<{
1389
+ number: string;
1390
+ name: string;
1391
+ active?: boolean | undefined;
1392
+ type?: "vat" | "bank" | "cash" | "other_financial" | "receivable" | "payable" | "income" | "expense" | "other" | undefined;
1393
+ }[]>;
1394
+ getBalanceOfAccounts(filter: {
1395
+ accounts: string[];
1396
+ start: string;
1397
+ end: string;
1398
+ }): import("../types/api").RequestData<{
1399
+ account_number: string;
1400
+ debit: number;
1401
+ credit: number;
1402
+ balance: number;
1403
+ }[]>;
1404
+ getEmployees(): import("../types/api").RequestData<{
1405
+ id: string;
1406
+ name: string;
1407
+ first_name?: string | undefined;
1408
+ last_name?: string | undefined;
1409
+ function?: string | undefined;
1410
+ phone?: string | undefined;
1411
+ mobile?: string | undefined;
1412
+ email?: string | undefined;
1413
+ active?: boolean | undefined;
1414
+ reference?: string | undefined;
1415
+ account_number?: string | undefined;
1416
+ }[]>;
1417
+ createFinancialEntry(financial_entry: {
1418
+ date: string;
1419
+ journal_id: string;
1420
+ currency: string;
1421
+ currency_exchange_rate?: number | undefined;
1422
+ reference?: string | undefined;
1423
+ items: {
1424
+ type: "general_account" | "customer_account" | "supplier_account" | "employee_account";
1425
+ account_number: string;
1426
+ partner_id?: string | undefined;
1427
+ amount: number;
1428
+ description?: string | undefined;
1429
+ }[];
1430
+ number?: string | undefined;
1431
+ pdf?: string | undefined;
1432
+ }): import("../types/api").RequestData<{
1433
+ date: string;
1434
+ journal_id: string;
1435
+ currency: string;
1436
+ currency_exchange_rate?: number | undefined;
1437
+ reference?: string | undefined;
1438
+ items: {
1439
+ type: "general_account" | "customer_account" | "supplier_account" | "employee_account";
1440
+ account_number: string;
1441
+ partner_id?: string | undefined;
1442
+ amount: number;
1443
+ description?: string | undefined;
1444
+ counterpart_account: string;
1445
+ }[];
1446
+ id: string;
1447
+ number: string;
1448
+ }>;
1449
+ }>;
1450
+ invoicing: import("../types/api").ApiFor<{
1451
+ getInvoices(params: {
1452
+ invoice_type?: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund" | "all" | undefined;
1453
+ date_from?: string | undefined;
1454
+ date_to?: string | undefined;
1455
+ page?: number | undefined;
1456
+ size?: number | undefined;
1457
+ } | undefined): import("../types/api").RequestData<{
1458
+ id: string;
1459
+ source_ref: {
1460
+ id?: string | undefined;
1461
+ model?: string | undefined;
1462
+ };
1463
+ currency: string;
1464
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
1465
+ status: "draft" | "posted" | "cancelled" | "paid";
1466
+ invoice_date: string;
1467
+ tax_amount: number;
1468
+ untaxed_amount: number;
1469
+ total: number;
1470
+ lines?: {
1471
+ description: string;
1472
+ unit_price: number;
1473
+ quantity: number;
1474
+ tax_amount: number;
1475
+ total: number;
1476
+ untaxed_amount: number;
1477
+ tax_rate?: number | undefined;
1478
+ account_number?: string | undefined;
1479
+ tax_id?: string | undefined;
1480
+ unit_of_measure?: string | undefined;
1481
+ product_id?: string | undefined;
1482
+ product_code?: string | undefined;
1483
+ product_name?: string | undefined;
1484
+ }[] | undefined;
1485
+ partner_id?: string | undefined;
1486
+ invoice_number?: string | undefined;
1487
+ due_date?: string | undefined;
1488
+ reference?: string | undefined;
1489
+ payment_communication?: string | undefined;
1490
+ customer_memo?: string | undefined;
1491
+ journal_ref?: {
1492
+ id?: string | undefined;
1493
+ model?: string | undefined;
1494
+ name?: string | undefined;
1495
+ } | undefined;
1496
+ }[]>;
1497
+ getInvoiceById(invoiceId: string, params: {
1498
+ include_pdf?: "true" | "false" | undefined;
1499
+ } | undefined): import("../types/api").RequestData<{
1500
+ id: string;
1501
+ source_ref: {
1502
+ id?: string | undefined;
1503
+ model?: string | undefined;
1504
+ };
1505
+ currency: string;
1506
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
1507
+ status: "draft" | "posted" | "cancelled" | "paid";
1508
+ invoice_date: string;
1509
+ tax_amount: number;
1510
+ untaxed_amount: number;
1511
+ total: number;
1512
+ lines?: {
1513
+ description: string;
1514
+ unit_price: number;
1515
+ quantity: number;
1516
+ tax_amount: number;
1517
+ total: number;
1518
+ untaxed_amount: number;
1519
+ tax_rate?: number | undefined;
1520
+ account_number?: string | undefined;
1521
+ tax_id?: string | undefined;
1522
+ unit_of_measure?: string | undefined;
1523
+ product_id?: string | undefined;
1524
+ product_code?: string | undefined;
1525
+ product_name?: string | undefined;
1526
+ }[] | undefined;
1527
+ partner_id?: string | undefined;
1528
+ invoice_number?: string | undefined;
1529
+ due_date?: string | undefined;
1530
+ reference?: string | undefined;
1531
+ payment_communication?: string | undefined;
1532
+ customer_memo?: string | undefined;
1533
+ journal_ref?: {
1534
+ id?: string | undefined;
1535
+ model?: string | undefined;
1536
+ name?: string | undefined;
1537
+ } | undefined;
1538
+ }>;
1539
+ createInvoice(invoice: {
1540
+ currency: string;
1541
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
1542
+ status: "draft" | "posted" | "cancelled" | "paid";
1543
+ invoice_date: string;
1544
+ tax_amount: number;
1545
+ untaxed_amount: number;
1546
+ total: number;
1547
+ lines?: {
1548
+ description: string;
1549
+ unit_price: number;
1550
+ quantity: number;
1551
+ tax_amount: number;
1552
+ total: number;
1553
+ untaxed_amount: number;
1554
+ tax_rate?: number | undefined;
1555
+ account_number?: string | undefined;
1556
+ tax_id?: string | undefined;
1557
+ unit_of_measure?: string | undefined;
1558
+ product_id?: string | undefined;
1559
+ product_code?: string | undefined;
1560
+ product_name?: string | undefined;
1561
+ }[] | undefined;
1562
+ partner_id?: string | undefined;
1563
+ invoice_number?: string | undefined;
1564
+ due_date?: string | undefined;
1565
+ reference?: string | undefined;
1566
+ payment_communication?: string | undefined;
1567
+ customer_memo?: string | undefined;
1568
+ journal_ref?: {
1569
+ id?: string | undefined;
1570
+ model?: string | undefined;
1571
+ name?: string | undefined;
1572
+ } | undefined;
1573
+ }): import("../types/api").RequestData<{
1574
+ id: string;
1575
+ source_ref: {
1576
+ id?: string | undefined;
1577
+ model?: string | undefined;
1578
+ };
1579
+ currency: string;
1580
+ invoice_type: "customer_invoice" | "customer_refund" | "supplier_invoice" | "supplier_refund";
1581
+ status: "draft" | "posted" | "cancelled" | "paid";
1582
+ invoice_date: string;
1583
+ tax_amount: number;
1584
+ untaxed_amount: number;
1585
+ total: number;
1586
+ lines?: {
1587
+ description: string;
1588
+ unit_price: number;
1589
+ quantity: number;
1590
+ tax_amount: number;
1591
+ total: number;
1592
+ untaxed_amount: number;
1593
+ tax_rate?: number | undefined;
1594
+ account_number?: string | undefined;
1595
+ tax_id?: string | undefined;
1596
+ unit_of_measure?: string | undefined;
1597
+ product_id?: string | undefined;
1598
+ product_code?: string | undefined;
1599
+ product_name?: string | undefined;
1600
+ }[] | undefined;
1601
+ partner_id?: string | undefined;
1602
+ invoice_number?: string | undefined;
1603
+ due_date?: string | undefined;
1604
+ reference?: string | undefined;
1605
+ payment_communication?: string | undefined;
1606
+ customer_memo?: string | undefined;
1607
+ journal_ref?: {
1608
+ id?: string | undefined;
1609
+ model?: string | undefined;
1610
+ name?: string | undefined;
1611
+ } | undefined;
1612
+ }>;
1613
+ getProducts(): import("../types/api").RequestData<{
1614
+ id: string;
1615
+ source_ref: {
1616
+ id?: string | undefined;
1617
+ model?: string | undefined;
1618
+ };
1619
+ name: string;
1620
+ unit_price?: number | undefined;
1621
+ tax_id?: string | undefined;
1622
+ code?: string | undefined;
1623
+ unit?: string | undefined;
1624
+ category?: string | undefined;
1625
+ currency?: string | undefined;
1626
+ description?: string | undefined;
1627
+ }[]>;
1628
+ getProductById(productId: string): import("../types/api").RequestData<{
1629
+ id: string;
1630
+ source_ref: {
1631
+ id?: string | undefined;
1632
+ model?: string | undefined;
1633
+ };
1634
+ name: string;
1635
+ unit_price?: number | undefined;
1636
+ tax_id?: string | undefined;
1637
+ code?: string | undefined;
1638
+ unit?: string | undefined;
1639
+ category?: string | undefined;
1640
+ currency?: string | undefined;
1641
+ description?: string | undefined;
1642
+ }>;
1643
+ createProduct(product: {
1644
+ name: string;
1645
+ unit_price?: number | undefined;
1646
+ tax_id?: string | undefined;
1647
+ code?: string | undefined;
1648
+ unit?: string | undefined;
1649
+ category?: string | undefined;
1650
+ currency?: string | undefined;
1651
+ description?: string | undefined;
1652
+ }): import("../types/api").RequestData<{
1653
+ id: string;
1654
+ source_ref: {
1655
+ id?: string | undefined;
1656
+ model?: string | undefined;
1657
+ };
1658
+ name: string;
1659
+ unit_price?: number | undefined;
1660
+ tax_id?: string | undefined;
1661
+ code?: string | undefined;
1662
+ unit?: string | undefined;
1663
+ category?: string | undefined;
1664
+ currency?: string | undefined;
1665
+ description?: string | undefined;
1666
+ }>;
1667
+ getTaxes(): import("../types/api").RequestData<{
1668
+ id: string;
1669
+ source_ref: {
1670
+ id?: string | undefined;
1671
+ model?: string | undefined;
1672
+ };
1673
+ label: string;
1674
+ rate: number;
1675
+ type: "unknown" | "sale" | "purchase" | "both";
1676
+ code?: string | undefined;
1677
+ scope?: "nat" | "eu" | "int" | "unknown" | undefined;
1678
+ }[]>;
1679
+ getTaxById(taxId: string): import("../types/api").RequestData<{
1680
+ id: string;
1681
+ source_ref: {
1682
+ id?: string | undefined;
1683
+ model?: string | undefined;
1684
+ };
1685
+ label: string;
1686
+ rate: number;
1687
+ type: "unknown" | "sale" | "purchase" | "both";
1688
+ code?: string | undefined;
1689
+ scope?: "nat" | "eu" | "int" | "unknown" | undefined;
1690
+ }>;
1691
+ getOpportunities(): import("../types/api").RequestData<{
1692
+ id: string;
1693
+ source_ref: {
1694
+ id?: string | undefined;
1695
+ model?: string | undefined;
1696
+ };
1697
+ name: string;
1698
+ total: number;
1699
+ probability: number;
1700
+ status: "open" | "closed" | "cancelled" | "won" | "lost";
1701
+ partner_id?: string | undefined;
1702
+ comment?: string | undefined;
1703
+ currency?: string | undefined;
1704
+ description?: string | undefined;
1705
+ pipe_status?: string | undefined;
1706
+ pipe_name?: string | undefined;
1707
+ created_date?: string | undefined;
1708
+ due_date?: string | undefined;
1709
+ end_date?: string | undefined;
1710
+ is_won?: boolean | undefined;
1711
+ owner_ref?: {
1712
+ id?: string | undefined;
1713
+ model?: string | undefined;
1714
+ name?: string | undefined;
1715
+ } | undefined;
1716
+ }[]>;
1717
+ getOpportunitiesById(opportunityId: string): import("../types/api").RequestData<{
1718
+ id: string;
1719
+ source_ref: {
1720
+ id?: string | undefined;
1721
+ model?: string | undefined;
1722
+ };
1723
+ name: string;
1724
+ total: number;
1725
+ probability: number;
1726
+ status: "open" | "closed" | "cancelled" | "won" | "lost";
1727
+ partner_id?: string | undefined;
1728
+ comment?: string | undefined;
1729
+ currency?: string | undefined;
1730
+ description?: string | undefined;
1731
+ pipe_status?: string | undefined;
1732
+ pipe_name?: string | undefined;
1733
+ created_date?: string | undefined;
1734
+ due_date?: string | undefined;
1735
+ end_date?: string | undefined;
1736
+ is_won?: boolean | undefined;
1737
+ owner_ref?: {
1738
+ id?: string | undefined;
1739
+ model?: string | undefined;
1740
+ name?: string | undefined;
1741
+ } | undefined;
1742
+ }>;
1743
+ getContacts(params?: {
1744
+ contact_type?: "all" | "prospect" | "customer" | "supplier" | undefined;
1745
+ page?: number | undefined;
1746
+ size?: number | undefined;
1747
+ } | undefined): import("../types/api").RequestData<{
1748
+ id: string;
1749
+ source_ref: {
1750
+ id?: string | undefined;
1751
+ model?: string | undefined;
1752
+ };
1753
+ is_prospect?: boolean | undefined;
1754
+ is_customer?: boolean | undefined;
1755
+ is_supplier?: boolean | undefined;
1756
+ is_company?: boolean | undefined;
1757
+ company_name?: string | undefined;
1758
+ first_name?: string | undefined;
1759
+ last_name?: string | undefined;
1760
+ email?: string | undefined;
1761
+ phone?: string | undefined;
1762
+ mobile?: string | undefined;
1763
+ company_id?: string | undefined;
1764
+ vat?: string | undefined;
1765
+ company_number?: string | undefined;
1766
+ currency?: string | undefined;
1767
+ language?: string | undefined;
1768
+ comment?: string | undefined;
1769
+ customer_account_number?: string | undefined;
1770
+ supplier_account_number?: string | undefined;
1771
+ birthdate?: string | undefined;
1772
+ gender?: "H" | "F" | "N/A" | undefined;
1773
+ addresses?: {
1774
+ address_type: "main" | "delivery" | "invoice";
1775
+ name?: string | undefined;
1776
+ number?: string | undefined;
1777
+ box?: string | undefined;
1778
+ phone?: string | undefined;
1779
+ mobile?: string | undefined;
1780
+ email?: string | undefined;
1781
+ street?: string | undefined;
1782
+ city?: string | undefined;
1783
+ postal_code?: string | undefined;
1784
+ country?: string | undefined;
1785
+ }[] | undefined;
1786
+ }[]>;
1787
+ getContactById(contactId: string): import("../types/api").RequestData<{
1788
+ id: string;
1789
+ source_ref: {
1790
+ id?: string | undefined;
1791
+ model?: string | undefined;
1792
+ };
1793
+ is_prospect?: boolean | undefined;
1794
+ is_customer?: boolean | undefined;
1795
+ is_supplier?: boolean | undefined;
1796
+ is_company?: boolean | undefined;
1797
+ company_name?: string | undefined;
1798
+ first_name?: string | undefined;
1799
+ last_name?: string | undefined;
1800
+ email?: string | undefined;
1801
+ phone?: string | undefined;
1802
+ mobile?: string | undefined;
1803
+ company_id?: string | undefined;
1804
+ vat?: string | undefined;
1805
+ company_number?: string | undefined;
1806
+ currency?: string | undefined;
1807
+ language?: string | undefined;
1808
+ comment?: string | undefined;
1809
+ customer_account_number?: string | undefined;
1810
+ supplier_account_number?: string | undefined;
1811
+ birthdate?: string | undefined;
1812
+ gender?: "H" | "F" | "N/A" | undefined;
1813
+ addresses?: {
1814
+ address_type: "main" | "delivery" | "invoice";
1815
+ name?: string | undefined;
1816
+ number?: string | undefined;
1817
+ box?: string | undefined;
1818
+ phone?: string | undefined;
1819
+ mobile?: string | undefined;
1820
+ email?: string | undefined;
1821
+ street?: string | undefined;
1822
+ city?: string | undefined;
1823
+ postal_code?: string | undefined;
1824
+ country?: string | undefined;
1825
+ }[] | undefined;
1826
+ }>;
1827
+ createContact(contact: {
1828
+ is_prospect?: boolean | undefined;
1829
+ is_customer?: boolean | undefined;
1830
+ is_supplier?: boolean | undefined;
1831
+ is_company?: boolean | undefined;
1832
+ company_name?: string | undefined;
1833
+ first_name?: string | undefined;
1834
+ last_name?: string | undefined;
1835
+ email?: string | undefined;
1836
+ phone?: string | undefined;
1837
+ mobile?: string | undefined;
1838
+ company_id?: string | undefined;
1839
+ vat?: string | undefined;
1840
+ company_number?: string | undefined;
1841
+ currency?: string | undefined;
1842
+ language?: string | undefined;
1843
+ comment?: string | undefined;
1844
+ customer_account_number?: string | undefined;
1845
+ supplier_account_number?: string | undefined;
1846
+ birthdate?: string | undefined;
1847
+ gender?: "H" | "F" | "N/A" | undefined;
1848
+ addresses?: {
1849
+ address_type: "main" | "delivery" | "invoice";
1850
+ name?: string | undefined;
1851
+ number?: string | undefined;
1852
+ box?: string | undefined;
1853
+ phone?: string | undefined;
1854
+ mobile?: string | undefined;
1855
+ email?: string | undefined;
1856
+ street: string;
1857
+ city: string;
1858
+ postal_code: string;
1859
+ country: string;
1860
+ }[] | undefined;
1861
+ }): import("../types/api").RequestData<{
1862
+ id: string;
1863
+ source_ref: {
1864
+ id?: string | undefined;
1865
+ model?: string | undefined;
1866
+ };
1867
+ is_prospect?: boolean | undefined;
1868
+ is_customer?: boolean | undefined;
1869
+ is_supplier?: boolean | undefined;
1870
+ is_company?: boolean | undefined;
1871
+ company_name?: string | undefined;
1872
+ first_name?: string | undefined;
1873
+ last_name?: string | undefined;
1874
+ email?: string | undefined;
1875
+ phone?: string | undefined;
1876
+ mobile?: string | undefined;
1877
+ company_id?: string | undefined;
1878
+ vat?: string | undefined;
1879
+ company_number?: string | undefined;
1880
+ currency?: string | undefined;
1881
+ language?: string | undefined;
1882
+ comment?: string | undefined;
1883
+ customer_account_number?: string | undefined;
1884
+ supplier_account_number?: string | undefined;
1885
+ birthdate?: string | undefined;
1886
+ gender?: "H" | "F" | "N/A" | undefined;
1887
+ addresses?: {
1888
+ address_type: "main" | "delivery" | "invoice";
1889
+ name?: string | undefined;
1890
+ number?: string | undefined;
1891
+ box?: string | undefined;
1892
+ phone?: string | undefined;
1893
+ mobile?: string | undefined;
1894
+ email?: string | undefined;
1895
+ street?: string | undefined;
1896
+ city?: string | undefined;
1897
+ postal_code?: string | undefined;
1898
+ country?: string | undefined;
1899
+ }[] | undefined;
1900
+ }>;
1901
+ }>;
1902
+ ecommerce: import("../types/api").ApiFor<{
1903
+ getCustomers(): import("../types/api").RequestData<{
1904
+ id: string;
1905
+ source_ref: {
1906
+ id?: string | undefined;
1907
+ model?: string | undefined;
1908
+ };
1909
+ first_name?: string | undefined;
1910
+ last_name?: string | undefined;
1911
+ phone?: string | undefined;
1912
+ email?: string | undefined;
1913
+ language?: string | undefined;
1914
+ internal_notes?: string | undefined;
1915
+ currency?: string | undefined;
1916
+ addresses?: {
1917
+ address_type: "main" | "delivery" | "invoice";
1918
+ first_name?: string | undefined;
1919
+ last_name?: string | undefined;
1920
+ street?: string | undefined;
1921
+ number?: string | undefined;
1922
+ box?: string | undefined;
1923
+ city?: string | undefined;
1924
+ postal_code?: string | undefined;
1925
+ country?: string | undefined;
1926
+ phone?: string | undefined;
1927
+ email?: string | undefined;
1928
+ }[] | undefined;
1929
+ created_on?: string | undefined;
1930
+ }[]>;
1931
+ getProducts(): import("../types/api").RequestData<{
1932
+ id: string;
1933
+ source_ref: {
1934
+ id?: string | undefined;
1935
+ model?: string | undefined;
1936
+ };
1937
+ name: string;
1938
+ description?: string | undefined;
1939
+ description_html?: string | undefined;
1940
+ categories?: {
1941
+ id: string;
1942
+ name: string;
1943
+ }[] | undefined;
1944
+ created_on?: string | undefined;
1945
+ variants?: {
1946
+ id: string;
1947
+ source_ref: {
1948
+ id?: string | undefined;
1949
+ model?: string | undefined;
1950
+ };
1951
+ parent_id: string;
1952
+ name: string;
1953
+ description?: string | undefined;
1954
+ description_html?: string | undefined;
1955
+ categories?: {
1956
+ id: string;
1957
+ name: string;
1958
+ }[] | undefined;
1959
+ created_on?: string | undefined;
1960
+ sku?: string | undefined;
1961
+ barcode?: string | undefined;
1962
+ available_quantity?: number | undefined;
1963
+ prices?: {
1964
+ currency: string;
1965
+ price?: number | undefined;
1966
+ }[] | undefined;
1967
+ unit_of_measure?: string | undefined;
1968
+ weight?: number | undefined;
1969
+ weight_unit?: string | undefined;
1970
+ status?: "unknown" | "archived" | "unpublished" | "published" | undefined;
1971
+ variant_attributes?: {
1972
+ name: string;
1973
+ value: string;
1974
+ }[] | undefined;
1975
+ variant_images?: {
1976
+ id: string;
1977
+ main_image: boolean;
1978
+ url: string;
1979
+ }[] | undefined;
1980
+ }[] | undefined;
1981
+ status?: "unknown" | "archived" | "unpublished" | "published" | undefined;
1982
+ common_attributes?: {
1983
+ name: string;
1984
+ values: string[];
1985
+ }[] | undefined;
1986
+ variant_attributes_options?: {
1987
+ name: string;
1988
+ values: string[];
1989
+ }[] | undefined;
1990
+ common_images?: {
1991
+ id: string;
1992
+ main_image: boolean;
1993
+ url: string;
1994
+ }[] | undefined;
1995
+ }[]>;
1996
+ getCustomer(customerId: string): import("../types/api").RequestData<{
1997
+ id: string;
1998
+ source_ref: {
1999
+ id?: string | undefined;
2000
+ model?: string | undefined;
2001
+ };
2002
+ first_name?: string | undefined;
2003
+ last_name?: string | undefined;
2004
+ phone?: string | undefined;
2005
+ email?: string | undefined;
2006
+ language?: string | undefined;
2007
+ internal_notes?: string | undefined;
2008
+ currency?: string | undefined;
2009
+ addresses?: {
2010
+ address_type: "main" | "delivery" | "invoice";
2011
+ first_name?: string | undefined;
2012
+ last_name?: string | undefined;
2013
+ street?: string | undefined;
2014
+ number?: string | undefined;
2015
+ box?: string | undefined;
2016
+ city?: string | undefined;
2017
+ postal_code?: string | undefined;
2018
+ country?: string | undefined;
2019
+ phone?: string | undefined;
2020
+ email?: string | undefined;
2021
+ }[] | undefined;
2022
+ created_on?: string | undefined;
2023
+ }>;
2024
+ getProduct(productId: string): import("../types/api").RequestData<{
2025
+ id: string;
2026
+ source_ref: {
2027
+ id?: string | undefined;
2028
+ model?: string | undefined;
2029
+ };
2030
+ name: string;
2031
+ description?: string | undefined;
2032
+ description_html?: string | undefined;
2033
+ categories?: {
2034
+ id: string;
2035
+ name: string;
2036
+ }[] | undefined;
2037
+ created_on?: string | undefined;
2038
+ variants?: {
2039
+ id: string;
2040
+ source_ref: {
2041
+ id?: string | undefined;
2042
+ model?: string | undefined;
2043
+ };
2044
+ parent_id: string;
2045
+ name: string;
2046
+ description?: string | undefined;
2047
+ description_html?: string | undefined;
2048
+ categories?: {
2049
+ id: string;
2050
+ name: string;
2051
+ }[] | undefined;
2052
+ created_on?: string | undefined;
2053
+ sku?: string | undefined;
2054
+ barcode?: string | undefined;
2055
+ available_quantity?: number | undefined;
2056
+ prices?: {
2057
+ currency: string;
2058
+ price?: number | undefined;
2059
+ }[] | undefined;
2060
+ unit_of_measure?: string | undefined;
2061
+ weight?: number | undefined;
2062
+ weight_unit?: string | undefined;
2063
+ status?: "unknown" | "archived" | "unpublished" | "published" | undefined;
2064
+ variant_attributes?: {
2065
+ name: string;
2066
+ value: string;
2067
+ }[] | undefined;
2068
+ variant_images?: {
2069
+ id: string;
2070
+ main_image: boolean;
2071
+ url: string;
2072
+ }[] | undefined;
2073
+ }[] | undefined;
2074
+ status?: "unknown" | "archived" | "unpublished" | "published" | undefined;
2075
+ common_attributes?: {
2076
+ name: string;
2077
+ values: string[];
2078
+ }[] | undefined;
2079
+ variant_attributes_options?: {
2080
+ name: string;
2081
+ values: string[];
2082
+ }[] | undefined;
2083
+ common_images?: {
2084
+ id: string;
2085
+ main_image: boolean;
2086
+ url: string;
2087
+ }[] | undefined;
2088
+ }>;
2089
+ getProductVariantById(variantId: string): import("../types/api").RequestData<{
2090
+ id: string;
2091
+ source_ref: {
2092
+ id?: string | undefined;
2093
+ model?: string | undefined;
2094
+ };
2095
+ parent_id: string;
2096
+ name: string;
2097
+ description?: string | undefined;
2098
+ description_html?: string | undefined;
2099
+ categories?: {
2100
+ id: string;
2101
+ name: string;
2102
+ }[] | undefined;
2103
+ created_on?: string | undefined;
2104
+ sku?: string | undefined;
2105
+ barcode?: string | undefined;
2106
+ available_quantity?: number | undefined;
2107
+ prices?: {
2108
+ currency: string;
2109
+ price?: number | undefined;
2110
+ }[] | undefined;
2111
+ unit_of_measure?: string | undefined;
2112
+ weight?: number | undefined;
2113
+ weight_unit?: string | undefined;
2114
+ status?: "unknown" | "archived" | "unpublished" | "published" | undefined;
2115
+ inventory_details?: {
2116
+ location: {
2117
+ id: string;
2118
+ name: string;
2119
+ };
2120
+ available_quantity: number;
2121
+ }[] | undefined;
2122
+ common_attributes?: {
2123
+ name: string;
2124
+ values: string[];
2125
+ }[] | undefined;
2126
+ variant_attributes?: {
2127
+ name: string;
2128
+ value: string;
2129
+ }[] | undefined;
2130
+ common_images?: {
2131
+ id: string;
2132
+ main_image: boolean;
2133
+ url: string;
2134
+ }[] | undefined;
2135
+ variant_images?: {
2136
+ id: string;
2137
+ main_image: boolean;
2138
+ url: string;
2139
+ }[] | undefined;
2140
+ }>;
2141
+ updateAvailableQuantity(variantId: string, inventoryDetails: {
2142
+ location_id: string;
2143
+ available_quantity: number;
2144
+ }): import("../types/api").RequestData<{
2145
+ location: {
2146
+ id: string;
2147
+ name: string;
2148
+ };
2149
+ available_quantity: number;
2150
+ }>;
2151
+ getLocations(): import("../types/api").RequestData<{
2152
+ id: string;
2153
+ name: string;
2154
+ }[]>;
2155
+ getOrders(params: {}): import("../types/api").RequestData<{
2156
+ id: string;
2157
+ source_ref: {
2158
+ id?: string | undefined;
2159
+ model?: string | undefined;
2160
+ };
2161
+ order_number?: string | undefined;
2162
+ customer?: {
2163
+ email: string;
2164
+ first_name?: string | undefined;
2165
+ last_name?: string | undefined;
2166
+ phone?: string | undefined;
2167
+ internal_notes?: string | undefined;
2168
+ id: string;
2169
+ } | undefined;
2170
+ billing_address?: {
2171
+ address_type: "main" | "delivery" | "invoice";
2172
+ first_name?: string | undefined;
2173
+ last_name?: string | undefined;
2174
+ street?: string | undefined;
2175
+ number?: string | undefined;
2176
+ box?: string | undefined;
2177
+ city?: string | undefined;
2178
+ postal_code?: string | undefined;
2179
+ country?: string | undefined;
2180
+ phone?: string | undefined;
2181
+ email?: string | undefined;
2182
+ } | undefined;
2183
+ shipping_address?: {
2184
+ address_type: "main" | "delivery" | "invoice";
2185
+ first_name?: string | undefined;
2186
+ last_name?: string | undefined;
2187
+ street?: string | undefined;
2188
+ number?: string | undefined;
2189
+ box?: string | undefined;
2190
+ city?: string | undefined;
2191
+ postal_code?: string | undefined;
2192
+ country?: string | undefined;
2193
+ phone?: string | undefined;
2194
+ email?: string | undefined;
2195
+ } | undefined;
2196
+ created_on?: string | undefined;
2197
+ last_updated_on?: string | undefined;
2198
+ confirmed_on?: string | undefined;
2199
+ cancelled_on?: string | undefined;
2200
+ status: "draft" | "cancelled" | "confirmed";
2201
+ discount_amount: number;
2202
+ untaxed_amount_without_fees: number;
2203
+ tax_amount_without_fees: number;
2204
+ total_without_fees: number;
2205
+ untaxed_amount: number;
2206
+ tax_amount: number;
2207
+ total: number;
2208
+ refunded_amount?: number | undefined;
2209
+ detailed_refunds?: {
2210
+ created_on?: string | undefined;
2211
+ total: number;
2212
+ reason?: string | undefined;
2213
+ order_lines?: {
2214
+ id: string;
2215
+ variant?: {
2216
+ id: string;
2217
+ sku?: string | undefined;
2218
+ name: string;
2219
+ } | undefined;
2220
+ quantity: number;
2221
+ untaxed_amount: number;
2222
+ tax_amount: number;
2223
+ total: number;
2224
+ }[] | undefined;
2225
+ other?: number | undefined;
2226
+ }[] | undefined;
2227
+ currency: string;
2228
+ note?: string | undefined;
2229
+ lines: {
2230
+ id: string;
2231
+ source_ref: {
2232
+ id?: string | undefined;
2233
+ model?: string | undefined;
2234
+ };
2235
+ variant?: {
2236
+ id: string;
2237
+ sku?: string | undefined;
2238
+ name: string;
2239
+ } | undefined;
2240
+ quantity: number;
2241
+ unit_price: number;
2242
+ description: string;
2243
+ tax_rate: number;
2244
+ untaxed_amount: number;
2245
+ tax_amount: number;
2246
+ total: number;
2247
+ discounts?: {
2248
+ name: string;
2249
+ description: string;
2250
+ amount: number;
2251
+ }[] | undefined;
2252
+ }[];
2253
+ other_fees?: {
2254
+ type: "other" | "shipping";
2255
+ tax_rate: number;
2256
+ untaxed_amount: number;
2257
+ tax_amount: number;
2258
+ total: number;
2259
+ }[] | undefined;
2260
+ }[]>;
2261
+ createOrder(order: {
2262
+ customer: {
2263
+ email: string;
2264
+ first_name?: string | undefined;
2265
+ last_name?: string | undefined;
2266
+ phone?: string | undefined;
2267
+ internal_notes?: string | undefined;
2268
+ };
2269
+ billing_address: {
2270
+ first_name: string;
2271
+ last_name: string;
2272
+ street: string;
2273
+ number: string;
2274
+ box?: string | undefined;
2275
+ city: string;
2276
+ postal_code?: string | undefined;
2277
+ country: string;
2278
+ phone?: string | undefined;
2279
+ email?: string | undefined;
2280
+ };
2281
+ shipping_address: {
2282
+ first_name: string;
2283
+ last_name: string;
2284
+ street: string;
2285
+ number: string;
2286
+ box?: string | undefined;
2287
+ city: string;
2288
+ postal_code?: string | undefined;
2289
+ country: string;
2290
+ phone?: string | undefined;
2291
+ email?: string | undefined;
2292
+ };
2293
+ currency: string;
2294
+ note?: string | undefined;
2295
+ lines: {
2296
+ variant_id: string;
2297
+ quantity: number;
2298
+ tax_rate: number;
2299
+ unit_price: number;
2300
+ }[];
2301
+ payment_method?: string | undefined;
2302
+ }): import("../types/api").RequestData<{
2303
+ id: string;
2304
+ source_ref: {
2305
+ id?: string | undefined;
2306
+ model?: string | undefined;
2307
+ };
2308
+ order_number?: string | undefined;
2309
+ customer?: {
2310
+ email: string;
2311
+ first_name?: string | undefined;
2312
+ last_name?: string | undefined;
2313
+ phone?: string | undefined;
2314
+ internal_notes?: string | undefined;
2315
+ id: string;
2316
+ } | undefined;
2317
+ billing_address?: {
2318
+ address_type: "main" | "delivery" | "invoice";
2319
+ first_name?: string | undefined;
2320
+ last_name?: string | undefined;
2321
+ street?: string | undefined;
2322
+ number?: string | undefined;
2323
+ box?: string | undefined;
2324
+ city?: string | undefined;
2325
+ postal_code?: string | undefined;
2326
+ country?: string | undefined;
2327
+ phone?: string | undefined;
2328
+ email?: string | undefined;
2329
+ } | undefined;
2330
+ shipping_address?: {
2331
+ address_type: "main" | "delivery" | "invoice";
2332
+ first_name?: string | undefined;
2333
+ last_name?: string | undefined;
2334
+ street?: string | undefined;
2335
+ number?: string | undefined;
2336
+ box?: string | undefined;
2337
+ city?: string | undefined;
2338
+ postal_code?: string | undefined;
2339
+ country?: string | undefined;
2340
+ phone?: string | undefined;
2341
+ email?: string | undefined;
2342
+ } | undefined;
2343
+ created_on?: string | undefined;
2344
+ last_updated_on?: string | undefined;
2345
+ confirmed_on?: string | undefined;
2346
+ cancelled_on?: string | undefined;
2347
+ status: "draft" | "cancelled" | "confirmed";
2348
+ discount_amount: number;
2349
+ untaxed_amount_without_fees: number;
2350
+ tax_amount_without_fees: number;
2351
+ total_without_fees: number;
2352
+ untaxed_amount: number;
2353
+ tax_amount: number;
2354
+ total: number;
2355
+ refunded_amount?: number | undefined;
2356
+ detailed_refunds?: {
2357
+ created_on?: string | undefined;
2358
+ total: number;
2359
+ reason?: string | undefined;
2360
+ order_lines?: {
2361
+ id: string;
2362
+ variant?: {
2363
+ id: string;
2364
+ sku?: string | undefined;
2365
+ name: string;
2366
+ } | undefined;
2367
+ quantity: number;
2368
+ untaxed_amount: number;
2369
+ tax_amount: number;
2370
+ total: number;
2371
+ }[] | undefined;
2372
+ other?: number | undefined;
2373
+ }[] | undefined;
2374
+ currency: string;
2375
+ note?: string | undefined;
2376
+ lines: {
2377
+ id: string;
2378
+ source_ref: {
2379
+ id?: string | undefined;
2380
+ model?: string | undefined;
2381
+ };
2382
+ variant?: {
2383
+ id: string;
2384
+ sku?: string | undefined;
2385
+ name: string;
2386
+ } | undefined;
2387
+ quantity: number;
2388
+ unit_price: number;
2389
+ description: string;
2390
+ tax_rate: number;
2391
+ untaxed_amount: number;
2392
+ tax_amount: number;
2393
+ total: number;
2394
+ discounts?: {
2395
+ name: string;
2396
+ description: string;
2397
+ amount: number;
2398
+ }[] | undefined;
2399
+ }[];
2400
+ other_fees?: {
2401
+ type: "other" | "shipping";
2402
+ tax_rate: number;
2403
+ untaxed_amount: number;
2404
+ tax_amount: number;
2405
+ total: number;
2406
+ }[] | undefined;
2407
+ }>;
2408
+ getOrder(orderId: string): import("../types/api").RequestData<{
2409
+ id: string;
2410
+ source_ref: {
2411
+ id?: string | undefined;
2412
+ model?: string | undefined;
2413
+ };
2414
+ order_number?: string | undefined;
2415
+ customer?: {
2416
+ email: string;
2417
+ first_name?: string | undefined;
2418
+ last_name?: string | undefined;
2419
+ phone?: string | undefined;
2420
+ internal_notes?: string | undefined;
2421
+ id: string;
2422
+ } | undefined;
2423
+ billing_address?: {
2424
+ address_type: "main" | "delivery" | "invoice";
2425
+ first_name?: string | undefined;
2426
+ last_name?: string | undefined;
2427
+ street?: string | undefined;
2428
+ number?: string | undefined;
2429
+ box?: string | undefined;
2430
+ city?: string | undefined;
2431
+ postal_code?: string | undefined;
2432
+ country?: string | undefined;
2433
+ phone?: string | undefined;
2434
+ email?: string | undefined;
2435
+ } | undefined;
2436
+ shipping_address?: {
2437
+ address_type: "main" | "delivery" | "invoice";
2438
+ first_name?: string | undefined;
2439
+ last_name?: string | undefined;
2440
+ street?: string | undefined;
2441
+ number?: string | undefined;
2442
+ box?: string | undefined;
2443
+ city?: string | undefined;
2444
+ postal_code?: string | undefined;
2445
+ country?: string | undefined;
2446
+ phone?: string | undefined;
2447
+ email?: string | undefined;
2448
+ } | undefined;
2449
+ created_on?: string | undefined;
2450
+ last_updated_on?: string | undefined;
2451
+ confirmed_on?: string | undefined;
2452
+ cancelled_on?: string | undefined;
2453
+ status: "draft" | "cancelled" | "confirmed";
2454
+ discount_amount: number;
2455
+ untaxed_amount_without_fees: number;
2456
+ tax_amount_without_fees: number;
2457
+ total_without_fees: number;
2458
+ untaxed_amount: number;
2459
+ tax_amount: number;
2460
+ total: number;
2461
+ refunded_amount?: number | undefined;
2462
+ detailed_refunds?: {
2463
+ created_on?: string | undefined;
2464
+ total: number;
2465
+ reason?: string | undefined;
2466
+ order_lines?: {
2467
+ id: string;
2468
+ variant?: {
2469
+ id: string;
2470
+ sku?: string | undefined;
2471
+ name: string;
2472
+ } | undefined;
2473
+ quantity: number;
2474
+ untaxed_amount: number;
2475
+ tax_amount: number;
2476
+ total: number;
2477
+ }[] | undefined;
2478
+ other?: number | undefined;
2479
+ }[] | undefined;
2480
+ currency: string;
2481
+ note?: string | undefined;
2482
+ lines: {
2483
+ id: string;
2484
+ source_ref: {
2485
+ id?: string | undefined;
2486
+ model?: string | undefined;
2487
+ };
2488
+ variant?: {
2489
+ id: string;
2490
+ sku?: string | undefined;
2491
+ name: string;
2492
+ } | undefined;
2493
+ quantity: number;
2494
+ unit_price: number;
2495
+ description: string;
2496
+ tax_rate: number;
2497
+ untaxed_amount: number;
2498
+ tax_amount: number;
2499
+ total: number;
2500
+ discounts?: {
2501
+ name: string;
2502
+ description: string;
2503
+ amount: number;
2504
+ }[] | undefined;
2505
+ }[];
2506
+ other_fees?: {
2507
+ type: "other" | "shipping";
2508
+ tax_rate: number;
2509
+ untaxed_amount: number;
2510
+ tax_amount: number;
2511
+ total: number;
2512
+ }[] | undefined;
2513
+ }>;
2514
+ }>;
2515
+ custom: import("../types/api").ApiFor<{
2516
+ get(name: string, resource: string, params?: any): import("../types/api").RequestData<any>;
2517
+ post(name: string, resource: string, body: any, params?: any): import("../types/api").RequestData<any>;
2518
+ patch(name: string, resource: string, body: any, params?: any): import("../types/api").RequestData<any>;
2519
+ delete(name: string, resource: string, params?: any): import("../types/api").RequestData<any>;
2520
+ }>;
2521
+ getDataByDataStoreId: (dataStoreId: string, params?: object) => Promise<{
2522
+ data: Record<string, never>;
2523
+ id: string;
2524
+ created_on: string;
2525
+ }[]>;
2526
+ addDataByDataStoreId: (dataStoreId: string, data: components['schemas']['DataItem'][]) => Promise<{
2527
+ data: Record<string, never>;
2528
+ id: string;
2529
+ created_on: string;
2530
+ }[]>;
2531
+ getSyncData: (syncId: string) => Promise<{
2532
+ syncid: string;
2533
+ sync_name: string;
2534
+ status?: "active" | "inactive" | undefined;
2535
+ status_details?: string | undefined;
2536
+ link_createdon: string;
2537
+ link_mappings?: {
2538
+ name: string;
2539
+ description: string;
2540
+ values: {
2541
+ source_id: string;
2542
+ target_id: string;
2543
+ }[];
2544
+ }[] | undefined;
2545
+ enabled_flows?: {
2546
+ name: string;
2547
+ description?: string | undefined;
2548
+ id: string;
2549
+ config?: {
2550
+ definitionFields?: Record<string, never>[] | undefined;
2551
+ doorkeyFields?: Record<string, never>[] | undefined;
2552
+ customFields?: Record<string, never>[] | undefined;
2553
+ datastores?: {
2554
+ id?: string | undefined;
2555
+ name: string;
2556
+ status?: "active" | "inactive" | undefined;
2557
+ definition: {
2558
+ columns: {
2559
+ name: string;
2560
+ title: string;
2561
+ type: string;
2562
+ Optional?: boolean | undefined;
2563
+ }[];
2564
+ search_column?: string | undefined;
2565
+ };
2566
+ }[] | undefined;
2567
+ } | undefined;
2568
+ values: Record<string, never>;
2569
+ }[] | undefined;
2570
+ }>;
2571
+ getDataByDataStoreName: (dataStoreName: string, params?: object) => Promise<{
2572
+ data: Record<string, never>;
2573
+ id: string;
2574
+ created_on: string;
2575
+ }[]>;
2576
+ addDataByDataStoreName: (dataStoreName: string, data: components['schemas']['DataItem'][]) => Promise<{
2577
+ data: Record<string, never>;
2578
+ id: string;
2579
+ created_on: string;
2580
+ }[] | undefined>;
2581
+ updateDataStoreData: (dataStoreId: string, dataStoreDataId: string, data: components['schemas']['DataItem']) => Promise<{
2582
+ data: Record<string, never>;
2583
+ id: string;
2584
+ created_on: string;
2585
+ }[]>;
2586
+ logData: (logs: ConsumerLog[]) => Promise<SimpleResponseModel>;
2587
+ };
2588
+ export { Consumer };