@emilgroup/payment-sdk 1.4.1-beta.3 → 1.4.1-beta.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (224) hide show
  1. package/.openapi-generator/FILES +12 -39
  2. package/README.md +2 -2
  3. package/api/bank-accounts-api.ts +497 -47
  4. package/api/bank-transaction-api.ts +128 -96
  5. package/api/{default-api.ts → health-check-api.ts} +22 -18
  6. package/api/payment-methods-api.ts +74 -203
  7. package/api/payment-reminders-api.ts +76 -66
  8. package/api/payment-setup-api.ts +29 -37
  9. package/api/payments-api.ts +66 -89
  10. package/api/refunds-api.ts +74 -84
  11. package/api/tenant-bank-account-api.ts +88 -62
  12. package/api/webhooks-api.ts +17 -13
  13. package/api.ts +3 -3
  14. package/base.ts +6 -2
  15. package/common.ts +2 -2
  16. package/configuration.ts +1 -1
  17. package/dist/api/bank-accounts-api.d.ts +297 -49
  18. package/dist/api/bank-accounts-api.js +416 -28
  19. package/dist/api/bank-transaction-api.d.ts +109 -91
  20. package/dist/api/bank-transaction-api.js +83 -68
  21. package/dist/api/health-check-api.d.ts +70 -0
  22. package/dist/api/{default-api.js → health-check-api.js} +31 -27
  23. package/dist/api/payment-methods-api.d.ts +66 -134
  24. package/dist/api/payment-methods-api.js +55 -157
  25. package/dist/api/payment-reminders-api.d.ts +72 -65
  26. package/dist/api/payment-reminders-api.js +48 -42
  27. package/dist/api/payment-setup-api.d.ts +19 -23
  28. package/dist/api/payment-setup-api.js +25 -25
  29. package/dist/api/payments-api.d.ts +64 -76
  30. package/dist/api/payments-api.js +47 -55
  31. package/dist/api/refunds-api.d.ts +74 -74
  32. package/dist/api/refunds-api.js +52 -48
  33. package/dist/api/tenant-bank-account-api.d.ts +89 -66
  34. package/dist/api/tenant-bank-account-api.js +59 -39
  35. package/dist/api/webhooks-api.d.ts +17 -13
  36. package/dist/api/webhooks-api.js +15 -11
  37. package/dist/api.d.ts +2 -2
  38. package/dist/api.js +2 -2
  39. package/dist/base.d.ts +2 -1
  40. package/dist/base.js +5 -2
  41. package/dist/common.d.ts +2 -2
  42. package/dist/common.js +1 -1
  43. package/dist/configuration.d.ts +1 -1
  44. package/dist/configuration.js +1 -1
  45. package/dist/index.d.ts +1 -1
  46. package/dist/index.js +1 -1
  47. package/dist/models/{bank-transaction-response-class.d.ts → bank-transaction-class-without-expand-properties.d.ts} +26 -34
  48. package/dist/models/{bank-account-class.js → bank-transaction-class-without-expand-properties.js} +1 -1
  49. package/dist/models/create-bank-account-request-dto.d.ts +15 -3
  50. package/dist/models/create-bank-account-request-dto.js +1 -1
  51. package/dist/models/create-payment-reminder-request-dto.d.ts +1 -1
  52. package/dist/models/create-payment-reminder-request-dto.js +1 -1
  53. package/dist/models/create-payment-request-dto.d.ts +4 -4
  54. package/dist/models/create-payment-request-dto.js +1 -1
  55. package/dist/models/create-refund-request-dto.d.ts +1 -1
  56. package/dist/models/create-refund-request-dto.js +1 -1
  57. package/dist/models/create-tenant-bank-account-request-dto.d.ts +1 -1
  58. package/dist/models/create-tenant-bank-account-request-dto.js +1 -1
  59. package/dist/models/create-tenant-bank-account-response-class.d.ts +25 -0
  60. package/dist/models/{bank-transaction-response-class.js → create-tenant-bank-account-response-class.js} +1 -1
  61. package/dist/models/deactivate-payment-reminder-request-dto.d.ts +1 -1
  62. package/dist/models/deactivate-payment-reminder-request-dto.js +1 -1
  63. package/dist/models/get-tenant-bank-account-response-class.d.ts +5 -5
  64. package/dist/models/get-tenant-bank-account-response-class.js +1 -1
  65. package/dist/models/index.d.ts +11 -38
  66. package/dist/models/index.js +11 -38
  67. package/dist/models/inline-response200.d.ts +1 -1
  68. package/dist/models/inline-response200.js +1 -1
  69. package/dist/models/inline-response503.d.ts +1 -1
  70. package/dist/models/inline-response503.js +1 -1
  71. package/dist/models/link-bank-transaction-request-dto-rest.d.ts +24 -0
  72. package/dist/models/{billing-profile-limited-response-dto.js → link-bank-transaction-request-dto-rest.js} +1 -1
  73. package/dist/models/list-tenant-bank-account-response-class.d.ts +31 -0
  74. package/dist/models/{billing-profile-dto.js → list-tenant-bank-account-response-class.js} +1 -1
  75. package/dist/models/set-primary-bank-account-request-dto-rest.d.ts +24 -0
  76. package/dist/models/set-primary-bank-account-request-dto-rest.js +15 -0
  77. package/dist/models/{tenant-bank-account-response-class.d.ts → tenant-bank-account-class-without-expand-properties.d.ts} +11 -11
  78. package/dist/models/tenant-bank-account-class-without-expand-properties.js +15 -0
  79. package/dist/models/tenant-bank-account-class.d.ts +73 -0
  80. package/dist/models/tenant-bank-account-class.js +15 -0
  81. package/dist/models/unlink-bank-transaction-request-dto-rest.d.ts +24 -0
  82. package/dist/models/unlink-bank-transaction-request-dto-rest.js +15 -0
  83. package/dist/models/update-bank-account-request-dto-rest.d.ts +30 -0
  84. package/dist/models/update-bank-account-request-dto-rest.js +15 -0
  85. package/dist/models/update-bank-account-request-dto.d.ts +36 -0
  86. package/dist/models/update-bank-account-request-dto.js +15 -0
  87. package/dist/models/update-tenant-bank-account-response-class.d.ts +25 -0
  88. package/dist/models/update-tenant-bank-account-response-class.js +15 -0
  89. package/dist/models/update-tenant-bank-account-rest-request-dto.d.ts +1 -1
  90. package/dist/models/update-tenant-bank-account-rest-request-dto.js +1 -1
  91. package/dist/models/validate-pspconfig-request-dto.d.ts +2 -9
  92. package/dist/models/validate-pspconfig-request-dto.js +1 -8
  93. package/index.ts +1 -1
  94. package/models/{bank-transaction-response-class.ts → bank-transaction-class-without-expand-properties.ts} +26 -34
  95. package/models/create-bank-account-request-dto.ts +15 -3
  96. package/models/create-payment-reminder-request-dto.ts +1 -1
  97. package/models/create-payment-request-dto.ts +4 -4
  98. package/models/create-refund-request-dto.ts +1 -1
  99. package/models/create-tenant-bank-account-request-dto.ts +1 -1
  100. package/models/create-tenant-bank-account-response-class.ts +31 -0
  101. package/models/deactivate-payment-reminder-request-dto.ts +1 -1
  102. package/models/get-tenant-bank-account-response-class.ts +5 -5
  103. package/models/index.ts +11 -38
  104. package/models/inline-response200.ts +1 -1
  105. package/models/inline-response503.ts +1 -1
  106. package/models/link-bank-transaction-request-dto-rest.ts +30 -0
  107. package/models/list-tenant-bank-account-response-class.ts +37 -0
  108. package/models/set-primary-bank-account-request-dto-rest.ts +30 -0
  109. package/models/{tenant-bank-account-response-class.ts → tenant-bank-account-class-without-expand-properties.ts} +11 -11
  110. package/models/tenant-bank-account-class.ts +79 -0
  111. package/models/unlink-bank-transaction-request-dto-rest.ts +30 -0
  112. package/models/update-bank-account-request-dto-rest.ts +36 -0
  113. package/models/update-bank-account-request-dto.ts +42 -0
  114. package/models/update-tenant-bank-account-response-class.ts +31 -0
  115. package/models/update-tenant-bank-account-rest-request-dto.ts +1 -1
  116. package/models/validate-pspconfig-request-dto.ts +2 -12
  117. package/package.json +1 -1
  118. package/dist/api/default-api.d.ts +0 -66
  119. package/dist/models/bank-account-class.d.ts +0 -54
  120. package/dist/models/billing-profile-dto.d.ts +0 -38
  121. package/dist/models/billing-profile-limited-response-dto.d.ts +0 -54
  122. package/dist/models/complete-braintree-payment-setup-request-dto.d.ts +0 -48
  123. package/dist/models/complete-braintree-payment-setup-request-dto.js +0 -15
  124. package/dist/models/complete-payment-setup-request-dto.d.ts +0 -32
  125. package/dist/models/complete-payment-setup-request-dto.js +0 -15
  126. package/dist/models/complete-payment-setup-response-class.d.ts +0 -25
  127. package/dist/models/complete-payment-setup-response-class.js +0 -15
  128. package/dist/models/complete-stripe-payment-setup-request-dto.d.ts +0 -60
  129. package/dist/models/complete-stripe-payment-setup-request-dto.js +0 -15
  130. package/dist/models/create-payment-method-response-class.d.ts +0 -25
  131. package/dist/models/create-payment-method-response-class.js +0 -15
  132. package/dist/models/create-payment-response-class.d.ts +0 -25
  133. package/dist/models/create-payment-response-class.js +0 -15
  134. package/dist/models/create-psp-payment-method-request-dto.d.ts +0 -61
  135. package/dist/models/create-psp-payment-method-request-dto.js +0 -32
  136. package/dist/models/create-refund-response-class.d.ts +0 -25
  137. package/dist/models/create-refund-response-class.js +0 -15
  138. package/dist/models/deactivate-payment-reminder-response-class.d.ts +0 -25
  139. package/dist/models/deactivate-payment-reminder-response-class.js +0 -15
  140. package/dist/models/get-bank-transactions-response-class.d.ts +0 -25
  141. package/dist/models/get-bank-transactions-response-class.js +0 -15
  142. package/dist/models/get-payment-method-response-class.d.ts +0 -25
  143. package/dist/models/get-payment-method-response-class.js +0 -15
  144. package/dist/models/get-payment-response-class.d.ts +0 -25
  145. package/dist/models/get-payment-response-class.js +0 -15
  146. package/dist/models/get-refund-response-class.d.ts +0 -25
  147. package/dist/models/get-refund-response-class.js +0 -15
  148. package/dist/models/get-request-dto.d.ts +0 -30
  149. package/dist/models/get-request-dto.js +0 -15
  150. package/dist/models/initiate-braintree-payment-setup-request-dto.d.ts +0 -30
  151. package/dist/models/initiate-braintree-payment-setup-request-dto.js +0 -15
  152. package/dist/models/initiate-braintree-payment-setup-response-class.d.ts +0 -24
  153. package/dist/models/initiate-braintree-payment-setup-response-class.js +0 -15
  154. package/dist/models/initiate-payment-setup-request-dto.d.ts +0 -44
  155. package/dist/models/initiate-payment-setup-request-dto.js +0 -15
  156. package/dist/models/initiate-payment-setup-response-class.d.ts +0 -32
  157. package/dist/models/initiate-payment-setup-response-class.js +0 -15
  158. package/dist/models/initiate-stripe-payment-setup-request-dto.d.ts +0 -30
  159. package/dist/models/initiate-stripe-payment-setup-request-dto.js +0 -15
  160. package/dist/models/initiate-stripe-payment-setup-response-class.d.ts +0 -30
  161. package/dist/models/initiate-stripe-payment-setup-response-class.js +0 -15
  162. package/dist/models/list-bank-accounts-response-class.d.ts +0 -31
  163. package/dist/models/list-bank-accounts-response-class.js +0 -15
  164. package/dist/models/list-bank-transactions-response-class.d.ts +0 -31
  165. package/dist/models/list-bank-transactions-response-class.js +0 -15
  166. package/dist/models/list-payment-methods-response-class.d.ts +0 -31
  167. package/dist/models/list-payment-methods-response-class.js +0 -15
  168. package/dist/models/list-payment-reminders-response-class.d.ts +0 -31
  169. package/dist/models/list-payment-reminders-response-class.js +0 -15
  170. package/dist/models/list-payments-response-class.d.ts +0 -31
  171. package/dist/models/list-payments-response-class.js +0 -15
  172. package/dist/models/list-refunds-response-class.d.ts +0 -31
  173. package/dist/models/list-refunds-response-class.js +0 -15
  174. package/dist/models/payment-class.d.ts +0 -103
  175. package/dist/models/payment-class.js +0 -15
  176. package/dist/models/payment-method-class.d.ts +0 -66
  177. package/dist/models/payment-method-class.js +0 -15
  178. package/dist/models/payment-reminder-class.d.ts +0 -112
  179. package/dist/models/payment-reminder-class.js +0 -36
  180. package/dist/models/refund-class.d.ts +0 -104
  181. package/dist/models/refund-class.js +0 -28
  182. package/dist/models/sepa-direct-dto.d.ts +0 -24
  183. package/dist/models/sepa-direct-dto.js +0 -15
  184. package/dist/models/symphony-profile-limited-response-dto.d.ts +0 -42
  185. package/dist/models/symphony-profile-limited-response-dto.js +0 -15
  186. package/dist/models/tenant-bank-account-response-class.js +0 -15
  187. package/dist/models/transaction-class.d.ts +0 -54
  188. package/dist/models/transaction-class.js +0 -15
  189. package/models/bank-account-class.ts +0 -60
  190. package/models/billing-profile-dto.ts +0 -44
  191. package/models/billing-profile-limited-response-dto.ts +0 -60
  192. package/models/complete-braintree-payment-setup-request-dto.ts +0 -54
  193. package/models/complete-payment-setup-request-dto.ts +0 -38
  194. package/models/complete-payment-setup-response-class.ts +0 -31
  195. package/models/complete-stripe-payment-setup-request-dto.ts +0 -66
  196. package/models/create-payment-method-response-class.ts +0 -31
  197. package/models/create-payment-response-class.ts +0 -31
  198. package/models/create-psp-payment-method-request-dto.ts +0 -70
  199. package/models/create-refund-response-class.ts +0 -31
  200. package/models/deactivate-payment-reminder-response-class.ts +0 -31
  201. package/models/get-bank-transactions-response-class.ts +0 -31
  202. package/models/get-payment-method-response-class.ts +0 -31
  203. package/models/get-payment-response-class.ts +0 -31
  204. package/models/get-refund-response-class.ts +0 -31
  205. package/models/get-request-dto.ts +0 -36
  206. package/models/initiate-braintree-payment-setup-request-dto.ts +0 -36
  207. package/models/initiate-braintree-payment-setup-response-class.ts +0 -30
  208. package/models/initiate-payment-setup-request-dto.ts +0 -50
  209. package/models/initiate-payment-setup-response-class.ts +0 -38
  210. package/models/initiate-stripe-payment-setup-request-dto.ts +0 -36
  211. package/models/initiate-stripe-payment-setup-response-class.ts +0 -36
  212. package/models/list-bank-accounts-response-class.ts +0 -37
  213. package/models/list-bank-transactions-response-class.ts +0 -37
  214. package/models/list-payment-methods-response-class.ts +0 -37
  215. package/models/list-payment-reminders-response-class.ts +0 -37
  216. package/models/list-payments-response-class.ts +0 -37
  217. package/models/list-refunds-response-class.ts +0 -37
  218. package/models/payment-class.ts +0 -109
  219. package/models/payment-method-class.ts +0 -72
  220. package/models/payment-reminder-class.ts +0 -122
  221. package/models/refund-class.ts +0 -114
  222. package/models/sepa-direct-dto.ts +0 -30
  223. package/models/symphony-profile-limited-response-dto.ts +0 -48
  224. 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) 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.
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
@@ -23,7 +23,9 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } fr
23
23
  // @ts-ignore
24
24
  import { CreateBankAccountRequestDto } from '../models';
25
25
  // @ts-ignore
26
- import { ListBankAccountsResponseClass } from '../models';
26
+ import { SetPrimaryBankAccountRequestDtoRest } from '../models';
27
+ // @ts-ignore
28
+ import { UpdateBankAccountRequestDtoRest } from '../models';
27
29
  /**
28
30
  * BankAccountsApi - axios parameter creator
29
31
  * @export
@@ -31,8 +33,8 @@ import { ListBankAccountsResponseClass } from '../models';
31
33
  export const BankAccountsApiAxiosParamCreator = function (configuration?: Configuration) {
32
34
  return {
33
35
  /**
34
- * Creates a bank account for a specified account.
35
- * @summary Create a bank account
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
36
38
  * @param {CreateBankAccountRequestDto} createBankAccountRequestDto
37
39
  * @param {string} [authorization] Bearer Token
38
40
  * @param {*} [options] Override http request option.
@@ -78,20 +80,115 @@ export const BankAccountsApiAxiosParamCreator = function (configuration?: Config
78
80
  };
79
81
  },
80
82
  /**
81
- * Returns a list of bank accounts you’ve previously created. The bank accounts are returned in sorted order, with the oldest payment appearing first. For more information about pagination, read the Pagination documentation.
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.
86
+ * @param {string} [authorization] Bearer Token
87
+ * @param {*} [options] Override http request option.
88
+ * @throws {RequiredError}
89
+ */
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 Unique identifier for the object.
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.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: primaryBankAccount.&lt;i&gt;
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)));
141
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
142
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
143
+ let baseOptions;
144
+ let baseAccessToken;
145
+ if (configuration) {
146
+ baseOptions = configuration.baseOptions;
147
+ baseAccessToken = configuration.accessToken;
148
+ }
149
+
150
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
151
+ const localVarHeaderParameter = {} as any;
152
+ const localVarQueryParameter = {} as any;
153
+
154
+ // authentication bearer required
155
+ // http bearer authentication required
156
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
157
+
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);
164
+ }
165
+
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.
82
179
  * @summary List bank accounts
83
180
  * @param {string} [authorization] Bearer Token
84
181
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
85
182
  * @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&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
86
- * @param {any} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
87
- * @param {any} [search] Search the list by any field. For instance, if you want to search by code add code&#x3D;xxx in order to fetch the result.
88
- * @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.
89
- * @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.
90
- * @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.
183
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, id, accountCode, partnerCode&lt;/i&gt;
184
+ * @param {any} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
185
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, createdAt&lt;/i&gt;
186
+ * @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.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: primaryBankAccount.&lt;i&gt;
187
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, id, accountCode, partnerCode&lt;/i&gt;
91
188
  * @param {*} [options] Override http request option.
92
189
  * @throws {RequiredError}
93
190
  */
94
- listBankAccounts: async (authorization?: string, pageSize?: any, pageToken?: any, filter?: any, search?: any, order?: any, expand?: any, filters?: any, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
191
+ listBankAccounts: async (authorization?: string, pageSize?: any, pageToken?: any, filter?: string, search?: any, order?: string, expand?: string, filters?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
95
192
  const localVarPath = `/paymentservice/v1/bank-accounts`;
96
193
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
97
194
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
@@ -148,6 +245,108 @@ export const BankAccountsApiAxiosParamCreator = function (configuration?: Config
148
245
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
149
246
  localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
150
247
 
248
+ return {
249
+ url: toPathString(localVarUrlObj),
250
+ options: localVarRequestOptions,
251
+ };
252
+ },
253
+ /**
254
+ * Set the primary bank account for the specified partner/account
255
+ * @summary Set primary bank account
256
+ * @param {string} code Code of the bank account to set primary
257
+ * @param {SetPrimaryBankAccountRequestDtoRest} setPrimaryBankAccountRequestDtoRest
258
+ * @param {string} [authorization] Bearer Token
259
+ * @param {*} [options] Override http request option.
260
+ * @throws {RequiredError}
261
+ */
262
+ setPrimaryBankAccount: async (code: string, setPrimaryBankAccountRequestDtoRest: SetPrimaryBankAccountRequestDtoRest, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
263
+ // verify required parameter 'code' is not null or undefined
264
+ assertParamExists('setPrimaryBankAccount', 'code', code)
265
+ // verify required parameter 'setPrimaryBankAccountRequestDtoRest' is not null or undefined
266
+ assertParamExists('setPrimaryBankAccount', 'setPrimaryBankAccountRequestDtoRest', setPrimaryBankAccountRequestDtoRest)
267
+ const localVarPath = `/paymentservice/v1/bank-accounts/{code}/primary`
268
+ .replace(`{${"code"}}`, encodeURIComponent(String(code)));
269
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
270
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
271
+ let baseOptions;
272
+ let baseAccessToken;
273
+ if (configuration) {
274
+ baseOptions = configuration.baseOptions;
275
+ baseAccessToken = configuration.accessToken;
276
+ }
277
+
278
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
279
+ const localVarHeaderParameter = {} as any;
280
+ const localVarQueryParameter = {} as any;
281
+
282
+ // authentication bearer required
283
+ // http bearer authentication required
284
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
285
+
286
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
287
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
288
+ }
289
+
290
+
291
+
292
+ localVarHeaderParameter['Content-Type'] = 'application/json';
293
+
294
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
295
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
296
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
297
+ localVarRequestOptions.data = serializeDataIfNeeded(setPrimaryBankAccountRequestDtoRest, localVarRequestOptions, configuration)
298
+
299
+ return {
300
+ url: toPathString(localVarUrlObj),
301
+ options: localVarRequestOptions,
302
+ };
303
+ },
304
+ /**
305
+ * Update a bank account by code
306
+ * @summary Update the bank account
307
+ * @param {string} code Unique identifier for the object.
308
+ * @param {UpdateBankAccountRequestDtoRest} updateBankAccountRequestDtoRest
309
+ * @param {string} [authorization] Bearer Token
310
+ * @param {*} [options] Override http request option.
311
+ * @throws {RequiredError}
312
+ */
313
+ updateBankAccount: async (code: string, updateBankAccountRequestDtoRest: UpdateBankAccountRequestDtoRest, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
314
+ // verify required parameter 'code' is not null or undefined
315
+ assertParamExists('updateBankAccount', 'code', code)
316
+ // verify required parameter 'updateBankAccountRequestDtoRest' is not null or undefined
317
+ assertParamExists('updateBankAccount', 'updateBankAccountRequestDtoRest', updateBankAccountRequestDtoRest)
318
+ const localVarPath = `/paymentservice/v1/bank-accounts/{code}`
319
+ .replace(`{${"code"}}`, encodeURIComponent(String(code)));
320
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
321
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
322
+ let baseOptions;
323
+ let baseAccessToken;
324
+ if (configuration) {
325
+ baseOptions = configuration.baseOptions;
326
+ baseAccessToken = configuration.accessToken;
327
+ }
328
+
329
+ const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
330
+ const localVarHeaderParameter = {} as any;
331
+ const localVarQueryParameter = {} as any;
332
+
333
+ // authentication bearer required
334
+ // http bearer authentication required
335
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
336
+
337
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
338
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
339
+ }
340
+
341
+
342
+
343
+ localVarHeaderParameter['Content-Type'] = 'application/json';
344
+
345
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
346
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
347
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
348
+ localVarRequestOptions.data = serializeDataIfNeeded(updateBankAccountRequestDtoRest, localVarRequestOptions, configuration)
349
+
151
350
  return {
152
351
  url: toPathString(localVarUrlObj),
153
352
  options: localVarRequestOptions,
@@ -164,35 +363,86 @@ export const BankAccountsApiFp = function(configuration?: Configuration) {
164
363
  const localVarAxiosParamCreator = BankAccountsApiAxiosParamCreator(configuration)
165
364
  return {
166
365
  /**
167
- * Creates a bank account for a specified account.
168
- * @summary Create a bank account
366
+ * 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.
367
+ * @summary Create the bank account
169
368
  * @param {CreateBankAccountRequestDto} createBankAccountRequestDto
170
369
  * @param {string} [authorization] Bearer Token
171
370
  * @param {*} [options] Override http request option.
172
371
  * @throws {RequiredError}
173
372
  */
174
- async createBankAccount(createBankAccountRequestDto: CreateBankAccountRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<object>> {
373
+ async createBankAccount(createBankAccountRequestDto: CreateBankAccountRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
175
374
  const localVarAxiosArgs = await localVarAxiosParamCreator.createBankAccount(createBankAccountRequestDto, authorization, options);
176
375
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
177
376
  },
178
377
  /**
179
- * Returns a list of bank accounts you’ve previously created. The bank accounts are returned in sorted order, with the oldest payment appearing first. For more information about pagination, read the Pagination documentation.
378
+ * 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.
379
+ * @summary Delete the bank account
380
+ * @param {string} code Unique identifier for the object.
381
+ * @param {string} [authorization] Bearer Token
382
+ * @param {*} [options] Override http request option.
383
+ * @throws {RequiredError}
384
+ */
385
+ async deleteBankAccount(code: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
386
+ const localVarAxiosArgs = await localVarAxiosParamCreator.deleteBankAccount(code, authorization, options);
387
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
388
+ },
389
+ /**
390
+ * 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.
391
+ * @summary Retrieve the bank account
392
+ * @param {string} code Unique identifier for the object.
393
+ * @param {string} [authorization] Bearer Token
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.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: primaryBankAccount.&lt;i&gt;
395
+ * @param {*} [options] Override http request option.
396
+ * @throws {RequiredError}
397
+ */
398
+ async getBankAccount(code: string, authorization?: string, expand?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
399
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getBankAccount(code, authorization, expand, options);
400
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
401
+ },
402
+ /**
403
+ * 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.
180
404
  * @summary List bank accounts
181
405
  * @param {string} [authorization] Bearer Token
182
406
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
183
407
  * @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&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
184
- * @param {any} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
185
- * @param {any} [search] Search the list by any field. For instance, if you want to search by code add code&#x3D;xxx in order to fetch the result.
186
- * @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.
187
- * @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.
188
- * @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.
408
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, id, accountCode, partnerCode&lt;/i&gt;
409
+ * @param {any} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
410
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, createdAt&lt;/i&gt;
411
+ * @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.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: primaryBankAccount.&lt;i&gt;
412
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, id, accountCode, partnerCode&lt;/i&gt;
189
413
  * @param {*} [options] Override http request option.
190
414
  * @throws {RequiredError}
191
415
  */
192
- async listBankAccounts(authorization?: string, pageSize?: any, pageToken?: any, filter?: any, search?: any, order?: any, expand?: any, filters?: any, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListBankAccountsResponseClass>> {
416
+ async listBankAccounts(authorization?: string, pageSize?: any, pageToken?: any, filter?: string, search?: any, order?: string, expand?: string, filters?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
193
417
  const localVarAxiosArgs = await localVarAxiosParamCreator.listBankAccounts(authorization, pageSize, pageToken, filter, search, order, expand, filters, options);
194
418
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
195
419
  },
420
+ /**
421
+ * Set the primary bank account for the specified partner/account
422
+ * @summary Set primary bank account
423
+ * @param {string} code Code of the bank account to set primary
424
+ * @param {SetPrimaryBankAccountRequestDtoRest} setPrimaryBankAccountRequestDtoRest
425
+ * @param {string} [authorization] Bearer Token
426
+ * @param {*} [options] Override http request option.
427
+ * @throws {RequiredError}
428
+ */
429
+ async setPrimaryBankAccount(code: string, setPrimaryBankAccountRequestDtoRest: SetPrimaryBankAccountRequestDtoRest, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
430
+ const localVarAxiosArgs = await localVarAxiosParamCreator.setPrimaryBankAccount(code, setPrimaryBankAccountRequestDtoRest, authorization, options);
431
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
432
+ },
433
+ /**
434
+ * Update a bank account by code
435
+ * @summary Update the bank account
436
+ * @param {string} code Unique identifier for the object.
437
+ * @param {UpdateBankAccountRequestDtoRest} updateBankAccountRequestDtoRest
438
+ * @param {string} [authorization] Bearer Token
439
+ * @param {*} [options] Override http request option.
440
+ * @throws {RequiredError}
441
+ */
442
+ async updateBankAccount(code: string, updateBankAccountRequestDtoRest: UpdateBankAccountRequestDtoRest, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
443
+ const localVarAxiosArgs = await localVarAxiosParamCreator.updateBankAccount(code, updateBankAccountRequestDtoRest, authorization, options);
444
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
445
+ },
196
446
  }
197
447
  };
198
448
 
@@ -204,33 +454,80 @@ export const BankAccountsApiFactory = function (configuration?: Configuration, b
204
454
  const localVarFp = BankAccountsApiFp(configuration)
205
455
  return {
206
456
  /**
207
- * Creates a bank account for a specified account.
208
- * @summary Create a bank account
457
+ * 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.
458
+ * @summary Create the bank account
209
459
  * @param {CreateBankAccountRequestDto} createBankAccountRequestDto
210
460
  * @param {string} [authorization] Bearer Token
211
461
  * @param {*} [options] Override http request option.
212
462
  * @throws {RequiredError}
213
463
  */
214
- createBankAccount(createBankAccountRequestDto: CreateBankAccountRequestDto, authorization?: string, options?: any): AxiosPromise<object> {
464
+ createBankAccount(createBankAccountRequestDto: CreateBankAccountRequestDto, authorization?: string, options?: any): AxiosPromise<void> {
215
465
  return localVarFp.createBankAccount(createBankAccountRequestDto, authorization, options).then((request) => request(axios, basePath));
216
466
  },
217
467
  /**
218
- * Returns a list of bank accounts you’ve previously created. The bank accounts are returned in sorted order, with the oldest payment appearing first. For more information about pagination, read the Pagination documentation.
468
+ * 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.
469
+ * @summary Delete the bank account
470
+ * @param {string} code Unique identifier for the object.
471
+ * @param {string} [authorization] Bearer Token
472
+ * @param {*} [options] Override http request option.
473
+ * @throws {RequiredError}
474
+ */
475
+ deleteBankAccount(code: string, authorization?: string, options?: any): AxiosPromise<void> {
476
+ return localVarFp.deleteBankAccount(code, authorization, options).then((request) => request(axios, basePath));
477
+ },
478
+ /**
479
+ * 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.
480
+ * @summary Retrieve the bank account
481
+ * @param {string} code Unique identifier for the object.
482
+ * @param {string} [authorization] Bearer Token
483
+ * @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.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: primaryBankAccount.&lt;i&gt;
484
+ * @param {*} [options] Override http request option.
485
+ * @throws {RequiredError}
486
+ */
487
+ getBankAccount(code: string, authorization?: string, expand?: string, options?: any): AxiosPromise<void> {
488
+ return localVarFp.getBankAccount(code, authorization, expand, options).then((request) => request(axios, basePath));
489
+ },
490
+ /**
491
+ * 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.
219
492
  * @summary List bank accounts
220
493
  * @param {string} [authorization] Bearer Token
221
494
  * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
222
495
  * @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&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
223
- * @param {any} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
224
- * @param {any} [search] Search the list by any field. For instance, if you want to search by code add code&#x3D;xxx in order to fetch the result.
225
- * @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.
226
- * @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.
227
- * @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.
496
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, id, accountCode, partnerCode&lt;/i&gt;
497
+ * @param {any} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
498
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, createdAt&lt;/i&gt;
499
+ * @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.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: primaryBankAccount.&lt;i&gt;
500
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, id, accountCode, partnerCode&lt;/i&gt;
228
501
  * @param {*} [options] Override http request option.
229
502
  * @throws {RequiredError}
230
503
  */
231
- listBankAccounts(authorization?: string, pageSize?: any, pageToken?: any, filter?: any, search?: any, order?: any, expand?: any, filters?: any, options?: any): AxiosPromise<ListBankAccountsResponseClass> {
504
+ listBankAccounts(authorization?: string, pageSize?: any, pageToken?: any, filter?: string, search?: any, order?: string, expand?: string, filters?: string, options?: any): AxiosPromise<void> {
232
505
  return localVarFp.listBankAccounts(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then((request) => request(axios, basePath));
233
506
  },
507
+ /**
508
+ * Set the primary bank account for the specified partner/account
509
+ * @summary Set primary bank account
510
+ * @param {string} code Code of the bank account to set primary
511
+ * @param {SetPrimaryBankAccountRequestDtoRest} setPrimaryBankAccountRequestDtoRest
512
+ * @param {string} [authorization] Bearer Token
513
+ * @param {*} [options] Override http request option.
514
+ * @throws {RequiredError}
515
+ */
516
+ setPrimaryBankAccount(code: string, setPrimaryBankAccountRequestDtoRest: SetPrimaryBankAccountRequestDtoRest, authorization?: string, options?: any): AxiosPromise<void> {
517
+ return localVarFp.setPrimaryBankAccount(code, setPrimaryBankAccountRequestDtoRest, authorization, options).then((request) => request(axios, basePath));
518
+ },
519
+ /**
520
+ * Update a bank account by code
521
+ * @summary Update the bank account
522
+ * @param {string} code Unique identifier for the object.
523
+ * @param {UpdateBankAccountRequestDtoRest} updateBankAccountRequestDtoRest
524
+ * @param {string} [authorization] Bearer Token
525
+ * @param {*} [options] Override http request option.
526
+ * @throws {RequiredError}
527
+ */
528
+ updateBankAccount(code: string, updateBankAccountRequestDtoRest: UpdateBankAccountRequestDtoRest, authorization?: string, options?: any): AxiosPromise<void> {
529
+ return localVarFp.updateBankAccount(code, updateBankAccountRequestDtoRest, authorization, options).then((request) => request(axios, basePath));
530
+ },
234
531
  };
235
532
  };
236
533
 
@@ -255,6 +552,55 @@ export interface BankAccountsApiCreateBankAccountRequest {
255
552
  readonly authorization?: string
256
553
  }
257
554
 
555
+ /**
556
+ * Request parameters for deleteBankAccount operation in BankAccountsApi.
557
+ * @export
558
+ * @interface BankAccountsApiDeleteBankAccountRequest
559
+ */
560
+ export interface BankAccountsApiDeleteBankAccountRequest {
561
+ /**
562
+ * Unique identifier for the object.
563
+ * @type {string}
564
+ * @memberof BankAccountsApiDeleteBankAccount
565
+ */
566
+ readonly code: string
567
+
568
+ /**
569
+ * Bearer Token
570
+ * @type {string}
571
+ * @memberof BankAccountsApiDeleteBankAccount
572
+ */
573
+ readonly authorization?: string
574
+ }
575
+
576
+ /**
577
+ * Request parameters for getBankAccount operation in BankAccountsApi.
578
+ * @export
579
+ * @interface BankAccountsApiGetBankAccountRequest
580
+ */
581
+ export interface BankAccountsApiGetBankAccountRequest {
582
+ /**
583
+ * Unique identifier for the object.
584
+ * @type {string}
585
+ * @memberof BankAccountsApiGetBankAccount
586
+ */
587
+ readonly code: string
588
+
589
+ /**
590
+ * Bearer Token
591
+ * @type {string}
592
+ * @memberof BankAccountsApiGetBankAccount
593
+ */
594
+ readonly authorization?: string
595
+
596
+ /**
597
+ * 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.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: primaryBankAccount.&lt;i&gt;
598
+ * @type {string}
599
+ * @memberof BankAccountsApiGetBankAccount
600
+ */
601
+ readonly expand?: string
602
+ }
603
+
258
604
  /**
259
605
  * Request parameters for listBankAccounts operation in BankAccountsApi.
260
606
  * @export
@@ -283,39 +629,95 @@ export interface BankAccountsApiListBankAccountsRequest {
283
629
  readonly pageToken?: any
284
630
 
285
631
  /**
286
- * Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
287
- * @type {any}
632
+ * Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, id, accountCode, partnerCode&lt;/i&gt;
633
+ * @type {string}
288
634
  * @memberof BankAccountsApiListBankAccounts
289
635
  */
290
- readonly filter?: any
636
+ readonly filter?: string
291
637
 
292
638
  /**
293
- * Search the list by any field. For instance, if you want to search by code add code&#x3D;xxx in order to fetch the result.
639
+ * To search the list by any field, pass search&#x3D;xxx to fetch the result.
294
640
  * @type {any}
295
641
  * @memberof BankAccountsApiListBankAccounts
296
642
  */
297
643
  readonly search?: any
298
644
 
299
645
  /**
300
- * 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.
301
- * @type {any}
646
+ * Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, createdAt&lt;/i&gt;
647
+ * @type {string}
302
648
  * @memberof BankAccountsApiListBankAccounts
303
649
  */
304
- readonly order?: any
650
+ readonly order?: string
305
651
 
306
652
  /**
307
- * 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.
308
- * @type {any}
653
+ * 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.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: primaryBankAccount.&lt;i&gt;
654
+ * @type {string}
309
655
  * @memberof BankAccountsApiListBankAccounts
310
656
  */
311
- readonly expand?: any
657
+ readonly expand?: string
312
658
 
313
659
  /**
314
- * 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.
315
- * @type {any}
660
+ * Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: code, id, accountCode, partnerCode&lt;/i&gt;
661
+ * @type {string}
316
662
  * @memberof BankAccountsApiListBankAccounts
317
663
  */
318
- readonly filters?: any
664
+ readonly filters?: string
665
+ }
666
+
667
+ /**
668
+ * Request parameters for setPrimaryBankAccount operation in BankAccountsApi.
669
+ * @export
670
+ * @interface BankAccountsApiSetPrimaryBankAccountRequest
671
+ */
672
+ export interface BankAccountsApiSetPrimaryBankAccountRequest {
673
+ /**
674
+ * Code of the bank account to set primary
675
+ * @type {string}
676
+ * @memberof BankAccountsApiSetPrimaryBankAccount
677
+ */
678
+ readonly code: string
679
+
680
+ /**
681
+ *
682
+ * @type {SetPrimaryBankAccountRequestDtoRest}
683
+ * @memberof BankAccountsApiSetPrimaryBankAccount
684
+ */
685
+ readonly setPrimaryBankAccountRequestDtoRest: SetPrimaryBankAccountRequestDtoRest
686
+
687
+ /**
688
+ * Bearer Token
689
+ * @type {string}
690
+ * @memberof BankAccountsApiSetPrimaryBankAccount
691
+ */
692
+ readonly authorization?: string
693
+ }
694
+
695
+ /**
696
+ * Request parameters for updateBankAccount operation in BankAccountsApi.
697
+ * @export
698
+ * @interface BankAccountsApiUpdateBankAccountRequest
699
+ */
700
+ export interface BankAccountsApiUpdateBankAccountRequest {
701
+ /**
702
+ * Unique identifier for the object.
703
+ * @type {string}
704
+ * @memberof BankAccountsApiUpdateBankAccount
705
+ */
706
+ readonly code: string
707
+
708
+ /**
709
+ *
710
+ * @type {UpdateBankAccountRequestDtoRest}
711
+ * @memberof BankAccountsApiUpdateBankAccount
712
+ */
713
+ readonly updateBankAccountRequestDtoRest: UpdateBankAccountRequestDtoRest
714
+
715
+ /**
716
+ * Bearer Token
717
+ * @type {string}
718
+ * @memberof BankAccountsApiUpdateBankAccount
719
+ */
720
+ readonly authorization?: string
319
721
  }
320
722
 
321
723
  /**
@@ -326,8 +728,8 @@ export interface BankAccountsApiListBankAccountsRequest {
326
728
  */
327
729
  export class BankAccountsApi extends BaseAPI {
328
730
  /**
329
- * Creates a bank account for a specified account.
330
- * @summary Create a bank account
731
+ * 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.
732
+ * @summary Create the bank account
331
733
  * @param {BankAccountsApiCreateBankAccountRequest} requestParameters Request parameters.
332
734
  * @param {*} [options] Override http request option.
333
735
  * @throws {RequiredError}
@@ -338,7 +740,31 @@ export class BankAccountsApi extends BaseAPI {
338
740
  }
339
741
 
340
742
  /**
341
- * Returns a list of bank accounts you’ve previously created. The bank accounts are returned in sorted order, with the oldest payment appearing first. For more information about pagination, read the Pagination documentation.
743
+ * 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.
744
+ * @summary Delete the bank account
745
+ * @param {BankAccountsApiDeleteBankAccountRequest} requestParameters Request parameters.
746
+ * @param {*} [options] Override http request option.
747
+ * @throws {RequiredError}
748
+ * @memberof BankAccountsApi
749
+ */
750
+ public deleteBankAccount(requestParameters: BankAccountsApiDeleteBankAccountRequest, options?: AxiosRequestConfig) {
751
+ return BankAccountsApiFp(this.configuration).deleteBankAccount(requestParameters.code, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
752
+ }
753
+
754
+ /**
755
+ * 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.
756
+ * @summary Retrieve the bank account
757
+ * @param {BankAccountsApiGetBankAccountRequest} requestParameters Request parameters.
758
+ * @param {*} [options] Override http request option.
759
+ * @throws {RequiredError}
760
+ * @memberof BankAccountsApi
761
+ */
762
+ public getBankAccount(requestParameters: BankAccountsApiGetBankAccountRequest, options?: AxiosRequestConfig) {
763
+ return BankAccountsApiFp(this.configuration).getBankAccount(requestParameters.code, requestParameters.authorization, requestParameters.expand, options).then((request) => request(this.axios, this.basePath));
764
+ }
765
+
766
+ /**
767
+ * 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.
342
768
  * @summary List bank accounts
343
769
  * @param {BankAccountsApiListBankAccountsRequest} requestParameters Request parameters.
344
770
  * @param {*} [options] Override http request option.
@@ -348,4 +774,28 @@ export class BankAccountsApi extends BaseAPI {
348
774
  public listBankAccounts(requestParameters: BankAccountsApiListBankAccountsRequest = {}, options?: AxiosRequestConfig) {
349
775
  return BankAccountsApiFp(this.configuration).listBankAccounts(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then((request) => request(this.axios, this.basePath));
350
776
  }
777
+
778
+ /**
779
+ * Set the primary bank account for the specified partner/account
780
+ * @summary Set primary bank account
781
+ * @param {BankAccountsApiSetPrimaryBankAccountRequest} requestParameters Request parameters.
782
+ * @param {*} [options] Override http request option.
783
+ * @throws {RequiredError}
784
+ * @memberof BankAccountsApi
785
+ */
786
+ public setPrimaryBankAccount(requestParameters: BankAccountsApiSetPrimaryBankAccountRequest, options?: AxiosRequestConfig) {
787
+ return BankAccountsApiFp(this.configuration).setPrimaryBankAccount(requestParameters.code, requestParameters.setPrimaryBankAccountRequestDtoRest, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
788
+ }
789
+
790
+ /**
791
+ * Update a bank account by code
792
+ * @summary Update the bank account
793
+ * @param {BankAccountsApiUpdateBankAccountRequest} requestParameters Request parameters.
794
+ * @param {*} [options] Override http request option.
795
+ * @throws {RequiredError}
796
+ * @memberof BankAccountsApi
797
+ */
798
+ public updateBankAccount(requestParameters: BankAccountsApiUpdateBankAccountRequest, options?: AxiosRequestConfig) {
799
+ return BankAccountsApiFp(this.configuration).updateBankAccount(requestParameters.code, requestParameters.updateBankAccountRequestDtoRest, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
800
+ }
351
801
  }