@sp-api-sdk/external-fulfillment-inventory-api-2024-09-11 1.1.12 → 2.1.0

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 (71) hide show
  1. package/README.md +7 -8
  2. package/dist/index.cjs +315 -0
  3. package/dist/index.cjs.map +1 -0
  4. package/dist/index.d.cts +429 -0
  5. package/dist/index.d.ts +429 -0
  6. package/dist/index.js +284 -0
  7. package/dist/index.js.map +1 -0
  8. package/package.json +26 -12
  9. package/dist/cjs/api-model/api/external-fulfillment-inventory-api.js +0 -117
  10. package/dist/cjs/api-model/api.js +0 -30
  11. package/dist/cjs/api-model/base.js +0 -52
  12. package/dist/cjs/api-model/common.js +0 -123
  13. package/dist/cjs/api-model/configuration.js +0 -98
  14. package/dist/cjs/api-model/index.js +0 -32
  15. package/dist/cjs/api-model/models/actionable-error.js +0 -15
  16. package/dist/cjs/api-model/models/batch-inventory-request.js +0 -15
  17. package/dist/cjs/api-model/models/batch-inventory-response.js +0 -15
  18. package/dist/cjs/api-model/models/error-list.js +0 -15
  19. package/dist/cjs/api-model/models/http-method.js +0 -23
  20. package/dist/cjs/api-model/models/http-status-line.js +0 -15
  21. package/dist/cjs/api-model/models/index.js +0 -28
  22. package/dist/cjs/api-model/models/inventory-request-params.js +0 -15
  23. package/dist/cjs/api-model/models/inventory-request.js +0 -15
  24. package/dist/cjs/api-model/models/inventory-response-body.js +0 -15
  25. package/dist/cjs/api-model/models/inventory-response.js +0 -15
  26. package/dist/cjs/api-model/models/marketplace-attributes.js +0 -21
  27. package/dist/cjs/api-model/models/model-error.js +0 -15
  28. package/dist/cjs/client.js +0 -13
  29. package/dist/cjs/index.js +0 -19
  30. package/dist/es/api-model/api/external-fulfillment-inventory-api.js +0 -107
  31. package/dist/es/api-model/api.js +0 -14
  32. package/dist/es/api-model/base.js +0 -44
  33. package/dist/es/api-model/common.js +0 -110
  34. package/dist/es/api-model/configuration.js +0 -94
  35. package/dist/es/api-model/index.js +0 -16
  36. package/dist/es/api-model/models/actionable-error.js +0 -14
  37. package/dist/es/api-model/models/batch-inventory-request.js +0 -14
  38. package/dist/es/api-model/models/batch-inventory-response.js +0 -14
  39. package/dist/es/api-model/models/error-list.js +0 -14
  40. package/dist/es/api-model/models/http-method.js +0 -20
  41. package/dist/es/api-model/models/http-status-line.js +0 -14
  42. package/dist/es/api-model/models/index.js +0 -12
  43. package/dist/es/api-model/models/inventory-request-params.js +0 -14
  44. package/dist/es/api-model/models/inventory-request.js +0 -14
  45. package/dist/es/api-model/models/inventory-response-body.js +0 -14
  46. package/dist/es/api-model/models/inventory-response.js +0 -14
  47. package/dist/es/api-model/models/marketplace-attributes.js +0 -18
  48. package/dist/es/api-model/models/model-error.js +0 -14
  49. package/dist/es/client.js +0 -9
  50. package/dist/es/index.js +0 -3
  51. package/dist/types/api-model/api/external-fulfillment-inventory-api.d.ts +0 -74
  52. package/dist/types/api-model/api.d.ts +0 -12
  53. package/dist/types/api-model/base.d.ts +0 -42
  54. package/dist/types/api-model/common.d.ts +0 -34
  55. package/dist/types/api-model/configuration.d.ts +0 -98
  56. package/dist/types/api-model/index.d.ts +0 -14
  57. package/dist/types/api-model/models/actionable-error.d.ts +0 -24
  58. package/dist/types/api-model/models/batch-inventory-request.d.ts +0 -21
  59. package/dist/types/api-model/models/batch-inventory-response.d.ts +0 -21
  60. package/dist/types/api-model/models/error-list.d.ts +0 -20
  61. package/dist/types/api-model/models/http-method.d.ts +0 -19
  62. package/dist/types/api-model/models/http-status-line.d.ts +0 -24
  63. package/dist/types/api-model/models/index.d.ts +0 -12
  64. package/dist/types/api-model/models/inventory-request-params.d.ts +0 -26
  65. package/dist/types/api-model/models/inventory-request.d.ts +0 -24
  66. package/dist/types/api-model/models/inventory-response-body.d.ts +0 -43
  67. package/dist/types/api-model/models/inventory-response.d.ts +0 -20
  68. package/dist/types/api-model/models/marketplace-attributes.d.ts +0 -30
  69. package/dist/types/api-model/models/model-error.d.ts +0 -28
  70. package/dist/types/client.d.ts +0 -6
  71. package/dist/types/index.d.ts +0 -3
@@ -0,0 +1,429 @@
1
+ import { ClientConfiguration, RateLimit } from "@sp-api-sdk/common";
2
+ import { AxiosInstance, AxiosPromise, RawAxiosRequestConfig } from "axios";
3
+ //#region src/api-model/configuration.d.ts
4
+ /**
5
+ * The Selling Partner API for External Fulfillment Inventory Management
6
+ * You can use the Amazon External Fulfillment Inventory API to manage inventory operations in Amazon\'s External Fulfillment network, including batch inventory updates and retrievals.
7
+ *
8
+ * The version of the OpenAPI document: 2024-09-11
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ interface AWSv4Configuration {
16
+ options?: {
17
+ region?: string;
18
+ service?: string;
19
+ };
20
+ credentials?: {
21
+ accessKeyId?: string;
22
+ secretAccessKey?: string;
23
+ sessionToken?: string;
24
+ };
25
+ }
26
+ interface ConfigurationParameters {
27
+ apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);
28
+ username?: string;
29
+ password?: string;
30
+ accessToken?: string | Promise<string> | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise<string>);
31
+ awsv4?: AWSv4Configuration;
32
+ basePath?: string;
33
+ serverIndex?: number;
34
+ baseOptions?: any;
35
+ formDataCtor?: new () => any;
36
+ }
37
+ declare class Configuration {
38
+ /**
39
+ * parameter for apiKey security
40
+ * @param name security name
41
+ */
42
+ apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);
43
+ /**
44
+ * parameter for basic security
45
+ */
46
+ username?: string;
47
+ /**
48
+ * parameter for basic security
49
+ */
50
+ password?: string;
51
+ /**
52
+ * parameter for oauth2 security
53
+ * @param name security name
54
+ * @param scopes oauth2 scope
55
+ */
56
+ accessToken?: string | Promise<string> | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise<string>);
57
+ /**
58
+ * parameter for aws4 signature security
59
+ * @param {Object} AWS4Signature - AWS4 Signature security
60
+ * @param {string} options.region - aws region
61
+ * @param {string} options.service - name of the service.
62
+ * @param {string} credentials.accessKeyId - aws access key id
63
+ * @param {string} credentials.secretAccessKey - aws access key
64
+ * @param {string} credentials.sessionToken - aws session token
65
+ * @memberof Configuration
66
+ */
67
+ awsv4?: AWSv4Configuration;
68
+ /**
69
+ * override base path
70
+ */
71
+ basePath?: string;
72
+ /**
73
+ * override server index
74
+ */
75
+ serverIndex?: number;
76
+ /**
77
+ * base options for axios calls
78
+ */
79
+ baseOptions?: any;
80
+ /**
81
+ * The FormData constructor that will be used to create multipart form data
82
+ * requests. You can inject this here so that execution environments that
83
+ * do not support the FormData class can still run the generated client.
84
+ *
85
+ * @type {new () => FormData}
86
+ */
87
+ formDataCtor?: new () => any;
88
+ constructor(param?: ConfigurationParameters);
89
+ /**
90
+ * Check if the given MIME is a JSON MIME.
91
+ * JSON MIME examples:
92
+ * application/json
93
+ * application/json; charset=UTF8
94
+ * APPLICATION/JSON
95
+ * application/vnd.company+json
96
+ * @param mime - MIME (Multipurpose Internet Mail Extensions)
97
+ * @return True if the given MIME is JSON, false otherwise.
98
+ */
99
+ isJsonMime(mime: string): boolean;
100
+ }
101
+ //#endregion
102
+ //#region src/api-model/base.d.ts
103
+ interface RequestArgs {
104
+ url: string;
105
+ options: RawAxiosRequestConfig;
106
+ }
107
+ declare class BaseAPI {
108
+ protected basePath: string;
109
+ protected axios: AxiosInstance;
110
+ protected configuration: Configuration | undefined;
111
+ constructor(configuration?: Configuration, basePath?: string, axios?: AxiosInstance);
112
+ }
113
+ //#endregion
114
+ //#region src/api-model/models/actionable-error.d.ts
115
+ /**
116
+ * The Selling Partner API for External Fulfillment Inventory Management
117
+ * You can use the Amazon External Fulfillment Inventory API to manage inventory operations in Amazon\'s External Fulfillment network, including batch inventory updates and retrievals.
118
+ *
119
+ * The version of the OpenAPI document: 2024-09-11
120
+ *
121
+ *
122
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
123
+ * https://openapi-generator.tech
124
+ * Do not edit the class manually.
125
+ */
126
+ /**
127
+ * Error details you can take action on.
128
+ */
129
+ interface ActionableError {
130
+ /**
131
+ * The top level error type that may contain multiple error subtypes.
132
+ */
133
+ 'errorType'?: string;
134
+ /**
135
+ * The secondary level error type.
136
+ */
137
+ 'errorSubType'?: string;
138
+ }
139
+ //#endregion
140
+ //#region src/api-model/models/http-method.d.ts
141
+ /**
142
+ * The Selling Partner API for External Fulfillment Inventory Management
143
+ * You can use the Amazon External Fulfillment Inventory API to manage inventory operations in Amazon\'s External Fulfillment network, including batch inventory updates and retrievals.
144
+ *
145
+ * The version of the OpenAPI document: 2024-09-11
146
+ *
147
+ *
148
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
149
+ * https://openapi-generator.tech
150
+ * Do not edit the class manually.
151
+ */
152
+ /**
153
+ * The HTTP method associated with an individual request within a batch.
154
+ */
155
+ declare const HttpMethod: {
156
+ readonly Get: "GET";
157
+ readonly Post: "POST";
158
+ };
159
+ type HttpMethod = typeof HttpMethod[keyof typeof HttpMethod];
160
+ //#endregion
161
+ //#region src/api-model/models/marketplace-attributes.d.ts
162
+ /**
163
+ * The Selling Partner API for External Fulfillment Inventory Management
164
+ * You can use the Amazon External Fulfillment Inventory API to manage inventory operations in Amazon\'s External Fulfillment network, including batch inventory updates and retrievals.
165
+ *
166
+ * The version of the OpenAPI document: 2024-09-11
167
+ *
168
+ *
169
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
170
+ * https://openapi-generator.tech
171
+ * Do not edit the class manually.
172
+ */
173
+ /**
174
+ * The channel name and marketplace ID. This is required only when multiple channels have the same location ID.
175
+ */
176
+ interface MarketplaceAttributes {
177
+ /**
178
+ * The name of the fulfillment channel in which to update inventory.
179
+ */
180
+ 'channelName'?: MarketplaceAttributesChannelNameEnum;
181
+ /**
182
+ * The marketplace ID of the marketplace where you want to update inventory.
183
+ */
184
+ 'marketplaceId'?: string;
185
+ }
186
+ declare const MarketplaceAttributesChannelNameEnum: {
187
+ readonly Fba: "FBA";
188
+ readonly Mfn: "MFN";
189
+ readonly Df: "DF";
190
+ };
191
+ type MarketplaceAttributesChannelNameEnum = typeof MarketplaceAttributesChannelNameEnum[keyof typeof MarketplaceAttributesChannelNameEnum];
192
+ //#endregion
193
+ //#region src/api-model/models/inventory-request-params.d.ts
194
+ /**
195
+ * The parameters for an individual request.
196
+ */
197
+ interface InventoryRequestParams {
198
+ /**
199
+ * The latest sequence number for the inventory update operation. You find this value in the `clientSequenceNumber` property in the response to the `batchInventory` operation.
200
+ */
201
+ 'clientSequenceNumber'?: number;
202
+ /**
203
+ * The absolute inventory quantity.
204
+ */
205
+ 'quantity'?: number;
206
+ 'marketplaceAttributes'?: MarketplaceAttributes;
207
+ }
208
+ //#endregion
209
+ //#region src/api-model/models/inventory-request.d.ts
210
+ /**
211
+ * An inventory request.
212
+ */
213
+ interface InventoryRequest {
214
+ /**
215
+ * The URI associated with the individual APIs from the batch request. The user must provide the resource identifier for the operation they want to use.
216
+ */
217
+ 'uri': string;
218
+ 'method': HttpMethod;
219
+ 'body'?: InventoryRequestParams;
220
+ }
221
+ //#endregion
222
+ //#region src/api-model/models/batch-inventory-request.d.ts
223
+ /**
224
+ * A list of inventory requests.
225
+ */
226
+ interface BatchInventoryRequest {
227
+ /**
228
+ * A list of inventory requests.
229
+ */
230
+ 'requests'?: Array<InventoryRequest>;
231
+ }
232
+ //#endregion
233
+ //#region src/api-model/models/http-status-line.d.ts
234
+ /**
235
+ * The Selling Partner API for External Fulfillment Inventory Management
236
+ * You can use the Amazon External Fulfillment Inventory API to manage inventory operations in Amazon\'s External Fulfillment network, including batch inventory updates and retrievals.
237
+ *
238
+ * The version of the OpenAPI document: 2024-09-11
239
+ *
240
+ *
241
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
242
+ * https://openapi-generator.tech
243
+ * Do not edit the class manually.
244
+ */
245
+ /**
246
+ * The HTTP status associated with the response for an individual request within a batch.
247
+ */
248
+ interface HttpStatusLine {
249
+ /**
250
+ * The HTTP response status code.
251
+ */
252
+ 'statusCode'?: number;
253
+ /**
254
+ * The HTTP response reason phrase.
255
+ */
256
+ 'reasonPhrase'?: string;
257
+ }
258
+ //#endregion
259
+ //#region src/api-model/models/inventory-response-body.d.ts
260
+ /**
261
+ * The response to an inventory request.
262
+ */
263
+ interface InventoryResponseBody {
264
+ /**
265
+ * Latest sequence number for an inventory update.
266
+ */
267
+ 'clientSequenceNumber'?: number;
268
+ /**
269
+ * The location where inventory is updated or retrieved.
270
+ */
271
+ 'locationId'?: string;
272
+ /**
273
+ * The SKU ID for which inventory is updated or retrieved
274
+ */
275
+ 'skuId'?: string;
276
+ /**
277
+ * The number of items of the specified SKU that are available for purchase.
278
+ */
279
+ 'sellableQuantity'?: number;
280
+ /**
281
+ * The number of items of the specified SKU created in any marketplace that are reserved for shipment and yet to be fulfilled.
282
+ */
283
+ 'reservedQuantity'?: number;
284
+ 'marketplaceAttributes'?: MarketplaceAttributes;
285
+ /**
286
+ * Inventory operation errors that require seller action before retrying the inventory request.
287
+ */
288
+ 'actionableErrors'?: Array<ActionableError>;
289
+ }
290
+ //#endregion
291
+ //#region src/api-model/models/inventory-response.d.ts
292
+ /**
293
+ * A response to an individual inventory request.
294
+ */
295
+ interface InventoryResponse {
296
+ 'status': HttpStatusLine;
297
+ 'body': InventoryResponseBody;
298
+ }
299
+ //#endregion
300
+ //#region src/api-model/models/batch-inventory-response.d.ts
301
+ /**
302
+ * The response of the `batchInventory` operation.
303
+ */
304
+ interface BatchInventoryResponse {
305
+ /**
306
+ * A list of inventory request responses.
307
+ */
308
+ 'responses'?: Array<InventoryResponse>;
309
+ }
310
+ //#endregion
311
+ //#region src/api-model/models/error-list.d.ts
312
+ /**
313
+ * The Selling Partner API for External Fulfillment Inventory Management
314
+ * You can use the Amazon External Fulfillment Inventory API to manage inventory operations in Amazon\'s External Fulfillment network, including batch inventory updates and retrievals.
315
+ *
316
+ * The version of the OpenAPI document: 2024-09-11
317
+ *
318
+ *
319
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
320
+ * https://openapi-generator.tech
321
+ * Do not edit the class manually.
322
+ */
323
+ /**
324
+ * An object containing a list of error responses returned when a request is unsuccessful.
325
+ */
326
+ interface ErrorList {
327
+ /**
328
+ * A list of error responses returned when a request is unsuccessful.
329
+ */
330
+ 'errors': Array<Error>;
331
+ }
332
+ //#endregion
333
+ //#region src/api-model/models/model-error.d.ts
334
+ /**
335
+ * The Selling Partner API for External Fulfillment Inventory Management
336
+ * You can use the Amazon External Fulfillment Inventory API to manage inventory operations in Amazon\'s External Fulfillment network, including batch inventory updates and retrievals.
337
+ *
338
+ * The version of the OpenAPI document: 2024-09-11
339
+ *
340
+ *
341
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
342
+ * https://openapi-generator.tech
343
+ * Do not edit the class manually.
344
+ */
345
+ /**
346
+ * Error response returned when the request is unsuccessful.
347
+ */
348
+ interface ModelError {
349
+ /**
350
+ * An error code that identifies the type of error that occurred.
351
+ */
352
+ 'code': string;
353
+ /**
354
+ * A message that describes the error condition.
355
+ */
356
+ 'message': string;
357
+ /**
358
+ * Additional details that can help the caller understand or fix the issue.
359
+ */
360
+ 'details'?: string;
361
+ }
362
+ //#endregion
363
+ //#region src/api-model/api/external-fulfillment-inventory-api.d.ts
364
+ /**
365
+ * ExternalFulfillmentInventoryApi - axios parameter creator
366
+ */
367
+ declare const ExternalFulfillmentInventoryApiAxiosParamCreator: (configuration?: Configuration) => {
368
+ /**
369
+ * Make up to 10 inventory requests. The response includes the set of responses that correspond to requests. The response for each successful request in the set includes the inventory count for the provided `sku` and `locationId` pair.
370
+ * @param {BatchInventoryRequest} body A list of inventory requests.
371
+ * @param {*} [options] Override http request option.
372
+ * @throws {RequiredError}
373
+ */
374
+ batchInventory: (body: BatchInventoryRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
375
+ };
376
+ /**
377
+ * ExternalFulfillmentInventoryApi - functional programming interface
378
+ */
379
+ declare const ExternalFulfillmentInventoryApiFp: (configuration?: Configuration) => {
380
+ /**
381
+ * Make up to 10 inventory requests. The response includes the set of responses that correspond to requests. The response for each successful request in the set includes the inventory count for the provided `sku` and `locationId` pair.
382
+ * @param {BatchInventoryRequest} body A list of inventory requests.
383
+ * @param {*} [options] Override http request option.
384
+ * @throws {RequiredError}
385
+ */
386
+ batchInventory(body: BatchInventoryRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<BatchInventoryResponse>>;
387
+ };
388
+ /**
389
+ * ExternalFulfillmentInventoryApi - factory interface
390
+ */
391
+ declare const ExternalFulfillmentInventoryApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
392
+ /**
393
+ * Make up to 10 inventory requests. The response includes the set of responses that correspond to requests. The response for each successful request in the set includes the inventory count for the provided `sku` and `locationId` pair.
394
+ * @param {ExternalFulfillmentInventoryApiBatchInventoryRequest} requestParameters Request parameters.
395
+ * @param {*} [options] Override http request option.
396
+ * @throws {RequiredError}
397
+ */
398
+ batchInventory(requestParameters: ExternalFulfillmentInventoryApiBatchInventoryRequest, options?: RawAxiosRequestConfig): AxiosPromise<BatchInventoryResponse>;
399
+ };
400
+ /**
401
+ * Request parameters for batchInventory operation in ExternalFulfillmentInventoryApi.
402
+ */
403
+ interface ExternalFulfillmentInventoryApiBatchInventoryRequest {
404
+ /**
405
+ * A list of inventory requests.
406
+ */
407
+ readonly body: BatchInventoryRequest;
408
+ }
409
+ /**
410
+ * ExternalFulfillmentInventoryApi - object-oriented interface
411
+ */
412
+ declare class ExternalFulfillmentInventoryApi extends BaseAPI {
413
+ /**
414
+ * Make up to 10 inventory requests. The response includes the set of responses that correspond to requests. The response for each successful request in the set includes the inventory count for the provided `sku` and `locationId` pair.
415
+ * @param {ExternalFulfillmentInventoryApiBatchInventoryRequest} requestParameters Request parameters.
416
+ * @param {*} [options] Override http request option.
417
+ * @throws {RequiredError}
418
+ */
419
+ batchInventory(requestParameters: ExternalFulfillmentInventoryApiBatchInventoryRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<BatchInventoryResponse, any, {}>>;
420
+ }
421
+ //#endregion
422
+ //#region src/client.d.ts
423
+ declare const clientRateLimits: RateLimit[];
424
+ declare class ExternalFulfillmentInventoryApiClient extends ExternalFulfillmentInventoryApi {
425
+ constructor(configuration: ClientConfiguration);
426
+ }
427
+ //#endregion
428
+ export { ActionableError, BatchInventoryRequest, BatchInventoryResponse, ErrorList, ExternalFulfillmentInventoryApi, ExternalFulfillmentInventoryApiAxiosParamCreator, ExternalFulfillmentInventoryApiBatchInventoryRequest, ExternalFulfillmentInventoryApiClient, ExternalFulfillmentInventoryApiFactory, ExternalFulfillmentInventoryApiFp, HttpMethod, HttpStatusLine, InventoryRequest, InventoryRequestParams, InventoryResponse, InventoryResponseBody, MarketplaceAttributes, MarketplaceAttributesChannelNameEnum, ModelError, clientRateLimits };
429
+ //# sourceMappingURL=index.d.cts.map