@sp-api-sdk/fulfillment-outbound-api-2020-07-01 1.7.1 → 1.7.2
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/README.md
CHANGED
|
@@ -2,6 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
The Selling Partner API for Fulfillment Outbound lets you create applications that help a seller fulfill Multi-Channel Fulfillment orders using their inventory in Amazon's fulfillment network. You can get information on both potential and existing fulfillment orders.
|
|
4
4
|
|
|
5
|
+
## Documentation
|
|
6
|
+
|
|
7
|
+
Learn more about this Selling Partner API by visiting the [official documentation](https://github.com/amzn/selling-partner-api-docs/tree/main/references/fulfillment-outbound-api/fulfillmentOutbound_2020-07-01.md).
|
|
8
|
+
|
|
9
|
+
Also, see the [generated documentation](https://bizon.github.io/selling-partner-api-sdk/modules/_sp_api_sdk_fulfillment_outbound_api_2020_07_01.html) for this API client.
|
|
10
|
+
|
|
5
11
|
## Installing
|
|
6
12
|
|
|
7
13
|
```sh
|
|
@@ -19,26 +25,25 @@ import {SellingPartnerApiAuth} from '@sp-api-sdk/auth'
|
|
|
19
25
|
import {FulfillmentOutboundApiClient} from '@sp-api-sdk/fulfillment-outbound-api-2020-07-01'
|
|
20
26
|
|
|
21
27
|
const auth = new SellingPartnerApiAuth({
|
|
22
|
-
clientId:
|
|
23
|
-
clientSecret:
|
|
24
|
-
refreshToken: '',
|
|
25
|
-
secretAccessKey: '',
|
|
28
|
+
clientId: process.env.LWA_CLIENT_ID,
|
|
29
|
+
clientSecret: process.env.LWA_CLIENT_SECRET,
|
|
30
|
+
refreshToken: 'Atzr|…',
|
|
26
31
|
accessKeyId: '',
|
|
27
|
-
|
|
32
|
+
secretAccessKey: '',
|
|
28
33
|
role: {
|
|
29
|
-
arn: '',
|
|
30
|
-
}
|
|
34
|
+
arn: 'arn:aws:iam::…',
|
|
35
|
+
},
|
|
31
36
|
})
|
|
32
37
|
|
|
33
38
|
const client = new FulfillmentOutboundApiClient({
|
|
34
39
|
auth,
|
|
35
|
-
region: 'eu'
|
|
40
|
+
region: 'eu',
|
|
36
41
|
})
|
|
37
42
|
```
|
|
38
43
|
|
|
39
|
-
##
|
|
44
|
+
## Rate Limiting
|
|
40
45
|
|
|
41
|
-
|
|
46
|
+
In order to retry rate limited requests (HTTP 429), you can configure the API client as such:
|
|
42
47
|
|
|
43
48
|
```javascript
|
|
44
49
|
const client = new FulfillmentOutboundApiClient({
|
|
@@ -46,13 +51,28 @@ const client = new FulfillmentOutboundApiClient({
|
|
|
46
51
|
region: 'eu',
|
|
47
52
|
rateLimiting: {
|
|
48
53
|
retry: true,
|
|
49
|
-
|
|
50
|
-
|
|
54
|
+
// Optionally specify a callback that will be called on every retry.
|
|
55
|
+
onRetry: (retryInfo) => {
|
|
56
|
+
console.log(retryInfo)
|
|
57
|
+
},
|
|
58
|
+
},
|
|
51
59
|
})
|
|
52
60
|
```
|
|
53
61
|
|
|
54
|
-
The
|
|
62
|
+
The rate limits used for each route are specified in the [API documentation]((https://github.com/amzn/selling-partner-api-docs/tree/main/references/fulfillment-outbound-api/fulfillmentOutbound_2020-07-01.md)).
|
|
63
|
+
|
|
64
|
+
## License
|
|
65
|
+
|
|
66
|
+
MIT
|
|
55
67
|
|
|
56
|
-
##
|
|
68
|
+
## Miscellaneous
|
|
57
69
|
|
|
58
|
-
|
|
70
|
+
```
|
|
71
|
+
╚⊙ ⊙╝
|
|
72
|
+
╚═(███)═╝
|
|
73
|
+
╚═(███)═╝
|
|
74
|
+
╚═(███)═╝
|
|
75
|
+
╚═(███)═╝
|
|
76
|
+
╚═(███)═╝
|
|
77
|
+
╚═(███)═╝
|
|
78
|
+
```
|
|
@@ -558,7 +558,7 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
558
558
|
* @throws {RequiredError}
|
|
559
559
|
* @memberof FbaOutboundApi
|
|
560
560
|
*/
|
|
561
|
-
cancelFulfillmentOrder(requestParameters: FbaOutboundApiCancelFulfillmentOrderRequest, options?: any): Promise<import("axios").AxiosResponse<CancelFulfillmentOrderResponse>>;
|
|
561
|
+
cancelFulfillmentOrder(requestParameters: FbaOutboundApiCancelFulfillmentOrderRequest, options?: any): Promise<import("axios").AxiosResponse<CancelFulfillmentOrderResponse, any>>;
|
|
562
562
|
/**
|
|
563
563
|
* Requests that Amazon ship items from the seller\'s inventory in Amazon\'s fulfillment network to a destination address. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 30 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
|
|
564
564
|
* @param {FbaOutboundApiCreateFulfillmentOrderRequest} requestParameters Request parameters.
|
|
@@ -566,7 +566,7 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
566
566
|
* @throws {RequiredError}
|
|
567
567
|
* @memberof FbaOutboundApi
|
|
568
568
|
*/
|
|
569
|
-
createFulfillmentOrder(requestParameters: FbaOutboundApiCreateFulfillmentOrderRequest, options?: any): Promise<import("axios").AxiosResponse<CreateFulfillmentOrderResponse>>;
|
|
569
|
+
createFulfillmentOrder(requestParameters: FbaOutboundApiCreateFulfillmentOrderRequest, options?: any): Promise<import("axios").AxiosResponse<CreateFulfillmentOrderResponse, any>>;
|
|
570
570
|
/**
|
|
571
571
|
* Creates a fulfillment return. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 30 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
|
|
572
572
|
* @param {FbaOutboundApiCreateFulfillmentReturnRequest} requestParameters Request parameters.
|
|
@@ -574,7 +574,7 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
574
574
|
* @throws {RequiredError}
|
|
575
575
|
* @memberof FbaOutboundApi
|
|
576
576
|
*/
|
|
577
|
-
createFulfillmentReturn(requestParameters: FbaOutboundApiCreateFulfillmentReturnRequest, options?: any): Promise<import("axios").AxiosResponse<CreateFulfillmentReturnResponse>>;
|
|
577
|
+
createFulfillmentReturn(requestParameters: FbaOutboundApiCreateFulfillmentReturnRequest, options?: any): Promise<import("axios").AxiosResponse<CreateFulfillmentReturnResponse, any>>;
|
|
578
578
|
/**
|
|
579
579
|
* Returns a list of inventory items that are eligible for the fulfillment feature you specify. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 30 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
|
|
580
580
|
* @param {FbaOutboundApiGetFeatureInventoryRequest} requestParameters Request parameters.
|
|
@@ -582,7 +582,7 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
582
582
|
* @throws {RequiredError}
|
|
583
583
|
* @memberof FbaOutboundApi
|
|
584
584
|
*/
|
|
585
|
-
getFeatureInventory(requestParameters: FbaOutboundApiGetFeatureInventoryRequest, options?: any): Promise<import("axios").AxiosResponse<GetFeatureInventoryResponse>>;
|
|
585
|
+
getFeatureInventory(requestParameters: FbaOutboundApiGetFeatureInventoryRequest, options?: any): Promise<import("axios").AxiosResponse<GetFeatureInventoryResponse, any>>;
|
|
586
586
|
/**
|
|
587
587
|
* Returns the number of items with the sellerSKU you specify that can have orders fulfilled using the specified feature. Note that if the sellerSKU isn\'t eligible, the response will contain an empty skuInfo object. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 30 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
|
|
588
588
|
* @param {FbaOutboundApiGetFeatureSKURequest} requestParameters Request parameters.
|
|
@@ -590,7 +590,7 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
590
590
|
* @throws {RequiredError}
|
|
591
591
|
* @memberof FbaOutboundApi
|
|
592
592
|
*/
|
|
593
|
-
getFeatureSKU(requestParameters: FbaOutboundApiGetFeatureSKURequest, options?: any): Promise<import("axios").AxiosResponse<GetFeatureSkuResponse>>;
|
|
593
|
+
getFeatureSKU(requestParameters: FbaOutboundApiGetFeatureSKURequest, options?: any): Promise<import("axios").AxiosResponse<GetFeatureSkuResponse, any>>;
|
|
594
594
|
/**
|
|
595
595
|
* Returns a list of features available for Multi-Channel Fulfillment orders in the marketplace you specify, and whether the seller for which you made the call is enrolled for each feature. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 30 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
|
|
596
596
|
* @param {FbaOutboundApiGetFeaturesRequest} requestParameters Request parameters.
|
|
@@ -598,7 +598,7 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
598
598
|
* @throws {RequiredError}
|
|
599
599
|
* @memberof FbaOutboundApi
|
|
600
600
|
*/
|
|
601
|
-
getFeatures(requestParameters: FbaOutboundApiGetFeaturesRequest, options?: any): Promise<import("axios").AxiosResponse<GetFeaturesResponse>>;
|
|
601
|
+
getFeatures(requestParameters: FbaOutboundApiGetFeaturesRequest, options?: any): Promise<import("axios").AxiosResponse<GetFeaturesResponse, any>>;
|
|
602
602
|
/**
|
|
603
603
|
* Returns the fulfillment order indicated by the specified order identifier. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 30 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
|
|
604
604
|
* @param {FbaOutboundApiGetFulfillmentOrderRequest} requestParameters Request parameters.
|
|
@@ -606,7 +606,7 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
606
606
|
* @throws {RequiredError}
|
|
607
607
|
* @memberof FbaOutboundApi
|
|
608
608
|
*/
|
|
609
|
-
getFulfillmentOrder(requestParameters: FbaOutboundApiGetFulfillmentOrderRequest, options?: any): Promise<import("axios").AxiosResponse<GetFulfillmentOrderResponse>>;
|
|
609
|
+
getFulfillmentOrder(requestParameters: FbaOutboundApiGetFulfillmentOrderRequest, options?: any): Promise<import("axios").AxiosResponse<GetFulfillmentOrderResponse, any>>;
|
|
610
610
|
/**
|
|
611
611
|
* Returns a list of fulfillment order previews based on shipping criteria that you specify. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 30 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
|
|
612
612
|
* @param {FbaOutboundApiGetFulfillmentPreviewRequest} requestParameters Request parameters.
|
|
@@ -614,7 +614,7 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
614
614
|
* @throws {RequiredError}
|
|
615
615
|
* @memberof FbaOutboundApi
|
|
616
616
|
*/
|
|
617
|
-
getFulfillmentPreview(requestParameters: FbaOutboundApiGetFulfillmentPreviewRequest, options?: any): Promise<import("axios").AxiosResponse<GetFulfillmentPreviewResponse>>;
|
|
617
|
+
getFulfillmentPreview(requestParameters: FbaOutboundApiGetFulfillmentPreviewRequest, options?: any): Promise<import("axios").AxiosResponse<GetFulfillmentPreviewResponse, any>>;
|
|
618
618
|
/**
|
|
619
619
|
* Returns delivery tracking information for a package in an outbound shipment for a Multi-Channel Fulfillment order. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 30 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
|
|
620
620
|
* @param {FbaOutboundApiGetPackageTrackingDetailsRequest} requestParameters Request parameters.
|
|
@@ -622,7 +622,7 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
622
622
|
* @throws {RequiredError}
|
|
623
623
|
* @memberof FbaOutboundApi
|
|
624
624
|
*/
|
|
625
|
-
getPackageTrackingDetails(requestParameters: FbaOutboundApiGetPackageTrackingDetailsRequest, options?: any): Promise<import("axios").AxiosResponse<GetPackageTrackingDetailsResponse>>;
|
|
625
|
+
getPackageTrackingDetails(requestParameters: FbaOutboundApiGetPackageTrackingDetailsRequest, options?: any): Promise<import("axios").AxiosResponse<GetPackageTrackingDetailsResponse, any>>;
|
|
626
626
|
/**
|
|
627
627
|
* Returns a list of fulfillment orders fulfilled after (or at) a specified date-time, or indicated by the next token parameter. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 30 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
|
|
628
628
|
* @param {FbaOutboundApiListAllFulfillmentOrdersRequest} requestParameters Request parameters.
|
|
@@ -630,7 +630,7 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
630
630
|
* @throws {RequiredError}
|
|
631
631
|
* @memberof FbaOutboundApi
|
|
632
632
|
*/
|
|
633
|
-
listAllFulfillmentOrders(requestParameters?: FbaOutboundApiListAllFulfillmentOrdersRequest, options?: any): Promise<import("axios").AxiosResponse<ListAllFulfillmentOrdersResponse>>;
|
|
633
|
+
listAllFulfillmentOrders(requestParameters?: FbaOutboundApiListAllFulfillmentOrdersRequest, options?: any): Promise<import("axios").AxiosResponse<ListAllFulfillmentOrdersResponse, any>>;
|
|
634
634
|
/**
|
|
635
635
|
* Returns a list of return reason codes for a seller SKU in a given marketplace. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 30 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
|
|
636
636
|
* @param {FbaOutboundApiListReturnReasonCodesRequest} requestParameters Request parameters.
|
|
@@ -638,7 +638,7 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
638
638
|
* @throws {RequiredError}
|
|
639
639
|
* @memberof FbaOutboundApi
|
|
640
640
|
*/
|
|
641
|
-
listReturnReasonCodes(requestParameters: FbaOutboundApiListReturnReasonCodesRequest, options?: any): Promise<import("axios").AxiosResponse<ListReturnReasonCodesResponse>>;
|
|
641
|
+
listReturnReasonCodes(requestParameters: FbaOutboundApiListReturnReasonCodesRequest, options?: any): Promise<import("axios").AxiosResponse<ListReturnReasonCodesResponse, any>>;
|
|
642
642
|
/**
|
|
643
643
|
* Updates and/or requests shipment for a fulfillment order with an order hold on it. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 30 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
|
|
644
644
|
* @param {FbaOutboundApiUpdateFulfillmentOrderRequest} requestParameters Request parameters.
|
|
@@ -646,5 +646,5 @@ export declare class FbaOutboundApi extends BaseAPI {
|
|
|
646
646
|
* @throws {RequiredError}
|
|
647
647
|
* @memberof FbaOutboundApi
|
|
648
648
|
*/
|
|
649
|
-
updateFulfillmentOrder(requestParameters: FbaOutboundApiUpdateFulfillmentOrderRequest, options?: any): Promise<import("axios").AxiosResponse<UpdateFulfillmentOrderResponse>>;
|
|
649
|
+
updateFulfillmentOrder(requestParameters: FbaOutboundApiUpdateFulfillmentOrderRequest, options?: any): Promise<import("axios").AxiosResponse<UpdateFulfillmentOrderResponse, any>>;
|
|
650
650
|
}
|
|
@@ -62,4 +62,4 @@ export declare const toPathString: (url: URL) => string;
|
|
|
62
62
|
*
|
|
63
63
|
* @export
|
|
64
64
|
*/
|
|
65
|
-
export declare const createRequestFunction: (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration | undefined) => (axios?: AxiosInstance, basePath?: string) => Promise<import("axios").AxiosResponse<any>>;
|
|
65
|
+
export declare const createRequestFunction: (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration | undefined) => (axios?: AxiosInstance, basePath?: string) => Promise<import("axios").AxiosResponse<any, any>>;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import type { ClientConfiguration, RateLimit } from '@sp-api-sdk/common';
|
|
1
|
+
import type { ClientConfiguration, RateLimit, OnRetryHandler } from '@sp-api-sdk/common';
|
|
3
2
|
import { FbaOutboundApi } from './api-model';
|
|
4
3
|
export declare const RATE_LIMITS: RateLimit[];
|
|
5
4
|
export interface ClientParameters extends Omit<ClientConfiguration, 'rateLimits' | 'onRetry'> {
|
|
6
5
|
rateLimiting?: {
|
|
7
6
|
retry: boolean;
|
|
8
|
-
onRetry?:
|
|
7
|
+
onRetry?: OnRetryHandler;
|
|
9
8
|
};
|
|
10
9
|
}
|
|
11
10
|
export declare class FulfillmentOutboundApiClient extends FbaOutboundApi {
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@sp-api-sdk/fulfillment-outbound-api-2020-07-01",
|
|
3
3
|
"author": "Vincent Mesquita <vincent.mesquita@bizon.solutions>",
|
|
4
4
|
"description": "The Selling Partner API for Fulfillment Outbound lets you create applications that help a seller fulfill Multi-Channel Fulfillment orders using their inventory in Amazon's fulfillment network. You can get information on both potential and existing fulfillment orders.",
|
|
5
|
-
"version": "1.7.
|
|
5
|
+
"version": "1.7.2",
|
|
6
6
|
"main": "dist/cjs/index.js",
|
|
7
7
|
"module": "dist/es/index.js",
|
|
8
8
|
"types": "dist/types/index.d.ts",
|
|
@@ -25,9 +25,9 @@
|
|
|
25
25
|
"test": "NODE_ENV='test' yarn jest"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@sp-api-sdk/auth": "^1.9.
|
|
29
|
-
"@sp-api-sdk/common": "^1.7.
|
|
30
|
-
"axios": "^0.
|
|
28
|
+
"@sp-api-sdk/auth": "^1.9.5",
|
|
29
|
+
"@sp-api-sdk/common": "^1.7.7",
|
|
30
|
+
"axios": "^0.24.0"
|
|
31
31
|
},
|
|
32
32
|
"repository": {
|
|
33
33
|
"type": "git",
|
|
@@ -48,5 +48,5 @@
|
|
|
48
48
|
"sp sdk",
|
|
49
49
|
"fulfillment outbound api"
|
|
50
50
|
],
|
|
51
|
-
"gitHead": "
|
|
51
|
+
"gitHead": "e8c21d7d481263e8a6663ee11f6708d4dc6968b6"
|
|
52
52
|
}
|