@emilgroup/payment-sdk 1.14.1-beta.54 → 1.14.1-beta.56

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.
@@ -6,6 +6,7 @@ api.ts
6
6
  api/bank-accounts-api.ts
7
7
  api/bank-orders-api.ts
8
8
  api/bank-transaction-api.ts
9
+ api/billing-addresses-api.ts
9
10
  api/credit-allocation-api.ts
10
11
  api/exceeding-credits-api.ts
11
12
  api/health-check-api.ts
@@ -31,6 +32,7 @@ models/bank-transaction-class-without-expand-properties.ts
31
32
  models/bank-transaction-class.ts
32
33
  models/bank-transaction-invoice-class.ts
33
34
  models/bank-transfer-dto.ts
35
+ models/billing-address-class.ts
34
36
  models/billing-address-dto.ts
35
37
  models/billing-profile-dto.ts
36
38
  models/billing-profile-limited-response-dto.ts
@@ -45,6 +47,8 @@ models/create-bank-account-request-dto.ts
45
47
  models/create-bank-account-response-class.ts
46
48
  models/create-bank-order-request-dto.ts
47
49
  models/create-bank-order-response-class.ts
50
+ models/create-billing-address-request-dto.ts
51
+ models/create-billing-address-response-class.ts
48
52
  models/create-credit-allocation-request-dto.ts
49
53
  models/create-credit-allocation-response-class.ts
50
54
  models/create-payment-method-response-class.ts
@@ -72,6 +76,7 @@ models/generate-invoice-match-suggestions-response-class.ts
72
76
  models/get-bank-account-response-class.ts
73
77
  models/get-bank-order-response-class.ts
74
78
  models/get-bank-transactions-response-class.ts
79
+ models/get-billing-address-response-class.ts
75
80
  models/get-credit-allocation-response-class.ts
76
81
  models/get-exceeding-credit-response-class.ts
77
82
  models/get-payment-method-response-class.ts
@@ -99,6 +104,7 @@ models/link-bank-transactions-response-class.ts
99
104
  models/list-bank-accounts-response-class.ts
100
105
  models/list-bank-orders-response-class.ts
101
106
  models/list-bank-transactions-response-class.ts
107
+ models/list-billing-addresses-response-class.ts
102
108
  models/list-credit-allocations-response-class.ts
103
109
  models/list-exceeding-credits-response-class.ts
104
110
  models/list-payment-methods-response-class.ts
package/README.md CHANGED
@@ -17,11 +17,11 @@ Although this package can be used in both TypeScript and JavaScript, it is inten
17
17
  Navigate to the folder of your consuming project and run one of the following commands:
18
18
 
19
19
  ```
20
- npm install @emilgroup/payment-sdk@1.14.1-beta.54 --save
20
+ npm install @emilgroup/payment-sdk@1.14.1-beta.56 --save
21
21
  ```
22
22
  or
23
23
  ```
24
- yarn add @emilgroup/payment-sdk@1.14.1-beta.54
24
+ yarn add @emilgroup/payment-sdk@1.14.1-beta.56
25
25
  ```
26
26
 
27
27
  And then you can import `PaymentsApi`.
@@ -0,0 +1,571 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
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.
6
+ *
7
+ * The version of the OpenAPI document: 1.0
8
+ * Contact: kontakt@emil.de
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+
16
+ import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
17
+ import { Configuration } from '../configuration';
18
+ // Some imports not used depending on template conditions
19
+ // @ts-ignore
20
+ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../common';
21
+ // @ts-ignore
22
+ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from '../base';
23
+ // @ts-ignore
24
+ import { CreateBillingAddressRequestDto } from '../models';
25
+ // @ts-ignore
26
+ import { CreateBillingAddressResponseClass } from '../models';
27
+ // @ts-ignore
28
+ import { GetBillingAddressResponseClass } from '../models';
29
+ // @ts-ignore
30
+ import { ListBillingAddressesResponseClass } from '../models';
31
+ /**
32
+ * BillingAddressesApi - axios parameter creator
33
+ * @export
34
+ */
35
+ export const BillingAddressesApiAxiosParamCreator = function (configuration?: Configuration) {
36
+ return {
37
+ /**
38
+ * This will create a new billing address for a specified account or partner **Required Permissions** \"payment-management.payments.create\"
39
+ * @summary Create the Billing Address
40
+ * @param {CreateBillingAddressRequestDto} createBillingAddressRequestDto
41
+ * @param {string} [authorization] Bearer Token
42
+ * @param {*} [options] Override http request option.
43
+ * @throws {RequiredError}
44
+ */
45
+ createBillingAddress: async (createBillingAddressRequestDto: CreateBillingAddressRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
46
+ // verify required parameter 'createBillingAddressRequestDto' is not null or undefined
47
+ assertParamExists('createBillingAddress', 'createBillingAddressRequestDto', createBillingAddressRequestDto)
48
+ const localVarPath = `/paymentservice/v1/billing-addresses`;
49
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
50
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
51
+ let baseOptions;
52
+ let baseAccessToken;
53
+ if (configuration) {
54
+ baseOptions = configuration.baseOptions;
55
+ baseAccessToken = configuration.accessToken;
56
+ }
57
+
58
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
59
+ const localVarHeaderParameter = {} as any;
60
+ const localVarQueryParameter = {} as any;
61
+
62
+ // authentication bearer required
63
+ // http bearer authentication required
64
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
65
+
66
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
67
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
68
+ }
69
+
70
+
71
+
72
+ localVarHeaderParameter['Content-Type'] = 'application/json';
73
+
74
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
75
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
76
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
77
+ localVarRequestOptions.data = serializeDataIfNeeded(createBillingAddressRequestDto, localVarRequestOptions, configuration)
78
+
79
+ return {
80
+ url: toPathString(localVarUrlObj),
81
+ options: localVarRequestOptions,
82
+ };
83
+ },
84
+ /**
85
+ * Deletes a billing address by code **Required Permissions** \"payment-management.payments.delete\"
86
+ * @summary Delete the Billing Address
87
+ * @param {string} code Unique identifier for the object.
88
+ * @param {string} [authorization] Bearer Token
89
+ * @param {*} [options] Override http request option.
90
+ * @throws {RequiredError}
91
+ */
92
+ deleteBillingAddress: async (code: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
93
+ // verify required parameter 'code' is not null or undefined
94
+ assertParamExists('deleteBillingAddress', 'code', code)
95
+ const localVarPath = `/paymentservice/v1/billing-addresses/{code}`
96
+ .replace(`{${"code"}}`, encodeURIComponent(String(code)));
97
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
98
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
99
+ let baseOptions;
100
+ let baseAccessToken;
101
+ if (configuration) {
102
+ baseOptions = configuration.baseOptions;
103
+ baseAccessToken = configuration.accessToken;
104
+ }
105
+
106
+ const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options};
107
+ const localVarHeaderParameter = {} as any;
108
+ const localVarQueryParameter = {} as any;
109
+
110
+ // authentication bearer required
111
+ // http bearer authentication required
112
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
113
+
114
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
115
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
116
+ }
117
+
118
+
119
+
120
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
121
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
122
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
123
+
124
+ return {
125
+ url: toPathString(localVarUrlObj),
126
+ options: localVarRequestOptions,
127
+ };
128
+ },
129
+ /**
130
+ * Retrieves the details of the Billing Address that was previously created. Supply the unique Billing Address code that was returned when you created it and Emil Api will return the corresponding Billing Address information. **Required Permissions** \"payment-management.payments.view\"
131
+ * @summary Retrieve the Billing Address
132
+ * @param {string} code
133
+ * @param {string} [authorization] Bearer Token
134
+ * @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: &lt;i&gt;
135
+ * @param {*} [options] Override http request option.
136
+ * @throws {RequiredError}
137
+ */
138
+ getBillingAddress: async (code: string, authorization?: string, expand?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
139
+ // verify required parameter 'code' is not null or undefined
140
+ assertParamExists('getBillingAddress', 'code', code)
141
+ const localVarPath = `/paymentservice/v1/billing-addresses/{code}`
142
+ .replace(`{${"code"}}`, encodeURIComponent(String(code)));
143
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
144
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
145
+ let baseOptions;
146
+ let baseAccessToken;
147
+ if (configuration) {
148
+ baseOptions = configuration.baseOptions;
149
+ baseAccessToken = configuration.accessToken;
150
+ }
151
+
152
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
153
+ const localVarHeaderParameter = {} as any;
154
+ const localVarQueryParameter = {} as any;
155
+
156
+ // authentication bearer required
157
+ // http bearer authentication required
158
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
159
+
160
+ if (expand !== undefined) {
161
+ localVarQueryParameter['expand'] = expand;
162
+ }
163
+
164
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
165
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
166
+ }
167
+
168
+
169
+
170
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
171
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
172
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
173
+
174
+ return {
175
+ url: toPathString(localVarUrlObj),
176
+ options: localVarRequestOptions,
177
+ };
178
+ },
179
+ /**
180
+ * Returns a list of Billing Addresses you have previously created. The Billing Addresses are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"payment-management.payments.view\"
181
+ * @summary List Billing Addresses
182
+ * @param {string} [authorization] Bearer Token
183
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
184
+ * @param {string} [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.
185
+ * @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: id, code, city, zipCode, countryCode, accountCode, partnerCode, createdAt, updatedAt&lt;/i&gt;
186
+ * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Searchable fields: firstName, lastName, accountCode, partnerCode&lt;/i&gt;
187
+ * @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, code, createdAt, updatedAt&lt;/i&gt;
188
+ * @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: &lt;i&gt;
189
+ * @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: id, code, city, zipCode, countryCode, accountCode, partnerCode, createdAt, updatedAt&lt;/i&gt;
190
+ * @param {*} [options] Override http request option.
191
+ * @throws {RequiredError}
192
+ */
193
+ listBillingAddresses: async (authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
194
+ const localVarPath = `/paymentservice/v1/billing-addresses`;
195
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
196
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
197
+ let baseOptions;
198
+ let baseAccessToken;
199
+ if (configuration) {
200
+ baseOptions = configuration.baseOptions;
201
+ baseAccessToken = configuration.accessToken;
202
+ }
203
+
204
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
205
+ const localVarHeaderParameter = {} as any;
206
+ const localVarQueryParameter = {} as any;
207
+
208
+ // authentication bearer required
209
+ // http bearer authentication required
210
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
211
+
212
+ if (pageSize !== undefined) {
213
+ localVarQueryParameter['pageSize'] = pageSize;
214
+ }
215
+
216
+ if (pageToken !== undefined) {
217
+ localVarQueryParameter['pageToken'] = pageToken;
218
+ }
219
+
220
+ if (filter !== undefined) {
221
+ localVarQueryParameter['filter'] = filter;
222
+ }
223
+
224
+ if (search !== undefined) {
225
+ localVarQueryParameter['search'] = search;
226
+ }
227
+
228
+ if (order !== undefined) {
229
+ localVarQueryParameter['order'] = order;
230
+ }
231
+
232
+ if (expand !== undefined) {
233
+ localVarQueryParameter['expand'] = expand;
234
+ }
235
+
236
+ if (filters !== undefined) {
237
+ localVarQueryParameter['filters'] = filters;
238
+ }
239
+
240
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
241
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
242
+ }
243
+
244
+
245
+
246
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
247
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
248
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
249
+
250
+ return {
251
+ url: toPathString(localVarUrlObj),
252
+ options: localVarRequestOptions,
253
+ };
254
+ },
255
+ }
256
+ };
257
+
258
+ /**
259
+ * BillingAddressesApi - functional programming interface
260
+ * @export
261
+ */
262
+ export const BillingAddressesApiFp = function(configuration?: Configuration) {
263
+ const localVarAxiosParamCreator = BillingAddressesApiAxiosParamCreator(configuration)
264
+ return {
265
+ /**
266
+ * This will create a new billing address for a specified account or partner **Required Permissions** \"payment-management.payments.create\"
267
+ * @summary Create the Billing Address
268
+ * @param {CreateBillingAddressRequestDto} createBillingAddressRequestDto
269
+ * @param {string} [authorization] Bearer Token
270
+ * @param {*} [options] Override http request option.
271
+ * @throws {RequiredError}
272
+ */
273
+ async createBillingAddress(createBillingAddressRequestDto: CreateBillingAddressRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateBillingAddressResponseClass>> {
274
+ const localVarAxiosArgs = await localVarAxiosParamCreator.createBillingAddress(createBillingAddressRequestDto, authorization, options);
275
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
276
+ },
277
+ /**
278
+ * Deletes a billing address by code **Required Permissions** \"payment-management.payments.delete\"
279
+ * @summary Delete the Billing Address
280
+ * @param {string} code Unique identifier for the object.
281
+ * @param {string} [authorization] Bearer Token
282
+ * @param {*} [options] Override http request option.
283
+ * @throws {RequiredError}
284
+ */
285
+ async deleteBillingAddress(code: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<object>> {
286
+ const localVarAxiosArgs = await localVarAxiosParamCreator.deleteBillingAddress(code, authorization, options);
287
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
288
+ },
289
+ /**
290
+ * Retrieves the details of the Billing Address that was previously created. Supply the unique Billing Address code that was returned when you created it and Emil Api will return the corresponding Billing Address information. **Required Permissions** \"payment-management.payments.view\"
291
+ * @summary Retrieve the Billing Address
292
+ * @param {string} code
293
+ * @param {string} [authorization] Bearer Token
294
+ * @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: &lt;i&gt;
295
+ * @param {*} [options] Override http request option.
296
+ * @throws {RequiredError}
297
+ */
298
+ async getBillingAddress(code: string, authorization?: string, expand?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetBillingAddressResponseClass>> {
299
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getBillingAddress(code, authorization, expand, options);
300
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
301
+ },
302
+ /**
303
+ * Returns a list of Billing Addresses you have previously created. The Billing Addresses are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"payment-management.payments.view\"
304
+ * @summary List Billing Addresses
305
+ * @param {string} [authorization] Bearer Token
306
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
307
+ * @param {string} [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.
308
+ * @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: id, code, city, zipCode, countryCode, accountCode, partnerCode, createdAt, updatedAt&lt;/i&gt;
309
+ * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Searchable fields: firstName, lastName, accountCode, partnerCode&lt;/i&gt;
310
+ * @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, code, createdAt, updatedAt&lt;/i&gt;
311
+ * @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: &lt;i&gt;
312
+ * @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: id, code, city, zipCode, countryCode, accountCode, partnerCode, createdAt, updatedAt&lt;/i&gt;
313
+ * @param {*} [options] Override http request option.
314
+ * @throws {RequiredError}
315
+ */
316
+ async listBillingAddresses(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListBillingAddressesResponseClass>> {
317
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listBillingAddresses(authorization, pageSize, pageToken, filter, search, order, expand, filters, options);
318
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
319
+ },
320
+ }
321
+ };
322
+
323
+ /**
324
+ * BillingAddressesApi - factory interface
325
+ * @export
326
+ */
327
+ export const BillingAddressesApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
328
+ const localVarFp = BillingAddressesApiFp(configuration)
329
+ return {
330
+ /**
331
+ * This will create a new billing address for a specified account or partner **Required Permissions** \"payment-management.payments.create\"
332
+ * @summary Create the Billing Address
333
+ * @param {CreateBillingAddressRequestDto} createBillingAddressRequestDto
334
+ * @param {string} [authorization] Bearer Token
335
+ * @param {*} [options] Override http request option.
336
+ * @throws {RequiredError}
337
+ */
338
+ createBillingAddress(createBillingAddressRequestDto: CreateBillingAddressRequestDto, authorization?: string, options?: any): AxiosPromise<CreateBillingAddressResponseClass> {
339
+ return localVarFp.createBillingAddress(createBillingAddressRequestDto, authorization, options).then((request) => request(axios, basePath));
340
+ },
341
+ /**
342
+ * Deletes a billing address by code **Required Permissions** \"payment-management.payments.delete\"
343
+ * @summary Delete the Billing Address
344
+ * @param {string} code Unique identifier for the object.
345
+ * @param {string} [authorization] Bearer Token
346
+ * @param {*} [options] Override http request option.
347
+ * @throws {RequiredError}
348
+ */
349
+ deleteBillingAddress(code: string, authorization?: string, options?: any): AxiosPromise<object> {
350
+ return localVarFp.deleteBillingAddress(code, authorization, options).then((request) => request(axios, basePath));
351
+ },
352
+ /**
353
+ * Retrieves the details of the Billing Address that was previously created. Supply the unique Billing Address code that was returned when you created it and Emil Api will return the corresponding Billing Address information. **Required Permissions** \"payment-management.payments.view\"
354
+ * @summary Retrieve the Billing Address
355
+ * @param {string} code
356
+ * @param {string} [authorization] Bearer Token
357
+ * @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: &lt;i&gt;
358
+ * @param {*} [options] Override http request option.
359
+ * @throws {RequiredError}
360
+ */
361
+ getBillingAddress(code: string, authorization?: string, expand?: string, options?: any): AxiosPromise<GetBillingAddressResponseClass> {
362
+ return localVarFp.getBillingAddress(code, authorization, expand, options).then((request) => request(axios, basePath));
363
+ },
364
+ /**
365
+ * Returns a list of Billing Addresses you have previously created. The Billing Addresses are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"payment-management.payments.view\"
366
+ * @summary List Billing Addresses
367
+ * @param {string} [authorization] Bearer Token
368
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
369
+ * @param {string} [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.
370
+ * @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: id, code, city, zipCode, countryCode, accountCode, partnerCode, createdAt, updatedAt&lt;/i&gt;
371
+ * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Searchable fields: firstName, lastName, accountCode, partnerCode&lt;/i&gt;
372
+ * @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, code, createdAt, updatedAt&lt;/i&gt;
373
+ * @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: &lt;i&gt;
374
+ * @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: id, code, city, zipCode, countryCode, accountCode, partnerCode, createdAt, updatedAt&lt;/i&gt;
375
+ * @param {*} [options] Override http request option.
376
+ * @throws {RequiredError}
377
+ */
378
+ listBillingAddresses(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: any): AxiosPromise<ListBillingAddressesResponseClass> {
379
+ return localVarFp.listBillingAddresses(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then((request) => request(axios, basePath));
380
+ },
381
+ };
382
+ };
383
+
384
+ /**
385
+ * Request parameters for createBillingAddress operation in BillingAddressesApi.
386
+ * @export
387
+ * @interface BillingAddressesApiCreateBillingAddressRequest
388
+ */
389
+ export interface BillingAddressesApiCreateBillingAddressRequest {
390
+ /**
391
+ *
392
+ * @type {CreateBillingAddressRequestDto}
393
+ * @memberof BillingAddressesApiCreateBillingAddress
394
+ */
395
+ readonly createBillingAddressRequestDto: CreateBillingAddressRequestDto
396
+
397
+ /**
398
+ * Bearer Token
399
+ * @type {string}
400
+ * @memberof BillingAddressesApiCreateBillingAddress
401
+ */
402
+ readonly authorization?: string
403
+ }
404
+
405
+ /**
406
+ * Request parameters for deleteBillingAddress operation in BillingAddressesApi.
407
+ * @export
408
+ * @interface BillingAddressesApiDeleteBillingAddressRequest
409
+ */
410
+ export interface BillingAddressesApiDeleteBillingAddressRequest {
411
+ /**
412
+ * Unique identifier for the object.
413
+ * @type {string}
414
+ * @memberof BillingAddressesApiDeleteBillingAddress
415
+ */
416
+ readonly code: string
417
+
418
+ /**
419
+ * Bearer Token
420
+ * @type {string}
421
+ * @memberof BillingAddressesApiDeleteBillingAddress
422
+ */
423
+ readonly authorization?: string
424
+ }
425
+
426
+ /**
427
+ * Request parameters for getBillingAddress operation in BillingAddressesApi.
428
+ * @export
429
+ * @interface BillingAddressesApiGetBillingAddressRequest
430
+ */
431
+ export interface BillingAddressesApiGetBillingAddressRequest {
432
+ /**
433
+ *
434
+ * @type {string}
435
+ * @memberof BillingAddressesApiGetBillingAddress
436
+ */
437
+ readonly code: string
438
+
439
+ /**
440
+ * Bearer Token
441
+ * @type {string}
442
+ * @memberof BillingAddressesApiGetBillingAddress
443
+ */
444
+ readonly authorization?: string
445
+
446
+ /**
447
+ * 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: &lt;i&gt;
448
+ * @type {string}
449
+ * @memberof BillingAddressesApiGetBillingAddress
450
+ */
451
+ readonly expand?: string
452
+ }
453
+
454
+ /**
455
+ * Request parameters for listBillingAddresses operation in BillingAddressesApi.
456
+ * @export
457
+ * @interface BillingAddressesApiListBillingAddressesRequest
458
+ */
459
+ export interface BillingAddressesApiListBillingAddressesRequest {
460
+ /**
461
+ * Bearer Token
462
+ * @type {string}
463
+ * @memberof BillingAddressesApiListBillingAddresses
464
+ */
465
+ readonly authorization?: string
466
+
467
+ /**
468
+ * A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
469
+ * @type {number}
470
+ * @memberof BillingAddressesApiListBillingAddresses
471
+ */
472
+ readonly pageSize?: number
473
+
474
+ /**
475
+ * 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.
476
+ * @type {string}
477
+ * @memberof BillingAddressesApiListBillingAddresses
478
+ */
479
+ readonly pageToken?: string
480
+
481
+ /**
482
+ * 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: id, code, city, zipCode, countryCode, accountCode, partnerCode, createdAt, updatedAt&lt;/i&gt;
483
+ * @type {string}
484
+ * @memberof BillingAddressesApiListBillingAddresses
485
+ */
486
+ readonly filter?: string
487
+
488
+ /**
489
+ * Search the response for matches in any searchable field. Use filter instead where possible for improved performance.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Searchable fields: firstName, lastName, accountCode, partnerCode&lt;/i&gt;
490
+ * @type {string}
491
+ * @memberof BillingAddressesApiListBillingAddresses
492
+ */
493
+ readonly search?: string
494
+
495
+ /**
496
+ * 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, code, createdAt, updatedAt&lt;/i&gt;
497
+ * @type {string}
498
+ * @memberof BillingAddressesApiListBillingAddresses
499
+ */
500
+ readonly order?: string
501
+
502
+ /**
503
+ * 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: &lt;i&gt;
504
+ * @type {string}
505
+ * @memberof BillingAddressesApiListBillingAddresses
506
+ */
507
+ readonly expand?: string
508
+
509
+ /**
510
+ * 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: id, code, city, zipCode, countryCode, accountCode, partnerCode, createdAt, updatedAt&lt;/i&gt;
511
+ * @type {string}
512
+ * @memberof BillingAddressesApiListBillingAddresses
513
+ */
514
+ readonly filters?: string
515
+ }
516
+
517
+ /**
518
+ * BillingAddressesApi - object-oriented interface
519
+ * @export
520
+ * @class BillingAddressesApi
521
+ * @extends {BaseAPI}
522
+ */
523
+ export class BillingAddressesApi extends BaseAPI {
524
+ /**
525
+ * This will create a new billing address for a specified account or partner **Required Permissions** \"payment-management.payments.create\"
526
+ * @summary Create the Billing Address
527
+ * @param {BillingAddressesApiCreateBillingAddressRequest} requestParameters Request parameters.
528
+ * @param {*} [options] Override http request option.
529
+ * @throws {RequiredError}
530
+ * @memberof BillingAddressesApi
531
+ */
532
+ public createBillingAddress(requestParameters: BillingAddressesApiCreateBillingAddressRequest, options?: AxiosRequestConfig) {
533
+ return BillingAddressesApiFp(this.configuration).createBillingAddress(requestParameters.createBillingAddressRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
534
+ }
535
+
536
+ /**
537
+ * Deletes a billing address by code **Required Permissions** \"payment-management.payments.delete\"
538
+ * @summary Delete the Billing Address
539
+ * @param {BillingAddressesApiDeleteBillingAddressRequest} requestParameters Request parameters.
540
+ * @param {*} [options] Override http request option.
541
+ * @throws {RequiredError}
542
+ * @memberof BillingAddressesApi
543
+ */
544
+ public deleteBillingAddress(requestParameters: BillingAddressesApiDeleteBillingAddressRequest, options?: AxiosRequestConfig) {
545
+ return BillingAddressesApiFp(this.configuration).deleteBillingAddress(requestParameters.code, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
546
+ }
547
+
548
+ /**
549
+ * Retrieves the details of the Billing Address that was previously created. Supply the unique Billing Address code that was returned when you created it and Emil Api will return the corresponding Billing Address information. **Required Permissions** \"payment-management.payments.view\"
550
+ * @summary Retrieve the Billing Address
551
+ * @param {BillingAddressesApiGetBillingAddressRequest} requestParameters Request parameters.
552
+ * @param {*} [options] Override http request option.
553
+ * @throws {RequiredError}
554
+ * @memberof BillingAddressesApi
555
+ */
556
+ public getBillingAddress(requestParameters: BillingAddressesApiGetBillingAddressRequest, options?: AxiosRequestConfig) {
557
+ return BillingAddressesApiFp(this.configuration).getBillingAddress(requestParameters.code, requestParameters.authorization, requestParameters.expand, options).then((request) => request(this.axios, this.basePath));
558
+ }
559
+
560
+ /**
561
+ * Returns a list of Billing Addresses you have previously created. The Billing Addresses are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"payment-management.payments.view\"
562
+ * @summary List Billing Addresses
563
+ * @param {BillingAddressesApiListBillingAddressesRequest} requestParameters Request parameters.
564
+ * @param {*} [options] Override http request option.
565
+ * @throws {RequiredError}
566
+ * @memberof BillingAddressesApi
567
+ */
568
+ public listBillingAddresses(requestParameters: BillingAddressesApiListBillingAddressesRequest = {}, options?: AxiosRequestConfig) {
569
+ return BillingAddressesApiFp(this.configuration).listBillingAddresses(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then((request) => request(this.axios, this.basePath));
570
+ }
571
+ }
package/api.ts CHANGED
@@ -23,6 +23,7 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } fr
23
23
  import { BankAccountsApi } from './api';
24
24
  import { BankOrdersApi } from './api';
25
25
  import { BankTransactionApi } from './api';
26
+ import { BillingAddressesApi } from './api';
26
27
  import { CreditAllocationApi } from './api';
27
28
  import { ExceedingCreditsApi } from './api';
28
29
  import { HealthCheckApi } from './api';
@@ -39,6 +40,7 @@ import { WebhooksApi } from './api';
39
40
  export * from './api/bank-accounts-api';
40
41
  export * from './api/bank-orders-api';
41
42
  export * from './api/bank-transaction-api';
43
+ export * from './api/billing-addresses-api';
42
44
  export * from './api/credit-allocation-api';
43
45
  export * from './api/exceeding-credits-api';
44
46
  export * from './api/health-check-api';