@sp-api-sdk/uploads-api-2020-11-01 1.10.9 → 1.11.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/README.md CHANGED
@@ -33,6 +33,7 @@ const auth = new SellingPartnerApiAuth({
33
33
  refreshToken: 'Atzr|…',
34
34
  accessKeyId: '',
35
35
  secretAccessKey: '',
36
+ region: 'eu-west-1',
36
37
  role: {
37
38
  arn: 'arn:aws:iam::…',
38
39
  },
@@ -28,7 +28,7 @@ const base_1 = require("../base");
28
28
  const UploadsApiAxiosParamCreator = function (configuration) {
29
29
  return {
30
30
  /**
31
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
31
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
32
32
  * @param {Array<string>} marketplaceIds A list of marketplace identifiers. This specifies the marketplaces where the upload will be available. Only one marketplace can be specified.
33
33
  * @param {string} contentMD5 An MD5 hash of the content to be submitted to the upload destination. This value is used to determine if the data has been corrupted or tampered with during transit.
34
34
  * @param {string} resource The resource for the upload destination that you are creating. For example, if you are creating an upload destination for the createLegalDisclosure operation of the Messaging API, the &#x60;{resource}&#x60; would be &#x60;/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;, and the entire path would be &#x60;/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;. If you are creating an upload destination for an Aplus content document, the &#x60;{resource}&#x60; would be &#x60;aplus/2020-11-01/contentDocuments&#x60; and the path would be &#x60;/uploads/v1/uploadDestinations/aplus/2020-11-01/contentDocuments&#x60;.
@@ -82,7 +82,7 @@ const UploadsApiFp = function (configuration) {
82
82
  const localVarAxiosParamCreator = (0, exports.UploadsApiAxiosParamCreator)(configuration);
83
83
  return {
84
84
  /**
85
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
85
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
86
86
  * @param {Array<string>} marketplaceIds A list of marketplace identifiers. This specifies the marketplaces where the upload will be available. Only one marketplace can be specified.
87
87
  * @param {string} contentMD5 An MD5 hash of the content to be submitted to the upload destination. This value is used to determine if the data has been corrupted or tampered with during transit.
88
88
  * @param {string} resource The resource for the upload destination that you are creating. For example, if you are creating an upload destination for the createLegalDisclosure operation of the Messaging API, the &#x60;{resource}&#x60; would be &#x60;/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;, and the entire path would be &#x60;/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;. If you are creating an upload destination for an Aplus content document, the &#x60;{resource}&#x60; would be &#x60;aplus/2020-11-01/contentDocuments&#x60; and the path would be &#x60;/uploads/v1/uploadDestinations/aplus/2020-11-01/contentDocuments&#x60;.
@@ -105,16 +105,13 @@ const UploadsApiFactory = function (configuration, basePath, axios) {
105
105
  const localVarFp = (0, exports.UploadsApiFp)(configuration);
106
106
  return {
107
107
  /**
108
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
109
- * @param {Array<string>} marketplaceIds A list of marketplace identifiers. This specifies the marketplaces where the upload will be available. Only one marketplace can be specified.
110
- * @param {string} contentMD5 An MD5 hash of the content to be submitted to the upload destination. This value is used to determine if the data has been corrupted or tampered with during transit.
111
- * @param {string} resource The resource for the upload destination that you are creating. For example, if you are creating an upload destination for the createLegalDisclosure operation of the Messaging API, the &#x60;{resource}&#x60; would be &#x60;/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;, and the entire path would be &#x60;/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;. If you are creating an upload destination for an Aplus content document, the &#x60;{resource}&#x60; would be &#x60;aplus/2020-11-01/contentDocuments&#x60; and the path would be &#x60;/uploads/v1/uploadDestinations/aplus/2020-11-01/contentDocuments&#x60;.
112
- * @param {string} [contentType] The content type of the file to be uploaded.
108
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
109
+ * @param {UploadsApiCreateUploadDestinationForResourceRequest} requestParameters Request parameters.
113
110
  * @param {*} [options] Override http request option.
114
111
  * @throws {RequiredError}
115
112
  */
116
- createUploadDestinationForResource(marketplaceIds, contentMD5, resource, contentType, options) {
117
- return localVarFp.createUploadDestinationForResource(marketplaceIds, contentMD5, resource, contentType, options).then((request) => request(axios, basePath));
113
+ createUploadDestinationForResource(requestParameters, options) {
114
+ return localVarFp.createUploadDestinationForResource(requestParameters.marketplaceIds, requestParameters.contentMD5, requestParameters.resource, requestParameters.contentType, options).then((request) => request(axios, basePath));
118
115
  },
119
116
  };
120
117
  };
@@ -127,7 +124,7 @@ exports.UploadsApiFactory = UploadsApiFactory;
127
124
  */
128
125
  class UploadsApi extends base_1.BaseAPI {
129
126
  /**
130
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
127
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
131
128
  * @param {UploadsApiCreateUploadDestinationForResourceRequest} requestParameters Request parameters.
132
129
  * @param {*} [options] Override http request option.
133
130
  * @throws {RequiredError}
@@ -15,8 +15,6 @@
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
16
  exports.RequiredError = exports.BaseAPI = exports.COLLECTION_FORMATS = exports.BASE_PATH = void 0;
17
17
  const tslib_1 = require("tslib");
18
- // Some imports not used depending on template conditions
19
- // @ts-ignore
20
18
  const axios_1 = tslib_1.__importDefault(require("axios"));
21
19
  exports.BASE_PATH = "https://sellingpartnerapi-na.amazon.com".replace(/\/+$/, "");
22
20
  /**
@@ -57,10 +55,10 @@ exports.BaseAPI = BaseAPI;
57
55
  */
58
56
  class RequiredError extends Error {
59
57
  field;
60
- name = "RequiredError";
61
58
  constructor(field, msg) {
62
59
  super(msg);
63
60
  this.field = field;
61
+ this.name = "RequiredError";
64
62
  }
65
63
  }
66
64
  exports.RequiredError = RequiredError;
@@ -81,6 +81,8 @@ const setOAuthToObject = async function (object, name, scopes, configuration) {
81
81
  };
82
82
  exports.setOAuthToObject = setOAuthToObject;
83
83
  function setFlattenedQueryParams(urlSearchParams, parameter, key = "") {
84
+ if (parameter == null)
85
+ return;
84
86
  if (typeof parameter === "object") {
85
87
  if (Array.isArray(parameter)) {
86
88
  parameter.forEach(item => setFlattenedQueryParams(urlSearchParams, item, key));
@@ -8,8 +8,8 @@ exports.clientRateLimits = [
8
8
  method: 'post',
9
9
  // eslint-disable-next-line prefer-regex-literals
10
10
  urlRegex: new RegExp('^/uploads/2020-11-01/uploadDestinations/[^/]*$'),
11
- rate: 0.1,
12
- burst: 5,
11
+ rate: 10,
12
+ burst: 10,
13
13
  },
14
14
  ];
15
15
  class UploadsApiClient extends api_model_1.UploadsApi {
@@ -24,7 +24,7 @@ import { BASE_PATH, COLLECTION_FORMATS, BaseAPI } from '../base';
24
24
  export const UploadsApiAxiosParamCreator = function (configuration) {
25
25
  return {
26
26
  /**
27
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
27
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
28
28
  * @param {Array<string>} marketplaceIds A list of marketplace identifiers. This specifies the marketplaces where the upload will be available. Only one marketplace can be specified.
29
29
  * @param {string} contentMD5 An MD5 hash of the content to be submitted to the upload destination. This value is used to determine if the data has been corrupted or tampered with during transit.
30
30
  * @param {string} resource The resource for the upload destination that you are creating. For example, if you are creating an upload destination for the createLegalDisclosure operation of the Messaging API, the &#x60;{resource}&#x60; would be &#x60;/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;, and the entire path would be &#x60;/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;. If you are creating an upload destination for an Aplus content document, the &#x60;{resource}&#x60; would be &#x60;aplus/2020-11-01/contentDocuments&#x60; and the path would be &#x60;/uploads/v1/uploadDestinations/aplus/2020-11-01/contentDocuments&#x60;.
@@ -77,7 +77,7 @@ export const UploadsApiFp = function (configuration) {
77
77
  const localVarAxiosParamCreator = UploadsApiAxiosParamCreator(configuration);
78
78
  return {
79
79
  /**
80
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
80
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
81
81
  * @param {Array<string>} marketplaceIds A list of marketplace identifiers. This specifies the marketplaces where the upload will be available. Only one marketplace can be specified.
82
82
  * @param {string} contentMD5 An MD5 hash of the content to be submitted to the upload destination. This value is used to determine if the data has been corrupted or tampered with during transit.
83
83
  * @param {string} resource The resource for the upload destination that you are creating. For example, if you are creating an upload destination for the createLegalDisclosure operation of the Messaging API, the &#x60;{resource}&#x60; would be &#x60;/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;, and the entire path would be &#x60;/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;. If you are creating an upload destination for an Aplus content document, the &#x60;{resource}&#x60; would be &#x60;aplus/2020-11-01/contentDocuments&#x60; and the path would be &#x60;/uploads/v1/uploadDestinations/aplus/2020-11-01/contentDocuments&#x60;.
@@ -99,16 +99,13 @@ export const UploadsApiFactory = function (configuration, basePath, axios) {
99
99
  const localVarFp = UploadsApiFp(configuration);
100
100
  return {
101
101
  /**
102
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
103
- * @param {Array<string>} marketplaceIds A list of marketplace identifiers. This specifies the marketplaces where the upload will be available. Only one marketplace can be specified.
104
- * @param {string} contentMD5 An MD5 hash of the content to be submitted to the upload destination. This value is used to determine if the data has been corrupted or tampered with during transit.
105
- * @param {string} resource The resource for the upload destination that you are creating. For example, if you are creating an upload destination for the createLegalDisclosure operation of the Messaging API, the &#x60;{resource}&#x60; would be &#x60;/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;, and the entire path would be &#x60;/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;. If you are creating an upload destination for an Aplus content document, the &#x60;{resource}&#x60; would be &#x60;aplus/2020-11-01/contentDocuments&#x60; and the path would be &#x60;/uploads/v1/uploadDestinations/aplus/2020-11-01/contentDocuments&#x60;.
106
- * @param {string} [contentType] The content type of the file to be uploaded.
102
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
103
+ * @param {UploadsApiCreateUploadDestinationForResourceRequest} requestParameters Request parameters.
107
104
  * @param {*} [options] Override http request option.
108
105
  * @throws {RequiredError}
109
106
  */
110
- createUploadDestinationForResource(marketplaceIds, contentMD5, resource, contentType, options) {
111
- return localVarFp.createUploadDestinationForResource(marketplaceIds, contentMD5, resource, contentType, options).then((request) => request(axios, basePath));
107
+ createUploadDestinationForResource(requestParameters, options) {
108
+ return localVarFp.createUploadDestinationForResource(requestParameters.marketplaceIds, requestParameters.contentMD5, requestParameters.resource, requestParameters.contentType, options).then((request) => request(axios, basePath));
112
109
  },
113
110
  };
114
111
  };
@@ -120,7 +117,7 @@ export const UploadsApiFactory = function (configuration, basePath, axios) {
120
117
  */
121
118
  export class UploadsApi extends BaseAPI {
122
119
  /**
123
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
120
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
124
121
  * @param {UploadsApiCreateUploadDestinationForResourceRequest} requestParameters Request parameters.
125
122
  * @param {*} [options] Override http request option.
126
123
  * @throws {RequiredError}
@@ -11,8 +11,6 @@
11
11
  * https://openapi-generator.tech
12
12
  * Do not edit the class manually.
13
13
  */
14
- // Some imports not used depending on template conditions
15
- // @ts-ignore
16
14
  import globalAxios from 'axios';
17
15
  export const BASE_PATH = "https://sellingpartnerapi-na.amazon.com".replace(/\/+$/, "");
18
16
  /**
@@ -52,9 +50,9 @@ export class BaseAPI {
52
50
  */
53
51
  export class RequiredError extends Error {
54
52
  field;
55
- name = "RequiredError";
56
53
  constructor(field, msg) {
57
54
  super(msg);
58
55
  this.field = field;
56
+ this.name = "RequiredError";
59
57
  }
60
58
  }
@@ -73,6 +73,8 @@ export const setOAuthToObject = async function (object, name, scopes, configurat
73
73
  }
74
74
  };
75
75
  function setFlattenedQueryParams(urlSearchParams, parameter, key = "") {
76
+ if (parameter == null)
77
+ return;
76
78
  if (typeof parameter === "object") {
77
79
  if (Array.isArray(parameter)) {
78
80
  parameter.forEach(item => setFlattenedQueryParams(urlSearchParams, item, key));
@@ -5,8 +5,8 @@ export const clientRateLimits = [
5
5
  method: 'post',
6
6
  // eslint-disable-next-line prefer-regex-literals
7
7
  urlRegex: new RegExp('^/uploads/2020-11-01/uploadDestinations/[^/]*$'),
8
- rate: 0.1,
9
- burst: 5,
8
+ rate: 10,
9
+ burst: 10,
10
10
  },
11
11
  ];
12
12
  export class UploadsApiClient extends UploadsApi {
@@ -9,8 +9,8 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
- import { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
13
- import { Configuration } from '../configuration';
12
+ import type { Configuration } from '../configuration';
13
+ import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
14
14
  import { RequestArgs, BaseAPI } from '../base';
15
15
  import { CreateUploadDestinationResponse } from '../models';
16
16
  /**
@@ -19,7 +19,7 @@ import { CreateUploadDestinationResponse } from '../models';
19
19
  */
20
20
  export declare const UploadsApiAxiosParamCreator: (configuration?: Configuration) => {
21
21
  /**
22
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
22
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
23
23
  * @param {Array<string>} marketplaceIds A list of marketplace identifiers. This specifies the marketplaces where the upload will be available. Only one marketplace can be specified.
24
24
  * @param {string} contentMD5 An MD5 hash of the content to be submitted to the upload destination. This value is used to determine if the data has been corrupted or tampered with during transit.
25
25
  * @param {string} resource The resource for the upload destination that you are creating. For example, if you are creating an upload destination for the createLegalDisclosure operation of the Messaging API, the &#x60;{resource}&#x60; would be &#x60;/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;, and the entire path would be &#x60;/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;. If you are creating an upload destination for an Aplus content document, the &#x60;{resource}&#x60; would be &#x60;aplus/2020-11-01/contentDocuments&#x60; and the path would be &#x60;/uploads/v1/uploadDestinations/aplus/2020-11-01/contentDocuments&#x60;.
@@ -35,7 +35,7 @@ export declare const UploadsApiAxiosParamCreator: (configuration?: Configuration
35
35
  */
36
36
  export declare const UploadsApiFp: (configuration?: Configuration) => {
37
37
  /**
38
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
38
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
39
39
  * @param {Array<string>} marketplaceIds A list of marketplace identifiers. This specifies the marketplaces where the upload will be available. Only one marketplace can be specified.
40
40
  * @param {string} contentMD5 An MD5 hash of the content to be submitted to the upload destination. This value is used to determine if the data has been corrupted or tampered with during transit.
41
41
  * @param {string} resource The resource for the upload destination that you are creating. For example, if you are creating an upload destination for the createLegalDisclosure operation of the Messaging API, the &#x60;{resource}&#x60; would be &#x60;/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;, and the entire path would be &#x60;/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;. If you are creating an upload destination for an Aplus content document, the &#x60;{resource}&#x60; would be &#x60;aplus/2020-11-01/contentDocuments&#x60; and the path would be &#x60;/uploads/v1/uploadDestinations/aplus/2020-11-01/contentDocuments&#x60;.
@@ -51,15 +51,12 @@ export declare const UploadsApiFp: (configuration?: Configuration) => {
51
51
  */
52
52
  export declare const UploadsApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
53
53
  /**
54
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
55
- * @param {Array<string>} marketplaceIds A list of marketplace identifiers. This specifies the marketplaces where the upload will be available. Only one marketplace can be specified.
56
- * @param {string} contentMD5 An MD5 hash of the content to be submitted to the upload destination. This value is used to determine if the data has been corrupted or tampered with during transit.
57
- * @param {string} resource The resource for the upload destination that you are creating. For example, if you are creating an upload destination for the createLegalDisclosure operation of the Messaging API, the &#x60;{resource}&#x60; would be &#x60;/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;, and the entire path would be &#x60;/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure&#x60;. If you are creating an upload destination for an Aplus content document, the &#x60;{resource}&#x60; would be &#x60;aplus/2020-11-01/contentDocuments&#x60; and the path would be &#x60;/uploads/v1/uploadDestinations/aplus/2020-11-01/contentDocuments&#x60;.
58
- * @param {string} [contentType] The content type of the file to be uploaded.
54
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
55
+ * @param {UploadsApiCreateUploadDestinationForResourceRequest} requestParameters Request parameters.
59
56
  * @param {*} [options] Override http request option.
60
57
  * @throws {RequiredError}
61
58
  */
62
- createUploadDestinationForResource(marketplaceIds: Array<string>, contentMD5: string, resource: string, contentType?: string, options?: any): AxiosPromise<CreateUploadDestinationResponse>;
59
+ createUploadDestinationForResource(requestParameters: UploadsApiCreateUploadDestinationForResourceRequest, options?: AxiosRequestConfig): AxiosPromise<CreateUploadDestinationResponse>;
63
60
  };
64
61
  /**
65
62
  * Request parameters for createUploadDestinationForResource operation in UploadsApi.
@@ -100,7 +97,7 @@ export interface UploadsApiCreateUploadDestinationForResourceRequest {
100
97
  */
101
98
  export declare class UploadsApi extends BaseAPI {
102
99
  /**
103
- * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | .1 | 5 | For more information, see \"Usage Plans and Rate Limits\" in the Selling Partner API documentation.
100
+ * Creates an upload destination, returning the information required to upload a file to the destination and to programmatically access the file. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 10 | 10 | 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).
104
101
  * @param {UploadsApiCreateUploadDestinationForResourceRequest} requestParameters Request parameters.
105
102
  * @param {*} [options] Override http request option.
106
103
  * @throws {RequiredError}
@@ -9,8 +9,8 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
- import { Configuration } from "./configuration";
13
- import { AxiosInstance, AxiosRequestConfig } from 'axios';
12
+ import type { Configuration } from './configuration';
13
+ import type { AxiosInstance, AxiosRequestConfig } from 'axios';
14
14
  export declare const BASE_PATH: string;
15
15
  /**
16
16
  *
@@ -50,6 +50,5 @@ export declare class BaseAPI {
50
50
  */
51
51
  export declare class RequiredError extends Error {
52
52
  field: string;
53
- name: "RequiredError";
54
53
  constructor(field: string, msg?: string);
55
54
  }
@@ -10,9 +10,9 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  /// <reference types="node" />
13
- import { Configuration } from "./configuration";
14
- import { RequestArgs } from "./base";
15
- import { AxiosInstance, AxiosResponse } from 'axios';
13
+ import type { Configuration } from "./configuration";
14
+ import type { RequestArgs } from "./base";
15
+ import type { AxiosInstance, AxiosResponse } from 'axios';
16
16
  /**
17
17
  *
18
18
  * @export
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@sp-api-sdk/uploads-api-2020-11-01",
3
3
  "author": "Vincent Mesquita <vincent.mesquita@bizon.solutions>",
4
4
  "description": "The Uploads API lets you upload files that you can programmatically access using other Selling Partner APIs, such as the A+ Content API and the Messaging API.",
5
- "version": "1.10.9",
5
+ "version": "1.11.0",
6
6
  "main": "dist/cjs/index.js",
7
7
  "module": "dist/es/index.js",
8
8
  "types": "dist/types/index.d.ts",
@@ -26,7 +26,7 @@
26
26
  "test": "jest"
27
27
  },
28
28
  "dependencies": {
29
- "@sp-api-sdk/common": "^1.9.21",
29
+ "@sp-api-sdk/common": "^1.10.0",
30
30
  "axios": "^0.27.2"
31
31
  },
32
32
  "repository": {
@@ -51,5 +51,5 @@
51
51
  "typedoc": {
52
52
  "entryPoint": "./index.ts"
53
53
  },
54
- "gitHead": "4aae180b5a1395b37b673b93c285065ddba25470"
54
+ "gitHead": "3a4bc7db3349aaf06b421f0e89c9fb3f60a76cd1"
55
55
  }