@revenexx/sdk 0.0.2 → 0.0.5
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.
- package/dist/cjs/sdk.js +13496 -3442
- package/dist/cjs/sdk.js.map +1 -1
- package/dist/esm/sdk.js +13467 -3443
- package/dist/esm/sdk.js.map +1 -1
- package/dist/iife/sdk.js +13496 -3442
- package/package.json +1 -1
- package/src/client.ts +1 -1
- package/src/enums/address-type.ts +4 -0
- package/src/enums/cart-export-format.ts +4 -0
- package/src/enums/cart-io-apply-mode.ts +5 -0
- package/src/enums/cart-io-direction.ts +4 -0
- package/src/enums/cart-io-entity.ts +4 -0
- package/src/enums/cart-io-format.ts +4 -0
- package/src/enums/cart-item-type.ts +5 -0
- package/src/enums/channel-status.ts +4 -0
- package/src/enums/channel-type.ts +7 -0
- package/src/enums/contact-role.ts +6 -0
- package/src/enums/contact-status.ts +5 -0
- package/src/enums/location-type.ts +6 -0
- package/src/enums/market-status.ts +4 -0
- package/src/enums/order-comment-visibility.ts +4 -0
- package/src/enums/order-item-type.ts +5 -0
- package/src/enums/order-payment-status.ts +9 -0
- package/src/enums/organization-status.ts +4 -0
- package/src/enums/page-status.ts +5 -0
- package/src/enums/payment-fee-type.ts +5 -0
- package/src/enums/payment-method-kind.ts +4 -0
- package/src/enums/price-entry-type.ts +4 -0
- package/src/enums/price-list-status.ts +4 -0
- package/src/enums/shipping-method-matrix-basis.ts +6 -0
- package/src/enums/shipping-method-pricing-type.ts +5 -0
- package/src/index.ts +30 -0
- package/src/models.ts +5628 -410
- package/src/services/apps.ts +154 -154
- package/src/services/avatars.ts +57 -57
- package/src/services/carts.ts +739 -104
- package/src/services/channels.ts +147 -19
- package/src/services/customers.ts +801 -69
- package/src/services/greetings.ts +18 -18
- package/src/services/inventories.ts +1278 -0
- package/src/services/locale.ts +16 -16
- package/src/services/markets.ts +373 -75
- package/src/services/messaging.ts +273 -273
- package/src/services/orders.ts +1648 -0
- package/src/services/pages.ts +2317 -0
- package/src/services/payments.ts +1334 -0
- package/src/services/prices.ts +1036 -0
- package/src/services/products.ts +1836 -272
- package/src/services/search.ts +24 -24
- package/src/services/shipping.ts +956 -0
- package/src/services/sites.ts +116 -116
- package/src/services/storage.ts +72 -72
- package/src/services/tokens.ts +14 -14
- package/types/enums/address-type.d.ts +4 -0
- package/types/enums/cart-export-format.d.ts +4 -0
- package/types/enums/cart-io-apply-mode.d.ts +5 -0
- package/types/enums/cart-io-direction.d.ts +4 -0
- package/types/enums/cart-io-entity.d.ts +4 -0
- package/types/enums/cart-io-format.d.ts +4 -0
- package/types/enums/cart-item-type.d.ts +5 -0
- package/types/enums/channel-status.d.ts +4 -0
- package/types/enums/channel-type.d.ts +7 -0
- package/types/enums/contact-role.d.ts +6 -0
- package/types/enums/contact-status.d.ts +5 -0
- package/types/enums/location-type.d.ts +6 -0
- package/types/enums/market-status.d.ts +4 -0
- package/types/enums/order-comment-visibility.d.ts +4 -0
- package/types/enums/order-item-type.d.ts +5 -0
- package/types/enums/order-payment-status.d.ts +9 -0
- package/types/enums/organization-status.d.ts +4 -0
- package/types/enums/page-status.d.ts +5 -0
- package/types/enums/payment-fee-type.d.ts +5 -0
- package/types/enums/payment-method-kind.d.ts +4 -0
- package/types/enums/price-entry-type.d.ts +4 -0
- package/types/enums/price-list-status.d.ts +4 -0
- package/types/enums/shipping-method-matrix-basis.d.ts +6 -0
- package/types/enums/shipping-method-pricing-type.d.ts +5 -0
- package/types/index.d.ts +30 -0
- package/types/models.d.ts +5470 -404
- package/types/services/carts.d.ts +271 -12
- package/types/services/channels.d.ts +54 -2
- package/types/services/customers.d.ts +295 -12
- package/types/services/inventories.d.ts +440 -0
- package/types/services/markets.d.ts +123 -6
- package/types/services/orders.d.ts +590 -0
- package/types/services/pages.d.ts +792 -0
- package/types/services/payments.d.ts +480 -0
- package/types/services/prices.d.ts +384 -0
- package/types/services/products.d.ts +646 -32
- package/types/services/shipping.d.ts +351 -0
|
@@ -0,0 +1,440 @@
|
|
|
1
|
+
import { Client } from '../client';
|
|
2
|
+
import type { Models } from '../models';
|
|
3
|
+
import { LocationType } from '../enums/location-type';
|
|
4
|
+
export declare class Inventories {
|
|
5
|
+
client: Client;
|
|
6
|
+
constructor(client: Client);
|
|
7
|
+
/**
|
|
8
|
+
*
|
|
9
|
+
* @param {Models.InventoryAdjustItem[]} params.items - The corrections — quantities are SIGNED deltas (at most 200).
|
|
10
|
+
* @param {string} params.reason - Mandatory audit reason — every adjustment is a ledger row.
|
|
11
|
+
* @param {string} params.locationCode - Adjusted location (default 'main').
|
|
12
|
+
* @throws {RevenexxException}
|
|
13
|
+
* @returns {Promise<{}>}
|
|
14
|
+
*/
|
|
15
|
+
inventoriesAdjust(params: {
|
|
16
|
+
items: Models.InventoryAdjustItem[];
|
|
17
|
+
reason: string;
|
|
18
|
+
locationCode?: string;
|
|
19
|
+
}): Promise<{}>;
|
|
20
|
+
/**
|
|
21
|
+
*
|
|
22
|
+
* @param {Models.InventoryAdjustItem[]} items - The corrections — quantities are SIGNED deltas (at most 200).
|
|
23
|
+
* @param {string} reason - Mandatory audit reason — every adjustment is a ledger row.
|
|
24
|
+
* @param {string} locationCode - Adjusted location (default 'main').
|
|
25
|
+
* @throws {RevenexxException}
|
|
26
|
+
* @returns {Promise<{}>}
|
|
27
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
28
|
+
*/
|
|
29
|
+
inventoriesAdjust(items: Models.InventoryAdjustItem[], reason: string, locationCode?: string): Promise<{}>;
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @param {Models.InventoryAvailabilityItem[]} params.items - The items to check (batch, at most 200).
|
|
33
|
+
* @param {string} params.locationCode - Restrict the check to one location (default: all enabled locations).
|
|
34
|
+
* @throws {RevenexxException}
|
|
35
|
+
* @returns {Promise<{}>}
|
|
36
|
+
*/
|
|
37
|
+
inventoriesAvailability(params: {
|
|
38
|
+
items: Models.InventoryAvailabilityItem[];
|
|
39
|
+
locationCode?: string;
|
|
40
|
+
}): Promise<{}>;
|
|
41
|
+
/**
|
|
42
|
+
*
|
|
43
|
+
* @param {Models.InventoryAvailabilityItem[]} items - The items to check (batch, at most 200).
|
|
44
|
+
* @param {string} locationCode - Restrict the check to one location (default: all enabled locations).
|
|
45
|
+
* @throws {RevenexxException}
|
|
46
|
+
* @returns {Promise<{}>}
|
|
47
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
48
|
+
*/
|
|
49
|
+
inventoriesAvailability(items: Models.InventoryAvailabilityItem[], locationCode?: string): Promise<{}>;
|
|
50
|
+
/**
|
|
51
|
+
*
|
|
52
|
+
* @param {string} params.orderRef - The order whose active reservations are committed (shipment).
|
|
53
|
+
* @throws {RevenexxException}
|
|
54
|
+
* @returns {Promise<{}>}
|
|
55
|
+
*/
|
|
56
|
+
inventoriesCommit(params: {
|
|
57
|
+
orderRef: string;
|
|
58
|
+
}): Promise<{}>;
|
|
59
|
+
/**
|
|
60
|
+
*
|
|
61
|
+
* @param {string} orderRef - The order whose active reservations are committed (shipment).
|
|
62
|
+
* @throws {RevenexxException}
|
|
63
|
+
* @returns {Promise<{}>}
|
|
64
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
65
|
+
*/
|
|
66
|
+
inventoriesCommit(orderRef: string): Promise<{}>;
|
|
67
|
+
/**
|
|
68
|
+
*
|
|
69
|
+
* @throws {RevenexxException}
|
|
70
|
+
* @returns {Promise<{}>}
|
|
71
|
+
*/
|
|
72
|
+
inventoriesLocationsList(): Promise<{}>;
|
|
73
|
+
/**
|
|
74
|
+
*
|
|
75
|
+
* @param {string} params.code - Unique location code (per tenant).
|
|
76
|
+
* @param {string} params.name -
|
|
77
|
+
* @param {object} params.address -
|
|
78
|
+
* @param {boolean} params.enabled - Disabled locations are skipped by availability and reserve (default true).
|
|
79
|
+
* @param {object} params.labels - Localised display names ({de, en, …}).
|
|
80
|
+
* @param {object} params.metadata - Free-form metadata.
|
|
81
|
+
* @param {number} params.priority - Sourcing order — lower wins (default 0).
|
|
82
|
+
* @param {LocationType} params.type - Default 'warehouse'.
|
|
83
|
+
* @throws {RevenexxException}
|
|
84
|
+
* @returns {Promise<Models.Location>}
|
|
85
|
+
*/
|
|
86
|
+
inventoriesLocationsCreate(params: {
|
|
87
|
+
code: string;
|
|
88
|
+
name: string;
|
|
89
|
+
address?: object;
|
|
90
|
+
enabled?: boolean;
|
|
91
|
+
labels?: object;
|
|
92
|
+
metadata?: object;
|
|
93
|
+
priority?: number;
|
|
94
|
+
type?: LocationType;
|
|
95
|
+
}): Promise<Models.Location>;
|
|
96
|
+
/**
|
|
97
|
+
*
|
|
98
|
+
* @param {string} code - Unique location code (per tenant).
|
|
99
|
+
* @param {string} name -
|
|
100
|
+
* @param {object} address -
|
|
101
|
+
* @param {boolean} enabled - Disabled locations are skipped by availability and reserve (default true).
|
|
102
|
+
* @param {object} labels - Localised display names ({de, en, …}).
|
|
103
|
+
* @param {object} metadata - Free-form metadata.
|
|
104
|
+
* @param {number} priority - Sourcing order — lower wins (default 0).
|
|
105
|
+
* @param {LocationType} type - Default 'warehouse'.
|
|
106
|
+
* @throws {RevenexxException}
|
|
107
|
+
* @returns {Promise<Models.Location>}
|
|
108
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
109
|
+
*/
|
|
110
|
+
inventoriesLocationsCreate(code: string, name: string, address?: object, enabled?: boolean, labels?: object, metadata?: object, priority?: number, type?: LocationType): Promise<Models.Location>;
|
|
111
|
+
/**
|
|
112
|
+
*
|
|
113
|
+
* @throws {RevenexxException}
|
|
114
|
+
* @returns {Promise<{}>}
|
|
115
|
+
*/
|
|
116
|
+
inventoriesLocationsDefaults(): Promise<{}>;
|
|
117
|
+
/**
|
|
118
|
+
*
|
|
119
|
+
* @param {string} params.id -
|
|
120
|
+
* @throws {RevenexxException}
|
|
121
|
+
* @returns {Promise<{}>}
|
|
122
|
+
*/
|
|
123
|
+
inventoriesLocationsDelete(params: {
|
|
124
|
+
id: string;
|
|
125
|
+
}): Promise<{}>;
|
|
126
|
+
/**
|
|
127
|
+
*
|
|
128
|
+
* @param {string} id -
|
|
129
|
+
* @throws {RevenexxException}
|
|
130
|
+
* @returns {Promise<{}>}
|
|
131
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
132
|
+
*/
|
|
133
|
+
inventoriesLocationsDelete(id: string): Promise<{}>;
|
|
134
|
+
/**
|
|
135
|
+
*
|
|
136
|
+
* @param {string} params.id -
|
|
137
|
+
* @throws {RevenexxException}
|
|
138
|
+
* @returns {Promise<Models.Location>}
|
|
139
|
+
*/
|
|
140
|
+
inventoriesLocationsGet(params: {
|
|
141
|
+
id: string;
|
|
142
|
+
}): Promise<Models.Location>;
|
|
143
|
+
/**
|
|
144
|
+
*
|
|
145
|
+
* @param {string} id -
|
|
146
|
+
* @throws {RevenexxException}
|
|
147
|
+
* @returns {Promise<Models.Location>}
|
|
148
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
149
|
+
*/
|
|
150
|
+
inventoriesLocationsGet(id: string): Promise<Models.Location>;
|
|
151
|
+
/**
|
|
152
|
+
*
|
|
153
|
+
* @param {string} params.id -
|
|
154
|
+
* @param {object} params.address -
|
|
155
|
+
* @param {string} params.code - Unique location code (per tenant).
|
|
156
|
+
* @param {boolean} params.enabled - Disabled locations are skipped by availability and reserve (default true).
|
|
157
|
+
* @param {object} params.labels - Localised display names ({de, en, …}).
|
|
158
|
+
* @param {object} params.metadata - Free-form metadata.
|
|
159
|
+
* @param {string} params.name -
|
|
160
|
+
* @param {number} params.priority - Sourcing order — lower wins (default 0).
|
|
161
|
+
* @param {LocationType} params.type - Default 'warehouse'.
|
|
162
|
+
* @throws {RevenexxException}
|
|
163
|
+
* @returns {Promise<Models.Location>}
|
|
164
|
+
*/
|
|
165
|
+
inventoriesLocationsUpdate(params: {
|
|
166
|
+
id: string;
|
|
167
|
+
address?: object;
|
|
168
|
+
code?: string;
|
|
169
|
+
enabled?: boolean;
|
|
170
|
+
labels?: object;
|
|
171
|
+
metadata?: object;
|
|
172
|
+
name?: string;
|
|
173
|
+
priority?: number;
|
|
174
|
+
type?: LocationType;
|
|
175
|
+
}): Promise<Models.Location>;
|
|
176
|
+
/**
|
|
177
|
+
*
|
|
178
|
+
* @param {string} id -
|
|
179
|
+
* @param {object} address -
|
|
180
|
+
* @param {string} code - Unique location code (per tenant).
|
|
181
|
+
* @param {boolean} enabled - Disabled locations are skipped by availability and reserve (default true).
|
|
182
|
+
* @param {object} labels - Localised display names ({de, en, …}).
|
|
183
|
+
* @param {object} metadata - Free-form metadata.
|
|
184
|
+
* @param {string} name -
|
|
185
|
+
* @param {number} priority - Sourcing order — lower wins (default 0).
|
|
186
|
+
* @param {LocationType} type - Default 'warehouse'.
|
|
187
|
+
* @throws {RevenexxException}
|
|
188
|
+
* @returns {Promise<Models.Location>}
|
|
189
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
190
|
+
*/
|
|
191
|
+
inventoriesLocationsUpdate(id: string, address?: object, code?: string, enabled?: boolean, labels?: object, metadata?: object, name?: string, priority?: number, type?: LocationType): Promise<Models.Location>;
|
|
192
|
+
/**
|
|
193
|
+
*
|
|
194
|
+
* @throws {RevenexxException}
|
|
195
|
+
* @returns {Promise<{}>}
|
|
196
|
+
*/
|
|
197
|
+
inventoriesMovementsList(): Promise<{}>;
|
|
198
|
+
/**
|
|
199
|
+
*
|
|
200
|
+
* @param {string} params.id -
|
|
201
|
+
* @throws {RevenexxException}
|
|
202
|
+
* @returns {Promise<Models.StockMovement>}
|
|
203
|
+
*/
|
|
204
|
+
inventoriesMovementsGet(params: {
|
|
205
|
+
id: string;
|
|
206
|
+
}): Promise<Models.StockMovement>;
|
|
207
|
+
/**
|
|
208
|
+
*
|
|
209
|
+
* @param {string} id -
|
|
210
|
+
* @throws {RevenexxException}
|
|
211
|
+
* @returns {Promise<Models.StockMovement>}
|
|
212
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
213
|
+
*/
|
|
214
|
+
inventoriesMovementsGet(id: string): Promise<Models.StockMovement>;
|
|
215
|
+
/**
|
|
216
|
+
*
|
|
217
|
+
* @param {Models.InventoryStockItem[]} params.items - The inbound items (at most 200).
|
|
218
|
+
* @param {string} params.locationCode - Receiving location (default 'main').
|
|
219
|
+
* @param {string} params.reason - Ledger note (e.g. delivery note number).
|
|
220
|
+
* @throws {RevenexxException}
|
|
221
|
+
* @returns {Promise<{}>}
|
|
222
|
+
*/
|
|
223
|
+
inventoriesReceive(params: {
|
|
224
|
+
items: Models.InventoryStockItem[];
|
|
225
|
+
locationCode?: string;
|
|
226
|
+
reason?: string;
|
|
227
|
+
}): Promise<{}>;
|
|
228
|
+
/**
|
|
229
|
+
*
|
|
230
|
+
* @param {Models.InventoryStockItem[]} items - The inbound items (at most 200).
|
|
231
|
+
* @param {string} locationCode - Receiving location (default 'main').
|
|
232
|
+
* @param {string} reason - Ledger note (e.g. delivery note number).
|
|
233
|
+
* @throws {RevenexxException}
|
|
234
|
+
* @returns {Promise<{}>}
|
|
235
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
236
|
+
*/
|
|
237
|
+
inventoriesReceive(items: Models.InventoryStockItem[], locationCode?: string, reason?: string): Promise<{}>;
|
|
238
|
+
/**
|
|
239
|
+
*
|
|
240
|
+
* @param {string} params.orderRef - The order whose active reservations are released.
|
|
241
|
+
* @throws {RevenexxException}
|
|
242
|
+
* @returns {Promise<{}>}
|
|
243
|
+
*/
|
|
244
|
+
inventoriesRelease(params: {
|
|
245
|
+
orderRef: string;
|
|
246
|
+
}): Promise<{}>;
|
|
247
|
+
/**
|
|
248
|
+
*
|
|
249
|
+
* @param {string} orderRef - The order whose active reservations are released.
|
|
250
|
+
* @throws {RevenexxException}
|
|
251
|
+
* @returns {Promise<{}>}
|
|
252
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
253
|
+
*/
|
|
254
|
+
inventoriesRelease(orderRef: string): Promise<{}>;
|
|
255
|
+
/**
|
|
256
|
+
*
|
|
257
|
+
* @throws {RevenexxException}
|
|
258
|
+
* @returns {Promise<{}>}
|
|
259
|
+
*/
|
|
260
|
+
inventoriesReservationsList(): Promise<{}>;
|
|
261
|
+
/**
|
|
262
|
+
*
|
|
263
|
+
* @param {string} params.id -
|
|
264
|
+
* @throws {RevenexxException}
|
|
265
|
+
* @returns {Promise<Models.Reservation>}
|
|
266
|
+
*/
|
|
267
|
+
inventoriesReservationsGet(params: {
|
|
268
|
+
id: string;
|
|
269
|
+
}): Promise<Models.Reservation>;
|
|
270
|
+
/**
|
|
271
|
+
*
|
|
272
|
+
* @param {string} id -
|
|
273
|
+
* @throws {RevenexxException}
|
|
274
|
+
* @returns {Promise<Models.Reservation>}
|
|
275
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
276
|
+
*/
|
|
277
|
+
inventoriesReservationsGet(id: string): Promise<Models.Reservation>;
|
|
278
|
+
/**
|
|
279
|
+
*
|
|
280
|
+
* @param {Models.InventoryStockItem[]} params.items - The items to reserve — all-or-nothing (at most 200).
|
|
281
|
+
* @param {string} params.orderRef - The order this reservation belongs to.
|
|
282
|
+
* @param {string} params.expiresAt - Optional reservation expiry.
|
|
283
|
+
* @throws {RevenexxException}
|
|
284
|
+
* @returns {Promise<{}>}
|
|
285
|
+
*/
|
|
286
|
+
inventoriesReserve(params: {
|
|
287
|
+
items: Models.InventoryStockItem[];
|
|
288
|
+
orderRef: string;
|
|
289
|
+
expiresAt?: string;
|
|
290
|
+
}): Promise<{}>;
|
|
291
|
+
/**
|
|
292
|
+
*
|
|
293
|
+
* @param {Models.InventoryStockItem[]} items - The items to reserve — all-or-nothing (at most 200).
|
|
294
|
+
* @param {string} orderRef - The order this reservation belongs to.
|
|
295
|
+
* @param {string} expiresAt - Optional reservation expiry.
|
|
296
|
+
* @throws {RevenexxException}
|
|
297
|
+
* @returns {Promise<{}>}
|
|
298
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
299
|
+
*/
|
|
300
|
+
inventoriesReserve(items: Models.InventoryStockItem[], orderRef: string, expiresAt?: string): Promise<{}>;
|
|
301
|
+
/**
|
|
302
|
+
*
|
|
303
|
+
* @param {Models.InventoryStockItem[]} params.items - The returned items (at most 200).
|
|
304
|
+
* @param {string} params.locationCode - Restocking location (default 'main').
|
|
305
|
+
* @param {string} params.orderRef - Originating order (ledger reference).
|
|
306
|
+
* @param {string} params.reason - Ledger note (e.g. return reason).
|
|
307
|
+
* @throws {RevenexxException}
|
|
308
|
+
* @returns {Promise<{}>}
|
|
309
|
+
*/
|
|
310
|
+
inventoriesRestock(params: {
|
|
311
|
+
items: Models.InventoryStockItem[];
|
|
312
|
+
locationCode?: string;
|
|
313
|
+
orderRef?: string;
|
|
314
|
+
reason?: string;
|
|
315
|
+
}): Promise<{}>;
|
|
316
|
+
/**
|
|
317
|
+
*
|
|
318
|
+
* @param {Models.InventoryStockItem[]} items - The returned items (at most 200).
|
|
319
|
+
* @param {string} locationCode - Restocking location (default 'main').
|
|
320
|
+
* @param {string} orderRef - Originating order (ledger reference).
|
|
321
|
+
* @param {string} reason - Ledger note (e.g. return reason).
|
|
322
|
+
* @throws {RevenexxException}
|
|
323
|
+
* @returns {Promise<{}>}
|
|
324
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
325
|
+
*/
|
|
326
|
+
inventoriesRestock(items: Models.InventoryStockItem[], locationCode?: string, orderRef?: string, reason?: string): Promise<{}>;
|
|
327
|
+
/**
|
|
328
|
+
*
|
|
329
|
+
* @throws {RevenexxException}
|
|
330
|
+
* @returns {Promise<{}>}
|
|
331
|
+
*/
|
|
332
|
+
inventoriesStockList(): Promise<{}>;
|
|
333
|
+
/**
|
|
334
|
+
*
|
|
335
|
+
* @param {string} params.locationId - Owning location.
|
|
336
|
+
* @param {object} params.metadata - Free-form metadata.
|
|
337
|
+
* @param {number} params.onHand - Physical stock (default 0).
|
|
338
|
+
* @param {string} params.productId - Tracked product.
|
|
339
|
+
* @param {number} params.reorderPoint -
|
|
340
|
+
* @param {number} params.reserved - Reserved stock (default 0) — normally managed by reserve/release/commit.
|
|
341
|
+
* @param {string} params.sku - Tracked SKU (alternative to product_id).
|
|
342
|
+
* @throws {RevenexxException}
|
|
343
|
+
* @returns {Promise<Models.StockLevel>}
|
|
344
|
+
*/
|
|
345
|
+
inventoriesStockCreate(params: {
|
|
346
|
+
locationId: string;
|
|
347
|
+
metadata?: object;
|
|
348
|
+
onHand?: number;
|
|
349
|
+
productId?: string;
|
|
350
|
+
reorderPoint?: number;
|
|
351
|
+
reserved?: number;
|
|
352
|
+
sku?: string;
|
|
353
|
+
}): Promise<Models.StockLevel>;
|
|
354
|
+
/**
|
|
355
|
+
*
|
|
356
|
+
* @param {string} locationId - Owning location.
|
|
357
|
+
* @param {object} metadata - Free-form metadata.
|
|
358
|
+
* @param {number} onHand - Physical stock (default 0).
|
|
359
|
+
* @param {string} productId - Tracked product.
|
|
360
|
+
* @param {number} reorderPoint -
|
|
361
|
+
* @param {number} reserved - Reserved stock (default 0) — normally managed by reserve/release/commit.
|
|
362
|
+
* @param {string} sku - Tracked SKU (alternative to product_id).
|
|
363
|
+
* @throws {RevenexxException}
|
|
364
|
+
* @returns {Promise<Models.StockLevel>}
|
|
365
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
366
|
+
*/
|
|
367
|
+
inventoriesStockCreate(locationId: string, metadata?: object, onHand?: number, productId?: string, reorderPoint?: number, reserved?: number, sku?: string): Promise<Models.StockLevel>;
|
|
368
|
+
/**
|
|
369
|
+
*
|
|
370
|
+
* @param {string} params.id -
|
|
371
|
+
* @throws {RevenexxException}
|
|
372
|
+
* @returns {Promise<{}>}
|
|
373
|
+
*/
|
|
374
|
+
inventoriesStockDelete(params: {
|
|
375
|
+
id: string;
|
|
376
|
+
}): Promise<{}>;
|
|
377
|
+
/**
|
|
378
|
+
*
|
|
379
|
+
* @param {string} id -
|
|
380
|
+
* @throws {RevenexxException}
|
|
381
|
+
* @returns {Promise<{}>}
|
|
382
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
383
|
+
*/
|
|
384
|
+
inventoriesStockDelete(id: string): Promise<{}>;
|
|
385
|
+
/**
|
|
386
|
+
*
|
|
387
|
+
* @param {string} params.id -
|
|
388
|
+
* @throws {RevenexxException}
|
|
389
|
+
* @returns {Promise<Models.StockLevel>}
|
|
390
|
+
*/
|
|
391
|
+
inventoriesStockGet(params: {
|
|
392
|
+
id: string;
|
|
393
|
+
}): Promise<Models.StockLevel>;
|
|
394
|
+
/**
|
|
395
|
+
*
|
|
396
|
+
* @param {string} id -
|
|
397
|
+
* @throws {RevenexxException}
|
|
398
|
+
* @returns {Promise<Models.StockLevel>}
|
|
399
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
400
|
+
*/
|
|
401
|
+
inventoriesStockGet(id: string): Promise<Models.StockLevel>;
|
|
402
|
+
/**
|
|
403
|
+
*
|
|
404
|
+
* @param {string} params.id -
|
|
405
|
+
* @param {string} params.locationId - Owning location.
|
|
406
|
+
* @param {object} params.metadata - Free-form metadata.
|
|
407
|
+
* @param {number} params.onHand - Physical stock (default 0).
|
|
408
|
+
* @param {string} params.productId - Tracked product.
|
|
409
|
+
* @param {number} params.reorderPoint -
|
|
410
|
+
* @param {number} params.reserved - Reserved stock (default 0) — normally managed by reserve/release/commit.
|
|
411
|
+
* @param {string} params.sku - Tracked SKU (alternative to product_id).
|
|
412
|
+
* @throws {RevenexxException}
|
|
413
|
+
* @returns {Promise<Models.StockLevel>}
|
|
414
|
+
*/
|
|
415
|
+
inventoriesStockUpdate(params: {
|
|
416
|
+
id: string;
|
|
417
|
+
locationId?: string;
|
|
418
|
+
metadata?: object;
|
|
419
|
+
onHand?: number;
|
|
420
|
+
productId?: string;
|
|
421
|
+
reorderPoint?: number;
|
|
422
|
+
reserved?: number;
|
|
423
|
+
sku?: string;
|
|
424
|
+
}): Promise<Models.StockLevel>;
|
|
425
|
+
/**
|
|
426
|
+
*
|
|
427
|
+
* @param {string} id -
|
|
428
|
+
* @param {string} locationId - Owning location.
|
|
429
|
+
* @param {object} metadata - Free-form metadata.
|
|
430
|
+
* @param {number} onHand - Physical stock (default 0).
|
|
431
|
+
* @param {string} productId - Tracked product.
|
|
432
|
+
* @param {number} reorderPoint -
|
|
433
|
+
* @param {number} reserved - Reserved stock (default 0) — normally managed by reserve/release/commit.
|
|
434
|
+
* @param {string} sku - Tracked SKU (alternative to product_id).
|
|
435
|
+
* @throws {RevenexxException}
|
|
436
|
+
* @returns {Promise<Models.StockLevel>}
|
|
437
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
438
|
+
*/
|
|
439
|
+
inventoriesStockUpdate(id: string, locationId?: string, metadata?: object, onHand?: number, productId?: string, reorderPoint?: number, reserved?: number, sku?: string): Promise<Models.StockLevel>;
|
|
440
|
+
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Client } from '../client';
|
|
2
2
|
import type { Models } from '../models';
|
|
3
|
+
import { MarketStatus } from '../enums/market-status';
|
|
3
4
|
export declare class Markets {
|
|
4
5
|
client: Client;
|
|
5
6
|
constructor(client: Client);
|
|
@@ -11,10 +12,39 @@ export declare class Markets {
|
|
|
11
12
|
marketsList(): Promise<{}>;
|
|
12
13
|
/**
|
|
13
14
|
*
|
|
15
|
+
* @param {string} params.code - Market code (unique per tenant).
|
|
16
|
+
* @param {string} params.name -
|
|
17
|
+
* @param {string} params.currency - ISO 4217 code (default 'EUR').
|
|
18
|
+
* @param {boolean} params.isDefault -
|
|
19
|
+
* @param {object} params.labels - Localized display names ({locale: label}).
|
|
20
|
+
* @param {number} params.position - Sort position (default 0).
|
|
21
|
+
* @param {MarketStatus} params.status - Default 'active'.
|
|
14
22
|
* @throws {RevenexxException}
|
|
15
23
|
* @returns {Promise<Models.Market>}
|
|
16
24
|
*/
|
|
17
|
-
marketsCreate(
|
|
25
|
+
marketsCreate(params: {
|
|
26
|
+
code: string;
|
|
27
|
+
name: string;
|
|
28
|
+
currency?: string;
|
|
29
|
+
isDefault?: boolean;
|
|
30
|
+
labels?: object;
|
|
31
|
+
position?: number;
|
|
32
|
+
status?: MarketStatus;
|
|
33
|
+
}): Promise<Models.Market>;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @param {string} code - Market code (unique per tenant).
|
|
37
|
+
* @param {string} name -
|
|
38
|
+
* @param {string} currency - ISO 4217 code (default 'EUR').
|
|
39
|
+
* @param {boolean} isDefault -
|
|
40
|
+
* @param {object} labels - Localized display names ({locale: label}).
|
|
41
|
+
* @param {number} position - Sort position (default 0).
|
|
42
|
+
* @param {MarketStatus} status - Default 'active'.
|
|
43
|
+
* @throws {RevenexxException}
|
|
44
|
+
* @returns {Promise<Models.Market>}
|
|
45
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
46
|
+
*/
|
|
47
|
+
marketsCreate(code: string, name: string, currency?: string, isDefault?: boolean, labels?: object, position?: number, status?: MarketStatus): Promise<Models.Market>;
|
|
18
48
|
/**
|
|
19
49
|
*
|
|
20
50
|
* @param {string} params.id -
|
|
@@ -52,20 +82,41 @@ export declare class Markets {
|
|
|
52
82
|
/**
|
|
53
83
|
*
|
|
54
84
|
* @param {string} params.id -
|
|
85
|
+
* @param {string} params.code - Market code (unique per tenant).
|
|
86
|
+
* @param {string} params.currency - ISO 4217 code (default 'EUR').
|
|
87
|
+
* @param {boolean} params.isDefault -
|
|
88
|
+
* @param {object} params.labels - Localized display names ({locale: label}).
|
|
89
|
+
* @param {string} params.name -
|
|
90
|
+
* @param {number} params.position - Sort position (default 0).
|
|
91
|
+
* @param {MarketStatus} params.status - Default 'active'.
|
|
55
92
|
* @throws {RevenexxException}
|
|
56
93
|
* @returns {Promise<Models.Market>}
|
|
57
94
|
*/
|
|
58
95
|
marketsUpdate(params: {
|
|
59
96
|
id: string;
|
|
97
|
+
code?: string;
|
|
98
|
+
currency?: string;
|
|
99
|
+
isDefault?: boolean;
|
|
100
|
+
labels?: object;
|
|
101
|
+
name?: string;
|
|
102
|
+
position?: number;
|
|
103
|
+
status?: MarketStatus;
|
|
60
104
|
}): Promise<Models.Market>;
|
|
61
105
|
/**
|
|
62
106
|
*
|
|
63
107
|
* @param {string} id -
|
|
108
|
+
* @param {string} code - Market code (unique per tenant).
|
|
109
|
+
* @param {string} currency - ISO 4217 code (default 'EUR').
|
|
110
|
+
* @param {boolean} isDefault -
|
|
111
|
+
* @param {object} labels - Localized display names ({locale: label}).
|
|
112
|
+
* @param {string} name -
|
|
113
|
+
* @param {number} position - Sort position (default 0).
|
|
114
|
+
* @param {MarketStatus} status - Default 'active'.
|
|
64
115
|
* @throws {RevenexxException}
|
|
65
116
|
* @returns {Promise<Models.Market>}
|
|
66
117
|
* @deprecated Use the object parameter style method for a better developer experience.
|
|
67
118
|
*/
|
|
68
|
-
marketsUpdate(id: string): Promise<Models.Market>;
|
|
119
|
+
marketsUpdate(id: string, code?: string, currency?: string, isDefault?: boolean, labels?: object, name?: string, position?: number, status?: MarketStatus): Promise<Models.Market>;
|
|
69
120
|
/**
|
|
70
121
|
*
|
|
71
122
|
* @param {string} params.id -
|
|
@@ -103,20 +154,35 @@ export declare class Markets {
|
|
|
103
154
|
/**
|
|
104
155
|
*
|
|
105
156
|
* @param {string} params.marketId -
|
|
157
|
+
* @param {string} params.code - Locale code, e.g. 'de-DE' (unique per market).
|
|
158
|
+
* @param {string} params.country - ISO 3166-1 alpha-2 country code.
|
|
159
|
+
* @param {string} params.language - ISO 639-1 language code.
|
|
160
|
+
* @param {boolean} params.isDefault -
|
|
161
|
+
* @param {number} params.position - Sort position (default 0).
|
|
106
162
|
* @throws {RevenexxException}
|
|
107
163
|
* @returns {Promise<Models.MarketLocale>}
|
|
108
164
|
*/
|
|
109
165
|
marketsLocalesCreate(params: {
|
|
110
166
|
marketId: string;
|
|
167
|
+
code: string;
|
|
168
|
+
country: string;
|
|
169
|
+
language: string;
|
|
170
|
+
isDefault?: boolean;
|
|
171
|
+
position?: number;
|
|
111
172
|
}): Promise<Models.MarketLocale>;
|
|
112
173
|
/**
|
|
113
174
|
*
|
|
114
175
|
* @param {string} marketId -
|
|
176
|
+
* @param {string} code - Locale code, e.g. 'de-DE' (unique per market).
|
|
177
|
+
* @param {string} country - ISO 3166-1 alpha-2 country code.
|
|
178
|
+
* @param {string} language - ISO 639-1 language code.
|
|
179
|
+
* @param {boolean} isDefault -
|
|
180
|
+
* @param {number} position - Sort position (default 0).
|
|
115
181
|
* @throws {RevenexxException}
|
|
116
182
|
* @returns {Promise<Models.MarketLocale>}
|
|
117
183
|
* @deprecated Use the object parameter style method for a better developer experience.
|
|
118
184
|
*/
|
|
119
|
-
marketsLocalesCreate(marketId: string): Promise<Models.MarketLocale>;
|
|
185
|
+
marketsLocalesCreate(marketId: string, code: string, country: string, language: string, isDefault?: boolean, position?: number): Promise<Models.MarketLocale>;
|
|
120
186
|
/**
|
|
121
187
|
*
|
|
122
188
|
* @param {string} params.marketId -
|
|
@@ -161,22 +227,37 @@ export declare class Markets {
|
|
|
161
227
|
*
|
|
162
228
|
* @param {string} params.marketId -
|
|
163
229
|
* @param {string} params.id -
|
|
230
|
+
* @param {string} params.code - Locale code, e.g. 'de-DE' (unique per market).
|
|
231
|
+
* @param {string} params.country - ISO 3166-1 alpha-2 country code.
|
|
232
|
+
* @param {boolean} params.isDefault -
|
|
233
|
+
* @param {string} params.language - ISO 639-1 language code.
|
|
234
|
+
* @param {number} params.position - Sort position (default 0).
|
|
164
235
|
* @throws {RevenexxException}
|
|
165
236
|
* @returns {Promise<Models.MarketLocale>}
|
|
166
237
|
*/
|
|
167
238
|
marketsLocalesUpdate(params: {
|
|
168
239
|
marketId: string;
|
|
169
240
|
id: string;
|
|
241
|
+
code?: string;
|
|
242
|
+
country?: string;
|
|
243
|
+
isDefault?: boolean;
|
|
244
|
+
language?: string;
|
|
245
|
+
position?: number;
|
|
170
246
|
}): Promise<Models.MarketLocale>;
|
|
171
247
|
/**
|
|
172
248
|
*
|
|
173
249
|
* @param {string} marketId -
|
|
174
250
|
* @param {string} id -
|
|
251
|
+
* @param {string} code - Locale code, e.g. 'de-DE' (unique per market).
|
|
252
|
+
* @param {string} country - ISO 3166-1 alpha-2 country code.
|
|
253
|
+
* @param {boolean} isDefault -
|
|
254
|
+
* @param {string} language - ISO 639-1 language code.
|
|
255
|
+
* @param {number} position - Sort position (default 0).
|
|
175
256
|
* @throws {RevenexxException}
|
|
176
257
|
* @returns {Promise<Models.MarketLocale>}
|
|
177
258
|
* @deprecated Use the object parameter style method for a better developer experience.
|
|
178
259
|
*/
|
|
179
|
-
marketsLocalesUpdate(marketId: string, id: string): Promise<Models.MarketLocale>;
|
|
260
|
+
marketsLocalesUpdate(marketId: string, id: string, code?: string, country?: string, isDefault?: boolean, language?: string, position?: number): Promise<Models.MarketLocale>;
|
|
180
261
|
/**
|
|
181
262
|
*
|
|
182
263
|
* @param {string} params.marketId -
|
|
@@ -197,20 +278,38 @@ export declare class Markets {
|
|
|
197
278
|
/**
|
|
198
279
|
*
|
|
199
280
|
* @param {string} params.marketId -
|
|
281
|
+
* @param {string} params.code - Tax class code (unique per market).
|
|
282
|
+
* @param {string} params.name -
|
|
283
|
+
* @param {boolean} params.isDefault -
|
|
284
|
+
* @param {object} params.labels - Localized display names ({locale: label}).
|
|
285
|
+
* @param {number} params.position - Sort position (default 0).
|
|
286
|
+
* @param {number} params.rate - Tax rate in percent, 0–100 (default 0).
|
|
200
287
|
* @throws {RevenexxException}
|
|
201
288
|
* @returns {Promise<Models.MarketTaxClass>}
|
|
202
289
|
*/
|
|
203
290
|
marketsTaxClassesCreate(params: {
|
|
204
291
|
marketId: string;
|
|
292
|
+
code: string;
|
|
293
|
+
name: string;
|
|
294
|
+
isDefault?: boolean;
|
|
295
|
+
labels?: object;
|
|
296
|
+
position?: number;
|
|
297
|
+
rate?: number;
|
|
205
298
|
}): Promise<Models.MarketTaxClass>;
|
|
206
299
|
/**
|
|
207
300
|
*
|
|
208
301
|
* @param {string} marketId -
|
|
302
|
+
* @param {string} code - Tax class code (unique per market).
|
|
303
|
+
* @param {string} name -
|
|
304
|
+
* @param {boolean} isDefault -
|
|
305
|
+
* @param {object} labels - Localized display names ({locale: label}).
|
|
306
|
+
* @param {number} position - Sort position (default 0).
|
|
307
|
+
* @param {number} rate - Tax rate in percent, 0–100 (default 0).
|
|
209
308
|
* @throws {RevenexxException}
|
|
210
309
|
* @returns {Promise<Models.MarketTaxClass>}
|
|
211
310
|
* @deprecated Use the object parameter style method for a better developer experience.
|
|
212
311
|
*/
|
|
213
|
-
marketsTaxClassesCreate(marketId: string): Promise<Models.MarketTaxClass>;
|
|
312
|
+
marketsTaxClassesCreate(marketId: string, code: string, name: string, isDefault?: boolean, labels?: object, position?: number, rate?: number): Promise<Models.MarketTaxClass>;
|
|
214
313
|
/**
|
|
215
314
|
*
|
|
216
315
|
* @param {string} params.marketId -
|
|
@@ -255,20 +354,38 @@ export declare class Markets {
|
|
|
255
354
|
*
|
|
256
355
|
* @param {string} params.marketId -
|
|
257
356
|
* @param {string} params.id -
|
|
357
|
+
* @param {string} params.code - Tax class code (unique per market).
|
|
358
|
+
* @param {boolean} params.isDefault -
|
|
359
|
+
* @param {object} params.labels - Localized display names ({locale: label}).
|
|
360
|
+
* @param {string} params.name -
|
|
361
|
+
* @param {number} params.position - Sort position (default 0).
|
|
362
|
+
* @param {number} params.rate - Tax rate in percent, 0–100 (default 0).
|
|
258
363
|
* @throws {RevenexxException}
|
|
259
364
|
* @returns {Promise<Models.MarketTaxClass>}
|
|
260
365
|
*/
|
|
261
366
|
marketsTaxClassesUpdate(params: {
|
|
262
367
|
marketId: string;
|
|
263
368
|
id: string;
|
|
369
|
+
code?: string;
|
|
370
|
+
isDefault?: boolean;
|
|
371
|
+
labels?: object;
|
|
372
|
+
name?: string;
|
|
373
|
+
position?: number;
|
|
374
|
+
rate?: number;
|
|
264
375
|
}): Promise<Models.MarketTaxClass>;
|
|
265
376
|
/**
|
|
266
377
|
*
|
|
267
378
|
* @param {string} marketId -
|
|
268
379
|
* @param {string} id -
|
|
380
|
+
* @param {string} code - Tax class code (unique per market).
|
|
381
|
+
* @param {boolean} isDefault -
|
|
382
|
+
* @param {object} labels - Localized display names ({locale: label}).
|
|
383
|
+
* @param {string} name -
|
|
384
|
+
* @param {number} position - Sort position (default 0).
|
|
385
|
+
* @param {number} rate - Tax rate in percent, 0–100 (default 0).
|
|
269
386
|
* @throws {RevenexxException}
|
|
270
387
|
* @returns {Promise<Models.MarketTaxClass>}
|
|
271
388
|
* @deprecated Use the object parameter style method for a better developer experience.
|
|
272
389
|
*/
|
|
273
|
-
marketsTaxClassesUpdate(marketId: string, id: string): Promise<Models.MarketTaxClass>;
|
|
390
|
+
marketsTaxClassesUpdate(marketId: string, id: string, code?: string, isDefault?: boolean, labels?: object, name?: string, position?: number, rate?: number): Promise<Models.MarketTaxClass>;
|
|
274
391
|
}
|