@sp-api-sdk/uploads-api-2020-11-01 3.0.1 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/api-model/api/uploads-api.js +6 -6
- package/dist/cjs/api-model/configuration.js +1 -2
- package/dist/es/api-model/api/uploads-api.js +6 -6
- package/dist/es/api-model/configuration.js +1 -2
- package/dist/types/api-model/api/uploads-api.d.ts +9 -9
- package/dist/types/api-model/common.d.ts +1 -1
- package/package.json +4 -4
|
@@ -31,10 +31,10 @@ const UploadsApiAxiosParamCreator = function (configuration) {
|
|
|
31
31
|
return {
|
|
32
32
|
/**
|
|
33
33
|
* 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).
|
|
34
|
-
* @param {Array<string>} marketplaceIds
|
|
34
|
+
* @param {Array<string>} marketplaceIds The marketplace ID is the globally unique identifier of a marketplace. To find the ID for your marketplace, refer to [Marketplace IDs](https://developer-docs.amazon.com/sp-api/docs/marketplace-ids).
|
|
35
35
|
* @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.
|
|
36
|
-
* @param {string} resource The
|
|
37
|
-
* @param {string} [contentType] The content type of the file
|
|
36
|
+
* @param {string} resource The upload destination for your resource. For example, if you create an upload destination for the `createLegalDisclosure` operation of the Messaging API, the `{resource}` would be `/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`, and the entire path would be `/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`. If you create an upload destination for an Aplus content document, the `{resource}` would be `aplus/2020-11-01/contentDocuments` and the path would be `/uploads/2020-11-01/uploadDestinations/aplus/2020-11-01/contentDocuments`.
|
|
37
|
+
* @param {string} [contentType] The content type of the file you upload.
|
|
38
38
|
* @param {*} [options] Override http request option.
|
|
39
39
|
* @throws {RequiredError}
|
|
40
40
|
*/
|
|
@@ -85,10 +85,10 @@ const UploadsApiFp = function (configuration) {
|
|
|
85
85
|
return {
|
|
86
86
|
/**
|
|
87
87
|
* 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).
|
|
88
|
-
* @param {Array<string>} marketplaceIds
|
|
88
|
+
* @param {Array<string>} marketplaceIds The marketplace ID is the globally unique identifier of a marketplace. To find the ID for your marketplace, refer to [Marketplace IDs](https://developer-docs.amazon.com/sp-api/docs/marketplace-ids).
|
|
89
89
|
* @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.
|
|
90
|
-
* @param {string} resource The
|
|
91
|
-
* @param {string} [contentType] The content type of the file
|
|
90
|
+
* @param {string} resource The upload destination for your resource. For example, if you create an upload destination for the `createLegalDisclosure` operation of the Messaging API, the `{resource}` would be `/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`, and the entire path would be `/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`. If you create an upload destination for an Aplus content document, the `{resource}` would be `aplus/2020-11-01/contentDocuments` and the path would be `/uploads/2020-11-01/uploadDestinations/aplus/2020-11-01/contentDocuments`.
|
|
91
|
+
* @param {string} [contentType] The content type of the file you upload.
|
|
92
92
|
* @param {*} [options] Override http request option.
|
|
93
93
|
* @throws {RequiredError}
|
|
94
94
|
*/
|
|
@@ -79,11 +79,10 @@ class Configuration {
|
|
|
79
79
|
this.basePath = param.basePath;
|
|
80
80
|
this.serverIndex = param.serverIndex;
|
|
81
81
|
this.baseOptions = {
|
|
82
|
+
...param.baseOptions,
|
|
82
83
|
headers: {
|
|
83
84
|
...param.baseOptions?.headers,
|
|
84
|
-
'User-Agent': "OpenAPI-Generator/typescript-axios"
|
|
85
85
|
},
|
|
86
|
-
...param.baseOptions
|
|
87
86
|
};
|
|
88
87
|
this.formDataCtor = param.formDataCtor;
|
|
89
88
|
}
|
|
@@ -25,10 +25,10 @@ export const UploadsApiAxiosParamCreator = function (configuration) {
|
|
|
25
25
|
return {
|
|
26
26
|
/**
|
|
27
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
|
-
* @param {Array<string>} marketplaceIds
|
|
28
|
+
* @param {Array<string>} marketplaceIds The marketplace ID is the globally unique identifier of a marketplace. To find the ID for your marketplace, refer to [Marketplace IDs](https://developer-docs.amazon.com/sp-api/docs/marketplace-ids).
|
|
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
|
-
* @param {string} resource The
|
|
31
|
-
* @param {string} [contentType] The content type of the file
|
|
30
|
+
* @param {string} resource The upload destination for your resource. For example, if you create an upload destination for the `createLegalDisclosure` operation of the Messaging API, the `{resource}` would be `/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`, and the entire path would be `/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`. If you create an upload destination for an Aplus content document, the `{resource}` would be `aplus/2020-11-01/contentDocuments` and the path would be `/uploads/2020-11-01/uploadDestinations/aplus/2020-11-01/contentDocuments`.
|
|
31
|
+
* @param {string} [contentType] The content type of the file you upload.
|
|
32
32
|
* @param {*} [options] Override http request option.
|
|
33
33
|
* @throws {RequiredError}
|
|
34
34
|
*/
|
|
@@ -78,10 +78,10 @@ export const UploadsApiFp = function (configuration) {
|
|
|
78
78
|
return {
|
|
79
79
|
/**
|
|
80
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
|
-
* @param {Array<string>} marketplaceIds
|
|
81
|
+
* @param {Array<string>} marketplaceIds The marketplace ID is the globally unique identifier of a marketplace. To find the ID for your marketplace, refer to [Marketplace IDs](https://developer-docs.amazon.com/sp-api/docs/marketplace-ids).
|
|
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
|
-
* @param {string} resource The
|
|
84
|
-
* @param {string} [contentType] The content type of the file
|
|
83
|
+
* @param {string} resource The upload destination for your resource. For example, if you create an upload destination for the `createLegalDisclosure` operation of the Messaging API, the `{resource}` would be `/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`, and the entire path would be `/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`. If you create an upload destination for an Aplus content document, the `{resource}` would be `aplus/2020-11-01/contentDocuments` and the path would be `/uploads/2020-11-01/uploadDestinations/aplus/2020-11-01/contentDocuments`.
|
|
84
|
+
* @param {string} [contentType] The content type of the file you upload.
|
|
85
85
|
* @param {*} [options] Override http request option.
|
|
86
86
|
* @throws {RequiredError}
|
|
87
87
|
*/
|
|
@@ -76,11 +76,10 @@ export class Configuration {
|
|
|
76
76
|
this.basePath = param.basePath;
|
|
77
77
|
this.serverIndex = param.serverIndex;
|
|
78
78
|
this.baseOptions = {
|
|
79
|
+
...param.baseOptions,
|
|
79
80
|
headers: {
|
|
80
81
|
...param.baseOptions?.headers,
|
|
81
|
-
'User-Agent': "OpenAPI-Generator/typescript-axios"
|
|
82
82
|
},
|
|
83
|
-
...param.baseOptions
|
|
84
83
|
};
|
|
85
84
|
this.formDataCtor = param.formDataCtor;
|
|
86
85
|
}
|
|
@@ -21,10 +21,10 @@ import type { CreateUploadDestinationResponse } from '../models';
|
|
|
21
21
|
export declare const UploadsApiAxiosParamCreator: (configuration?: Configuration) => {
|
|
22
22
|
/**
|
|
23
23
|
* 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).
|
|
24
|
-
* @param {Array<string>} marketplaceIds
|
|
24
|
+
* @param {Array<string>} marketplaceIds The marketplace ID is the globally unique identifier of a marketplace. To find the ID for your marketplace, refer to [Marketplace IDs](https://developer-docs.amazon.com/sp-api/docs/marketplace-ids).
|
|
25
25
|
* @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.
|
|
26
|
-
* @param {string} resource The
|
|
27
|
-
* @param {string} [contentType] The content type of the file
|
|
26
|
+
* @param {string} resource The upload destination for your resource. For example, if you create an upload destination for the `createLegalDisclosure` operation of the Messaging API, the `{resource}` would be `/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`, and the entire path would be `/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`. If you create an upload destination for an Aplus content document, the `{resource}` would be `aplus/2020-11-01/contentDocuments` and the path would be `/uploads/2020-11-01/uploadDestinations/aplus/2020-11-01/contentDocuments`.
|
|
27
|
+
* @param {string} [contentType] The content type of the file you upload.
|
|
28
28
|
* @param {*} [options] Override http request option.
|
|
29
29
|
* @throws {RequiredError}
|
|
30
30
|
*/
|
|
@@ -37,10 +37,10 @@ export declare const UploadsApiAxiosParamCreator: (configuration?: Configuration
|
|
|
37
37
|
export declare const UploadsApiFp: (configuration?: Configuration) => {
|
|
38
38
|
/**
|
|
39
39
|
* 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).
|
|
40
|
-
* @param {Array<string>} marketplaceIds
|
|
40
|
+
* @param {Array<string>} marketplaceIds The marketplace ID is the globally unique identifier of a marketplace. To find the ID for your marketplace, refer to [Marketplace IDs](https://developer-docs.amazon.com/sp-api/docs/marketplace-ids).
|
|
41
41
|
* @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.
|
|
42
|
-
* @param {string} resource The
|
|
43
|
-
* @param {string} [contentType] The content type of the file
|
|
42
|
+
* @param {string} resource The upload destination for your resource. For example, if you create an upload destination for the `createLegalDisclosure` operation of the Messaging API, the `{resource}` would be `/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`, and the entire path would be `/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`. If you create an upload destination for an Aplus content document, the `{resource}` would be `aplus/2020-11-01/contentDocuments` and the path would be `/uploads/2020-11-01/uploadDestinations/aplus/2020-11-01/contentDocuments`.
|
|
43
|
+
* @param {string} [contentType] The content type of the file you upload.
|
|
44
44
|
* @param {*} [options] Override http request option.
|
|
45
45
|
* @throws {RequiredError}
|
|
46
46
|
*/
|
|
@@ -66,7 +66,7 @@ export declare const UploadsApiFactory: (configuration?: Configuration, basePath
|
|
|
66
66
|
*/
|
|
67
67
|
export interface UploadsApiCreateUploadDestinationForResourceRequest {
|
|
68
68
|
/**
|
|
69
|
-
*
|
|
69
|
+
* The marketplace ID is the globally unique identifier of a marketplace. To find the ID for your marketplace, refer to [Marketplace IDs](https://developer-docs.amazon.com/sp-api/docs/marketplace-ids).
|
|
70
70
|
* @type {Array<string>}
|
|
71
71
|
* @memberof UploadsApiCreateUploadDestinationForResource
|
|
72
72
|
*/
|
|
@@ -78,13 +78,13 @@ export interface UploadsApiCreateUploadDestinationForResourceRequest {
|
|
|
78
78
|
*/
|
|
79
79
|
readonly contentMD5: string;
|
|
80
80
|
/**
|
|
81
|
-
* The
|
|
81
|
+
* The upload destination for your resource. For example, if you create an upload destination for the `createLegalDisclosure` operation of the Messaging API, the `{resource}` would be `/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`, and the entire path would be `/uploads/2020-11-01/uploadDestinations/messaging/v1/orders/{amazonOrderId}/messages/legalDisclosure`. If you create an upload destination for an Aplus content document, the `{resource}` would be `aplus/2020-11-01/contentDocuments` and the path would be `/uploads/2020-11-01/uploadDestinations/aplus/2020-11-01/contentDocuments`.
|
|
82
82
|
* @type {string}
|
|
83
83
|
* @memberof UploadsApiCreateUploadDestinationForResource
|
|
84
84
|
*/
|
|
85
85
|
readonly resource: string;
|
|
86
86
|
/**
|
|
87
|
-
* The content type of the file
|
|
87
|
+
* The content type of the file you upload.
|
|
88
88
|
* @type {string}
|
|
89
89
|
* @memberof UploadsApiCreateUploadDestinationForResource
|
|
90
90
|
*/
|
|
@@ -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) => <T = unknown, R = AxiosResponse<T
|
|
65
|
+
export declare const createRequestFunction: (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration) => <T = unknown, R = AxiosResponse<T>>(axios?: AxiosInstance, basePath?: string) => Promise<R>;
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@sp-api-sdk/uploads-api-2020-11-01",
|
|
3
3
|
"author": "Bertrand Marron <bertrand@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": "3.0
|
|
5
|
+
"version": "3.1.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.11",
|
|
22
|
+
"axios": "^1.8.1"
|
|
23
23
|
},
|
|
24
24
|
"repository": {
|
|
25
25
|
"type": "git",
|
|
@@ -40,5 +40,5 @@
|
|
|
40
40
|
"sp sdk",
|
|
41
41
|
"uploads api"
|
|
42
42
|
],
|
|
43
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "b5799742765e819f70161d2ac1905d8e570de8c0"
|
|
44
44
|
}
|