@emilgroup/payment-sdk 1.4.1-beta.9 → 1.5.1-beta.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/.openapi-generator/FILES +11 -11
- package/README.md +2 -2
- package/api/bank-accounts-api.ts +500 -88
- package/api/bank-transaction-api.ts +93 -123
- package/api/{default-api.ts → health-check-api.ts} +22 -18
- package/api/payment-methods-api.ts +61 -242
- package/api/payment-reminders-api.ts +57 -99
- package/api/payment-setup-api.ts +17 -9
- package/api/payments-api.ts +72 -135
- package/api/refunds-api.ts +80 -120
- package/api/tenant-bank-account-api.ts +96 -118
- package/api/webhooks-api.ts +38 -21
- package/api.ts +3 -3
- package/base.ts +22 -10
- package/common.ts +2 -2
- package/configuration.ts +1 -1
- package/dist/api/bank-accounts-api.d.ts +292 -69
- package/dist/api/bank-accounts-api.js +432 -62
- package/dist/api/bank-transaction-api.d.ts +84 -104
- package/dist/api/bank-transaction-api.js +63 -74
- package/dist/api/health-check-api.d.ts +70 -0
- package/dist/api/{default-api.js → health-check-api.js} +31 -27
- package/dist/api/payment-methods-api.d.ts +51 -151
- package/dist/api/payment-methods-api.js +48 -178
- package/dist/api/payment-reminders-api.d.ts +52 -79
- package/dist/api/payment-reminders-api.js +44 -62
- package/dist/api/payment-setup-api.d.ts +17 -9
- package/dist/api/payment-setup-api.js +17 -9
- package/dist/api/payments-api.d.ts +62 -98
- package/dist/api/payments-api.js +55 -85
- package/dist/api/refunds-api.d.ts +73 -91
- package/dist/api/refunds-api.js +58 -68
- package/dist/api/tenant-bank-account-api.d.ts +90 -105
- package/dist/api/tenant-bank-account-api.js +63 -75
- package/dist/api/webhooks-api.d.ts +29 -16
- package/dist/api/webhooks-api.js +29 -19
- package/dist/api.d.ts +2 -2
- package/dist/api.js +2 -2
- package/dist/base.d.ts +6 -3
- package/dist/base.js +31 -22
- package/dist/common.d.ts +2 -2
- package/dist/common.js +1 -1
- package/dist/configuration.d.ts +1 -1
- package/dist/configuration.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/models/{bank-transaction-response-class.d.ts → bank-transaction-class-without-expand-properties.d.ts} +31 -33
- package/dist/models/{bank-transaction-response-class.js → bank-transaction-class-without-expand-properties.js} +1 -1
- package/dist/models/create-bank-account-request-dto.d.ts +42 -0
- package/dist/models/{get-refund-response-class.js → create-bank-account-request-dto.js} +1 -1
- package/dist/models/create-payment-reminder-request-dto.d.ts +1 -1
- package/dist/models/create-payment-reminder-request-dto.js +1 -1
- package/dist/models/create-payment-request-dto.d.ts +3 -3
- package/dist/models/create-payment-request-dto.js +1 -1
- package/dist/models/create-refund-request-dto.d.ts +1 -1
- package/dist/models/create-refund-request-dto.js +1 -1
- package/dist/models/create-tenant-bank-account-request-dto.d.ts +1 -1
- package/dist/models/create-tenant-bank-account-request-dto.js +1 -1
- package/dist/models/create-tenant-bank-account-response-class.d.ts +25 -0
- package/dist/models/{create-refund-response-class.js → create-tenant-bank-account-response-class.js} +1 -1
- package/dist/models/deactivate-payment-reminder-request-dto.d.ts +1 -1
- package/dist/models/deactivate-payment-reminder-request-dto.js +1 -1
- package/dist/models/get-tenant-bank-account-response-class.d.ts +5 -5
- package/dist/models/get-tenant-bank-account-response-class.js +1 -1
- package/dist/models/index.d.ts +10 -10
- package/dist/models/index.js +10 -10
- package/dist/models/inline-response200.d.ts +1 -1
- package/dist/models/inline-response200.js +1 -1
- package/dist/models/inline-response503.d.ts +1 -1
- package/dist/models/inline-response503.js +1 -1
- package/dist/models/link-bank-transaction-request-dto-rest.d.ts +1 -1
- package/dist/models/link-bank-transaction-request-dto-rest.js +1 -1
- package/dist/models/list-tenant-bank-account-response-class.d.ts +31 -0
- package/dist/models/{get-bank-transactions-response-class.js → list-tenant-bank-account-response-class.js} +1 -1
- package/dist/models/set-primary-bank-account-request-dto-rest.d.ts +24 -0
- package/dist/models/set-primary-bank-account-request-dto-rest.js +15 -0
- package/dist/models/{tenant-bank-account-response-class.d.ts → tenant-bank-account-class-without-expand-properties.d.ts} +23 -11
- package/dist/models/tenant-bank-account-class-without-expand-properties.js +15 -0
- package/dist/models/tenant-bank-account-class.d.ts +85 -0
- package/dist/models/tenant-bank-account-class.js +15 -0
- package/dist/models/unlink-bank-transaction-request-dto-rest.d.ts +2 -2
- package/dist/models/unlink-bank-transaction-request-dto-rest.js +1 -1
- package/dist/models/update-bank-account-request-dto-rest.d.ts +30 -0
- package/dist/models/update-bank-account-request-dto-rest.js +15 -0
- package/dist/models/update-bank-account-request-dto.d.ts +36 -0
- package/dist/models/update-bank-account-request-dto.js +15 -0
- package/dist/models/update-tenant-bank-account-response-class.d.ts +25 -0
- package/dist/models/update-tenant-bank-account-response-class.js +15 -0
- package/dist/models/update-tenant-bank-account-rest-request-dto.d.ts +1 -1
- package/dist/models/update-tenant-bank-account-rest-request-dto.js +1 -1
- package/dist/models/validate-pspconfig-request-dto.d.ts +1 -1
- package/dist/models/validate-pspconfig-request-dto.js +1 -1
- package/index.ts +1 -1
- package/models/{bank-transaction-response-class.ts → bank-transaction-class-without-expand-properties.ts} +31 -33
- package/models/create-bank-account-request-dto.ts +48 -0
- package/models/create-payment-reminder-request-dto.ts +1 -1
- package/models/create-payment-request-dto.ts +3 -3
- package/models/create-refund-request-dto.ts +1 -1
- package/models/create-tenant-bank-account-request-dto.ts +1 -1
- package/models/create-tenant-bank-account-response-class.ts +31 -0
- package/models/deactivate-payment-reminder-request-dto.ts +1 -1
- package/models/get-tenant-bank-account-response-class.ts +5 -5
- package/models/index.ts +10 -10
- package/models/inline-response200.ts +1 -1
- package/models/inline-response503.ts +1 -1
- package/models/link-bank-transaction-request-dto-rest.ts +1 -1
- package/models/list-tenant-bank-account-response-class.ts +37 -0
- package/models/set-primary-bank-account-request-dto-rest.ts +30 -0
- package/models/{tenant-bank-account-response-class.ts → tenant-bank-account-class-without-expand-properties.ts} +23 -11
- package/models/tenant-bank-account-class.ts +91 -0
- package/models/unlink-bank-transaction-request-dto-rest.ts +2 -2
- package/models/update-bank-account-request-dto-rest.ts +36 -0
- package/models/update-bank-account-request-dto.ts +42 -0
- package/models/update-tenant-bank-account-response-class.ts +31 -0
- package/models/update-tenant-bank-account-rest-request-dto.ts +1 -1
- package/models/validate-pspconfig-request-dto.ts +1 -1
- package/package.json +1 -1
- package/dist/api/default-api.d.ts +0 -66
- package/dist/models/create-refund-response-class.d.ts +0 -25
- package/dist/models/get-bank-transactions-response-class.d.ts +0 -25
- package/dist/models/get-refund-response-class.d.ts +0 -25
- package/dist/models/get-request-dto.d.ts +0 -30
- package/dist/models/get-request-dto.js +0 -15
- package/dist/models/list-bank-transactions-response-class.d.ts +0 -31
- package/dist/models/list-bank-transactions-response-class.js +0 -15
- package/dist/models/list-refunds-response-class.d.ts +0 -31
- package/dist/models/list-refunds-response-class.js +0 -15
- package/dist/models/refund-class.d.ts +0 -104
- package/dist/models/refund-class.js +0 -28
- package/dist/models/tenant-bank-account-response-class.js +0 -15
- package/dist/models/transaction-class.d.ts +0 -54
- package/dist/models/transaction-class.js +0 -15
- package/models/create-refund-response-class.ts +0 -31
- package/models/get-bank-transactions-response-class.ts +0 -31
- package/models/get-refund-response-class.ts +0 -31
- package/models/get-request-dto.ts +0 -36
- package/models/list-bank-transactions-response-class.ts +0 -37
- package/models/list-refunds-response-class.ts +0 -37
- package/models/refund-class.ts +0 -114
- package/models/transaction-class.ts +0 -60
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
/**
|
|
4
4
|
* Emil Payment Service
|
|
5
|
-
* This service directly communicates with the various Payment Service Providers (PSPs)
|
|
5
|
+
* This service directly communicates with the various Payment Service Providers (PSPs) in order to charge or refund customers. This service will automatically connect to the PSP linked in your admin configuration; meaning if you configured Stripe, it will automatically create a payment on Stripe when you create it in Emil.
|
|
6
6
|
*
|
|
7
7
|
* The version of the OpenAPI document: 1.0
|
|
8
8
|
* Contact: kontakt@emil.de
|
|
@@ -28,7 +28,7 @@ export const PaymentMethodsApiAxiosParamCreator = function (configuration?: Conf
|
|
|
28
28
|
return {
|
|
29
29
|
/**
|
|
30
30
|
* This will create payment method in the database as well as in the PSP. The newly created payment method will be set as default payment method will be used by the customer to pay or receive a refund.
|
|
31
|
-
* @summary Create the payment
|
|
31
|
+
* @summary Create the payment method
|
|
32
32
|
* @param {object} body
|
|
33
33
|
* @param {string} [authorization] Bearer Token
|
|
34
34
|
* @param {*} [options] Override http request option.
|
|
@@ -74,71 +74,18 @@ export const PaymentMethodsApiAxiosParamCreator = function (configuration?: Conf
|
|
|
74
74
|
};
|
|
75
75
|
},
|
|
76
76
|
/**
|
|
77
|
-
*
|
|
78
|
-
* @summary
|
|
79
|
-
* @param {
|
|
77
|
+
* Retrieves the details of the payment method that was previously created. Supply the unique payment method code that was returned when you created it and Emil Api will return the corresponding payment method information.
|
|
78
|
+
* @summary Retrieve the payment method
|
|
79
|
+
* @param {string} code
|
|
80
80
|
* @param {string} [authorization] Bearer Token
|
|
81
81
|
* @param {*} [options] Override http request option.
|
|
82
82
|
* @throws {RequiredError}
|
|
83
83
|
*/
|
|
84
|
-
|
|
85
|
-
// verify required parameter 'id' is not null or undefined
|
|
86
|
-
assertParamExists('deletePaymentMethod', 'id', id)
|
|
87
|
-
const localVarPath = `/paymentservice/v1/payment-methods/{id}`;
|
|
88
|
-
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
89
|
-
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
90
|
-
let baseOptions;
|
|
91
|
-
let baseAccessToken;
|
|
92
|
-
if (configuration) {
|
|
93
|
-
baseOptions = configuration.baseOptions;
|
|
94
|
-
baseAccessToken = configuration.accessToken;
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options};
|
|
98
|
-
const localVarHeaderParameter = {} as any;
|
|
99
|
-
const localVarQueryParameter = {} as any;
|
|
100
|
-
|
|
101
|
-
// authentication bearer required
|
|
102
|
-
// http bearer authentication required
|
|
103
|
-
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
104
|
-
|
|
105
|
-
if (id !== undefined) {
|
|
106
|
-
localVarQueryParameter['id'] = id;
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
110
|
-
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
116
|
-
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
117
|
-
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
118
|
-
|
|
119
|
-
return {
|
|
120
|
-
url: toPathString(localVarUrlObj),
|
|
121
|
-
options: localVarRequestOptions,
|
|
122
|
-
};
|
|
123
|
-
},
|
|
124
|
-
/**
|
|
125
|
-
* Retrieves the details of a payment method that was previously created. Supply the unique payment method code that was returned when you created the payment method and Emil Api will return the corresponding payment method information.
|
|
126
|
-
* @summary Retrieve a payment method
|
|
127
|
-
* @param {string} code Unique identifier for the object.
|
|
128
|
-
* @param {string} expand Fields to expand response by
|
|
129
|
-
* @param {string} expand2 Fields to expand response by
|
|
130
|
-
* @param {string} [authorization] Bearer Token
|
|
131
|
-
* @param {*} [options] Override http request option.
|
|
132
|
-
* @throws {RequiredError}
|
|
133
|
-
*/
|
|
134
|
-
getPaymentMethod: async (code: string, expand: string, expand2: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
84
|
+
getPaymentMethod: async (code: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
135
85
|
// verify required parameter 'code' is not null or undefined
|
|
136
86
|
assertParamExists('getPaymentMethod', 'code', code)
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
// verify required parameter 'expand2' is not null or undefined
|
|
140
|
-
assertParamExists('getPaymentMethod', 'expand2', expand2)
|
|
141
|
-
const localVarPath = `/paymentservice/v1/payment-methods/{code}`;
|
|
87
|
+
const localVarPath = `/paymentservice/v1/payment-methods/{code}`
|
|
88
|
+
.replace(`{${"code"}}`, encodeURIComponent(String(code)));
|
|
142
89
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
143
90
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
144
91
|
let baseOptions;
|
|
@@ -156,18 +103,6 @@ export const PaymentMethodsApiAxiosParamCreator = function (configuration?: Conf
|
|
|
156
103
|
// http bearer authentication required
|
|
157
104
|
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
158
105
|
|
|
159
|
-
if (code !== undefined) {
|
|
160
|
-
localVarQueryParameter['code'] = code;
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
if (expand !== undefined) {
|
|
164
|
-
localVarQueryParameter['expand'] = expand;
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
if (expand2 !== undefined) {
|
|
168
|
-
localVarQueryParameter['expand'] = expand2;
|
|
169
|
-
}
|
|
170
|
-
|
|
171
106
|
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
172
107
|
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
173
108
|
}
|
|
@@ -184,20 +119,17 @@ export const PaymentMethodsApiAxiosParamCreator = function (configuration?: Conf
|
|
|
184
119
|
};
|
|
185
120
|
},
|
|
186
121
|
/**
|
|
187
|
-
* Returns a list of payment methods you
|
|
122
|
+
* Returns a list of payment methods you have previously created. The payment methods are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
188
123
|
* @summary List payment methods
|
|
189
124
|
* @param {string} [authorization] Bearer Token
|
|
190
|
-
* @param {
|
|
191
|
-
* @param {
|
|
192
|
-
* @param {
|
|
193
|
-
* @param {
|
|
194
|
-
* @param {any} [order] The order parameter determines how the results should be sorted according to a specified field. It functions similarly to an SQL ORDER BY. Sorting can be performed in either ascending (ASC) or descending (DESC) order. Default: ASC.
|
|
195
|
-
* @param {any} [expand] Use this parameter to fetch additional information about the list items. The expand query parameter increases the set of fields that appear in the response in addition to the default ones. Expanding resources can reduce the number of API calls required to accomplish a task. However, use this with parsimony as some expanded fields can drastically increase payload size.
|
|
196
|
-
* @param {any} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations. In general, fetching filtered responses conserves bandwidth and reduces response time.
|
|
125
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: code, id, pspCustomerId, psp, type</i>
|
|
126
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: code, id, pspCustomerId, psp, type</i>
|
|
127
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, createdAt</i>
|
|
128
|
+
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/> <i>Allowed values: <i>
|
|
197
129
|
* @param {*} [options] Override http request option.
|
|
198
130
|
* @throws {RequiredError}
|
|
199
131
|
*/
|
|
200
|
-
listPaymentMethods: async (authorization?: string,
|
|
132
|
+
listPaymentMethods: async (authorization?: string, filter?: string, filters?: string, order?: string, expand?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
201
133
|
const localVarPath = `/paymentservice/v1/payment-methods`;
|
|
202
134
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
203
135
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
@@ -216,20 +148,12 @@ export const PaymentMethodsApiAxiosParamCreator = function (configuration?: Conf
|
|
|
216
148
|
// http bearer authentication required
|
|
217
149
|
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
218
150
|
|
|
219
|
-
if (pageSize !== undefined) {
|
|
220
|
-
localVarQueryParameter['pageSize'] = pageSize;
|
|
221
|
-
}
|
|
222
|
-
|
|
223
|
-
if (pageToken !== undefined) {
|
|
224
|
-
localVarQueryParameter['pageToken'] = pageToken;
|
|
225
|
-
}
|
|
226
|
-
|
|
227
151
|
if (filter !== undefined) {
|
|
228
152
|
localVarQueryParameter['filter'] = filter;
|
|
229
153
|
}
|
|
230
154
|
|
|
231
|
-
if (
|
|
232
|
-
localVarQueryParameter['
|
|
155
|
+
if (filters !== undefined) {
|
|
156
|
+
localVarQueryParameter['filters'] = filters;
|
|
233
157
|
}
|
|
234
158
|
|
|
235
159
|
if (order !== undefined) {
|
|
@@ -240,10 +164,6 @@ export const PaymentMethodsApiAxiosParamCreator = function (configuration?: Conf
|
|
|
240
164
|
localVarQueryParameter['expand'] = expand;
|
|
241
165
|
}
|
|
242
166
|
|
|
243
|
-
if (filters !== undefined) {
|
|
244
|
-
localVarQueryParameter['filters'] = filters;
|
|
245
|
-
}
|
|
246
|
-
|
|
247
167
|
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
248
168
|
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
249
169
|
}
|
|
@@ -271,7 +191,7 @@ export const PaymentMethodsApiFp = function(configuration?: Configuration) {
|
|
|
271
191
|
return {
|
|
272
192
|
/**
|
|
273
193
|
* This will create payment method in the database as well as in the PSP. The newly created payment method will be set as default payment method will be used by the customer to pay or receive a refund.
|
|
274
|
-
* @summary Create the payment
|
|
194
|
+
* @summary Create the payment method
|
|
275
195
|
* @param {object} body
|
|
276
196
|
* @param {string} [authorization] Bearer Token
|
|
277
197
|
* @param {*} [options] Override http request option.
|
|
@@ -282,47 +202,30 @@ export const PaymentMethodsApiFp = function(configuration?: Configuration) {
|
|
|
282
202
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
283
203
|
},
|
|
284
204
|
/**
|
|
285
|
-
*
|
|
286
|
-
* @summary
|
|
287
|
-
* @param {
|
|
288
|
-
* @param {string} [authorization] Bearer Token
|
|
289
|
-
* @param {*} [options] Override http request option.
|
|
290
|
-
* @throws {RequiredError}
|
|
291
|
-
*/
|
|
292
|
-
async deletePaymentMethod(id: number, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
293
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.deletePaymentMethod(id, authorization, options);
|
|
294
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
295
|
-
},
|
|
296
|
-
/**
|
|
297
|
-
* Retrieves the details of a payment method that was previously created. Supply the unique payment method code that was returned when you created the payment method and Emil Api will return the corresponding payment method information.
|
|
298
|
-
* @summary Retrieve a payment method
|
|
299
|
-
* @param {string} code Unique identifier for the object.
|
|
300
|
-
* @param {string} expand Fields to expand response by
|
|
301
|
-
* @param {string} expand2 Fields to expand response by
|
|
205
|
+
* Retrieves the details of the payment method that was previously created. Supply the unique payment method code that was returned when you created it and Emil Api will return the corresponding payment method information.
|
|
206
|
+
* @summary Retrieve the payment method
|
|
207
|
+
* @param {string} code
|
|
302
208
|
* @param {string} [authorization] Bearer Token
|
|
303
209
|
* @param {*} [options] Override http request option.
|
|
304
210
|
* @throws {RequiredError}
|
|
305
211
|
*/
|
|
306
|
-
async getPaymentMethod(code: string,
|
|
307
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.getPaymentMethod(code,
|
|
212
|
+
async getPaymentMethod(code: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
213
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getPaymentMethod(code, authorization, options);
|
|
308
214
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
309
215
|
},
|
|
310
216
|
/**
|
|
311
|
-
* Returns a list of payment methods you
|
|
217
|
+
* Returns a list of payment methods you have previously created. The payment methods are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
312
218
|
* @summary List payment methods
|
|
313
219
|
* @param {string} [authorization] Bearer Token
|
|
314
|
-
* @param {
|
|
315
|
-
* @param {
|
|
316
|
-
* @param {
|
|
317
|
-
* @param {
|
|
318
|
-
* @param {any} [order] The order parameter determines how the results should be sorted according to a specified field. It functions similarly to an SQL ORDER BY. Sorting can be performed in either ascending (ASC) or descending (DESC) order. Default: ASC.
|
|
319
|
-
* @param {any} [expand] Use this parameter to fetch additional information about the list items. The expand query parameter increases the set of fields that appear in the response in addition to the default ones. Expanding resources can reduce the number of API calls required to accomplish a task. However, use this with parsimony as some expanded fields can drastically increase payload size.
|
|
320
|
-
* @param {any} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations. In general, fetching filtered responses conserves bandwidth and reduces response time.
|
|
220
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: code, id, pspCustomerId, psp, type</i>
|
|
221
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: code, id, pspCustomerId, psp, type</i>
|
|
222
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, createdAt</i>
|
|
223
|
+
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/> <i>Allowed values: <i>
|
|
321
224
|
* @param {*} [options] Override http request option.
|
|
322
225
|
* @throws {RequiredError}
|
|
323
226
|
*/
|
|
324
|
-
async listPaymentMethods(authorization?: string,
|
|
325
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.listPaymentMethods(authorization,
|
|
227
|
+
async listPaymentMethods(authorization?: string, filter?: string, filters?: string, order?: string, expand?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
228
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.listPaymentMethods(authorization, filter, filters, order, expand, options);
|
|
326
229
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
327
230
|
},
|
|
328
231
|
}
|
|
@@ -337,7 +240,7 @@ export const PaymentMethodsApiFactory = function (configuration?: Configuration,
|
|
|
337
240
|
return {
|
|
338
241
|
/**
|
|
339
242
|
* This will create payment method in the database as well as in the PSP. The newly created payment method will be set as default payment method will be used by the customer to pay or receive a refund.
|
|
340
|
-
* @summary Create the payment
|
|
243
|
+
* @summary Create the payment method
|
|
341
244
|
* @param {object} body
|
|
342
245
|
* @param {string} [authorization] Bearer Token
|
|
343
246
|
* @param {*} [options] Override http request option.
|
|
@@ -347,45 +250,29 @@ export const PaymentMethodsApiFactory = function (configuration?: Configuration,
|
|
|
347
250
|
return localVarFp.createPaymentMethod(body, authorization, options).then((request) => request(axios, basePath));
|
|
348
251
|
},
|
|
349
252
|
/**
|
|
350
|
-
*
|
|
351
|
-
* @summary
|
|
352
|
-
* @param {
|
|
253
|
+
* Retrieves the details of the payment method that was previously created. Supply the unique payment method code that was returned when you created it and Emil Api will return the corresponding payment method information.
|
|
254
|
+
* @summary Retrieve the payment method
|
|
255
|
+
* @param {string} code
|
|
353
256
|
* @param {string} [authorization] Bearer Token
|
|
354
257
|
* @param {*} [options] Override http request option.
|
|
355
258
|
* @throws {RequiredError}
|
|
356
259
|
*/
|
|
357
|
-
|
|
358
|
-
return localVarFp.
|
|
260
|
+
getPaymentMethod(code: string, authorization?: string, options?: any): AxiosPromise<void> {
|
|
261
|
+
return localVarFp.getPaymentMethod(code, authorization, options).then((request) => request(axios, basePath));
|
|
359
262
|
},
|
|
360
263
|
/**
|
|
361
|
-
*
|
|
362
|
-
* @summary Retrieve a payment method
|
|
363
|
-
* @param {string} code Unique identifier for the object.
|
|
364
|
-
* @param {string} expand Fields to expand response by
|
|
365
|
-
* @param {string} expand2 Fields to expand response by
|
|
366
|
-
* @param {string} [authorization] Bearer Token
|
|
367
|
-
* @param {*} [options] Override http request option.
|
|
368
|
-
* @throws {RequiredError}
|
|
369
|
-
*/
|
|
370
|
-
getPaymentMethod(code: string, expand: string, expand2: string, authorization?: string, options?: any): AxiosPromise<void> {
|
|
371
|
-
return localVarFp.getPaymentMethod(code, expand, expand2, authorization, options).then((request) => request(axios, basePath));
|
|
372
|
-
},
|
|
373
|
-
/**
|
|
374
|
-
* Returns a list of payment methods you’ve previously created. The payment methods are returned in sorted order, with the oldest payment appearing first. For more information about pagination, read the Pagination documentation.
|
|
264
|
+
* Returns a list of payment methods you have previously created. The payment methods are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
375
265
|
* @summary List payment methods
|
|
376
266
|
* @param {string} [authorization] Bearer Token
|
|
377
|
-
* @param {
|
|
378
|
-
* @param {
|
|
379
|
-
* @param {
|
|
380
|
-
* @param {
|
|
381
|
-
* @param {any} [order] The order parameter determines how the results should be sorted according to a specified field. It functions similarly to an SQL ORDER BY. Sorting can be performed in either ascending (ASC) or descending (DESC) order. Default: ASC.
|
|
382
|
-
* @param {any} [expand] Use this parameter to fetch additional information about the list items. The expand query parameter increases the set of fields that appear in the response in addition to the default ones. Expanding resources can reduce the number of API calls required to accomplish a task. However, use this with parsimony as some expanded fields can drastically increase payload size.
|
|
383
|
-
* @param {any} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations. In general, fetching filtered responses conserves bandwidth and reduces response time.
|
|
267
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: code, id, pspCustomerId, psp, type</i>
|
|
268
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: code, id, pspCustomerId, psp, type</i>
|
|
269
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, createdAt</i>
|
|
270
|
+
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/> <i>Allowed values: <i>
|
|
384
271
|
* @param {*} [options] Override http request option.
|
|
385
272
|
* @throws {RequiredError}
|
|
386
273
|
*/
|
|
387
|
-
listPaymentMethods(authorization?: string,
|
|
388
|
-
return localVarFp.listPaymentMethods(authorization,
|
|
274
|
+
listPaymentMethods(authorization?: string, filter?: string, filters?: string, order?: string, expand?: string, options?: any): AxiosPromise<void> {
|
|
275
|
+
return localVarFp.listPaymentMethods(authorization, filter, filters, order, expand, options).then((request) => request(axios, basePath));
|
|
389
276
|
},
|
|
390
277
|
};
|
|
391
278
|
};
|
|
@@ -411,27 +298,6 @@ export interface PaymentMethodsApiCreatePaymentMethodRequest {
|
|
|
411
298
|
readonly authorization?: string
|
|
412
299
|
}
|
|
413
300
|
|
|
414
|
-
/**
|
|
415
|
-
* Request parameters for deletePaymentMethod operation in PaymentMethodsApi.
|
|
416
|
-
* @export
|
|
417
|
-
* @interface PaymentMethodsApiDeletePaymentMethodRequest
|
|
418
|
-
*/
|
|
419
|
-
export interface PaymentMethodsApiDeletePaymentMethodRequest {
|
|
420
|
-
/**
|
|
421
|
-
* Unique identifier for payment method
|
|
422
|
-
* @type {number}
|
|
423
|
-
* @memberof PaymentMethodsApiDeletePaymentMethod
|
|
424
|
-
*/
|
|
425
|
-
readonly id: number
|
|
426
|
-
|
|
427
|
-
/**
|
|
428
|
-
* Bearer Token
|
|
429
|
-
* @type {string}
|
|
430
|
-
* @memberof PaymentMethodsApiDeletePaymentMethod
|
|
431
|
-
*/
|
|
432
|
-
readonly authorization?: string
|
|
433
|
-
}
|
|
434
|
-
|
|
435
301
|
/**
|
|
436
302
|
* Request parameters for getPaymentMethod operation in PaymentMethodsApi.
|
|
437
303
|
* @export
|
|
@@ -439,26 +305,12 @@ export interface PaymentMethodsApiDeletePaymentMethodRequest {
|
|
|
439
305
|
*/
|
|
440
306
|
export interface PaymentMethodsApiGetPaymentMethodRequest {
|
|
441
307
|
/**
|
|
442
|
-
*
|
|
308
|
+
*
|
|
443
309
|
* @type {string}
|
|
444
310
|
* @memberof PaymentMethodsApiGetPaymentMethod
|
|
445
311
|
*/
|
|
446
312
|
readonly code: string
|
|
447
313
|
|
|
448
|
-
/**
|
|
449
|
-
* Fields to expand response by
|
|
450
|
-
* @type {string}
|
|
451
|
-
* @memberof PaymentMethodsApiGetPaymentMethod
|
|
452
|
-
*/
|
|
453
|
-
readonly expand: string
|
|
454
|
-
|
|
455
|
-
/**
|
|
456
|
-
* Fields to expand response by
|
|
457
|
-
* @type {string}
|
|
458
|
-
* @memberof PaymentMethodsApiGetPaymentMethod
|
|
459
|
-
*/
|
|
460
|
-
readonly expand2: string
|
|
461
|
-
|
|
462
314
|
/**
|
|
463
315
|
* Bearer Token
|
|
464
316
|
* @type {string}
|
|
@@ -481,53 +333,32 @@ export interface PaymentMethodsApiListPaymentMethodsRequest {
|
|
|
481
333
|
readonly authorization?: string
|
|
482
334
|
|
|
483
335
|
/**
|
|
484
|
-
*
|
|
485
|
-
* @type {
|
|
486
|
-
* @memberof PaymentMethodsApiListPaymentMethods
|
|
487
|
-
*/
|
|
488
|
-
readonly pageSize?: any
|
|
489
|
-
|
|
490
|
-
/**
|
|
491
|
-
* A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken=1, your subsequent call can include pageToken=2 in order to fetch the next page of the list.
|
|
492
|
-
* @type {any}
|
|
493
|
-
* @memberof PaymentMethodsApiListPaymentMethods
|
|
494
|
-
*/
|
|
495
|
-
readonly pageToken?: any
|
|
496
|
-
|
|
497
|
-
/**
|
|
498
|
-
* Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
|
|
499
|
-
* @type {any}
|
|
500
|
-
* @memberof PaymentMethodsApiListPaymentMethods
|
|
501
|
-
*/
|
|
502
|
-
readonly filter?: any
|
|
503
|
-
|
|
504
|
-
/**
|
|
505
|
-
* Search the list by any field. For instance, if you want to search by code add code=xxx in order to fetch the result.
|
|
506
|
-
* @type {any}
|
|
336
|
+
* Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: code, id, pspCustomerId, psp, type</i>
|
|
337
|
+
* @type {string}
|
|
507
338
|
* @memberof PaymentMethodsApiListPaymentMethods
|
|
508
339
|
*/
|
|
509
|
-
readonly
|
|
340
|
+
readonly filter?: string
|
|
510
341
|
|
|
511
342
|
/**
|
|
512
|
-
*
|
|
513
|
-
* @type {
|
|
343
|
+
* Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: code, id, pspCustomerId, psp, type</i>
|
|
344
|
+
* @type {string}
|
|
514
345
|
* @memberof PaymentMethodsApiListPaymentMethods
|
|
515
346
|
*/
|
|
516
|
-
readonly
|
|
347
|
+
readonly filters?: string
|
|
517
348
|
|
|
518
349
|
/**
|
|
519
|
-
*
|
|
520
|
-
* @type {
|
|
350
|
+
* Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, createdAt</i>
|
|
351
|
+
* @type {string}
|
|
521
352
|
* @memberof PaymentMethodsApiListPaymentMethods
|
|
522
353
|
*/
|
|
523
|
-
readonly
|
|
354
|
+
readonly order?: string
|
|
524
355
|
|
|
525
356
|
/**
|
|
526
|
-
*
|
|
527
|
-
* @type {
|
|
357
|
+
* Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/> <i>Allowed values: <i>
|
|
358
|
+
* @type {string}
|
|
528
359
|
* @memberof PaymentMethodsApiListPaymentMethods
|
|
529
360
|
*/
|
|
530
|
-
readonly
|
|
361
|
+
readonly expand?: string
|
|
531
362
|
}
|
|
532
363
|
|
|
533
364
|
/**
|
|
@@ -539,7 +370,7 @@ export interface PaymentMethodsApiListPaymentMethodsRequest {
|
|
|
539
370
|
export class PaymentMethodsApi extends BaseAPI {
|
|
540
371
|
/**
|
|
541
372
|
* This will create payment method in the database as well as in the PSP. The newly created payment method will be set as default payment method will be used by the customer to pay or receive a refund.
|
|
542
|
-
* @summary Create the payment
|
|
373
|
+
* @summary Create the payment method
|
|
543
374
|
* @param {PaymentMethodsApiCreatePaymentMethodRequest} requestParameters Request parameters.
|
|
544
375
|
* @param {*} [options] Override http request option.
|
|
545
376
|
* @throws {RequiredError}
|
|
@@ -550,31 +381,19 @@ export class PaymentMethodsApi extends BaseAPI {
|
|
|
550
381
|
}
|
|
551
382
|
|
|
552
383
|
/**
|
|
553
|
-
*
|
|
554
|
-
* @summary
|
|
555
|
-
* @param {PaymentMethodsApiDeletePaymentMethodRequest} requestParameters Request parameters.
|
|
556
|
-
* @param {*} [options] Override http request option.
|
|
557
|
-
* @throws {RequiredError}
|
|
558
|
-
* @memberof PaymentMethodsApi
|
|
559
|
-
*/
|
|
560
|
-
public deletePaymentMethod(requestParameters: PaymentMethodsApiDeletePaymentMethodRequest, options?: AxiosRequestConfig) {
|
|
561
|
-
return PaymentMethodsApiFp(this.configuration).deletePaymentMethod(requestParameters.id, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
562
|
-
}
|
|
563
|
-
|
|
564
|
-
/**
|
|
565
|
-
* Retrieves the details of a payment method that was previously created. Supply the unique payment method code that was returned when you created the payment method and Emil Api will return the corresponding payment method information.
|
|
566
|
-
* @summary Retrieve a payment method
|
|
384
|
+
* Retrieves the details of the payment method that was previously created. Supply the unique payment method code that was returned when you created it and Emil Api will return the corresponding payment method information.
|
|
385
|
+
* @summary Retrieve the payment method
|
|
567
386
|
* @param {PaymentMethodsApiGetPaymentMethodRequest} requestParameters Request parameters.
|
|
568
387
|
* @param {*} [options] Override http request option.
|
|
569
388
|
* @throws {RequiredError}
|
|
570
389
|
* @memberof PaymentMethodsApi
|
|
571
390
|
*/
|
|
572
391
|
public getPaymentMethod(requestParameters: PaymentMethodsApiGetPaymentMethodRequest, options?: AxiosRequestConfig) {
|
|
573
|
-
return PaymentMethodsApiFp(this.configuration).getPaymentMethod(requestParameters.code, requestParameters.
|
|
392
|
+
return PaymentMethodsApiFp(this.configuration).getPaymentMethod(requestParameters.code, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
574
393
|
}
|
|
575
394
|
|
|
576
395
|
/**
|
|
577
|
-
* Returns a list of payment methods you
|
|
396
|
+
* Returns a list of payment methods you have previously created. The payment methods are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
578
397
|
* @summary List payment methods
|
|
579
398
|
* @param {PaymentMethodsApiListPaymentMethodsRequest} requestParameters Request parameters.
|
|
580
399
|
* @param {*} [options] Override http request option.
|
|
@@ -582,6 +401,6 @@ export class PaymentMethodsApi extends BaseAPI {
|
|
|
582
401
|
* @memberof PaymentMethodsApi
|
|
583
402
|
*/
|
|
584
403
|
public listPaymentMethods(requestParameters: PaymentMethodsApiListPaymentMethodsRequest = {}, options?: AxiosRequestConfig) {
|
|
585
|
-
return PaymentMethodsApiFp(this.configuration).listPaymentMethods(requestParameters.authorization, requestParameters.
|
|
404
|
+
return PaymentMethodsApiFp(this.configuration).listPaymentMethods(requestParameters.authorization, requestParameters.filter, requestParameters.filters, requestParameters.order, requestParameters.expand, options).then((request) => request(this.axios, this.basePath));
|
|
586
405
|
}
|
|
587
406
|
}
|