@sp-api-sdk/application-integrations-api-2024-04-01 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +97 -0
  3. package/dist/cjs/index.js +19 -0
  4. package/dist/cjs/src/api-model/api/app-integrations-api.js +248 -0
  5. package/dist/cjs/src/api-model/api.js +30 -0
  6. package/dist/cjs/src/api-model/base.js +71 -0
  7. package/dist/cjs/src/api-model/common.js +145 -0
  8. package/dist/cjs/src/api-model/configuration.js +99 -0
  9. package/dist/cjs/src/api-model/index.js +32 -0
  10. package/dist/cjs/src/api-model/models/create-notification-request.js +15 -0
  11. package/dist/cjs/src/api-model/models/create-notification-response.js +15 -0
  12. package/dist/cjs/src/api-model/models/delete-notifications-request.js +20 -0
  13. package/dist/cjs/src/api-model/models/error-list.js +15 -0
  14. package/dist/cjs/src/api-model/models/index.js +22 -0
  15. package/dist/cjs/src/api-model/models/model-error.js +15 -0
  16. package/dist/cjs/src/api-model/models/record-action-feedback-request.js +19 -0
  17. package/dist/cjs/src/client.js +35 -0
  18. package/dist/es/index.js +3 -0
  19. package/dist/es/src/api-model/api/app-integrations-api.js +238 -0
  20. package/dist/es/src/api-model/api.js +14 -0
  21. package/dist/es/src/api-model/base.js +63 -0
  22. package/dist/es/src/api-model/common.js +133 -0
  23. package/dist/es/src/api-model/configuration.js +95 -0
  24. package/dist/es/src/api-model/index.js +16 -0
  25. package/dist/es/src/api-model/models/create-notification-request.js +14 -0
  26. package/dist/es/src/api-model/models/create-notification-response.js +14 -0
  27. package/dist/es/src/api-model/models/delete-notifications-request.js +17 -0
  28. package/dist/es/src/api-model/models/error-list.js +14 -0
  29. package/dist/es/src/api-model/models/index.js +6 -0
  30. package/dist/es/src/api-model/models/model-error.js +14 -0
  31. package/dist/es/src/api-model/models/record-action-feedback-request.js +16 -0
  32. package/dist/es/src/client.js +31 -0
  33. package/dist/types/index.d.ts +3 -0
  34. package/dist/types/src/api-model/api/app-integrations-api.d.ts +179 -0
  35. package/dist/types/src/api-model/api.d.ts +12 -0
  36. package/dist/types/src/api-model/base.d.ts +66 -0
  37. package/dist/types/src/api-model/common.d.ts +65 -0
  38. package/dist/types/src/api-model/configuration.d.ts +91 -0
  39. package/dist/types/src/api-model/index.d.ts +14 -0
  40. package/dist/types/src/api-model/models/create-notification-request.d.ts +38 -0
  41. package/dist/types/src/api-model/models/create-notification-response.d.ts +24 -0
  42. package/dist/types/src/api-model/models/delete-notifications-request.d.ts +35 -0
  43. package/dist/types/src/api-model/models/error-list.d.ts +24 -0
  44. package/dist/types/src/api-model/models/index.d.ts +6 -0
  45. package/dist/types/src/api-model/models/model-error.d.ts +36 -0
  46. package/dist/types/src/api-model/models/record-action-feedback-request.d.ts +28 -0
  47. package/dist/types/src/client.d.ts +6 -0
  48. package/package.json +44 -0
@@ -0,0 +1,99 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * The Selling Partner API for third party application integrations.
6
+ * With the AppIntegrations API v2024-04-01, you can send notifications to Amazon Selling Partners and display the notifications in Seller Central.
7
+ *
8
+ * The version of the OpenAPI document: 2024-04-01
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.Configuration = void 0;
17
+ class Configuration {
18
+ /**
19
+ * parameter for apiKey security
20
+ * @param name security name
21
+ * @memberof Configuration
22
+ */
23
+ apiKey;
24
+ /**
25
+ * parameter for basic security
26
+ *
27
+ * @type {string}
28
+ * @memberof Configuration
29
+ */
30
+ username;
31
+ /**
32
+ * parameter for basic security
33
+ *
34
+ * @type {string}
35
+ * @memberof Configuration
36
+ */
37
+ password;
38
+ /**
39
+ * parameter for oauth2 security
40
+ * @param name security name
41
+ * @param scopes oauth2 scope
42
+ * @memberof Configuration
43
+ */
44
+ accessToken;
45
+ /**
46
+ * override base path
47
+ *
48
+ * @type {string}
49
+ * @memberof Configuration
50
+ */
51
+ basePath;
52
+ /**
53
+ * override server index
54
+ *
55
+ * @type {number}
56
+ * @memberof Configuration
57
+ */
58
+ serverIndex;
59
+ /**
60
+ * base options for axios calls
61
+ *
62
+ * @type {any}
63
+ * @memberof Configuration
64
+ */
65
+ baseOptions;
66
+ /**
67
+ * The FormData constructor that will be used to create multipart form data
68
+ * requests. You can inject this here so that execution environments that
69
+ * do not support the FormData class can still run the generated client.
70
+ *
71
+ * @type {new () => FormData}
72
+ */
73
+ formDataCtor;
74
+ constructor(param = {}) {
75
+ this.apiKey = param.apiKey;
76
+ this.username = param.username;
77
+ this.password = param.password;
78
+ this.accessToken = param.accessToken;
79
+ this.basePath = param.basePath;
80
+ this.serverIndex = param.serverIndex;
81
+ this.baseOptions = param.baseOptions;
82
+ this.formDataCtor = param.formDataCtor;
83
+ }
84
+ /**
85
+ * Check if the given MIME is a JSON MIME.
86
+ * JSON MIME examples:
87
+ * application/json
88
+ * application/json; charset=UTF8
89
+ * APPLICATION/JSON
90
+ * application/vnd.company+json
91
+ * @param mime - MIME (Multipurpose Internet Mail Extensions)
92
+ * @return True if the given MIME is JSON, false otherwise.
93
+ */
94
+ isJsonMime(mime) {
95
+ const jsonMime = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
96
+ return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
97
+ }
98
+ }
99
+ exports.Configuration = Configuration;
@@ -0,0 +1,32 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * The Selling Partner API for third party application integrations.
6
+ * With the AppIntegrations API v2024-04-01, you can send notifications to Amazon Selling Partners and display the notifications in Seller Central.
7
+ *
8
+ * The version of the OpenAPI document: 2024-04-01
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
16
+ if (k2 === undefined) k2 = k;
17
+ var desc = Object.getOwnPropertyDescriptor(m, k);
18
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
19
+ desc = { enumerable: true, get: function() { return m[k]; } };
20
+ }
21
+ Object.defineProperty(o, k2, desc);
22
+ }) : (function(o, m, k, k2) {
23
+ if (k2 === undefined) k2 = k;
24
+ o[k2] = m[k];
25
+ }));
26
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
27
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
28
+ };
29
+ Object.defineProperty(exports, "__esModule", { value: true });
30
+ __exportStar(require("./api"), exports);
31
+ __exportStar(require("./configuration"), exports);
32
+ __exportStar(require("./models"), exports);
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * The Selling Partner API for third party application integrations.
6
+ * With the AppIntegrations API v2024-04-01, you can send notifications to Amazon Selling Partners and display the notifications in Seller Central.
7
+ *
8
+ * The version of the OpenAPI document: 2024-04-01
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * The Selling Partner API for third party application integrations.
6
+ * With the AppIntegrations API v2024-04-01, you can send notifications to Amazon Selling Partners and display the notifications in Seller Central.
7
+ *
8
+ * The version of the OpenAPI document: 2024-04-01
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * The Selling Partner API for third party application integrations.
6
+ * With the AppIntegrations API v2024-04-01, you can send notifications to Amazon Selling Partners and display the notifications in Seller Central.
7
+ *
8
+ * The version of the OpenAPI document: 2024-04-01
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.DeleteNotificationsRequestDeletionReasonEnum = void 0;
17
+ exports.DeleteNotificationsRequestDeletionReasonEnum = {
18
+ Content: 'INCORRECT_CONTENT',
19
+ Recipient: 'INCORRECT_RECIPIENT'
20
+ };
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * The Selling Partner API for third party application integrations.
6
+ * With the AppIntegrations API v2024-04-01, you can send notifications to Amazon Selling Partners and display the notifications in Seller Central.
7
+ *
8
+ * The version of the OpenAPI document: 2024-04-01
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,22 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./create-notification-request"), exports);
18
+ __exportStar(require("./create-notification-response"), exports);
19
+ __exportStar(require("./delete-notifications-request"), exports);
20
+ __exportStar(require("./error-list"), exports);
21
+ __exportStar(require("./model-error"), exports);
22
+ __exportStar(require("./record-action-feedback-request"), exports);
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * The Selling Partner API for third party application integrations.
6
+ * With the AppIntegrations API v2024-04-01, you can send notifications to Amazon Selling Partners and display the notifications in Seller Central.
7
+ *
8
+ * The version of the OpenAPI document: 2024-04-01
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * The Selling Partner API for third party application integrations.
6
+ * With the AppIntegrations API v2024-04-01, you can send notifications to Amazon Selling Partners and display the notifications in Seller Central.
7
+ *
8
+ * The version of the OpenAPI document: 2024-04-01
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.RecordActionFeedbackRequestFeedbackActionCodeEnum = void 0;
17
+ exports.RecordActionFeedbackRequestFeedbackActionCodeEnum = {
18
+ SellerActionCompleted: 'SELLER_ACTION_COMPLETED'
19
+ };
@@ -0,0 +1,35 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ApplicationIntegrationsApiClient = exports.clientRateLimits = void 0;
4
+ const common_1 = require("@sp-api-sdk/common");
5
+ const api_model_1 = require("./api-model");
6
+ exports.clientRateLimits = [
7
+ {
8
+ method: 'post',
9
+ // eslint-disable-next-line prefer-regex-literals
10
+ urlRegex: new RegExp('^/appIntegrations/2024-04-01/notifications$'),
11
+ rate: 1,
12
+ burst: 5,
13
+ },
14
+ {
15
+ method: 'post',
16
+ // eslint-disable-next-line prefer-regex-literals
17
+ urlRegex: new RegExp('^/appIntegrations/2024-04-01/notifications/deletion$'),
18
+ rate: 1,
19
+ burst: 5,
20
+ },
21
+ {
22
+ method: 'post',
23
+ // eslint-disable-next-line prefer-regex-literals
24
+ urlRegex: new RegExp('^/appIntegrations/2024-04-01/notifications/[^/]*/feedback$'),
25
+ rate: 1,
26
+ burst: 5,
27
+ },
28
+ ];
29
+ class ApplicationIntegrationsApiClient extends api_model_1.AppIntegrationsApi {
30
+ constructor(configuration) {
31
+ const { axios, endpoint } = (0, common_1.createAxiosInstance)(configuration, exports.clientRateLimits);
32
+ super(new api_model_1.Configuration(), endpoint, axios);
33
+ }
34
+ }
35
+ exports.ApplicationIntegrationsApiClient = ApplicationIntegrationsApiClient;
@@ -0,0 +1,3 @@
1
+ export * from './src/client';
2
+ export * from './src/api-model/api';
3
+ export * from './src/api-model/models';
@@ -0,0 +1,238 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * The Selling Partner API for third party application integrations.
5
+ * With the AppIntegrations API v2024-04-01, you can send notifications to Amazon Selling Partners and display the notifications in Seller Central.
6
+ *
7
+ * The version of the OpenAPI document: 2024-04-01
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ import globalAxios from 'axios';
15
+ // Some imports not used depending on template conditions
16
+ // @ts-ignore
17
+ import { DUMMY_BASE_URL, assertParamExists, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../common';
18
+ // @ts-ignore
19
+ import { BASE_PATH, BaseAPI, operationServerMap } from '../base';
20
+ /**
21
+ * AppIntegrationsApi - axios parameter creator
22
+ * @export
23
+ */
24
+ export const AppIntegrationsApiAxiosParamCreator = function (configuration) {
25
+ return {
26
+ /**
27
+ * Create a notification for sellers in Seller Central. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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 {CreateNotificationRequest} body The request body for the `createNotification` operation.
29
+ * @param {*} [options] Override http request option.
30
+ * @throws {RequiredError}
31
+ */
32
+ createNotification: async (body, options = {}) => {
33
+ // verify required parameter 'body' is not null or undefined
34
+ assertParamExists('createNotification', 'body', body);
35
+ const localVarPath = `/appIntegrations/2024-04-01/notifications`;
36
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
37
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
38
+ let baseOptions;
39
+ if (configuration) {
40
+ baseOptions = configuration.baseOptions;
41
+ }
42
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options };
43
+ const localVarHeaderParameter = {};
44
+ const localVarQueryParameter = {};
45
+ localVarHeaderParameter['Content-Type'] = 'application/json';
46
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
47
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
48
+ localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
49
+ localVarRequestOptions.data = serializeDataIfNeeded(body, localVarRequestOptions, configuration);
50
+ return {
51
+ url: toPathString(localVarUrlObj),
52
+ options: localVarRequestOptions,
53
+ };
54
+ },
55
+ /**
56
+ * Remove your application\'s notifications from the Appstore notifications dashboard. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).
57
+ * @param {DeleteNotificationsRequest} body The request body for the `deleteNotifications` operation.
58
+ * @param {*} [options] Override http request option.
59
+ * @throws {RequiredError}
60
+ */
61
+ deleteNotifications: async (body, options = {}) => {
62
+ // verify required parameter 'body' is not null or undefined
63
+ assertParamExists('deleteNotifications', 'body', body);
64
+ const localVarPath = `/appIntegrations/2024-04-01/notifications/deletion`;
65
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
66
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
67
+ let baseOptions;
68
+ if (configuration) {
69
+ baseOptions = configuration.baseOptions;
70
+ }
71
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options };
72
+ const localVarHeaderParameter = {};
73
+ const localVarQueryParameter = {};
74
+ localVarHeaderParameter['Content-Type'] = 'application/json';
75
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
76
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
77
+ localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
78
+ localVarRequestOptions.data = serializeDataIfNeeded(body, localVarRequestOptions, configuration);
79
+ return {
80
+ url: toPathString(localVarUrlObj),
81
+ options: localVarRequestOptions,
82
+ };
83
+ },
84
+ /**
85
+ * Records the seller\'s response to a notification. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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
+ * @param {string} notificationId A `notificationId` uniquely identifies a notification.
87
+ * @param {RecordActionFeedbackRequest} body The request body for the `recordActionFeedback` operation.
88
+ * @param {*} [options] Override http request option.
89
+ * @throws {RequiredError}
90
+ */
91
+ recordActionFeedback: async (notificationId, body, options = {}) => {
92
+ // verify required parameter 'notificationId' is not null or undefined
93
+ assertParamExists('recordActionFeedback', 'notificationId', notificationId);
94
+ // verify required parameter 'body' is not null or undefined
95
+ assertParamExists('recordActionFeedback', 'body', body);
96
+ const localVarPath = `/appIntegrations/2024-04-01/notifications/{notificationId}/feedback`
97
+ .replace(`{${"notificationId"}}`, encodeURIComponent(String(notificationId)));
98
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
99
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
100
+ let baseOptions;
101
+ if (configuration) {
102
+ baseOptions = configuration.baseOptions;
103
+ }
104
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options };
105
+ const localVarHeaderParameter = {};
106
+ const localVarQueryParameter = {};
107
+ localVarHeaderParameter['Content-Type'] = 'application/json';
108
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
109
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
110
+ localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
111
+ localVarRequestOptions.data = serializeDataIfNeeded(body, localVarRequestOptions, configuration);
112
+ return {
113
+ url: toPathString(localVarUrlObj),
114
+ options: localVarRequestOptions,
115
+ };
116
+ },
117
+ };
118
+ };
119
+ /**
120
+ * AppIntegrationsApi - functional programming interface
121
+ * @export
122
+ */
123
+ export const AppIntegrationsApiFp = function (configuration) {
124
+ const localVarAxiosParamCreator = AppIntegrationsApiAxiosParamCreator(configuration);
125
+ return {
126
+ /**
127
+ * Create a notification for sellers in Seller Central. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).
128
+ * @param {CreateNotificationRequest} body The request body for the `createNotification` operation.
129
+ * @param {*} [options] Override http request option.
130
+ * @throws {RequiredError}
131
+ */
132
+ async createNotification(body, options) {
133
+ const localVarAxiosArgs = await localVarAxiosParamCreator.createNotification(body, options);
134
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
135
+ const localVarOperationServerBasePath = operationServerMap['AppIntegrationsApi.createNotification']?.[localVarOperationServerIndex]?.url;
136
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
137
+ },
138
+ /**
139
+ * Remove your application\'s notifications from the Appstore notifications dashboard. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).
140
+ * @param {DeleteNotificationsRequest} body The request body for the `deleteNotifications` operation.
141
+ * @param {*} [options] Override http request option.
142
+ * @throws {RequiredError}
143
+ */
144
+ async deleteNotifications(body, options) {
145
+ const localVarAxiosArgs = await localVarAxiosParamCreator.deleteNotifications(body, options);
146
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
147
+ const localVarOperationServerBasePath = operationServerMap['AppIntegrationsApi.deleteNotifications']?.[localVarOperationServerIndex]?.url;
148
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
149
+ },
150
+ /**
151
+ * Records the seller\'s response to a notification. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).
152
+ * @param {string} notificationId A `notificationId` uniquely identifies a notification.
153
+ * @param {RecordActionFeedbackRequest} body The request body for the `recordActionFeedback` operation.
154
+ * @param {*} [options] Override http request option.
155
+ * @throws {RequiredError}
156
+ */
157
+ async recordActionFeedback(notificationId, body, options) {
158
+ const localVarAxiosArgs = await localVarAxiosParamCreator.recordActionFeedback(notificationId, body, options);
159
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
160
+ const localVarOperationServerBasePath = operationServerMap['AppIntegrationsApi.recordActionFeedback']?.[localVarOperationServerIndex]?.url;
161
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
162
+ },
163
+ };
164
+ };
165
+ /**
166
+ * AppIntegrationsApi - factory interface
167
+ * @export
168
+ */
169
+ export const AppIntegrationsApiFactory = function (configuration, basePath, axios) {
170
+ const localVarFp = AppIntegrationsApiFp(configuration);
171
+ return {
172
+ /**
173
+ * Create a notification for sellers in Seller Central. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).
174
+ * @param {AppIntegrationsApiCreateNotificationRequest} requestParameters Request parameters.
175
+ * @param {*} [options] Override http request option.
176
+ * @throws {RequiredError}
177
+ */
178
+ createNotification(requestParameters, options) {
179
+ return localVarFp.createNotification(requestParameters.body, options).then((request) => request(axios, basePath));
180
+ },
181
+ /**
182
+ * Remove your application\'s notifications from the Appstore notifications dashboard. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).
183
+ * @param {AppIntegrationsApiDeleteNotificationsRequest} requestParameters Request parameters.
184
+ * @param {*} [options] Override http request option.
185
+ * @throws {RequiredError}
186
+ */
187
+ deleteNotifications(requestParameters, options) {
188
+ return localVarFp.deleteNotifications(requestParameters.body, options).then((request) => request(axios, basePath));
189
+ },
190
+ /**
191
+ * Records the seller\'s response to a notification. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).
192
+ * @param {AppIntegrationsApiRecordActionFeedbackRequest} requestParameters Request parameters.
193
+ * @param {*} [options] Override http request option.
194
+ * @throws {RequiredError}
195
+ */
196
+ recordActionFeedback(requestParameters, options) {
197
+ return localVarFp.recordActionFeedback(requestParameters.notificationId, requestParameters.body, options).then((request) => request(axios, basePath));
198
+ },
199
+ };
200
+ };
201
+ /**
202
+ * AppIntegrationsApi - object-oriented interface
203
+ * @export
204
+ * @class AppIntegrationsApi
205
+ * @extends {BaseAPI}
206
+ */
207
+ export class AppIntegrationsApi extends BaseAPI {
208
+ /**
209
+ * Create a notification for sellers in Seller Central. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).
210
+ * @param {AppIntegrationsApiCreateNotificationRequest} requestParameters Request parameters.
211
+ * @param {*} [options] Override http request option.
212
+ * @throws {RequiredError}
213
+ * @memberof AppIntegrationsApi
214
+ */
215
+ createNotification(requestParameters, options) {
216
+ return AppIntegrationsApiFp(this.configuration).createNotification(requestParameters.body, options).then((request) => request(this.axios, this.basePath));
217
+ }
218
+ /**
219
+ * Remove your application\'s notifications from the Appstore notifications dashboard. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).
220
+ * @param {AppIntegrationsApiDeleteNotificationsRequest} requestParameters Request parameters.
221
+ * @param {*} [options] Override http request option.
222
+ * @throws {RequiredError}
223
+ * @memberof AppIntegrationsApi
224
+ */
225
+ deleteNotifications(requestParameters, options) {
226
+ return AppIntegrationsApiFp(this.configuration).deleteNotifications(requestParameters.body, options).then((request) => request(this.axios, this.basePath));
227
+ }
228
+ /**
229
+ * Records the seller\'s response to a notification. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Sellers whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).
230
+ * @param {AppIntegrationsApiRecordActionFeedbackRequest} requestParameters Request parameters.
231
+ * @param {*} [options] Override http request option.
232
+ * @throws {RequiredError}
233
+ * @memberof AppIntegrationsApi
234
+ */
235
+ recordActionFeedback(requestParameters, options) {
236
+ return AppIntegrationsApiFp(this.configuration).recordActionFeedback(requestParameters.notificationId, requestParameters.body, options).then((request) => request(this.axios, this.basePath));
237
+ }
238
+ }
@@ -0,0 +1,14 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * The Selling Partner API for third party application integrations.
5
+ * With the AppIntegrations API v2024-04-01, you can send notifications to Amazon Selling Partners and display the notifications in Seller Central.
6
+ *
7
+ * The version of the OpenAPI document: 2024-04-01
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ export * from './api/app-integrations-api';
@@ -0,0 +1,63 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * The Selling Partner API for third party application integrations.
5
+ * With the AppIntegrations API v2024-04-01, you can send notifications to Amazon Selling Partners and display the notifications in Seller Central.
6
+ *
7
+ * The version of the OpenAPI document: 2024-04-01
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ import globalAxios from 'axios';
15
+ export const BASE_PATH = "https://sellingpartnerapi-na.amazon.com".replace(/\/+$/, "");
16
+ /**
17
+ *
18
+ * @export
19
+ */
20
+ export const COLLECTION_FORMATS = {
21
+ csv: ",",
22
+ ssv: " ",
23
+ tsv: "\t",
24
+ pipes: "|",
25
+ };
26
+ /**
27
+ *
28
+ * @export
29
+ * @class BaseAPI
30
+ */
31
+ export class BaseAPI {
32
+ basePath;
33
+ axios;
34
+ configuration;
35
+ constructor(configuration, basePath = BASE_PATH, axios = globalAxios) {
36
+ this.basePath = basePath;
37
+ this.axios = axios;
38
+ if (configuration) {
39
+ this.configuration = configuration;
40
+ this.basePath = configuration.basePath ?? basePath;
41
+ }
42
+ }
43
+ }
44
+ ;
45
+ /**
46
+ *
47
+ * @export
48
+ * @class RequiredError
49
+ * @extends {Error}
50
+ */
51
+ export class RequiredError extends Error {
52
+ field;
53
+ constructor(field, msg) {
54
+ super(msg);
55
+ this.field = field;
56
+ this.name = "RequiredError";
57
+ }
58
+ }
59
+ /**
60
+ *
61
+ * @export
62
+ */
63
+ export const operationServerMap = {};