@emilgroup/payment-sdk 1.4.1-beta.4 → 1.4.1-beta.40
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 +15 -7
- package/README.md +2 -2
- package/api/bank-accounts-api.ts +501 -89
- package/api/bank-transaction-api.ts +303 -97
- package/api/{default-api.ts → health-check-api.ts} +23 -19
- package/api/payment-methods-api.ts +62 -243
- package/api/payment-reminders-api.ts +58 -100
- package/api/payment-setup-api.ts +18 -10
- package/api/payments-api.ts +73 -136
- package/api/refunds-api.ts +436 -0
- package/api/tenant-bank-account-api.ts +100 -102
- package/api/webhooks-api.ts +18 -14
- package/api.ts +6 -4
- package/base.ts +23 -11
- package/common.ts +4 -4
- package/configuration.ts +2 -2
- package/dist/api/bank-accounts-api.d.ts +293 -70
- package/dist/api/bank-accounts-api.js +433 -63
- package/dist/api/bank-transaction-api.d.ts +193 -83
- package/dist/api/bank-transaction-api.js +253 -66
- package/dist/api/health-check-api.d.ts +70 -0
- package/dist/api/{default-api.js → health-check-api.js} +32 -28
- package/dist/api/payment-methods-api.d.ts +52 -152
- package/dist/api/payment-methods-api.js +49 -179
- package/dist/api/payment-reminders-api.d.ts +53 -80
- package/dist/api/payment-reminders-api.js +45 -63
- package/dist/api/payment-setup-api.d.ts +18 -10
- package/dist/api/payment-setup-api.js +18 -10
- package/dist/api/payments-api.d.ts +63 -99
- package/dist/api/payments-api.js +56 -86
- package/dist/api/refunds-api.d.ts +251 -0
- package/dist/api/refunds-api.js +439 -0
- package/dist/api/tenant-bank-account-api.d.ts +94 -89
- package/dist/api/tenant-bank-account-api.js +72 -64
- package/dist/api/webhooks-api.d.ts +18 -14
- package/dist/api/webhooks-api.js +16 -12
- package/dist/api.d.ts +4 -3
- package/dist/api.js +4 -3
- package/dist/base.d.ts +7 -4
- package/dist/base.js +32 -23
- package/dist/common.d.ts +4 -4
- package/dist/common.js +2 -2
- package/dist/configuration.d.ts +2 -2
- package/dist/configuration.js +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/dist/models/{bank-transaction-response-class.d.ts → bank-transaction-class-without-expand-properties.d.ts} +32 -34
- package/dist/models/{bank-transaction-response-class.js → bank-transaction-class-without-expand-properties.js} +2 -2
- package/dist/models/create-bank-account-request-dto.d.ts +42 -0
- package/dist/models/{get-request-dto.js → create-bank-account-request-dto.js} +2 -2
- package/dist/models/create-payment-reminder-request-dto.d.ts +2 -2
- package/dist/models/create-payment-reminder-request-dto.js +2 -2
- package/dist/models/create-payment-request-dto.d.ts +4 -4
- package/dist/models/create-payment-request-dto.js +2 -2
- package/dist/models/create-refund-request-dto.d.ts +24 -0
- package/dist/models/{get-bank-transactions-response-class.js → create-refund-request-dto.js} +2 -2
- package/dist/models/create-tenant-bank-account-request-dto.d.ts +2 -2
- package/dist/models/create-tenant-bank-account-request-dto.js +2 -2
- package/dist/models/create-tenant-bank-account-response-class.d.ts +25 -0
- package/dist/models/{list-bank-transactions-response-class.js → create-tenant-bank-account-response-class.js} +2 -2
- package/dist/models/deactivate-payment-reminder-request-dto.d.ts +2 -2
- package/dist/models/deactivate-payment-reminder-request-dto.js +2 -2
- package/dist/models/get-tenant-bank-account-response-class.d.ts +6 -6
- package/dist/models/get-tenant-bank-account-response-class.js +2 -2
- package/dist/models/index.d.ts +13 -6
- package/dist/models/index.js +13 -6
- package/dist/models/inline-response200.d.ts +2 -2
- package/dist/models/inline-response200.js +2 -2
- package/dist/models/inline-response503.d.ts +2 -2
- package/dist/models/inline-response503.js +2 -2
- package/dist/models/link-bank-transaction-request-dto-rest.d.ts +24 -0
- package/dist/models/link-bank-transaction-request-dto-rest.js +15 -0
- package/dist/models/list-tenant-bank-account-response-class.d.ts +31 -0
- package/dist/models/list-tenant-bank-account-response-class.js +15 -0
- 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-class-without-expand-properties.d.ts +78 -0
- 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 +24 -0
- package/dist/models/unlink-bank-transaction-request-dto-rest.js +15 -0
- 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 +2 -2
- package/dist/models/update-tenant-bank-account-rest-request-dto.js +2 -2
- package/dist/models/validate-pspconfig-request-dto.d.ts +2 -2
- package/dist/models/validate-pspconfig-request-dto.js +2 -2
- package/index.ts +2 -2
- package/models/{bank-transaction-response-class.ts → bank-transaction-class-without-expand-properties.ts} +32 -34
- package/models/create-bank-account-request-dto.ts +48 -0
- package/models/create-payment-reminder-request-dto.ts +2 -2
- package/models/create-payment-request-dto.ts +4 -4
- package/models/create-refund-request-dto.ts +30 -0
- package/models/create-tenant-bank-account-request-dto.ts +2 -2
- package/models/create-tenant-bank-account-response-class.ts +31 -0
- package/models/deactivate-payment-reminder-request-dto.ts +2 -2
- package/models/get-tenant-bank-account-response-class.ts +6 -6
- package/models/index.ts +13 -6
- package/models/inline-response200.ts +2 -2
- package/models/inline-response503.ts +2 -2
- package/models/link-bank-transaction-request-dto-rest.ts +30 -0
- 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} +24 -12
- package/models/tenant-bank-account-class.ts +91 -0
- package/models/unlink-bank-transaction-request-dto-rest.ts +30 -0
- 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 +2 -2
- package/models/validate-pspconfig-request-dto.ts +2 -2
- package/package.json +1 -1
- package/dist/api/default-api.d.ts +0 -66
- package/dist/models/get-bank-transactions-response-class.d.ts +0 -25
- package/dist/models/get-request-dto.d.ts +0 -30
- package/dist/models/list-bank-transactions-response-class.d.ts +0 -31
- package/dist/models/tenant-bank-account-response-class.d.ts +0 -66
- 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/get-bank-transactions-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/transaction-class.ts +0 -60
package/api/bank-accounts-api.ts
CHANGED
|
@@ -2,10 +2,10 @@
|
|
|
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
|
-
* Contact:
|
|
8
|
+
* Contact: kontakt@emil.de
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
11
|
* https://openapi-generator.tech
|
|
@@ -20,6 +20,12 @@ import { Configuration } from '../configuration';
|
|
|
20
20
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../common';
|
|
21
21
|
// @ts-ignore
|
|
22
22
|
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from '../base';
|
|
23
|
+
// @ts-ignore
|
|
24
|
+
import { CreateBankAccountRequestDto } from '../models';
|
|
25
|
+
// @ts-ignore
|
|
26
|
+
import { SetPrimaryBankAccountRequestDtoRest } from '../models';
|
|
27
|
+
// @ts-ignore
|
|
28
|
+
import { UpdateBankAccountRequestDtoRest } from '../models';
|
|
23
29
|
/**
|
|
24
30
|
* BankAccountsApi - axios parameter creator
|
|
25
31
|
* @export
|
|
@@ -27,16 +33,16 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } fr
|
|
|
27
33
|
export const BankAccountsApiAxiosParamCreator = function (configuration?: Configuration) {
|
|
28
34
|
return {
|
|
29
35
|
/**
|
|
30
|
-
*
|
|
31
|
-
* @summary Create
|
|
32
|
-
* @param {
|
|
36
|
+
* This will create a bank account for a specified partner/account. If this is the first bank account for the specified partner/account, it will be marked as primary.
|
|
37
|
+
* @summary Create the bank account
|
|
38
|
+
* @param {CreateBankAccountRequestDto} createBankAccountRequestDto
|
|
33
39
|
* @param {string} [authorization] Bearer Token
|
|
34
40
|
* @param {*} [options] Override http request option.
|
|
35
41
|
* @throws {RequiredError}
|
|
36
42
|
*/
|
|
37
|
-
createBankAccount: async (
|
|
38
|
-
// verify required parameter '
|
|
39
|
-
assertParamExists('createBankAccount', '
|
|
43
|
+
createBankAccount: async (createBankAccountRequestDto: CreateBankAccountRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
44
|
+
// verify required parameter 'createBankAccountRequestDto' is not null or undefined
|
|
45
|
+
assertParamExists('createBankAccount', 'createBankAccountRequestDto', createBankAccountRequestDto)
|
|
40
46
|
const localVarPath = `/paymentservice/v1/bank-accounts`;
|
|
41
47
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
42
48
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
@@ -66,7 +72,7 @@ export const BankAccountsApiAxiosParamCreator = function (configuration?: Config
|
|
|
66
72
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
67
73
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
68
74
|
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
69
|
-
localVarRequestOptions.data = serializeDataIfNeeded(
|
|
75
|
+
localVarRequestOptions.data = serializeDataIfNeeded(createBankAccountRequestDto, localVarRequestOptions, configuration)
|
|
70
76
|
|
|
71
77
|
return {
|
|
72
78
|
url: toPathString(localVarUrlObj),
|
|
@@ -74,21 +80,64 @@ export const BankAccountsApiAxiosParamCreator = function (configuration?: Config
|
|
|
74
80
|
};
|
|
75
81
|
},
|
|
76
82
|
/**
|
|
77
|
-
*
|
|
78
|
-
* @summary
|
|
83
|
+
* Deletes a bank account by code. If the bank account was primary, then the first available bank account for the specified partner/account will be marked as primary.
|
|
84
|
+
* @summary Delete the bank account
|
|
85
|
+
* @param {string} code Unique identifier for the object.
|
|
79
86
|
* @param {string} [authorization] Bearer Token
|
|
80
|
-
* @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
|
|
81
|
-
* @param {any} [pageToken] 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.
|
|
82
|
-
* @param {any} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
|
|
83
|
-
* @param {any} [search] Search the list by any field. For instance, if you want to search by code add code=xxx in order to fetch the result.
|
|
84
|
-
* @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.
|
|
85
|
-
* @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.
|
|
86
|
-
* @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.
|
|
87
87
|
* @param {*} [options] Override http request option.
|
|
88
88
|
* @throws {RequiredError}
|
|
89
89
|
*/
|
|
90
|
-
|
|
91
|
-
|
|
90
|
+
deleteBankAccount: async (code: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
91
|
+
// verify required parameter 'code' is not null or undefined
|
|
92
|
+
assertParamExists('deleteBankAccount', 'code', code)
|
|
93
|
+
const localVarPath = `/paymentservice/v1/bank-accounts/{code}`
|
|
94
|
+
.replace(`{${"code"}}`, encodeURIComponent(String(code)));
|
|
95
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
96
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
97
|
+
let baseOptions;
|
|
98
|
+
let baseAccessToken;
|
|
99
|
+
if (configuration) {
|
|
100
|
+
baseOptions = configuration.baseOptions;
|
|
101
|
+
baseAccessToken = configuration.accessToken;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options};
|
|
105
|
+
const localVarHeaderParameter = {} as any;
|
|
106
|
+
const localVarQueryParameter = {} as any;
|
|
107
|
+
|
|
108
|
+
// authentication bearer required
|
|
109
|
+
// http bearer authentication required
|
|
110
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
111
|
+
|
|
112
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
113
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
119
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
120
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
121
|
+
|
|
122
|
+
return {
|
|
123
|
+
url: toPathString(localVarUrlObj),
|
|
124
|
+
options: localVarRequestOptions,
|
|
125
|
+
};
|
|
126
|
+
},
|
|
127
|
+
/**
|
|
128
|
+
* Retrieves the details of the bank account that was previously created. Supply the unique bank account code that was returned when you created it and Emil Api will return the corresponding bank account information.
|
|
129
|
+
* @summary Retrieve the bank account
|
|
130
|
+
* @param {string} code
|
|
131
|
+
* @param {string} [authorization] Bearer Token
|
|
132
|
+
* @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: primaryBankAccount<i>
|
|
133
|
+
* @param {*} [options] Override http request option.
|
|
134
|
+
* @throws {RequiredError}
|
|
135
|
+
*/
|
|
136
|
+
getBankAccount: async (code: string, authorization?: string, expand?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
137
|
+
// verify required parameter 'code' is not null or undefined
|
|
138
|
+
assertParamExists('getBankAccount', 'code', code)
|
|
139
|
+
const localVarPath = `/paymentservice/v1/bank-accounts/{code}`
|
|
140
|
+
.replace(`{${"code"}}`, encodeURIComponent(String(code)));
|
|
92
141
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
93
142
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
94
143
|
let baseOptions;
|
|
@@ -106,20 +155,61 @@ export const BankAccountsApiAxiosParamCreator = function (configuration?: Config
|
|
|
106
155
|
// http bearer authentication required
|
|
107
156
|
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
108
157
|
|
|
109
|
-
if (
|
|
110
|
-
localVarQueryParameter['
|
|
158
|
+
if (expand !== undefined) {
|
|
159
|
+
localVarQueryParameter['expand'] = expand;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
163
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
111
164
|
}
|
|
112
165
|
|
|
113
|
-
|
|
114
|
-
|
|
166
|
+
|
|
167
|
+
|
|
168
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
169
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
170
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
171
|
+
|
|
172
|
+
return {
|
|
173
|
+
url: toPathString(localVarUrlObj),
|
|
174
|
+
options: localVarRequestOptions,
|
|
175
|
+
};
|
|
176
|
+
},
|
|
177
|
+
/**
|
|
178
|
+
* Returns a list of bank accounts you have previously created. The bank accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
179
|
+
* @summary List bank accounts
|
|
180
|
+
* @param {string} [authorization] Bearer Token
|
|
181
|
+
* @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, accountCode, partnerCode</i>
|
|
182
|
+
* @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, accountCode, partnerCode</i>
|
|
183
|
+
* @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>
|
|
184
|
+
* @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: primaryBankAccount<i>
|
|
185
|
+
* @param {*} [options] Override http request option.
|
|
186
|
+
* @throws {RequiredError}
|
|
187
|
+
*/
|
|
188
|
+
listBankAccounts: async (authorization?: string, filter?: string, filters?: string, order?: string, expand?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
189
|
+
const localVarPath = `/paymentservice/v1/bank-accounts`;
|
|
190
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
191
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
192
|
+
let baseOptions;
|
|
193
|
+
let baseAccessToken;
|
|
194
|
+
if (configuration) {
|
|
195
|
+
baseOptions = configuration.baseOptions;
|
|
196
|
+
baseAccessToken = configuration.accessToken;
|
|
115
197
|
}
|
|
116
198
|
|
|
199
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
200
|
+
const localVarHeaderParameter = {} as any;
|
|
201
|
+
const localVarQueryParameter = {} as any;
|
|
202
|
+
|
|
203
|
+
// authentication bearer required
|
|
204
|
+
// http bearer authentication required
|
|
205
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
206
|
+
|
|
117
207
|
if (filter !== undefined) {
|
|
118
208
|
localVarQueryParameter['filter'] = filter;
|
|
119
209
|
}
|
|
120
210
|
|
|
121
|
-
if (
|
|
122
|
-
localVarQueryParameter['
|
|
211
|
+
if (filters !== undefined) {
|
|
212
|
+
localVarQueryParameter['filters'] = filters;
|
|
123
213
|
}
|
|
124
214
|
|
|
125
215
|
if (order !== undefined) {
|
|
@@ -130,19 +220,117 @@ export const BankAccountsApiAxiosParamCreator = function (configuration?: Config
|
|
|
130
220
|
localVarQueryParameter['expand'] = expand;
|
|
131
221
|
}
|
|
132
222
|
|
|
133
|
-
if (
|
|
134
|
-
|
|
223
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
224
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
|
|
229
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
230
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
231
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
232
|
+
|
|
233
|
+
return {
|
|
234
|
+
url: toPathString(localVarUrlObj),
|
|
235
|
+
options: localVarRequestOptions,
|
|
236
|
+
};
|
|
237
|
+
},
|
|
238
|
+
/**
|
|
239
|
+
* Set the primary bank account for the specified partner/account
|
|
240
|
+
* @summary Set primary bank account
|
|
241
|
+
* @param {string} code Code of the bank account to set primary
|
|
242
|
+
* @param {SetPrimaryBankAccountRequestDtoRest} setPrimaryBankAccountRequestDtoRest
|
|
243
|
+
* @param {string} [authorization] Bearer Token
|
|
244
|
+
* @param {*} [options] Override http request option.
|
|
245
|
+
* @throws {RequiredError}
|
|
246
|
+
*/
|
|
247
|
+
setPrimaryBankAccount: async (code: string, setPrimaryBankAccountRequestDtoRest: SetPrimaryBankAccountRequestDtoRest, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
248
|
+
// verify required parameter 'code' is not null or undefined
|
|
249
|
+
assertParamExists('setPrimaryBankAccount', 'code', code)
|
|
250
|
+
// verify required parameter 'setPrimaryBankAccountRequestDtoRest' is not null or undefined
|
|
251
|
+
assertParamExists('setPrimaryBankAccount', 'setPrimaryBankAccountRequestDtoRest', setPrimaryBankAccountRequestDtoRest)
|
|
252
|
+
const localVarPath = `/paymentservice/v1/bank-accounts/{code}/primary`
|
|
253
|
+
.replace(`{${"code"}}`, encodeURIComponent(String(code)));
|
|
254
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
255
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
256
|
+
let baseOptions;
|
|
257
|
+
let baseAccessToken;
|
|
258
|
+
if (configuration) {
|
|
259
|
+
baseOptions = configuration.baseOptions;
|
|
260
|
+
baseAccessToken = configuration.accessToken;
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
|
|
264
|
+
const localVarHeaderParameter = {} as any;
|
|
265
|
+
const localVarQueryParameter = {} as any;
|
|
266
|
+
|
|
267
|
+
// authentication bearer required
|
|
268
|
+
// http bearer authentication required
|
|
269
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
270
|
+
|
|
271
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
272
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
|
|
276
|
+
|
|
277
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
278
|
+
|
|
279
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
280
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
281
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
282
|
+
localVarRequestOptions.data = serializeDataIfNeeded(setPrimaryBankAccountRequestDtoRest, localVarRequestOptions, configuration)
|
|
283
|
+
|
|
284
|
+
return {
|
|
285
|
+
url: toPathString(localVarUrlObj),
|
|
286
|
+
options: localVarRequestOptions,
|
|
287
|
+
};
|
|
288
|
+
},
|
|
289
|
+
/**
|
|
290
|
+
* Update a bank account by code
|
|
291
|
+
* @summary Update the bank account
|
|
292
|
+
* @param {string} code Unique identifier for the object.
|
|
293
|
+
* @param {UpdateBankAccountRequestDtoRest} updateBankAccountRequestDtoRest
|
|
294
|
+
* @param {string} [authorization] Bearer Token
|
|
295
|
+
* @param {*} [options] Override http request option.
|
|
296
|
+
* @throws {RequiredError}
|
|
297
|
+
*/
|
|
298
|
+
updateBankAccount: async (code: string, updateBankAccountRequestDtoRest: UpdateBankAccountRequestDtoRest, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
299
|
+
// verify required parameter 'code' is not null or undefined
|
|
300
|
+
assertParamExists('updateBankAccount', 'code', code)
|
|
301
|
+
// verify required parameter 'updateBankAccountRequestDtoRest' is not null or undefined
|
|
302
|
+
assertParamExists('updateBankAccount', 'updateBankAccountRequestDtoRest', updateBankAccountRequestDtoRest)
|
|
303
|
+
const localVarPath = `/paymentservice/v1/bank-accounts/{code}`
|
|
304
|
+
.replace(`{${"code"}}`, encodeURIComponent(String(code)));
|
|
305
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
306
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
307
|
+
let baseOptions;
|
|
308
|
+
let baseAccessToken;
|
|
309
|
+
if (configuration) {
|
|
310
|
+
baseOptions = configuration.baseOptions;
|
|
311
|
+
baseAccessToken = configuration.accessToken;
|
|
135
312
|
}
|
|
136
313
|
|
|
314
|
+
const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
|
|
315
|
+
const localVarHeaderParameter = {} as any;
|
|
316
|
+
const localVarQueryParameter = {} as any;
|
|
317
|
+
|
|
318
|
+
// authentication bearer required
|
|
319
|
+
// http bearer authentication required
|
|
320
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
321
|
+
|
|
137
322
|
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
138
323
|
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
139
324
|
}
|
|
140
325
|
|
|
141
326
|
|
|
142
327
|
|
|
328
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
329
|
+
|
|
143
330
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
144
331
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
145
332
|
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
333
|
+
localVarRequestOptions.data = serializeDataIfNeeded(updateBankAccountRequestDtoRest, localVarRequestOptions, configuration)
|
|
146
334
|
|
|
147
335
|
return {
|
|
148
336
|
url: toPathString(localVarUrlObj),
|
|
@@ -160,33 +348,81 @@ export const BankAccountsApiFp = function(configuration?: Configuration) {
|
|
|
160
348
|
const localVarAxiosParamCreator = BankAccountsApiAxiosParamCreator(configuration)
|
|
161
349
|
return {
|
|
162
350
|
/**
|
|
163
|
-
*
|
|
164
|
-
* @summary Create
|
|
165
|
-
* @param {
|
|
351
|
+
* This will create a bank account for a specified partner/account. If this is the first bank account for the specified partner/account, it will be marked as primary.
|
|
352
|
+
* @summary Create the bank account
|
|
353
|
+
* @param {CreateBankAccountRequestDto} createBankAccountRequestDto
|
|
354
|
+
* @param {string} [authorization] Bearer Token
|
|
355
|
+
* @param {*} [options] Override http request option.
|
|
356
|
+
* @throws {RequiredError}
|
|
357
|
+
*/
|
|
358
|
+
async createBankAccount(createBankAccountRequestDto: CreateBankAccountRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
359
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.createBankAccount(createBankAccountRequestDto, authorization, options);
|
|
360
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
361
|
+
},
|
|
362
|
+
/**
|
|
363
|
+
* Deletes a bank account by code. If the bank account was primary, then the first available bank account for the specified partner/account will be marked as primary.
|
|
364
|
+
* @summary Delete the bank account
|
|
365
|
+
* @param {string} code Unique identifier for the object.
|
|
366
|
+
* @param {string} [authorization] Bearer Token
|
|
367
|
+
* @param {*} [options] Override http request option.
|
|
368
|
+
* @throws {RequiredError}
|
|
369
|
+
*/
|
|
370
|
+
async deleteBankAccount(code: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
371
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.deleteBankAccount(code, authorization, options);
|
|
372
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
373
|
+
},
|
|
374
|
+
/**
|
|
375
|
+
* Retrieves the details of the bank account that was previously created. Supply the unique bank account code that was returned when you created it and Emil Api will return the corresponding bank account information.
|
|
376
|
+
* @summary Retrieve the bank account
|
|
377
|
+
* @param {string} code
|
|
166
378
|
* @param {string} [authorization] Bearer Token
|
|
379
|
+
* @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: primaryBankAccount<i>
|
|
167
380
|
* @param {*} [options] Override http request option.
|
|
168
381
|
* @throws {RequiredError}
|
|
169
382
|
*/
|
|
170
|
-
async
|
|
171
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.
|
|
383
|
+
async getBankAccount(code: string, authorization?: string, expand?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
384
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getBankAccount(code, authorization, expand, options);
|
|
172
385
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
173
386
|
},
|
|
174
387
|
/**
|
|
175
|
-
* Returns a list of bank accounts you
|
|
388
|
+
* Returns a list of bank accounts you have previously created. The bank accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
176
389
|
* @summary List bank accounts
|
|
177
390
|
* @param {string} [authorization] Bearer Token
|
|
178
|
-
* @param {
|
|
179
|
-
* @param {
|
|
180
|
-
* @param {
|
|
181
|
-
* @param {
|
|
182
|
-
* @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.
|
|
183
|
-
* @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.
|
|
184
|
-
* @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.
|
|
391
|
+
* @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, accountCode, partnerCode</i>
|
|
392
|
+
* @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, accountCode, partnerCode</i>
|
|
393
|
+
* @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>
|
|
394
|
+
* @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: primaryBankAccount<i>
|
|
185
395
|
* @param {*} [options] Override http request option.
|
|
186
396
|
* @throws {RequiredError}
|
|
187
397
|
*/
|
|
188
|
-
async listBankAccounts(authorization?: string,
|
|
189
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.listBankAccounts(authorization,
|
|
398
|
+
async listBankAccounts(authorization?: string, filter?: string, filters?: string, order?: string, expand?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
399
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.listBankAccounts(authorization, filter, filters, order, expand, options);
|
|
400
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
401
|
+
},
|
|
402
|
+
/**
|
|
403
|
+
* Set the primary bank account for the specified partner/account
|
|
404
|
+
* @summary Set primary bank account
|
|
405
|
+
* @param {string} code Code of the bank account to set primary
|
|
406
|
+
* @param {SetPrimaryBankAccountRequestDtoRest} setPrimaryBankAccountRequestDtoRest
|
|
407
|
+
* @param {string} [authorization] Bearer Token
|
|
408
|
+
* @param {*} [options] Override http request option.
|
|
409
|
+
* @throws {RequiredError}
|
|
410
|
+
*/
|
|
411
|
+
async setPrimaryBankAccount(code: string, setPrimaryBankAccountRequestDtoRest: SetPrimaryBankAccountRequestDtoRest, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
412
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.setPrimaryBankAccount(code, setPrimaryBankAccountRequestDtoRest, authorization, options);
|
|
413
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
414
|
+
},
|
|
415
|
+
/**
|
|
416
|
+
* Update a bank account by code
|
|
417
|
+
* @summary Update the bank account
|
|
418
|
+
* @param {string} code Unique identifier for the object.
|
|
419
|
+
* @param {UpdateBankAccountRequestDtoRest} updateBankAccountRequestDtoRest
|
|
420
|
+
* @param {string} [authorization] Bearer Token
|
|
421
|
+
* @param {*} [options] Override http request option.
|
|
422
|
+
* @throws {RequiredError}
|
|
423
|
+
*/
|
|
424
|
+
async updateBankAccount(code: string, updateBankAccountRequestDtoRest: UpdateBankAccountRequestDtoRest, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
425
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.updateBankAccount(code, updateBankAccountRequestDtoRest, authorization, options);
|
|
190
426
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
191
427
|
},
|
|
192
428
|
}
|
|
@@ -200,32 +436,76 @@ export const BankAccountsApiFactory = function (configuration?: Configuration, b
|
|
|
200
436
|
const localVarFp = BankAccountsApiFp(configuration)
|
|
201
437
|
return {
|
|
202
438
|
/**
|
|
203
|
-
*
|
|
204
|
-
* @summary Create
|
|
205
|
-
* @param {
|
|
439
|
+
* This will create a bank account for a specified partner/account. If this is the first bank account for the specified partner/account, it will be marked as primary.
|
|
440
|
+
* @summary Create the bank account
|
|
441
|
+
* @param {CreateBankAccountRequestDto} createBankAccountRequestDto
|
|
206
442
|
* @param {string} [authorization] Bearer Token
|
|
207
443
|
* @param {*} [options] Override http request option.
|
|
208
444
|
* @throws {RequiredError}
|
|
209
445
|
*/
|
|
210
|
-
createBankAccount(
|
|
211
|
-
return localVarFp.createBankAccount(
|
|
446
|
+
createBankAccount(createBankAccountRequestDto: CreateBankAccountRequestDto, authorization?: string, options?: any): AxiosPromise<void> {
|
|
447
|
+
return localVarFp.createBankAccount(createBankAccountRequestDto, authorization, options).then((request) => request(axios, basePath));
|
|
212
448
|
},
|
|
213
449
|
/**
|
|
214
|
-
*
|
|
450
|
+
* Deletes a bank account by code. If the bank account was primary, then the first available bank account for the specified partner/account will be marked as primary.
|
|
451
|
+
* @summary Delete the bank account
|
|
452
|
+
* @param {string} code Unique identifier for the object.
|
|
453
|
+
* @param {string} [authorization] Bearer Token
|
|
454
|
+
* @param {*} [options] Override http request option.
|
|
455
|
+
* @throws {RequiredError}
|
|
456
|
+
*/
|
|
457
|
+
deleteBankAccount(code: string, authorization?: string, options?: any): AxiosPromise<void> {
|
|
458
|
+
return localVarFp.deleteBankAccount(code, authorization, options).then((request) => request(axios, basePath));
|
|
459
|
+
},
|
|
460
|
+
/**
|
|
461
|
+
* Retrieves the details of the bank account that was previously created. Supply the unique bank account code that was returned when you created it and Emil Api will return the corresponding bank account information.
|
|
462
|
+
* @summary Retrieve the bank account
|
|
463
|
+
* @param {string} code
|
|
464
|
+
* @param {string} [authorization] Bearer Token
|
|
465
|
+
* @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: primaryBankAccount<i>
|
|
466
|
+
* @param {*} [options] Override http request option.
|
|
467
|
+
* @throws {RequiredError}
|
|
468
|
+
*/
|
|
469
|
+
getBankAccount(code: string, authorization?: string, expand?: string, options?: any): AxiosPromise<void> {
|
|
470
|
+
return localVarFp.getBankAccount(code, authorization, expand, options).then((request) => request(axios, basePath));
|
|
471
|
+
},
|
|
472
|
+
/**
|
|
473
|
+
* Returns a list of bank accounts you have previously created. The bank accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
215
474
|
* @summary List bank accounts
|
|
216
475
|
* @param {string} [authorization] Bearer Token
|
|
217
|
-
* @param {
|
|
218
|
-
* @param {
|
|
219
|
-
* @param {
|
|
220
|
-
* @param {
|
|
221
|
-
* @param {
|
|
222
|
-
* @
|
|
223
|
-
|
|
476
|
+
* @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, accountCode, partnerCode</i>
|
|
477
|
+
* @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, accountCode, partnerCode</i>
|
|
478
|
+
* @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>
|
|
479
|
+
* @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: primaryBankAccount<i>
|
|
480
|
+
* @param {*} [options] Override http request option.
|
|
481
|
+
* @throws {RequiredError}
|
|
482
|
+
*/
|
|
483
|
+
listBankAccounts(authorization?: string, filter?: string, filters?: string, order?: string, expand?: string, options?: any): AxiosPromise<void> {
|
|
484
|
+
return localVarFp.listBankAccounts(authorization, filter, filters, order, expand, options).then((request) => request(axios, basePath));
|
|
485
|
+
},
|
|
486
|
+
/**
|
|
487
|
+
* Set the primary bank account for the specified partner/account
|
|
488
|
+
* @summary Set primary bank account
|
|
489
|
+
* @param {string} code Code of the bank account to set primary
|
|
490
|
+
* @param {SetPrimaryBankAccountRequestDtoRest} setPrimaryBankAccountRequestDtoRest
|
|
491
|
+
* @param {string} [authorization] Bearer Token
|
|
492
|
+
* @param {*} [options] Override http request option.
|
|
493
|
+
* @throws {RequiredError}
|
|
494
|
+
*/
|
|
495
|
+
setPrimaryBankAccount(code: string, setPrimaryBankAccountRequestDtoRest: SetPrimaryBankAccountRequestDtoRest, authorization?: string, options?: any): AxiosPromise<void> {
|
|
496
|
+
return localVarFp.setPrimaryBankAccount(code, setPrimaryBankAccountRequestDtoRest, authorization, options).then((request) => request(axios, basePath));
|
|
497
|
+
},
|
|
498
|
+
/**
|
|
499
|
+
* Update a bank account by code
|
|
500
|
+
* @summary Update the bank account
|
|
501
|
+
* @param {string} code Unique identifier for the object.
|
|
502
|
+
* @param {UpdateBankAccountRequestDtoRest} updateBankAccountRequestDtoRest
|
|
503
|
+
* @param {string} [authorization] Bearer Token
|
|
224
504
|
* @param {*} [options] Override http request option.
|
|
225
505
|
* @throws {RequiredError}
|
|
226
506
|
*/
|
|
227
|
-
|
|
228
|
-
return localVarFp.
|
|
507
|
+
updateBankAccount(code: string, updateBankAccountRequestDtoRest: UpdateBankAccountRequestDtoRest, authorization?: string, options?: any): AxiosPromise<void> {
|
|
508
|
+
return localVarFp.updateBankAccount(code, updateBankAccountRequestDtoRest, authorization, options).then((request) => request(axios, basePath));
|
|
229
509
|
},
|
|
230
510
|
};
|
|
231
511
|
};
|
|
@@ -238,10 +518,10 @@ export const BankAccountsApiFactory = function (configuration?: Configuration, b
|
|
|
238
518
|
export interface BankAccountsApiCreateBankAccountRequest {
|
|
239
519
|
/**
|
|
240
520
|
*
|
|
241
|
-
* @type {
|
|
521
|
+
* @type {CreateBankAccountRequestDto}
|
|
242
522
|
* @memberof BankAccountsApiCreateBankAccount
|
|
243
523
|
*/
|
|
244
|
-
readonly
|
|
524
|
+
readonly createBankAccountRequestDto: CreateBankAccountRequestDto
|
|
245
525
|
|
|
246
526
|
/**
|
|
247
527
|
* Bearer Token
|
|
@@ -251,6 +531,55 @@ export interface BankAccountsApiCreateBankAccountRequest {
|
|
|
251
531
|
readonly authorization?: string
|
|
252
532
|
}
|
|
253
533
|
|
|
534
|
+
/**
|
|
535
|
+
* Request parameters for deleteBankAccount operation in BankAccountsApi.
|
|
536
|
+
* @export
|
|
537
|
+
* @interface BankAccountsApiDeleteBankAccountRequest
|
|
538
|
+
*/
|
|
539
|
+
export interface BankAccountsApiDeleteBankAccountRequest {
|
|
540
|
+
/**
|
|
541
|
+
* Unique identifier for the object.
|
|
542
|
+
* @type {string}
|
|
543
|
+
* @memberof BankAccountsApiDeleteBankAccount
|
|
544
|
+
*/
|
|
545
|
+
readonly code: string
|
|
546
|
+
|
|
547
|
+
/**
|
|
548
|
+
* Bearer Token
|
|
549
|
+
* @type {string}
|
|
550
|
+
* @memberof BankAccountsApiDeleteBankAccount
|
|
551
|
+
*/
|
|
552
|
+
readonly authorization?: string
|
|
553
|
+
}
|
|
554
|
+
|
|
555
|
+
/**
|
|
556
|
+
* Request parameters for getBankAccount operation in BankAccountsApi.
|
|
557
|
+
* @export
|
|
558
|
+
* @interface BankAccountsApiGetBankAccountRequest
|
|
559
|
+
*/
|
|
560
|
+
export interface BankAccountsApiGetBankAccountRequest {
|
|
561
|
+
/**
|
|
562
|
+
*
|
|
563
|
+
* @type {string}
|
|
564
|
+
* @memberof BankAccountsApiGetBankAccount
|
|
565
|
+
*/
|
|
566
|
+
readonly code: string
|
|
567
|
+
|
|
568
|
+
/**
|
|
569
|
+
* Bearer Token
|
|
570
|
+
* @type {string}
|
|
571
|
+
* @memberof BankAccountsApiGetBankAccount
|
|
572
|
+
*/
|
|
573
|
+
readonly authorization?: string
|
|
574
|
+
|
|
575
|
+
/**
|
|
576
|
+
* 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: primaryBankAccount<i>
|
|
577
|
+
* @type {string}
|
|
578
|
+
* @memberof BankAccountsApiGetBankAccount
|
|
579
|
+
*/
|
|
580
|
+
readonly expand?: string
|
|
581
|
+
}
|
|
582
|
+
|
|
254
583
|
/**
|
|
255
584
|
* Request parameters for listBankAccounts operation in BankAccountsApi.
|
|
256
585
|
* @export
|
|
@@ -265,53 +594,88 @@ export interface BankAccountsApiListBankAccountsRequest {
|
|
|
265
594
|
readonly authorization?: string
|
|
266
595
|
|
|
267
596
|
/**
|
|
268
|
-
*
|
|
269
|
-
* @type {
|
|
597
|
+
* 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, accountCode, partnerCode</i>
|
|
598
|
+
* @type {string}
|
|
270
599
|
* @memberof BankAccountsApiListBankAccounts
|
|
271
600
|
*/
|
|
272
|
-
readonly
|
|
601
|
+
readonly filter?: string
|
|
273
602
|
|
|
274
603
|
/**
|
|
275
|
-
*
|
|
276
|
-
* @type {
|
|
604
|
+
* 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, accountCode, partnerCode</i>
|
|
605
|
+
* @type {string}
|
|
277
606
|
* @memberof BankAccountsApiListBankAccounts
|
|
278
607
|
*/
|
|
279
|
-
readonly
|
|
608
|
+
readonly filters?: string
|
|
280
609
|
|
|
281
610
|
/**
|
|
282
|
-
*
|
|
283
|
-
* @type {
|
|
611
|
+
* 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>
|
|
612
|
+
* @type {string}
|
|
284
613
|
* @memberof BankAccountsApiListBankAccounts
|
|
285
614
|
*/
|
|
286
|
-
readonly
|
|
615
|
+
readonly order?: string
|
|
287
616
|
|
|
288
617
|
/**
|
|
289
|
-
*
|
|
290
|
-
* @type {
|
|
618
|
+
* 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: primaryBankAccount<i>
|
|
619
|
+
* @type {string}
|
|
291
620
|
* @memberof BankAccountsApiListBankAccounts
|
|
292
621
|
*/
|
|
293
|
-
readonly
|
|
622
|
+
readonly expand?: string
|
|
623
|
+
}
|
|
624
|
+
|
|
625
|
+
/**
|
|
626
|
+
* Request parameters for setPrimaryBankAccount operation in BankAccountsApi.
|
|
627
|
+
* @export
|
|
628
|
+
* @interface BankAccountsApiSetPrimaryBankAccountRequest
|
|
629
|
+
*/
|
|
630
|
+
export interface BankAccountsApiSetPrimaryBankAccountRequest {
|
|
631
|
+
/**
|
|
632
|
+
* Code of the bank account to set primary
|
|
633
|
+
* @type {string}
|
|
634
|
+
* @memberof BankAccountsApiSetPrimaryBankAccount
|
|
635
|
+
*/
|
|
636
|
+
readonly code: string
|
|
294
637
|
|
|
295
638
|
/**
|
|
296
|
-
*
|
|
297
|
-
* @type {
|
|
298
|
-
* @memberof
|
|
639
|
+
*
|
|
640
|
+
* @type {SetPrimaryBankAccountRequestDtoRest}
|
|
641
|
+
* @memberof BankAccountsApiSetPrimaryBankAccount
|
|
299
642
|
*/
|
|
300
|
-
readonly
|
|
643
|
+
readonly setPrimaryBankAccountRequestDtoRest: SetPrimaryBankAccountRequestDtoRest
|
|
301
644
|
|
|
302
645
|
/**
|
|
303
|
-
*
|
|
304
|
-
* @type {
|
|
305
|
-
* @memberof
|
|
646
|
+
* Bearer Token
|
|
647
|
+
* @type {string}
|
|
648
|
+
* @memberof BankAccountsApiSetPrimaryBankAccount
|
|
306
649
|
*/
|
|
307
|
-
readonly
|
|
650
|
+
readonly authorization?: string
|
|
651
|
+
}
|
|
308
652
|
|
|
653
|
+
/**
|
|
654
|
+
* Request parameters for updateBankAccount operation in BankAccountsApi.
|
|
655
|
+
* @export
|
|
656
|
+
* @interface BankAccountsApiUpdateBankAccountRequest
|
|
657
|
+
*/
|
|
658
|
+
export interface BankAccountsApiUpdateBankAccountRequest {
|
|
309
659
|
/**
|
|
310
|
-
*
|
|
311
|
-
* @type {
|
|
312
|
-
* @memberof
|
|
660
|
+
* Unique identifier for the object.
|
|
661
|
+
* @type {string}
|
|
662
|
+
* @memberof BankAccountsApiUpdateBankAccount
|
|
313
663
|
*/
|
|
314
|
-
readonly
|
|
664
|
+
readonly code: string
|
|
665
|
+
|
|
666
|
+
/**
|
|
667
|
+
*
|
|
668
|
+
* @type {UpdateBankAccountRequestDtoRest}
|
|
669
|
+
* @memberof BankAccountsApiUpdateBankAccount
|
|
670
|
+
*/
|
|
671
|
+
readonly updateBankAccountRequestDtoRest: UpdateBankAccountRequestDtoRest
|
|
672
|
+
|
|
673
|
+
/**
|
|
674
|
+
* Bearer Token
|
|
675
|
+
* @type {string}
|
|
676
|
+
* @memberof BankAccountsApiUpdateBankAccount
|
|
677
|
+
*/
|
|
678
|
+
readonly authorization?: string
|
|
315
679
|
}
|
|
316
680
|
|
|
317
681
|
/**
|
|
@@ -322,19 +686,43 @@ export interface BankAccountsApiListBankAccountsRequest {
|
|
|
322
686
|
*/
|
|
323
687
|
export class BankAccountsApi extends BaseAPI {
|
|
324
688
|
/**
|
|
325
|
-
*
|
|
326
|
-
* @summary Create
|
|
689
|
+
* This will create a bank account for a specified partner/account. If this is the first bank account for the specified partner/account, it will be marked as primary.
|
|
690
|
+
* @summary Create the bank account
|
|
327
691
|
* @param {BankAccountsApiCreateBankAccountRequest} requestParameters Request parameters.
|
|
328
692
|
* @param {*} [options] Override http request option.
|
|
329
693
|
* @throws {RequiredError}
|
|
330
694
|
* @memberof BankAccountsApi
|
|
331
695
|
*/
|
|
332
696
|
public createBankAccount(requestParameters: BankAccountsApiCreateBankAccountRequest, options?: AxiosRequestConfig) {
|
|
333
|
-
return BankAccountsApiFp(this.configuration).createBankAccount(requestParameters.
|
|
697
|
+
return BankAccountsApiFp(this.configuration).createBankAccount(requestParameters.createBankAccountRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
698
|
+
}
|
|
699
|
+
|
|
700
|
+
/**
|
|
701
|
+
* Deletes a bank account by code. If the bank account was primary, then the first available bank account for the specified partner/account will be marked as primary.
|
|
702
|
+
* @summary Delete the bank account
|
|
703
|
+
* @param {BankAccountsApiDeleteBankAccountRequest} requestParameters Request parameters.
|
|
704
|
+
* @param {*} [options] Override http request option.
|
|
705
|
+
* @throws {RequiredError}
|
|
706
|
+
* @memberof BankAccountsApi
|
|
707
|
+
*/
|
|
708
|
+
public deleteBankAccount(requestParameters: BankAccountsApiDeleteBankAccountRequest, options?: AxiosRequestConfig) {
|
|
709
|
+
return BankAccountsApiFp(this.configuration).deleteBankAccount(requestParameters.code, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
710
|
+
}
|
|
711
|
+
|
|
712
|
+
/**
|
|
713
|
+
* Retrieves the details of the bank account that was previously created. Supply the unique bank account code that was returned when you created it and Emil Api will return the corresponding bank account information.
|
|
714
|
+
* @summary Retrieve the bank account
|
|
715
|
+
* @param {BankAccountsApiGetBankAccountRequest} requestParameters Request parameters.
|
|
716
|
+
* @param {*} [options] Override http request option.
|
|
717
|
+
* @throws {RequiredError}
|
|
718
|
+
* @memberof BankAccountsApi
|
|
719
|
+
*/
|
|
720
|
+
public getBankAccount(requestParameters: BankAccountsApiGetBankAccountRequest, options?: AxiosRequestConfig) {
|
|
721
|
+
return BankAccountsApiFp(this.configuration).getBankAccount(requestParameters.code, requestParameters.authorization, requestParameters.expand, options).then((request) => request(this.axios, this.basePath));
|
|
334
722
|
}
|
|
335
723
|
|
|
336
724
|
/**
|
|
337
|
-
* Returns a list of bank accounts you
|
|
725
|
+
* Returns a list of bank accounts you have previously created. The bank accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
338
726
|
* @summary List bank accounts
|
|
339
727
|
* @param {BankAccountsApiListBankAccountsRequest} requestParameters Request parameters.
|
|
340
728
|
* @param {*} [options] Override http request option.
|
|
@@ -342,6 +730,30 @@ export class BankAccountsApi extends BaseAPI {
|
|
|
342
730
|
* @memberof BankAccountsApi
|
|
343
731
|
*/
|
|
344
732
|
public listBankAccounts(requestParameters: BankAccountsApiListBankAccountsRequest = {}, options?: AxiosRequestConfig) {
|
|
345
|
-
return BankAccountsApiFp(this.configuration).listBankAccounts(requestParameters.authorization, requestParameters.
|
|
733
|
+
return BankAccountsApiFp(this.configuration).listBankAccounts(requestParameters.authorization, requestParameters.filter, requestParameters.filters, requestParameters.order, requestParameters.expand, options).then((request) => request(this.axios, this.basePath));
|
|
734
|
+
}
|
|
735
|
+
|
|
736
|
+
/**
|
|
737
|
+
* Set the primary bank account for the specified partner/account
|
|
738
|
+
* @summary Set primary bank account
|
|
739
|
+
* @param {BankAccountsApiSetPrimaryBankAccountRequest} requestParameters Request parameters.
|
|
740
|
+
* @param {*} [options] Override http request option.
|
|
741
|
+
* @throws {RequiredError}
|
|
742
|
+
* @memberof BankAccountsApi
|
|
743
|
+
*/
|
|
744
|
+
public setPrimaryBankAccount(requestParameters: BankAccountsApiSetPrimaryBankAccountRequest, options?: AxiosRequestConfig) {
|
|
745
|
+
return BankAccountsApiFp(this.configuration).setPrimaryBankAccount(requestParameters.code, requestParameters.setPrimaryBankAccountRequestDtoRest, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
746
|
+
}
|
|
747
|
+
|
|
748
|
+
/**
|
|
749
|
+
* Update a bank account by code
|
|
750
|
+
* @summary Update the bank account
|
|
751
|
+
* @param {BankAccountsApiUpdateBankAccountRequest} requestParameters Request parameters.
|
|
752
|
+
* @param {*} [options] Override http request option.
|
|
753
|
+
* @throws {RequiredError}
|
|
754
|
+
* @memberof BankAccountsApi
|
|
755
|
+
*/
|
|
756
|
+
public updateBankAccount(requestParameters: BankAccountsApiUpdateBankAccountRequest, options?: AxiosRequestConfig) {
|
|
757
|
+
return BankAccountsApiFp(this.configuration).updateBankAccount(requestParameters.code, requestParameters.updateBankAccountRequestDtoRest, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
346
758
|
}
|
|
347
759
|
}
|