@sp-api-sdk/replenishment-api-2022-11-07 4.0.3 → 5.0.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.
- package/dist/cjs/api-model/api/{offers-api.js → replenishment-api.js} +31 -31
- package/dist/cjs/api-model/api.js +1 -1
- package/dist/cjs/client.js +1 -1
- package/dist/es/api-model/api/{offers-api.js → replenishment-api.js} +26 -26
- package/dist/es/api-model/api.js +1 -1
- package/dist/es/client.js +2 -2
- package/dist/types/api-model/api/{offers-api.d.ts → replenishment-api.d.ts} +36 -36
- package/dist/types/api-model/api.d.ts +1 -1
- package/dist/types/client.d.ts +2 -2
- package/package.json +4 -4
|
@@ -16,7 +16,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
16
16
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
17
17
|
};
|
|
18
18
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
19
|
-
exports.
|
|
19
|
+
exports.ReplenishmentApi = exports.ReplenishmentApiFactory = exports.ReplenishmentApiFp = exports.ReplenishmentApiAxiosParamCreator = void 0;
|
|
20
20
|
const axios_1 = __importDefault(require("axios"));
|
|
21
21
|
// Some imports not used depending on template conditions
|
|
22
22
|
// @ts-ignore
|
|
@@ -24,10 +24,10 @@ const common_1 = require("../common");
|
|
|
24
24
|
// @ts-ignore
|
|
25
25
|
const base_1 = require("../base");
|
|
26
26
|
/**
|
|
27
|
-
*
|
|
27
|
+
* ReplenishmentApi - axios parameter creator
|
|
28
28
|
* @export
|
|
29
29
|
*/
|
|
30
|
-
const
|
|
30
|
+
const ReplenishmentApiAxiosParamCreator = function (configuration) {
|
|
31
31
|
return {
|
|
32
32
|
/**
|
|
33
33
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
@@ -112,13 +112,13 @@ const OffersApiAxiosParamCreator = function (configuration) {
|
|
|
112
112
|
},
|
|
113
113
|
};
|
|
114
114
|
};
|
|
115
|
-
exports.
|
|
115
|
+
exports.ReplenishmentApiAxiosParamCreator = ReplenishmentApiAxiosParamCreator;
|
|
116
116
|
/**
|
|
117
|
-
*
|
|
117
|
+
* ReplenishmentApi - functional programming interface
|
|
118
118
|
* @export
|
|
119
119
|
*/
|
|
120
|
-
const
|
|
121
|
-
const localVarAxiosParamCreator = (0, exports.
|
|
120
|
+
const ReplenishmentApiFp = function (configuration) {
|
|
121
|
+
const localVarAxiosParamCreator = (0, exports.ReplenishmentApiAxiosParamCreator)(configuration);
|
|
122
122
|
return {
|
|
123
123
|
/**
|
|
124
124
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
@@ -129,7 +129,7 @@ const OffersApiFp = function (configuration) {
|
|
|
129
129
|
async getSellingPartnerMetrics(body, options) {
|
|
130
130
|
const localVarAxiosArgs = await localVarAxiosParamCreator.getSellingPartnerMetrics(body, options);
|
|
131
131
|
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
132
|
-
const localVarOperationServerBasePath = base_1.operationServerMap['
|
|
132
|
+
const localVarOperationServerBasePath = base_1.operationServerMap['ReplenishmentApi.getSellingPartnerMetrics']?.[localVarOperationServerIndex]?.url;
|
|
133
133
|
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
134
134
|
},
|
|
135
135
|
/**
|
|
@@ -141,7 +141,7 @@ const OffersApiFp = function (configuration) {
|
|
|
141
141
|
async listOfferMetrics(body, options) {
|
|
142
142
|
const localVarAxiosArgs = await localVarAxiosParamCreator.listOfferMetrics(body, options);
|
|
143
143
|
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
144
|
-
const localVarOperationServerBasePath = base_1.operationServerMap['
|
|
144
|
+
const localVarOperationServerBasePath = base_1.operationServerMap['ReplenishmentApi.listOfferMetrics']?.[localVarOperationServerIndex]?.url;
|
|
145
145
|
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
146
146
|
},
|
|
147
147
|
/**
|
|
@@ -153,22 +153,22 @@ const OffersApiFp = function (configuration) {
|
|
|
153
153
|
async listOffers(body, options) {
|
|
154
154
|
const localVarAxiosArgs = await localVarAxiosParamCreator.listOffers(body, options);
|
|
155
155
|
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
156
|
-
const localVarOperationServerBasePath = base_1.operationServerMap['
|
|
156
|
+
const localVarOperationServerBasePath = base_1.operationServerMap['ReplenishmentApi.listOffers']?.[localVarOperationServerIndex]?.url;
|
|
157
157
|
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
158
158
|
},
|
|
159
159
|
};
|
|
160
160
|
};
|
|
161
|
-
exports.
|
|
161
|
+
exports.ReplenishmentApiFp = ReplenishmentApiFp;
|
|
162
162
|
/**
|
|
163
|
-
*
|
|
163
|
+
* ReplenishmentApi - factory interface
|
|
164
164
|
* @export
|
|
165
165
|
*/
|
|
166
|
-
const
|
|
167
|
-
const localVarFp = (0, exports.
|
|
166
|
+
const ReplenishmentApiFactory = function (configuration, basePath, axios) {
|
|
167
|
+
const localVarFp = (0, exports.ReplenishmentApiFp)(configuration);
|
|
168
168
|
return {
|
|
169
169
|
/**
|
|
170
170
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
171
|
-
* @param {
|
|
171
|
+
* @param {ReplenishmentApiGetSellingPartnerMetricsRequest} requestParameters Request parameters.
|
|
172
172
|
* @param {*} [options] Override http request option.
|
|
173
173
|
* @throws {RequiredError}
|
|
174
174
|
*/
|
|
@@ -177,7 +177,7 @@ const OffersApiFactory = function (configuration, basePath, axios) {
|
|
|
177
177
|
},
|
|
178
178
|
/**
|
|
179
179
|
* Returns aggregated replenishment program metrics for a selling partner\'s offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
180
|
-
* @param {
|
|
180
|
+
* @param {ReplenishmentApiListOfferMetricsRequest} requestParameters Request parameters.
|
|
181
181
|
* @param {*} [options] Override http request option.
|
|
182
182
|
* @throws {RequiredError}
|
|
183
183
|
*/
|
|
@@ -186,7 +186,7 @@ const OffersApiFactory = function (configuration, basePath, axios) {
|
|
|
186
186
|
},
|
|
187
187
|
/**
|
|
188
188
|
* Returns the details of a selling partner\'s replenishment program offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
189
|
-
* @param {
|
|
189
|
+
* @param {ReplenishmentApiListOffersRequest} requestParameters Request parameters.
|
|
190
190
|
* @param {*} [options] Override http request option.
|
|
191
191
|
* @throws {RequiredError}
|
|
192
192
|
*/
|
|
@@ -195,43 +195,43 @@ const OffersApiFactory = function (configuration, basePath, axios) {
|
|
|
195
195
|
},
|
|
196
196
|
};
|
|
197
197
|
};
|
|
198
|
-
exports.
|
|
198
|
+
exports.ReplenishmentApiFactory = ReplenishmentApiFactory;
|
|
199
199
|
/**
|
|
200
|
-
*
|
|
200
|
+
* ReplenishmentApi - object-oriented interface
|
|
201
201
|
* @export
|
|
202
|
-
* @class
|
|
202
|
+
* @class ReplenishmentApi
|
|
203
203
|
* @extends {BaseAPI}
|
|
204
204
|
*/
|
|
205
|
-
class
|
|
205
|
+
class ReplenishmentApi extends base_1.BaseAPI {
|
|
206
206
|
/**
|
|
207
207
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
208
|
-
* @param {
|
|
208
|
+
* @param {ReplenishmentApiGetSellingPartnerMetricsRequest} requestParameters Request parameters.
|
|
209
209
|
* @param {*} [options] Override http request option.
|
|
210
210
|
* @throws {RequiredError}
|
|
211
|
-
* @memberof
|
|
211
|
+
* @memberof ReplenishmentApi
|
|
212
212
|
*/
|
|
213
213
|
getSellingPartnerMetrics(requestParameters = {}, options) {
|
|
214
|
-
return (0, exports.
|
|
214
|
+
return (0, exports.ReplenishmentApiFp)(this.configuration).getSellingPartnerMetrics(requestParameters.body, options).then((request) => request(this.axios, this.basePath));
|
|
215
215
|
}
|
|
216
216
|
/**
|
|
217
217
|
* Returns aggregated replenishment program metrics for a selling partner\'s offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
218
|
-
* @param {
|
|
218
|
+
* @param {ReplenishmentApiListOfferMetricsRequest} requestParameters Request parameters.
|
|
219
219
|
* @param {*} [options] Override http request option.
|
|
220
220
|
* @throws {RequiredError}
|
|
221
|
-
* @memberof
|
|
221
|
+
* @memberof ReplenishmentApi
|
|
222
222
|
*/
|
|
223
223
|
listOfferMetrics(requestParameters = {}, options) {
|
|
224
|
-
return (0, exports.
|
|
224
|
+
return (0, exports.ReplenishmentApiFp)(this.configuration).listOfferMetrics(requestParameters.body, options).then((request) => request(this.axios, this.basePath));
|
|
225
225
|
}
|
|
226
226
|
/**
|
|
227
227
|
* Returns the details of a selling partner\'s replenishment program offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
228
|
-
* @param {
|
|
228
|
+
* @param {ReplenishmentApiListOffersRequest} requestParameters Request parameters.
|
|
229
229
|
* @param {*} [options] Override http request option.
|
|
230
230
|
* @throws {RequiredError}
|
|
231
|
-
* @memberof
|
|
231
|
+
* @memberof ReplenishmentApi
|
|
232
232
|
*/
|
|
233
233
|
listOffers(requestParameters = {}, options) {
|
|
234
|
-
return (0, exports.
|
|
234
|
+
return (0, exports.ReplenishmentApiFp)(this.configuration).listOffers(requestParameters.body, options).then((request) => request(this.axios, this.basePath));
|
|
235
235
|
}
|
|
236
236
|
}
|
|
237
|
-
exports.
|
|
237
|
+
exports.ReplenishmentApi = ReplenishmentApi;
|
|
@@ -27,4 +27,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
27
27
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
28
28
|
};
|
|
29
29
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30
|
-
__exportStar(require("./api/
|
|
30
|
+
__exportStar(require("./api/replenishment-api"), exports);
|
package/dist/cjs/client.js
CHANGED
|
@@ -26,7 +26,7 @@ exports.clientRateLimits = [
|
|
|
26
26
|
burst: 1,
|
|
27
27
|
},
|
|
28
28
|
];
|
|
29
|
-
class ReplenishmentApiClient extends api_model_1.
|
|
29
|
+
class ReplenishmentApiClient extends api_model_1.ReplenishmentApi {
|
|
30
30
|
constructor(configuration) {
|
|
31
31
|
const { axios, endpoint } = (0, common_1.createAxiosInstance)(configuration, exports.clientRateLimits);
|
|
32
32
|
super(new api_model_1.Configuration(), endpoint, axios);
|
|
@@ -18,10 +18,10 @@ import { DUMMY_BASE_URL, setSearchParams, serializeDataIfNeeded, toPathString, c
|
|
|
18
18
|
// @ts-ignore
|
|
19
19
|
import { BASE_PATH, BaseAPI, operationServerMap } from '../base';
|
|
20
20
|
/**
|
|
21
|
-
*
|
|
21
|
+
* ReplenishmentApi - axios parameter creator
|
|
22
22
|
* @export
|
|
23
23
|
*/
|
|
24
|
-
export const
|
|
24
|
+
export const ReplenishmentApiAxiosParamCreator = function (configuration) {
|
|
25
25
|
return {
|
|
26
26
|
/**
|
|
27
27
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
@@ -107,11 +107,11 @@ export const OffersApiAxiosParamCreator = function (configuration) {
|
|
|
107
107
|
};
|
|
108
108
|
};
|
|
109
109
|
/**
|
|
110
|
-
*
|
|
110
|
+
* ReplenishmentApi - functional programming interface
|
|
111
111
|
* @export
|
|
112
112
|
*/
|
|
113
|
-
export const
|
|
114
|
-
const localVarAxiosParamCreator =
|
|
113
|
+
export const ReplenishmentApiFp = function (configuration) {
|
|
114
|
+
const localVarAxiosParamCreator = ReplenishmentApiAxiosParamCreator(configuration);
|
|
115
115
|
return {
|
|
116
116
|
/**
|
|
117
117
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
@@ -122,7 +122,7 @@ export const OffersApiFp = function (configuration) {
|
|
|
122
122
|
async getSellingPartnerMetrics(body, options) {
|
|
123
123
|
const localVarAxiosArgs = await localVarAxiosParamCreator.getSellingPartnerMetrics(body, options);
|
|
124
124
|
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
125
|
-
const localVarOperationServerBasePath = operationServerMap['
|
|
125
|
+
const localVarOperationServerBasePath = operationServerMap['ReplenishmentApi.getSellingPartnerMetrics']?.[localVarOperationServerIndex]?.url;
|
|
126
126
|
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
127
127
|
},
|
|
128
128
|
/**
|
|
@@ -134,7 +134,7 @@ export const OffersApiFp = function (configuration) {
|
|
|
134
134
|
async listOfferMetrics(body, options) {
|
|
135
135
|
const localVarAxiosArgs = await localVarAxiosParamCreator.listOfferMetrics(body, options);
|
|
136
136
|
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
137
|
-
const localVarOperationServerBasePath = operationServerMap['
|
|
137
|
+
const localVarOperationServerBasePath = operationServerMap['ReplenishmentApi.listOfferMetrics']?.[localVarOperationServerIndex]?.url;
|
|
138
138
|
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
139
139
|
},
|
|
140
140
|
/**
|
|
@@ -146,21 +146,21 @@ export const OffersApiFp = function (configuration) {
|
|
|
146
146
|
async listOffers(body, options) {
|
|
147
147
|
const localVarAxiosArgs = await localVarAxiosParamCreator.listOffers(body, options);
|
|
148
148
|
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
149
|
-
const localVarOperationServerBasePath = operationServerMap['
|
|
149
|
+
const localVarOperationServerBasePath = operationServerMap['ReplenishmentApi.listOffers']?.[localVarOperationServerIndex]?.url;
|
|
150
150
|
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
151
151
|
},
|
|
152
152
|
};
|
|
153
153
|
};
|
|
154
154
|
/**
|
|
155
|
-
*
|
|
155
|
+
* ReplenishmentApi - factory interface
|
|
156
156
|
* @export
|
|
157
157
|
*/
|
|
158
|
-
export const
|
|
159
|
-
const localVarFp =
|
|
158
|
+
export const ReplenishmentApiFactory = function (configuration, basePath, axios) {
|
|
159
|
+
const localVarFp = ReplenishmentApiFp(configuration);
|
|
160
160
|
return {
|
|
161
161
|
/**
|
|
162
162
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
163
|
-
* @param {
|
|
163
|
+
* @param {ReplenishmentApiGetSellingPartnerMetricsRequest} requestParameters Request parameters.
|
|
164
164
|
* @param {*} [options] Override http request option.
|
|
165
165
|
* @throws {RequiredError}
|
|
166
166
|
*/
|
|
@@ -169,7 +169,7 @@ export const OffersApiFactory = function (configuration, basePath, axios) {
|
|
|
169
169
|
},
|
|
170
170
|
/**
|
|
171
171
|
* Returns aggregated replenishment program metrics for a selling partner\'s offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
172
|
-
* @param {
|
|
172
|
+
* @param {ReplenishmentApiListOfferMetricsRequest} requestParameters Request parameters.
|
|
173
173
|
* @param {*} [options] Override http request option.
|
|
174
174
|
* @throws {RequiredError}
|
|
175
175
|
*/
|
|
@@ -178,7 +178,7 @@ export const OffersApiFactory = function (configuration, basePath, axios) {
|
|
|
178
178
|
},
|
|
179
179
|
/**
|
|
180
180
|
* Returns the details of a selling partner\'s replenishment program offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
181
|
-
* @param {
|
|
181
|
+
* @param {ReplenishmentApiListOffersRequest} requestParameters Request parameters.
|
|
182
182
|
* @param {*} [options] Override http request option.
|
|
183
183
|
* @throws {RequiredError}
|
|
184
184
|
*/
|
|
@@ -188,40 +188,40 @@ export const OffersApiFactory = function (configuration, basePath, axios) {
|
|
|
188
188
|
};
|
|
189
189
|
};
|
|
190
190
|
/**
|
|
191
|
-
*
|
|
191
|
+
* ReplenishmentApi - object-oriented interface
|
|
192
192
|
* @export
|
|
193
|
-
* @class
|
|
193
|
+
* @class ReplenishmentApi
|
|
194
194
|
* @extends {BaseAPI}
|
|
195
195
|
*/
|
|
196
|
-
export class
|
|
196
|
+
export class ReplenishmentApi extends BaseAPI {
|
|
197
197
|
/**
|
|
198
198
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
199
|
-
* @param {
|
|
199
|
+
* @param {ReplenishmentApiGetSellingPartnerMetricsRequest} requestParameters Request parameters.
|
|
200
200
|
* @param {*} [options] Override http request option.
|
|
201
201
|
* @throws {RequiredError}
|
|
202
|
-
* @memberof
|
|
202
|
+
* @memberof ReplenishmentApi
|
|
203
203
|
*/
|
|
204
204
|
getSellingPartnerMetrics(requestParameters = {}, options) {
|
|
205
|
-
return
|
|
205
|
+
return ReplenishmentApiFp(this.configuration).getSellingPartnerMetrics(requestParameters.body, options).then((request) => request(this.axios, this.basePath));
|
|
206
206
|
}
|
|
207
207
|
/**
|
|
208
208
|
* Returns aggregated replenishment program metrics for a selling partner\'s offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
209
|
-
* @param {
|
|
209
|
+
* @param {ReplenishmentApiListOfferMetricsRequest} requestParameters Request parameters.
|
|
210
210
|
* @param {*} [options] Override http request option.
|
|
211
211
|
* @throws {RequiredError}
|
|
212
|
-
* @memberof
|
|
212
|
+
* @memberof ReplenishmentApi
|
|
213
213
|
*/
|
|
214
214
|
listOfferMetrics(requestParameters = {}, options) {
|
|
215
|
-
return
|
|
215
|
+
return ReplenishmentApiFp(this.configuration).listOfferMetrics(requestParameters.body, options).then((request) => request(this.axios, this.basePath));
|
|
216
216
|
}
|
|
217
217
|
/**
|
|
218
218
|
* Returns the details of a selling partner\'s replenishment program offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
219
|
-
* @param {
|
|
219
|
+
* @param {ReplenishmentApiListOffersRequest} requestParameters Request parameters.
|
|
220
220
|
* @param {*} [options] Override http request option.
|
|
221
221
|
* @throws {RequiredError}
|
|
222
|
-
* @memberof
|
|
222
|
+
* @memberof ReplenishmentApi
|
|
223
223
|
*/
|
|
224
224
|
listOffers(requestParameters = {}, options) {
|
|
225
|
-
return
|
|
225
|
+
return ReplenishmentApiFp(this.configuration).listOffers(requestParameters.body, options).then((request) => request(this.axios, this.basePath));
|
|
226
226
|
}
|
|
227
227
|
}
|
package/dist/es/api-model/api.js
CHANGED
package/dist/es/client.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createAxiosInstance } from '@sp-api-sdk/common';
|
|
2
|
-
import { Configuration,
|
|
2
|
+
import { Configuration, ReplenishmentApi } from './api-model';
|
|
3
3
|
export const clientRateLimits = [
|
|
4
4
|
{
|
|
5
5
|
method: 'post',
|
|
@@ -23,7 +23,7 @@ export const clientRateLimits = [
|
|
|
23
23
|
burst: 1,
|
|
24
24
|
},
|
|
25
25
|
];
|
|
26
|
-
export class ReplenishmentApiClient extends
|
|
26
|
+
export class ReplenishmentApiClient extends ReplenishmentApi {
|
|
27
27
|
constructor(configuration) {
|
|
28
28
|
const { axios, endpoint } = createAxiosInstance(configuration, clientRateLimits);
|
|
29
29
|
super(new Configuration(), endpoint, axios);
|
|
@@ -20,10 +20,10 @@ import type { ListOfferMetricsResponse } from '../models';
|
|
|
20
20
|
import type { ListOffersRequest } from '../models';
|
|
21
21
|
import type { ListOffersResponse } from '../models';
|
|
22
22
|
/**
|
|
23
|
-
*
|
|
23
|
+
* ReplenishmentApi - axios parameter creator
|
|
24
24
|
* @export
|
|
25
25
|
*/
|
|
26
|
-
export declare const
|
|
26
|
+
export declare const ReplenishmentApiAxiosParamCreator: (configuration?: Configuration) => {
|
|
27
27
|
/**
|
|
28
28
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
29
29
|
* @param {GetSellingPartnerMetricsRequest} [body] The request body for the `getSellingPartnerMetrics` operation.
|
|
@@ -47,10 +47,10 @@ export declare const OffersApiAxiosParamCreator: (configuration?: Configuration)
|
|
|
47
47
|
listOffers: (body?: ListOffersRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
48
48
|
};
|
|
49
49
|
/**
|
|
50
|
-
*
|
|
50
|
+
* ReplenishmentApi - functional programming interface
|
|
51
51
|
* @export
|
|
52
52
|
*/
|
|
53
|
-
export declare const
|
|
53
|
+
export declare const ReplenishmentApiFp: (configuration?: Configuration) => {
|
|
54
54
|
/**
|
|
55
55
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
56
56
|
* @param {GetSellingPartnerMetricsRequest} [body] The request body for the `getSellingPartnerMetrics` operation.
|
|
@@ -74,100 +74,100 @@ export declare const OffersApiFp: (configuration?: Configuration) => {
|
|
|
74
74
|
listOffers(body?: ListOffersRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListOffersResponse>>;
|
|
75
75
|
};
|
|
76
76
|
/**
|
|
77
|
-
*
|
|
77
|
+
* ReplenishmentApi - factory interface
|
|
78
78
|
* @export
|
|
79
79
|
*/
|
|
80
|
-
export declare const
|
|
80
|
+
export declare const ReplenishmentApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
|
|
81
81
|
/**
|
|
82
82
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
83
|
-
* @param {
|
|
83
|
+
* @param {ReplenishmentApiGetSellingPartnerMetricsRequest} requestParameters Request parameters.
|
|
84
84
|
* @param {*} [options] Override http request option.
|
|
85
85
|
* @throws {RequiredError}
|
|
86
86
|
*/
|
|
87
|
-
getSellingPartnerMetrics(requestParameters?:
|
|
87
|
+
getSellingPartnerMetrics(requestParameters?: ReplenishmentApiGetSellingPartnerMetricsRequest, options?: RawAxiosRequestConfig): AxiosPromise<GetSellingPartnerMetricsResponse>;
|
|
88
88
|
/**
|
|
89
89
|
* Returns aggregated replenishment program metrics for a selling partner\'s offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
90
|
-
* @param {
|
|
90
|
+
* @param {ReplenishmentApiListOfferMetricsRequest} requestParameters Request parameters.
|
|
91
91
|
* @param {*} [options] Override http request option.
|
|
92
92
|
* @throws {RequiredError}
|
|
93
93
|
*/
|
|
94
|
-
listOfferMetrics(requestParameters?:
|
|
94
|
+
listOfferMetrics(requestParameters?: ReplenishmentApiListOfferMetricsRequest, options?: RawAxiosRequestConfig): AxiosPromise<ListOfferMetricsResponse>;
|
|
95
95
|
/**
|
|
96
96
|
* Returns the details of a selling partner\'s replenishment program offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
97
|
-
* @param {
|
|
97
|
+
* @param {ReplenishmentApiListOffersRequest} requestParameters Request parameters.
|
|
98
98
|
* @param {*} [options] Override http request option.
|
|
99
99
|
* @throws {RequiredError}
|
|
100
100
|
*/
|
|
101
|
-
listOffers(requestParameters?:
|
|
101
|
+
listOffers(requestParameters?: ReplenishmentApiListOffersRequest, options?: RawAxiosRequestConfig): AxiosPromise<ListOffersResponse>;
|
|
102
102
|
};
|
|
103
103
|
/**
|
|
104
|
-
* Request parameters for getSellingPartnerMetrics operation in
|
|
104
|
+
* Request parameters for getSellingPartnerMetrics operation in ReplenishmentApi.
|
|
105
105
|
* @export
|
|
106
|
-
* @interface
|
|
106
|
+
* @interface ReplenishmentApiGetSellingPartnerMetricsRequest
|
|
107
107
|
*/
|
|
108
|
-
export interface
|
|
108
|
+
export interface ReplenishmentApiGetSellingPartnerMetricsRequest {
|
|
109
109
|
/**
|
|
110
110
|
* The request body for the `getSellingPartnerMetrics` operation.
|
|
111
111
|
* @type {GetSellingPartnerMetricsRequest}
|
|
112
|
-
* @memberof
|
|
112
|
+
* @memberof ReplenishmentApiGetSellingPartnerMetrics
|
|
113
113
|
*/
|
|
114
114
|
readonly body?: GetSellingPartnerMetricsRequest;
|
|
115
115
|
}
|
|
116
116
|
/**
|
|
117
|
-
* Request parameters for listOfferMetrics operation in
|
|
117
|
+
* Request parameters for listOfferMetrics operation in ReplenishmentApi.
|
|
118
118
|
* @export
|
|
119
|
-
* @interface
|
|
119
|
+
* @interface ReplenishmentApiListOfferMetricsRequest
|
|
120
120
|
*/
|
|
121
|
-
export interface
|
|
121
|
+
export interface ReplenishmentApiListOfferMetricsRequest {
|
|
122
122
|
/**
|
|
123
123
|
* The request body for the `listOfferMetrics` operation.
|
|
124
124
|
* @type {ListOfferMetricsRequest}
|
|
125
|
-
* @memberof
|
|
125
|
+
* @memberof ReplenishmentApiListOfferMetrics
|
|
126
126
|
*/
|
|
127
127
|
readonly body?: ListOfferMetricsRequest;
|
|
128
128
|
}
|
|
129
129
|
/**
|
|
130
|
-
* Request parameters for listOffers operation in
|
|
130
|
+
* Request parameters for listOffers operation in ReplenishmentApi.
|
|
131
131
|
* @export
|
|
132
|
-
* @interface
|
|
132
|
+
* @interface ReplenishmentApiListOffersRequest
|
|
133
133
|
*/
|
|
134
|
-
export interface
|
|
134
|
+
export interface ReplenishmentApiListOffersRequest {
|
|
135
135
|
/**
|
|
136
136
|
* The request body for the `listOffers` operation.
|
|
137
137
|
* @type {ListOffersRequest}
|
|
138
|
-
* @memberof
|
|
138
|
+
* @memberof ReplenishmentApiListOffers
|
|
139
139
|
*/
|
|
140
140
|
readonly body?: ListOffersRequest;
|
|
141
141
|
}
|
|
142
142
|
/**
|
|
143
|
-
*
|
|
143
|
+
* ReplenishmentApi - object-oriented interface
|
|
144
144
|
* @export
|
|
145
|
-
* @class
|
|
145
|
+
* @class ReplenishmentApi
|
|
146
146
|
* @extends {BaseAPI}
|
|
147
147
|
*/
|
|
148
|
-
export declare class
|
|
148
|
+
export declare class ReplenishmentApi extends BaseAPI {
|
|
149
149
|
/**
|
|
150
150
|
* Returns aggregated replenishment program metrics for a selling partner. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
151
|
-
* @param {
|
|
151
|
+
* @param {ReplenishmentApiGetSellingPartnerMetricsRequest} requestParameters Request parameters.
|
|
152
152
|
* @param {*} [options] Override http request option.
|
|
153
153
|
* @throws {RequiredError}
|
|
154
|
-
* @memberof
|
|
154
|
+
* @memberof ReplenishmentApi
|
|
155
155
|
*/
|
|
156
|
-
getSellingPartnerMetrics(requestParameters?:
|
|
156
|
+
getSellingPartnerMetrics(requestParameters?: ReplenishmentApiGetSellingPartnerMetricsRequest, options?: RawAxiosRequestConfig): Promise<globalAxios.AxiosResponse<GetSellingPartnerMetricsResponse, any>>;
|
|
157
157
|
/**
|
|
158
158
|
* Returns aggregated replenishment program metrics for a selling partner\'s offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
159
|
-
* @param {
|
|
159
|
+
* @param {ReplenishmentApiListOfferMetricsRequest} requestParameters Request parameters.
|
|
160
160
|
* @param {*} [options] Override http request option.
|
|
161
161
|
* @throws {RequiredError}
|
|
162
|
-
* @memberof
|
|
162
|
+
* @memberof ReplenishmentApi
|
|
163
163
|
*/
|
|
164
|
-
listOfferMetrics(requestParameters?:
|
|
164
|
+
listOfferMetrics(requestParameters?: ReplenishmentApiListOfferMetricsRequest, options?: RawAxiosRequestConfig): Promise<globalAxios.AxiosResponse<ListOfferMetricsResponse, any>>;
|
|
165
165
|
/**
|
|
166
166
|
* Returns the details of a selling partner\'s replenishment program offers. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 1 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
|
|
167
|
-
* @param {
|
|
167
|
+
* @param {ReplenishmentApiListOffersRequest} requestParameters Request parameters.
|
|
168
168
|
* @param {*} [options] Override http request option.
|
|
169
169
|
* @throws {RequiredError}
|
|
170
|
-
* @memberof
|
|
170
|
+
* @memberof ReplenishmentApi
|
|
171
171
|
*/
|
|
172
|
-
listOffers(requestParameters?:
|
|
172
|
+
listOffers(requestParameters?: ReplenishmentApiListOffersRequest, options?: RawAxiosRequestConfig): Promise<globalAxios.AxiosResponse<ListOffersResponse, any>>;
|
|
173
173
|
}
|
package/dist/types/client.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type ClientConfiguration, type RateLimit } from '@sp-api-sdk/common';
|
|
2
|
-
import {
|
|
2
|
+
import { ReplenishmentApi } from './api-model';
|
|
3
3
|
export declare const clientRateLimits: RateLimit[];
|
|
4
|
-
export declare class ReplenishmentApiClient extends
|
|
4
|
+
export declare class ReplenishmentApiClient extends ReplenishmentApi {
|
|
5
5
|
constructor(configuration: ClientConfiguration);
|
|
6
6
|
}
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@sp-api-sdk/replenishment-api-2022-11-07",
|
|
3
3
|
"author": "Bertrand Marron <bertrand@bizon.solutions>",
|
|
4
4
|
"description": "The Selling Partner API for Replenishment (Replenishment API) provides programmatic access to replenishment program metrics and offers. These programs provide recurring delivery of any replenishable item at a frequency chosen by the customer. The Replenishment API is available worldwide wherever Amazon Subscribe & Save is available or is supported. The API is available to vendors and FBA selling partners.",
|
|
5
|
-
"version": "
|
|
5
|
+
"version": "5.0.0",
|
|
6
6
|
"main": "dist/cjs/index.js",
|
|
7
7
|
"module": "dist/es/index.js",
|
|
8
8
|
"types": "dist/types/index.d.ts",
|
|
@@ -18,8 +18,8 @@
|
|
|
18
18
|
"dist/**/*.d.ts"
|
|
19
19
|
],
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@sp-api-sdk/common": "2.1.
|
|
22
|
-
"axios": "^1.
|
|
21
|
+
"@sp-api-sdk/common": "2.1.14",
|
|
22
|
+
"axios": "^1.9.0"
|
|
23
23
|
},
|
|
24
24
|
"repository": {
|
|
25
25
|
"type": "git",
|
|
@@ -40,5 +40,5 @@
|
|
|
40
40
|
"sp sdk",
|
|
41
41
|
"replenishment api"
|
|
42
42
|
],
|
|
43
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "773f45c3f4aab28e0bd9f6033045988800d7f258"
|
|
44
44
|
}
|