@emilgroup/payment-sdk 1.16.1-beta.96 → 1.16.1-beta.97

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
@@ -17,11 +17,11 @@ Although this package can be used in both TypeScript and JavaScript, it is inten
17
17
  Navigate to the folder of your consuming project and run one of the following commands:
18
18
 
19
19
  ```
20
- npm install @emilgroup/payment-sdk@1.16.1-beta.96 --save
20
+ npm install @emilgroup/payment-sdk@1.16.1-beta.97 --save
21
21
  ```
22
22
  or
23
23
  ```
24
- yarn add @emilgroup/payment-sdk@1.16.1-beta.96
24
+ yarn add @emilgroup/payment-sdk@1.16.1-beta.97
25
25
  ```
26
26
 
27
27
  And then you can import `PaymentsApi`.
@@ -31,24 +31,20 @@ export const WebhooksApiAxiosParamCreator = function (configuration?: Configurat
31
31
  * @summary Handle the webhook from PSP
32
32
  * @param {string} pspType The type of the payment service provider (PSP).<br/> <br/> <i>Supported PSP: braintree, stripe, b4u, eis, adyen</i>
33
33
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
34
- * @param {string} productSlug
35
34
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
36
35
  * @param {*} [options] Override http request option.
37
36
  * @throws {RequiredError}
38
37
  */
39
- postWebhook0: async (pspType: string, tenantSlug: string, productSlug: string, body: object, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
38
+ postWebhook: async (pspType: string, tenantSlug: string, body: object, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
40
39
  // verify required parameter 'pspType' is not null or undefined
41
- assertParamExists('postWebhook0', 'pspType', pspType)
40
+ assertParamExists('postWebhook', 'pspType', pspType)
42
41
  // verify required parameter 'tenantSlug' is not null or undefined
43
- assertParamExists('postWebhook0', 'tenantSlug', tenantSlug)
44
- // verify required parameter 'productSlug' is not null or undefined
45
- assertParamExists('postWebhook0', 'productSlug', productSlug)
42
+ assertParamExists('postWebhook', 'tenantSlug', tenantSlug)
46
43
  // verify required parameter 'body' is not null or undefined
47
- assertParamExists('postWebhook0', 'body', body)
44
+ assertParamExists('postWebhook', 'body', body)
48
45
  const localVarPath = `/paymentservice/v1/webhooks/{pspType}/{tenantSlug}`
49
46
  .replace(`{${"pspType"}}`, encodeURIComponent(String(pspType)))
50
- .replace(`{${"tenantSlug"}}`, encodeURIComponent(String(tenantSlug)))
51
- .replace(`{${"productSlug"}}`, encodeURIComponent(String(productSlug)));
47
+ .replace(`{${"tenantSlug"}}`, encodeURIComponent(String(tenantSlug)));
52
48
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
53
49
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
54
50
  let baseOptions;
@@ -81,20 +77,20 @@ export const WebhooksApiAxiosParamCreator = function (configuration?: Configurat
81
77
  * @summary Handle the webhook from PSP
82
78
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
83
79
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
84
- * @param {string} productSlug
80
+ * @param {string} productSlug Optional product slug associated with the webhook.
85
81
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
86
82
  * @param {*} [options] Override http request option.
87
83
  * @throws {RequiredError}
88
84
  */
89
- postWebhook1: async (pspType: string, tenantSlug: string, productSlug: string, body: object, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
85
+ postWebhookWithProductSlug: async (pspType: string, tenantSlug: string, productSlug: string, body: object, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
90
86
  // verify required parameter 'pspType' is not null or undefined
91
- assertParamExists('postWebhook1', 'pspType', pspType)
87
+ assertParamExists('postWebhookWithProductSlug', 'pspType', pspType)
92
88
  // verify required parameter 'tenantSlug' is not null or undefined
93
- assertParamExists('postWebhook1', 'tenantSlug', tenantSlug)
89
+ assertParamExists('postWebhookWithProductSlug', 'tenantSlug', tenantSlug)
94
90
  // verify required parameter 'productSlug' is not null or undefined
95
- assertParamExists('postWebhook1', 'productSlug', productSlug)
91
+ assertParamExists('postWebhookWithProductSlug', 'productSlug', productSlug)
96
92
  // verify required parameter 'body' is not null or undefined
97
- assertParamExists('postWebhook1', 'body', body)
93
+ assertParamExists('postWebhookWithProductSlug', 'body', body)
98
94
  const localVarPath = `/paymentservice/v1/webhooks/{pspType}/{tenantSlug}/{productSlug}`
99
95
  .replace(`{${"pspType"}}`, encodeURIComponent(String(pspType)))
100
96
  .replace(`{${"tenantSlug"}}`, encodeURIComponent(String(tenantSlug)))
@@ -141,13 +137,12 @@ export const WebhooksApiFp = function(configuration?: Configuration) {
141
137
  * @summary Handle the webhook from PSP
142
138
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
143
139
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
144
- * @param {string} productSlug
145
140
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
146
141
  * @param {*} [options] Override http request option.
147
142
  * @throws {RequiredError}
148
143
  */
149
- async postWebhook0(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
150
- const localVarAxiosArgs = await localVarAxiosParamCreator.postWebhook0(pspType, tenantSlug, productSlug, body, options);
144
+ async postWebhook(pspType: string, tenantSlug: string, body: object, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
145
+ const localVarAxiosArgs = await localVarAxiosParamCreator.postWebhook(pspType, tenantSlug, body, options);
151
146
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
152
147
  },
153
148
  /**
@@ -155,13 +150,13 @@ export const WebhooksApiFp = function(configuration?: Configuration) {
155
150
  * @summary Handle the webhook from PSP
156
151
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
157
152
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
158
- * @param {string} productSlug
153
+ * @param {string} productSlug Optional product slug associated with the webhook.
159
154
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
160
155
  * @param {*} [options] Override http request option.
161
156
  * @throws {RequiredError}
162
157
  */
163
- async postWebhook1(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
164
- const localVarAxiosArgs = await localVarAxiosParamCreator.postWebhook1(pspType, tenantSlug, productSlug, body, options);
158
+ async postWebhookWithProductSlug(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
159
+ const localVarAxiosArgs = await localVarAxiosParamCreator.postWebhookWithProductSlug(pspType, tenantSlug, productSlug, body, options);
165
160
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
166
161
  },
167
162
  }
@@ -179,96 +174,88 @@ export const WebhooksApiFactory = function (configuration?: Configuration, baseP
179
174
  * @summary Handle the webhook from PSP
180
175
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
181
176
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
182
- * @param {string} productSlug
183
177
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
184
178
  * @param {*} [options] Override http request option.
185
179
  * @throws {RequiredError}
186
180
  */
187
- postWebhook0(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: any): AxiosPromise<void> {
188
- return localVarFp.postWebhook0(pspType, tenantSlug, productSlug, body, options).then((request) => request(axios, basePath));
181
+ postWebhook(pspType: string, tenantSlug: string, body: object, options?: any): AxiosPromise<void> {
182
+ return localVarFp.postWebhook(pspType, tenantSlug, body, options).then((request) => request(axios, basePath));
189
183
  },
190
184
  /**
191
185
  * This will processes the webhook from external payment service provider. **Required Permissions** none
192
186
  * @summary Handle the webhook from PSP
193
187
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
194
188
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
195
- * @param {string} productSlug
189
+ * @param {string} productSlug Optional product slug associated with the webhook.
196
190
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
197
191
  * @param {*} [options] Override http request option.
198
192
  * @throws {RequiredError}
199
193
  */
200
- postWebhook1(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: any): AxiosPromise<void> {
201
- return localVarFp.postWebhook1(pspType, tenantSlug, productSlug, body, options).then((request) => request(axios, basePath));
194
+ postWebhookWithProductSlug(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: any): AxiosPromise<void> {
195
+ return localVarFp.postWebhookWithProductSlug(pspType, tenantSlug, productSlug, body, options).then((request) => request(axios, basePath));
202
196
  },
203
197
  };
204
198
  };
205
199
 
206
200
  /**
207
- * Request parameters for postWebhook0 operation in WebhooksApi.
201
+ * Request parameters for postWebhook operation in WebhooksApi.
208
202
  * @export
209
- * @interface WebhooksApiPostWebhook0Request
203
+ * @interface WebhooksApiPostWebhookRequest
210
204
  */
211
- export interface WebhooksApiPostWebhook0Request {
205
+ export interface WebhooksApiPostWebhookRequest {
212
206
  /**
213
207
  * The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
214
208
  * @type {string}
215
- * @memberof WebhooksApiPostWebhook0
209
+ * @memberof WebhooksApiPostWebhook
216
210
  */
217
211
  readonly pspType: string
218
212
 
219
213
  /**
220
214
  * Unique slug identifier representing a tenant.
221
215
  * @type {string}
222
- * @memberof WebhooksApiPostWebhook0
216
+ * @memberof WebhooksApiPostWebhook
223
217
  */
224
218
  readonly tenantSlug: string
225
219
 
226
- /**
227
- *
228
- * @type {string}
229
- * @memberof WebhooksApiPostWebhook0
230
- */
231
- readonly productSlug: string
232
-
233
220
  /**
234
221
  * Accepts a webhook payload. The structure may vary depending on the payment service provider.
235
222
  * @type {object}
236
- * @memberof WebhooksApiPostWebhook0
223
+ * @memberof WebhooksApiPostWebhook
237
224
  */
238
225
  readonly body: object
239
226
  }
240
227
 
241
228
  /**
242
- * Request parameters for postWebhook1 operation in WebhooksApi.
229
+ * Request parameters for postWebhookWithProductSlug operation in WebhooksApi.
243
230
  * @export
244
- * @interface WebhooksApiPostWebhook1Request
231
+ * @interface WebhooksApiPostWebhookWithProductSlugRequest
245
232
  */
246
- export interface WebhooksApiPostWebhook1Request {
233
+ export interface WebhooksApiPostWebhookWithProductSlugRequest {
247
234
  /**
248
235
  * The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
249
236
  * @type {string}
250
- * @memberof WebhooksApiPostWebhook1
237
+ * @memberof WebhooksApiPostWebhookWithProductSlug
251
238
  */
252
239
  readonly pspType: string
253
240
 
254
241
  /**
255
242
  * Unique slug identifier representing a tenant.
256
243
  * @type {string}
257
- * @memberof WebhooksApiPostWebhook1
244
+ * @memberof WebhooksApiPostWebhookWithProductSlug
258
245
  */
259
246
  readonly tenantSlug: string
260
247
 
261
248
  /**
262
- *
249
+ * Optional product slug associated with the webhook.
263
250
  * @type {string}
264
- * @memberof WebhooksApiPostWebhook1
251
+ * @memberof WebhooksApiPostWebhookWithProductSlug
265
252
  */
266
253
  readonly productSlug: string
267
254
 
268
255
  /**
269
256
  * Accepts a webhook payload. The structure may vary depending on the payment service provider.
270
257
  * @type {object}
271
- * @memberof WebhooksApiPostWebhook1
258
+ * @memberof WebhooksApiPostWebhookWithProductSlug
272
259
  */
273
260
  readonly body: object
274
261
  }
@@ -283,24 +270,24 @@ export class WebhooksApi extends BaseAPI {
283
270
  /**
284
271
  * This will processes the webhook from external payment service provider. **Required Permissions** none
285
272
  * @summary Handle the webhook from PSP
286
- * @param {WebhooksApiPostWebhook0Request} requestParameters Request parameters.
273
+ * @param {WebhooksApiPostWebhookRequest} requestParameters Request parameters.
287
274
  * @param {*} [options] Override http request option.
288
275
  * @throws {RequiredError}
289
276
  * @memberof WebhooksApi
290
277
  */
291
- public postWebhook0(requestParameters: WebhooksApiPostWebhook0Request, options?: AxiosRequestConfig) {
292
- return WebhooksApiFp(this.configuration).postWebhook0(requestParameters.pspType, requestParameters.tenantSlug, requestParameters.productSlug, requestParameters.body, options).then((request) => request(this.axios, this.basePath));
278
+ public postWebhook(requestParameters: WebhooksApiPostWebhookRequest, options?: AxiosRequestConfig) {
279
+ return WebhooksApiFp(this.configuration).postWebhook(requestParameters.pspType, requestParameters.tenantSlug, requestParameters.body, options).then((request) => request(this.axios, this.basePath));
293
280
  }
294
281
 
295
282
  /**
296
283
  * This will processes the webhook from external payment service provider. **Required Permissions** none
297
284
  * @summary Handle the webhook from PSP
298
- * @param {WebhooksApiPostWebhook1Request} requestParameters Request parameters.
285
+ * @param {WebhooksApiPostWebhookWithProductSlugRequest} requestParameters Request parameters.
299
286
  * @param {*} [options] Override http request option.
300
287
  * @throws {RequiredError}
301
288
  * @memberof WebhooksApi
302
289
  */
303
- public postWebhook1(requestParameters: WebhooksApiPostWebhook1Request, options?: AxiosRequestConfig) {
304
- return WebhooksApiFp(this.configuration).postWebhook1(requestParameters.pspType, requestParameters.tenantSlug, requestParameters.productSlug, requestParameters.body, options).then((request) => request(this.axios, this.basePath));
290
+ public postWebhookWithProductSlug(requestParameters: WebhooksApiPostWebhookWithProductSlugRequest, options?: AxiosRequestConfig) {
291
+ return WebhooksApiFp(this.configuration).postWebhookWithProductSlug(requestParameters.pspType, requestParameters.tenantSlug, requestParameters.productSlug, requestParameters.body, options).then((request) => request(this.axios, this.basePath));
305
292
  }
306
293
  }
@@ -22,23 +22,22 @@ export declare const WebhooksApiAxiosParamCreator: (configuration?: Configuratio
22
22
  * @summary Handle the webhook from PSP
23
23
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
24
24
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
25
- * @param {string} productSlug
26
25
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
27
26
  * @param {*} [options] Override http request option.
28
27
  * @throws {RequiredError}
29
28
  */
30
- postWebhook0: (pspType: string, tenantSlug: string, productSlug: string, body: object, options?: AxiosRequestConfig) => Promise<RequestArgs>;
29
+ postWebhook: (pspType: string, tenantSlug: string, body: object, options?: AxiosRequestConfig) => Promise<RequestArgs>;
31
30
  /**
32
31
  * This will processes the webhook from external payment service provider. **Required Permissions** none
33
32
  * @summary Handle the webhook from PSP
34
33
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
35
34
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
36
- * @param {string} productSlug
35
+ * @param {string} productSlug Optional product slug associated with the webhook.
37
36
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
38
37
  * @param {*} [options] Override http request option.
39
38
  * @throws {RequiredError}
40
39
  */
41
- postWebhook1: (pspType: string, tenantSlug: string, productSlug: string, body: object, options?: AxiosRequestConfig) => Promise<RequestArgs>;
40
+ postWebhookWithProductSlug: (pspType: string, tenantSlug: string, productSlug: string, body: object, options?: AxiosRequestConfig) => Promise<RequestArgs>;
42
41
  };
43
42
  /**
44
43
  * WebhooksApi - functional programming interface
@@ -50,23 +49,22 @@ export declare const WebhooksApiFp: (configuration?: Configuration) => {
50
49
  * @summary Handle the webhook from PSP
51
50
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
52
51
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
53
- * @param {string} productSlug
54
52
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
55
53
  * @param {*} [options] Override http request option.
56
54
  * @throws {RequiredError}
57
55
  */
58
- postWebhook0(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
56
+ postWebhook(pspType: string, tenantSlug: string, body: object, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
59
57
  /**
60
58
  * This will processes the webhook from external payment service provider. **Required Permissions** none
61
59
  * @summary Handle the webhook from PSP
62
60
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
63
61
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
64
- * @param {string} productSlug
62
+ * @param {string} productSlug Optional product slug associated with the webhook.
65
63
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
66
64
  * @param {*} [options] Override http request option.
67
65
  * @throws {RequiredError}
68
66
  */
69
- postWebhook1(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
67
+ postWebhookWithProductSlug(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
70
68
  };
71
69
  /**
72
70
  * WebhooksApi - factory interface
@@ -78,83 +76,76 @@ export declare const WebhooksApiFactory: (configuration?: Configuration, basePat
78
76
  * @summary Handle the webhook from PSP
79
77
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
80
78
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
81
- * @param {string} productSlug
82
79
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
83
80
  * @param {*} [options] Override http request option.
84
81
  * @throws {RequiredError}
85
82
  */
86
- postWebhook0(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: any): AxiosPromise<void>;
83
+ postWebhook(pspType: string, tenantSlug: string, body: object, options?: any): AxiosPromise<void>;
87
84
  /**
88
85
  * This will processes the webhook from external payment service provider. **Required Permissions** none
89
86
  * @summary Handle the webhook from PSP
90
87
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
91
88
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
92
- * @param {string} productSlug
89
+ * @param {string} productSlug Optional product slug associated with the webhook.
93
90
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
94
91
  * @param {*} [options] Override http request option.
95
92
  * @throws {RequiredError}
96
93
  */
97
- postWebhook1(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: any): AxiosPromise<void>;
94
+ postWebhookWithProductSlug(pspType: string, tenantSlug: string, productSlug: string, body: object, options?: any): AxiosPromise<void>;
98
95
  };
99
96
  /**
100
- * Request parameters for postWebhook0 operation in WebhooksApi.
97
+ * Request parameters for postWebhook operation in WebhooksApi.
101
98
  * @export
102
- * @interface WebhooksApiPostWebhook0Request
99
+ * @interface WebhooksApiPostWebhookRequest
103
100
  */
104
- export interface WebhooksApiPostWebhook0Request {
101
+ export interface WebhooksApiPostWebhookRequest {
105
102
  /**
106
103
  * The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
107
104
  * @type {string}
108
- * @memberof WebhooksApiPostWebhook0
105
+ * @memberof WebhooksApiPostWebhook
109
106
  */
110
107
  readonly pspType: string;
111
108
  /**
112
109
  * Unique slug identifier representing a tenant.
113
110
  * @type {string}
114
- * @memberof WebhooksApiPostWebhook0
111
+ * @memberof WebhooksApiPostWebhook
115
112
  */
116
113
  readonly tenantSlug: string;
117
- /**
118
- *
119
- * @type {string}
120
- * @memberof WebhooksApiPostWebhook0
121
- */
122
- readonly productSlug: string;
123
114
  /**
124
115
  * Accepts a webhook payload. The structure may vary depending on the payment service provider.
125
116
  * @type {object}
126
- * @memberof WebhooksApiPostWebhook0
117
+ * @memberof WebhooksApiPostWebhook
127
118
  */
128
119
  readonly body: object;
129
120
  }
130
121
  /**
131
- * Request parameters for postWebhook1 operation in WebhooksApi.
122
+ * Request parameters for postWebhookWithProductSlug operation in WebhooksApi.
132
123
  * @export
133
- * @interface WebhooksApiPostWebhook1Request
124
+ * @interface WebhooksApiPostWebhookWithProductSlugRequest
134
125
  */
135
- export interface WebhooksApiPostWebhook1Request {
126
+ export interface WebhooksApiPostWebhookWithProductSlugRequest {
136
127
  /**
137
128
  * The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
138
129
  * @type {string}
139
- * @memberof WebhooksApiPostWebhook1
130
+ * @memberof WebhooksApiPostWebhookWithProductSlug
140
131
  */
141
132
  readonly pspType: string;
142
133
  /**
143
134
  * Unique slug identifier representing a tenant.
144
135
  * @type {string}
145
- * @memberof WebhooksApiPostWebhook1
136
+ * @memberof WebhooksApiPostWebhookWithProductSlug
146
137
  */
147
138
  readonly tenantSlug: string;
148
139
  /**
149
- *
140
+ * Optional product slug associated with the webhook.
150
141
  * @type {string}
151
- * @memberof WebhooksApiPostWebhook1
142
+ * @memberof WebhooksApiPostWebhookWithProductSlug
152
143
  */
153
144
  readonly productSlug: string;
154
145
  /**
155
146
  * Accepts a webhook payload. The structure may vary depending on the payment service provider.
156
147
  * @type {object}
157
- * @memberof WebhooksApiPostWebhook1
148
+ * @memberof WebhooksApiPostWebhookWithProductSlug
158
149
  */
159
150
  readonly body: object;
160
151
  }
@@ -168,19 +159,19 @@ export declare class WebhooksApi extends BaseAPI {
168
159
  /**
169
160
  * This will processes the webhook from external payment service provider. **Required Permissions** none
170
161
  * @summary Handle the webhook from PSP
171
- * @param {WebhooksApiPostWebhook0Request} requestParameters Request parameters.
162
+ * @param {WebhooksApiPostWebhookRequest} requestParameters Request parameters.
172
163
  * @param {*} [options] Override http request option.
173
164
  * @throws {RequiredError}
174
165
  * @memberof WebhooksApi
175
166
  */
176
- postWebhook0(requestParameters: WebhooksApiPostWebhook0Request, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
167
+ postWebhook(requestParameters: WebhooksApiPostWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
177
168
  /**
178
169
  * This will processes the webhook from external payment service provider. **Required Permissions** none
179
170
  * @summary Handle the webhook from PSP
180
- * @param {WebhooksApiPostWebhook1Request} requestParameters Request parameters.
171
+ * @param {WebhooksApiPostWebhookWithProductSlugRequest} requestParameters Request parameters.
181
172
  * @param {*} [options] Override http request option.
182
173
  * @throws {RequiredError}
183
174
  * @memberof WebhooksApi
184
175
  */
185
- postWebhook1(requestParameters: WebhooksApiPostWebhook1Request, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
176
+ postWebhookWithProductSlug(requestParameters: WebhooksApiPostWebhookWithProductSlugRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
186
177
  }
@@ -97,28 +97,24 @@ var WebhooksApiAxiosParamCreator = function (configuration) {
97
97
  * @summary Handle the webhook from PSP
98
98
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
99
99
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
100
- * @param {string} productSlug
101
100
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
102
101
  * @param {*} [options] Override http request option.
103
102
  * @throws {RequiredError}
104
103
  */
105
- postWebhook0: function (pspType, tenantSlug, productSlug, body, options) {
104
+ postWebhook: function (pspType, tenantSlug, body, options) {
106
105
  if (options === void 0) { options = {}; }
107
106
  return __awaiter(_this, void 0, void 0, function () {
108
107
  var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
109
108
  return __generator(this, function (_a) {
110
109
  // verify required parameter 'pspType' is not null or undefined
111
- (0, common_1.assertParamExists)('postWebhook0', 'pspType', pspType);
110
+ (0, common_1.assertParamExists)('postWebhook', 'pspType', pspType);
112
111
  // verify required parameter 'tenantSlug' is not null or undefined
113
- (0, common_1.assertParamExists)('postWebhook0', 'tenantSlug', tenantSlug);
114
- // verify required parameter 'productSlug' is not null or undefined
115
- (0, common_1.assertParamExists)('postWebhook0', 'productSlug', productSlug);
112
+ (0, common_1.assertParamExists)('postWebhook', 'tenantSlug', tenantSlug);
116
113
  // verify required parameter 'body' is not null or undefined
117
- (0, common_1.assertParamExists)('postWebhook0', 'body', body);
114
+ (0, common_1.assertParamExists)('postWebhook', 'body', body);
118
115
  localVarPath = "/paymentservice/v1/webhooks/{pspType}/{tenantSlug}"
119
116
  .replace("{".concat("pspType", "}"), encodeURIComponent(String(pspType)))
120
- .replace("{".concat("tenantSlug", "}"), encodeURIComponent(String(tenantSlug)))
121
- .replace("{".concat("productSlug", "}"), encodeURIComponent(String(productSlug)));
117
+ .replace("{".concat("tenantSlug", "}"), encodeURIComponent(String(tenantSlug)));
122
118
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
123
119
  if (configuration) {
124
120
  baseOptions = configuration.baseOptions;
@@ -144,24 +140,24 @@ var WebhooksApiAxiosParamCreator = function (configuration) {
144
140
  * @summary Handle the webhook from PSP
145
141
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
146
142
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
147
- * @param {string} productSlug
143
+ * @param {string} productSlug Optional product slug associated with the webhook.
148
144
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
149
145
  * @param {*} [options] Override http request option.
150
146
  * @throws {RequiredError}
151
147
  */
152
- postWebhook1: function (pspType, tenantSlug, productSlug, body, options) {
148
+ postWebhookWithProductSlug: function (pspType, tenantSlug, productSlug, body, options) {
153
149
  if (options === void 0) { options = {}; }
154
150
  return __awaiter(_this, void 0, void 0, function () {
155
151
  var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
156
152
  return __generator(this, function (_a) {
157
153
  // verify required parameter 'pspType' is not null or undefined
158
- (0, common_1.assertParamExists)('postWebhook1', 'pspType', pspType);
154
+ (0, common_1.assertParamExists)('postWebhookWithProductSlug', 'pspType', pspType);
159
155
  // verify required parameter 'tenantSlug' is not null or undefined
160
- (0, common_1.assertParamExists)('postWebhook1', 'tenantSlug', tenantSlug);
156
+ (0, common_1.assertParamExists)('postWebhookWithProductSlug', 'tenantSlug', tenantSlug);
161
157
  // verify required parameter 'productSlug' is not null or undefined
162
- (0, common_1.assertParamExists)('postWebhook1', 'productSlug', productSlug);
158
+ (0, common_1.assertParamExists)('postWebhookWithProductSlug', 'productSlug', productSlug);
163
159
  // verify required parameter 'body' is not null or undefined
164
- (0, common_1.assertParamExists)('postWebhook1', 'body', body);
160
+ (0, common_1.assertParamExists)('postWebhookWithProductSlug', 'body', body);
165
161
  localVarPath = "/paymentservice/v1/webhooks/{pspType}/{tenantSlug}/{productSlug}"
166
162
  .replace("{".concat("pspType", "}"), encodeURIComponent(String(pspType)))
167
163
  .replace("{".concat("tenantSlug", "}"), encodeURIComponent(String(tenantSlug)))
@@ -201,17 +197,16 @@ var WebhooksApiFp = function (configuration) {
201
197
  * @summary Handle the webhook from PSP
202
198
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
203
199
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
204
- * @param {string} productSlug
205
200
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
206
201
  * @param {*} [options] Override http request option.
207
202
  * @throws {RequiredError}
208
203
  */
209
- postWebhook0: function (pspType, tenantSlug, productSlug, body, options) {
204
+ postWebhook: function (pspType, tenantSlug, body, options) {
210
205
  return __awaiter(this, void 0, void 0, function () {
211
206
  var localVarAxiosArgs;
212
207
  return __generator(this, function (_a) {
213
208
  switch (_a.label) {
214
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.postWebhook0(pspType, tenantSlug, productSlug, body, options)];
209
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.postWebhook(pspType, tenantSlug, body, options)];
215
210
  case 1:
216
211
  localVarAxiosArgs = _a.sent();
217
212
  return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
@@ -224,17 +219,17 @@ var WebhooksApiFp = function (configuration) {
224
219
  * @summary Handle the webhook from PSP
225
220
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
226
221
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
227
- * @param {string} productSlug
222
+ * @param {string} productSlug Optional product slug associated with the webhook.
228
223
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
229
224
  * @param {*} [options] Override http request option.
230
225
  * @throws {RequiredError}
231
226
  */
232
- postWebhook1: function (pspType, tenantSlug, productSlug, body, options) {
227
+ postWebhookWithProductSlug: function (pspType, tenantSlug, productSlug, body, options) {
233
228
  return __awaiter(this, void 0, void 0, function () {
234
229
  var localVarAxiosArgs;
235
230
  return __generator(this, function (_a) {
236
231
  switch (_a.label) {
237
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.postWebhook1(pspType, tenantSlug, productSlug, body, options)];
232
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.postWebhookWithProductSlug(pspType, tenantSlug, productSlug, body, options)];
238
233
  case 1:
239
234
  localVarAxiosArgs = _a.sent();
240
235
  return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
@@ -257,26 +252,25 @@ var WebhooksApiFactory = function (configuration, basePath, axios) {
257
252
  * @summary Handle the webhook from PSP
258
253
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
259
254
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
260
- * @param {string} productSlug
261
255
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
262
256
  * @param {*} [options] Override http request option.
263
257
  * @throws {RequiredError}
264
258
  */
265
- postWebhook0: function (pspType, tenantSlug, productSlug, body, options) {
266
- return localVarFp.postWebhook0(pspType, tenantSlug, productSlug, body, options).then(function (request) { return request(axios, basePath); });
259
+ postWebhook: function (pspType, tenantSlug, body, options) {
260
+ return localVarFp.postWebhook(pspType, tenantSlug, body, options).then(function (request) { return request(axios, basePath); });
267
261
  },
268
262
  /**
269
263
  * This will processes the webhook from external payment service provider. **Required Permissions** none
270
264
  * @summary Handle the webhook from PSP
271
265
  * @param {string} pspType The type of the payment service provider (PSP).&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Supported PSP: braintree, stripe, b4u, eis, adyen&lt;/i&gt;
272
266
  * @param {string} tenantSlug Unique slug identifier representing a tenant.
273
- * @param {string} productSlug
267
+ * @param {string} productSlug Optional product slug associated with the webhook.
274
268
  * @param {object} body Accepts a webhook payload. The structure may vary depending on the payment service provider.
275
269
  * @param {*} [options] Override http request option.
276
270
  * @throws {RequiredError}
277
271
  */
278
- postWebhook1: function (pspType, tenantSlug, productSlug, body, options) {
279
- return localVarFp.postWebhook1(pspType, tenantSlug, productSlug, body, options).then(function (request) { return request(axios, basePath); });
272
+ postWebhookWithProductSlug: function (pspType, tenantSlug, productSlug, body, options) {
273
+ return localVarFp.postWebhookWithProductSlug(pspType, tenantSlug, productSlug, body, options).then(function (request) { return request(axios, basePath); });
280
274
  },
281
275
  };
282
276
  };
@@ -295,26 +289,26 @@ var WebhooksApi = /** @class */ (function (_super) {
295
289
  /**
296
290
  * This will processes the webhook from external payment service provider. **Required Permissions** none
297
291
  * @summary Handle the webhook from PSP
298
- * @param {WebhooksApiPostWebhook0Request} requestParameters Request parameters.
292
+ * @param {WebhooksApiPostWebhookRequest} requestParameters Request parameters.
299
293
  * @param {*} [options] Override http request option.
300
294
  * @throws {RequiredError}
301
295
  * @memberof WebhooksApi
302
296
  */
303
- WebhooksApi.prototype.postWebhook0 = function (requestParameters, options) {
297
+ WebhooksApi.prototype.postWebhook = function (requestParameters, options) {
304
298
  var _this = this;
305
- return (0, exports.WebhooksApiFp)(this.configuration).postWebhook0(requestParameters.pspType, requestParameters.tenantSlug, requestParameters.productSlug, requestParameters.body, options).then(function (request) { return request(_this.axios, _this.basePath); });
299
+ return (0, exports.WebhooksApiFp)(this.configuration).postWebhook(requestParameters.pspType, requestParameters.tenantSlug, requestParameters.body, options).then(function (request) { return request(_this.axios, _this.basePath); });
306
300
  };
307
301
  /**
308
302
  * This will processes the webhook from external payment service provider. **Required Permissions** none
309
303
  * @summary Handle the webhook from PSP
310
- * @param {WebhooksApiPostWebhook1Request} requestParameters Request parameters.
304
+ * @param {WebhooksApiPostWebhookWithProductSlugRequest} requestParameters Request parameters.
311
305
  * @param {*} [options] Override http request option.
312
306
  * @throws {RequiredError}
313
307
  * @memberof WebhooksApi
314
308
  */
315
- WebhooksApi.prototype.postWebhook1 = function (requestParameters, options) {
309
+ WebhooksApi.prototype.postWebhookWithProductSlug = function (requestParameters, options) {
316
310
  var _this = this;
317
- return (0, exports.WebhooksApiFp)(this.configuration).postWebhook1(requestParameters.pspType, requestParameters.tenantSlug, requestParameters.productSlug, requestParameters.body, options).then(function (request) { return request(_this.axios, _this.basePath); });
311
+ return (0, exports.WebhooksApiFp)(this.configuration).postWebhookWithProductSlug(requestParameters.pspType, requestParameters.tenantSlug, requestParameters.productSlug, requestParameters.body, options).then(function (request) { return request(_this.axios, _this.basePath); });
318
312
  };
319
313
  return WebhooksApi;
320
314
  }(base_1.BaseAPI));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@emilgroup/payment-sdk",
3
- "version": "1.16.1-beta.96",
3
+ "version": "1.16.1-beta.97",
4
4
  "description": "OpenAPI client for @emilgroup/payment-sdk",
5
5
  "author": "OpenAPI-Generator Contributors",
6
6
  "keywords": [