@emilgroup/customer-sdk 1.56.1-beta.11 → 1.56.1-beta.13

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.
@@ -0,0 +1,2686 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * EMIL CustomerService
5
+ * The EMIL CustomerService API description
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 { ChangeCustomerEmailRequestDto } from '../models';
25
+ // @ts-ignore
26
+ import { ChangePasswordRequestDto } from '../models';
27
+ // @ts-ignore
28
+ import { ChangePasswordResponseClass } from '../models';
29
+ // @ts-ignore
30
+ import { CompletePaymentSetupPspRequest } from '../models';
31
+ // @ts-ignore
32
+ import { CompletePaymentSetupResponseClass } from '../models';
33
+ // @ts-ignore
34
+ import { CreateCustomerRequestDto } from '../models';
35
+ // @ts-ignore
36
+ import { CreateCustomerResponseClass } from '../models';
37
+ // @ts-ignore
38
+ import { CreatePresignedPostResponseClass } from '../models';
39
+ // @ts-ignore
40
+ import { ForgotPasswordRequestDto } from '../models';
41
+ // @ts-ignore
42
+ import { GetCustomerDocumentDownloadUrlRequestDto } from '../models';
43
+ // @ts-ignore
44
+ import { GetCustomerDocumentDownloadUrlResponseClass } from '../models';
45
+ // @ts-ignore
46
+ import { GetCustomerResponseClass } from '../models';
47
+ // @ts-ignore
48
+ import { InitiateAuthRequestDto } from '../models';
49
+ // @ts-ignore
50
+ import { InitiateAuthResponseClass } from '../models';
51
+ // @ts-ignore
52
+ import { InitiatePaymentSetupRequestDto } from '../models';
53
+ // @ts-ignore
54
+ import { InitiatePaymentSetupResponseClass } from '../models';
55
+ // @ts-ignore
56
+ import { InviteByCustomerRequestDto } from '../models';
57
+ // @ts-ignore
58
+ import { InviteByCustomerResponseClass } from '../models';
59
+ // @ts-ignore
60
+ import { InviteByTenantRequestDto } from '../models';
61
+ // @ts-ignore
62
+ import { InviteByTenantResponseClass } from '../models';
63
+ // @ts-ignore
64
+ import { ListDocumentsResponseClass } from '../models';
65
+ // @ts-ignore
66
+ import { ListInvoicesResponseClass } from '../models';
67
+ // @ts-ignore
68
+ import { RefreshTokenDto } from '../models';
69
+ // @ts-ignore
70
+ import { RequestChangeEmailByCustomerRequestDto } from '../models';
71
+ // @ts-ignore
72
+ import { RequestChangeEmailByCustomerResponseClass } from '../models';
73
+ // @ts-ignore
74
+ import { ResetPasswordByCustomerRequestDto } from '../models';
75
+ // @ts-ignore
76
+ import { RespondToAuthChallengeClass } from '../models';
77
+ // @ts-ignore
78
+ import { RespondToAuthChallengeRequestDto } from '../models';
79
+ // @ts-ignore
80
+ import { UpdateCustomerRequestDto } from '../models';
81
+ // @ts-ignore
82
+ import { UpdateCustomerResponseClass } from '../models';
83
+ // @ts-ignore
84
+ import { UploadAccountDocumentsRequestDto } from '../models';
85
+ // @ts-ignore
86
+ import { VerifyChangeEmailTokenRequestDto } from '../models';
87
+ // @ts-ignore
88
+ import { VerifyChangeEmailTokenResponseClass } from '../models';
89
+ // @ts-ignore
90
+ import { VerifyCustomerInviteResponseClass } from '../models';
91
+ // @ts-ignore
92
+ import { VerifyResetPasswordTokenResponseClass } from '../models';
93
+ // URLSearchParams not necessarily used
94
+ /**
95
+ * CustomerControllerRestApi - axios parameter creator
96
+ * @export
97
+ */
98
+ export const CustomerControllerRestApiAxiosParamCreator = function (configuration?: Configuration) {
99
+ return {
100
+ /**
101
+ * Change customer\'s email using the token provided by the request email change endpoint.
102
+ * @summary Change customer email
103
+ * @param {ChangeCustomerEmailRequestDto} changeCustomerEmailRequestDto
104
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
105
+ * @param {*} [options] Override http request option.
106
+ * @throws {RequiredError}
107
+ */
108
+ changeCustomerEmail: async (changeCustomerEmailRequestDto: ChangeCustomerEmailRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
109
+ // verify required parameter 'changeCustomerEmailRequestDto' is not null or undefined
110
+ assertParamExists('changeCustomerEmail', 'changeCustomerEmailRequestDto', changeCustomerEmailRequestDto)
111
+ const localVarPath = `/v1/customers/change-email`;
112
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
113
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
114
+ let baseOptions;
115
+ let baseAccessToken;
116
+ if (configuration) {
117
+ baseOptions = configuration.baseOptions;
118
+ baseAccessToken = configuration.accessToken;
119
+ }
120
+
121
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
122
+ const localVarHeaderParameter = {} as any;
123
+ const localVarQueryParameter = {} as any;
124
+
125
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
126
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
127
+ }
128
+
129
+
130
+
131
+ localVarHeaderParameter['Content-Type'] = 'application/json';
132
+
133
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
134
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
135
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
136
+ localVarRequestOptions.data = serializeDataIfNeeded(changeCustomerEmailRequestDto, localVarRequestOptions, configuration)
137
+
138
+ return {
139
+ url: toPathString(localVarUrlObj),
140
+ options: localVarRequestOptions,
141
+ };
142
+ },
143
+ /**
144
+ * Change the customer password. Please use forgot-password endpoint if current password is lost.
145
+ * @summary Change customer password
146
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
147
+ * @param {ChangePasswordRequestDto} changePasswordRequestDto
148
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
149
+ * @param {*} [options] Override http request option.
150
+ * @throws {RequiredError}
151
+ */
152
+ changePassword: async (customerCode: string, changePasswordRequestDto: ChangePasswordRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
153
+ // verify required parameter 'customerCode' is not null or undefined
154
+ assertParamExists('changePassword', 'customerCode', customerCode)
155
+ // verify required parameter 'changePasswordRequestDto' is not null or undefined
156
+ assertParamExists('changePassword', 'changePasswordRequestDto', changePasswordRequestDto)
157
+ const localVarPath = `/v1/customers/{customerCode}/change-password`
158
+ .replace(`{${"customerCode"}}`, encodeURIComponent(String(customerCode)));
159
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
160
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
161
+ let baseOptions;
162
+ let baseAccessToken;
163
+ if (configuration) {
164
+ baseOptions = configuration.baseOptions;
165
+ baseAccessToken = configuration.accessToken;
166
+ }
167
+
168
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
169
+ const localVarHeaderParameter = {} as any;
170
+ const localVarQueryParameter = {} as any;
171
+
172
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
173
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
174
+ }
175
+
176
+
177
+
178
+ localVarHeaderParameter['Content-Type'] = 'application/json';
179
+
180
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
181
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
182
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
183
+ localVarRequestOptions.data = serializeDataIfNeeded(changePasswordRequestDto, localVarRequestOptions, configuration)
184
+
185
+ return {
186
+ url: toPathString(localVarUrlObj),
187
+ options: localVarRequestOptions,
188
+ };
189
+ },
190
+ /**
191
+ * Request to complete a payment change by customer.
192
+ * @summary Request payment setup complete
193
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
194
+ * @param {CompletePaymentSetupPspRequest} completePaymentSetupPspRequest
195
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
196
+ * @param {*} [options] Override http request option.
197
+ * @throws {RequiredError}
198
+ */
199
+ completePaymentSetup: async (customerCode: string, completePaymentSetupPspRequest: CompletePaymentSetupPspRequest, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
200
+ // verify required parameter 'customerCode' is not null or undefined
201
+ assertParamExists('completePaymentSetup', 'customerCode', customerCode)
202
+ // verify required parameter 'completePaymentSetupPspRequest' is not null or undefined
203
+ assertParamExists('completePaymentSetup', 'completePaymentSetupPspRequest', completePaymentSetupPspRequest)
204
+ const localVarPath = `/v1/customers/{customerCode}/payment_setup/complete`
205
+ .replace(`{${"customerCode"}}`, encodeURIComponent(String(customerCode)));
206
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
207
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
208
+ let baseOptions;
209
+ let baseAccessToken;
210
+ if (configuration) {
211
+ baseOptions = configuration.baseOptions;
212
+ baseAccessToken = configuration.accessToken;
213
+ }
214
+
215
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
216
+ const localVarHeaderParameter = {} as any;
217
+ const localVarQueryParameter = {} as any;
218
+
219
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
220
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
221
+ }
222
+
223
+
224
+
225
+ localVarHeaderParameter['Content-Type'] = 'application/json';
226
+
227
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
228
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
229
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
230
+ localVarRequestOptions.data = serializeDataIfNeeded(completePaymentSetupPspRequest, localVarRequestOptions, configuration)
231
+
232
+ return {
233
+ url: toPathString(localVarUrlObj),
234
+ options: localVarRequestOptions,
235
+ };
236
+ },
237
+ /**
238
+ * Register a customer using the invite token sent to customer\'s email address. Customer can set a new password for his account created during booking a policy.
239
+ * @summary Register a customer after invite
240
+ * @param {CreateCustomerRequestDto} createCustomerRequestDto
241
+ * @param {*} [options] Override http request option.
242
+ * @throws {RequiredError}
243
+ */
244
+ createCustomer: async (createCustomerRequestDto: CreateCustomerRequestDto, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
245
+ // verify required parameter 'createCustomerRequestDto' is not null or undefined
246
+ assertParamExists('createCustomer', 'createCustomerRequestDto', createCustomerRequestDto)
247
+ const localVarPath = `/v1/customers/create`;
248
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
249
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
250
+ let baseOptions;
251
+ let baseAccessToken;
252
+ if (configuration) {
253
+ baseOptions = configuration.baseOptions;
254
+ baseAccessToken = configuration.accessToken;
255
+ }
256
+
257
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
258
+ const localVarHeaderParameter = {} as any;
259
+ const localVarQueryParameter = {} as any;
260
+
261
+
262
+
263
+ localVarHeaderParameter['Content-Type'] = 'application/json';
264
+
265
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
266
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
267
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
268
+ localVarRequestOptions.data = serializeDataIfNeeded(createCustomerRequestDto, localVarRequestOptions, configuration)
269
+
270
+ return {
271
+ url: toPathString(localVarUrlObj),
272
+ options: localVarRequestOptions,
273
+ };
274
+ },
275
+ /**
276
+ * Send a customer a reset-password token via email.
277
+ * @summary Forgot password by customer
278
+ * @param {ForgotPasswordRequestDto} forgotPasswordRequestDto
279
+ * @param {*} [options] Override http request option.
280
+ * @throws {RequiredError}
281
+ */
282
+ forgotPassword: async (forgotPasswordRequestDto: ForgotPasswordRequestDto, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
283
+ // verify required parameter 'forgotPasswordRequestDto' is not null or undefined
284
+ assertParamExists('forgotPassword', 'forgotPasswordRequestDto', forgotPasswordRequestDto)
285
+ const localVarPath = `/v1/customers/forgot-password`;
286
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
287
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
288
+ let baseOptions;
289
+ let baseAccessToken;
290
+ if (configuration) {
291
+ baseOptions = configuration.baseOptions;
292
+ baseAccessToken = configuration.accessToken;
293
+ }
294
+
295
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
296
+ const localVarHeaderParameter = {} as any;
297
+ const localVarQueryParameter = {} as any;
298
+
299
+
300
+
301
+ localVarHeaderParameter['Content-Type'] = 'application/json';
302
+
303
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
304
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
305
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
306
+ localVarRequestOptions.data = serializeDataIfNeeded(forgotPasswordRequestDto, localVarRequestOptions, configuration)
307
+
308
+ return {
309
+ url: toPathString(localVarUrlObj),
310
+ options: localVarRequestOptions,
311
+ };
312
+ },
313
+ /**
314
+ * Get customer details.
315
+ * @summary Get customer details
316
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
317
+ * @param {string} [expand] Fields to expand response by - [account]
318
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
319
+ * @param {*} [options] Override http request option.
320
+ * @throws {RequiredError}
321
+ */
322
+ getCustomer: async (customerCode: string, expand?: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
323
+ // verify required parameter 'customerCode' is not null or undefined
324
+ assertParamExists('getCustomer', 'customerCode', customerCode)
325
+ const localVarPath = `/v1/customers/{customerCode}`
326
+ .replace(`{${"customerCode"}}`, encodeURIComponent(String(customerCode)));
327
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
328
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
329
+ let baseOptions;
330
+ let baseAccessToken;
331
+ if (configuration) {
332
+ baseOptions = configuration.baseOptions;
333
+ baseAccessToken = configuration.accessToken;
334
+ }
335
+
336
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
337
+ const localVarHeaderParameter = {} as any;
338
+ const localVarQueryParameter = {} as any;
339
+
340
+ if (expand !== undefined) {
341
+ localVarQueryParameter['expand'] = expand;
342
+ }
343
+
344
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
345
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
346
+ }
347
+
348
+
349
+
350
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
351
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
352
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
353
+
354
+ return {
355
+ url: toPathString(localVarUrlObj),
356
+ options: localVarRequestOptions,
357
+ };
358
+ },
359
+ /**
360
+ * Get a presigned download url for document.
361
+ * @summary Get a download url for document
362
+ * @param {string} documentCode The document code.
363
+ * @param {string} customerCode
364
+ * @param {GetCustomerDocumentDownloadUrlRequestDto} [contentDisposition] Content disposition override. Default will be depending on the document type.
365
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
366
+ * @param {*} [options] Override http request option.
367
+ * @throws {RequiredError}
368
+ */
369
+ getCustomerDocumentDownloadUrl: async (documentCode: string, customerCode: string, contentDisposition?: GetCustomerDocumentDownloadUrlRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
370
+ // verify required parameter 'documentCode' is not null or undefined
371
+ assertParamExists('getCustomerDocumentDownloadUrl', 'documentCode', documentCode)
372
+ // verify required parameter 'customerCode' is not null or undefined
373
+ assertParamExists('getCustomerDocumentDownloadUrl', 'customerCode', customerCode)
374
+ const localVarPath = `/v1/customers/{customerCode}/documents/{documentCode}/download-url`
375
+ .replace(`{${"documentCode"}}`, encodeURIComponent(String(documentCode)))
376
+ .replace(`{${"customerCode"}}`, encodeURIComponent(String(customerCode)));
377
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
378
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
379
+ let baseOptions;
380
+ let baseAccessToken;
381
+ if (configuration) {
382
+ baseOptions = configuration.baseOptions;
383
+ baseAccessToken = configuration.accessToken;
384
+ }
385
+
386
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
387
+ const localVarHeaderParameter = {} as any;
388
+ const localVarQueryParameter = {} as any;
389
+
390
+ if (contentDisposition !== undefined) {
391
+ localVarQueryParameter['contentDisposition'] = contentDisposition;
392
+ }
393
+
394
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
395
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
396
+ }
397
+
398
+
399
+
400
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
401
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
402
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
403
+
404
+ return {
405
+ url: toPathString(localVarUrlObj),
406
+ options: localVarRequestOptions,
407
+ };
408
+ },
409
+ /**
410
+ * Start auth process to get new access token, refresh token after successful login.
411
+ * @summary Initiate auth by customer
412
+ * @param {InitiateAuthRequestDto} initiateAuthRequestDto
413
+ * @param {*} [options] Override http request option.
414
+ * @throws {RequiredError}
415
+ */
416
+ initiateAuth: async (initiateAuthRequestDto: InitiateAuthRequestDto, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
417
+ // verify required parameter 'initiateAuthRequestDto' is not null or undefined
418
+ assertParamExists('initiateAuth', 'initiateAuthRequestDto', initiateAuthRequestDto)
419
+ const localVarPath = `/v1/customers/auth/initiate`;
420
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
421
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
422
+ let baseOptions;
423
+ let baseAccessToken;
424
+ if (configuration) {
425
+ baseOptions = configuration.baseOptions;
426
+ baseAccessToken = configuration.accessToken;
427
+ }
428
+
429
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
430
+ const localVarHeaderParameter = {} as any;
431
+ const localVarQueryParameter = {} as any;
432
+
433
+
434
+
435
+ localVarHeaderParameter['Content-Type'] = 'application/json';
436
+
437
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
438
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
439
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
440
+ localVarRequestOptions.data = serializeDataIfNeeded(initiateAuthRequestDto, localVarRequestOptions, configuration)
441
+
442
+ return {
443
+ url: toPathString(localVarUrlObj),
444
+ options: localVarRequestOptions,
445
+ };
446
+ },
447
+ /**
448
+ * Request to initiate a payment change by customer.
449
+ * @summary Request payment setup initiation
450
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
451
+ * @param {InitiatePaymentSetupRequestDto} initiatePaymentSetupRequestDto
452
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
453
+ * @param {*} [options] Override http request option.
454
+ * @throws {RequiredError}
455
+ */
456
+ initiatePaymentSetup: async (customerCode: string, initiatePaymentSetupRequestDto: InitiatePaymentSetupRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
457
+ // verify required parameter 'customerCode' is not null or undefined
458
+ assertParamExists('initiatePaymentSetup', 'customerCode', customerCode)
459
+ // verify required parameter 'initiatePaymentSetupRequestDto' is not null or undefined
460
+ assertParamExists('initiatePaymentSetup', 'initiatePaymentSetupRequestDto', initiatePaymentSetupRequestDto)
461
+ const localVarPath = `/v1/customers/{customerCode}/payment_setup/initiate`
462
+ .replace(`{${"customerCode"}}`, encodeURIComponent(String(customerCode)));
463
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
464
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
465
+ let baseOptions;
466
+ let baseAccessToken;
467
+ if (configuration) {
468
+ baseOptions = configuration.baseOptions;
469
+ baseAccessToken = configuration.accessToken;
470
+ }
471
+
472
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
473
+ const localVarHeaderParameter = {} as any;
474
+ const localVarQueryParameter = {} as any;
475
+
476
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
477
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
478
+ }
479
+
480
+
481
+
482
+ localVarHeaderParameter['Content-Type'] = 'application/json';
483
+
484
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
485
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
486
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
487
+ localVarRequestOptions.data = serializeDataIfNeeded(initiatePaymentSetupRequestDto, localVarRequestOptions, configuration)
488
+
489
+ return {
490
+ url: toPathString(localVarUrlObj),
491
+ options: localVarRequestOptions,
492
+ };
493
+ },
494
+ /**
495
+ * Send a customer an invite via email to register. An account should have been created before inviting the customer. To invite users without accounts and policies is not yet supported.
496
+ * @summary Invite a customer by self
497
+ * @param {InviteByCustomerRequestDto} inviteByCustomerRequestDto
498
+ * @param {string} [authorization] Bearer Token: provided by the Emil Insurance Suite\&#39;s Auth login endpoint under the name accessToken.
499
+ * @param {*} [options] Override http request option.
500
+ * @throws {RequiredError}
501
+ */
502
+ inviteByCustomer: async (inviteByCustomerRequestDto: InviteByCustomerRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
503
+ // verify required parameter 'inviteByCustomerRequestDto' is not null or undefined
504
+ assertParamExists('inviteByCustomer', 'inviteByCustomerRequestDto', inviteByCustomerRequestDto)
505
+ const localVarPath = `/v1/customers/invites/by-customer`;
506
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
507
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
508
+ let baseOptions;
509
+ let baseAccessToken;
510
+ if (configuration) {
511
+ baseOptions = configuration.baseOptions;
512
+ baseAccessToken = configuration.accessToken;
513
+ }
514
+
515
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
516
+ const localVarHeaderParameter = {} as any;
517
+ const localVarQueryParameter = {} as any;
518
+
519
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
520
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
521
+ }
522
+
523
+
524
+
525
+ localVarHeaderParameter['Content-Type'] = 'application/json';
526
+
527
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
528
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
529
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
530
+ localVarRequestOptions.data = serializeDataIfNeeded(inviteByCustomerRequestDto, localVarRequestOptions, configuration)
531
+
532
+ return {
533
+ url: toPathString(localVarUrlObj),
534
+ options: localVarRequestOptions,
535
+ };
536
+ },
537
+ /**
538
+ * Send a customer an invite via email to register. An account should have been created before inviting the customer. To invite users without accounts and policies is not yet supported. **Required Permissions** \"customer-management.customers.create\"
539
+ * @summary Invite a customer by tenant
540
+ * @param {InviteByTenantRequestDto} inviteByTenantRequestDto
541
+ * @param {string} [authorization] Bearer Token: provided by the Emil Insurance Suite\&#39;s Auth login endpoint under the name accessToken.
542
+ * @param {*} [options] Override http request option.
543
+ * @throws {RequiredError}
544
+ */
545
+ inviteByTenant: async (inviteByTenantRequestDto: InviteByTenantRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
546
+ // verify required parameter 'inviteByTenantRequestDto' is not null or undefined
547
+ assertParamExists('inviteByTenant', 'inviteByTenantRequestDto', inviteByTenantRequestDto)
548
+ const localVarPath = `/v1/customers/invites/by-tenant`;
549
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
550
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
551
+ let baseOptions;
552
+ let baseAccessToken;
553
+ if (configuration) {
554
+ baseOptions = configuration.baseOptions;
555
+ baseAccessToken = configuration.accessToken;
556
+ }
557
+
558
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
559
+ const localVarHeaderParameter = {} as any;
560
+ const localVarQueryParameter = {} as any;
561
+
562
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
563
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
564
+ }
565
+
566
+
567
+
568
+ localVarHeaderParameter['Content-Type'] = 'application/json';
569
+
570
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
571
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
572
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
573
+ localVarRequestOptions.data = serializeDataIfNeeded(inviteByTenantRequestDto, localVarRequestOptions, configuration)
574
+
575
+ return {
576
+ url: toPathString(localVarUrlObj),
577
+ options: localVarRequestOptions,
578
+ };
579
+ },
580
+ /**
581
+ * Get customer list.
582
+ * @summary Get customers list
583
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
584
+ * @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.
585
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
586
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
587
+ * @param {string} [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.
588
+ * @param {string} [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.
589
+ * @param {string} [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.
590
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
591
+ * @param {*} [options] Override http request option.
592
+ * @throws {RequiredError}
593
+ */
594
+ listCustomers: async (pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
595
+ const localVarPath = `/v1/customers`;
596
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
597
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
598
+ let baseOptions;
599
+ let baseAccessToken;
600
+ if (configuration) {
601
+ baseOptions = configuration.baseOptions;
602
+ baseAccessToken = configuration.accessToken;
603
+ }
604
+
605
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
606
+ const localVarHeaderParameter = {} as any;
607
+ const localVarQueryParameter = {} as any;
608
+
609
+ if (pageSize !== undefined) {
610
+ localVarQueryParameter['pageSize'] = pageSize;
611
+ }
612
+
613
+ if (pageToken !== undefined) {
614
+ localVarQueryParameter['pageToken'] = pageToken;
615
+ }
616
+
617
+ if (filter !== undefined) {
618
+ localVarQueryParameter['filter'] = filter;
619
+ }
620
+
621
+ if (search !== undefined) {
622
+ localVarQueryParameter['search'] = search;
623
+ }
624
+
625
+ if (order !== undefined) {
626
+ localVarQueryParameter['order'] = order;
627
+ }
628
+
629
+ if (expand !== undefined) {
630
+ localVarQueryParameter['expand'] = expand;
631
+ }
632
+
633
+ if (filters !== undefined) {
634
+ localVarQueryParameter['filters'] = filters;
635
+ }
636
+
637
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
638
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
639
+ }
640
+
641
+
642
+
643
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
644
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
645
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
646
+
647
+ return {
648
+ url: toPathString(localVarUrlObj),
649
+ options: localVarRequestOptions,
650
+ };
651
+ },
652
+ /**
653
+ * List all the documents of a customer.
654
+ * @summary List documents of a customer
655
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
656
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
657
+ * @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.
658
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
659
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
660
+ * @param {string} [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.
661
+ * @param {string} [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.
662
+ * @param {string} [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.
663
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
664
+ * @param {*} [options] Override http request option.
665
+ * @throws {RequiredError}
666
+ */
667
+ listDocuments: async (customerCode: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
668
+ // verify required parameter 'customerCode' is not null or undefined
669
+ assertParamExists('listDocuments', 'customerCode', customerCode)
670
+ const localVarPath = `/v1/customers/{customerCode}/documents`
671
+ .replace(`{${"customerCode"}}`, encodeURIComponent(String(customerCode)));
672
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
673
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
674
+ let baseOptions;
675
+ let baseAccessToken;
676
+ if (configuration) {
677
+ baseOptions = configuration.baseOptions;
678
+ baseAccessToken = configuration.accessToken;
679
+ }
680
+
681
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
682
+ const localVarHeaderParameter = {} as any;
683
+ const localVarQueryParameter = {} as any;
684
+
685
+ if (pageSize !== undefined) {
686
+ localVarQueryParameter['pageSize'] = pageSize;
687
+ }
688
+
689
+ if (pageToken !== undefined) {
690
+ localVarQueryParameter['pageToken'] = pageToken;
691
+ }
692
+
693
+ if (filter !== undefined) {
694
+ localVarQueryParameter['filter'] = filter;
695
+ }
696
+
697
+ if (search !== undefined) {
698
+ localVarQueryParameter['search'] = search;
699
+ }
700
+
701
+ if (order !== undefined) {
702
+ localVarQueryParameter['order'] = order;
703
+ }
704
+
705
+ if (expand !== undefined) {
706
+ localVarQueryParameter['expand'] = expand;
707
+ }
708
+
709
+ if (filters !== undefined) {
710
+ localVarQueryParameter['filters'] = filters;
711
+ }
712
+
713
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
714
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
715
+ }
716
+
717
+
718
+
719
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
720
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
721
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
722
+
723
+ return {
724
+ url: toPathString(localVarUrlObj),
725
+ options: localVarRequestOptions,
726
+ };
727
+ },
728
+ /**
729
+ * List all the invoices of a customer.
730
+ * @summary List invoices of a customer
731
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
732
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
733
+ * @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.
734
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
735
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
736
+ * @param {string} [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.
737
+ * @param {string} [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.
738
+ * @param {string} [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.
739
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
740
+ * @param {*} [options] Override http request option.
741
+ * @throws {RequiredError}
742
+ */
743
+ listInvoices: async (customerCode: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
744
+ // verify required parameter 'customerCode' is not null or undefined
745
+ assertParamExists('listInvoices', 'customerCode', customerCode)
746
+ const localVarPath = `/v1/customers/{customerCode}/invoices`
747
+ .replace(`{${"customerCode"}}`, encodeURIComponent(String(customerCode)));
748
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
749
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
750
+ let baseOptions;
751
+ let baseAccessToken;
752
+ if (configuration) {
753
+ baseOptions = configuration.baseOptions;
754
+ baseAccessToken = configuration.accessToken;
755
+ }
756
+
757
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
758
+ const localVarHeaderParameter = {} as any;
759
+ const localVarQueryParameter = {} as any;
760
+
761
+ if (pageSize !== undefined) {
762
+ localVarQueryParameter['pageSize'] = pageSize;
763
+ }
764
+
765
+ if (pageToken !== undefined) {
766
+ localVarQueryParameter['pageToken'] = pageToken;
767
+ }
768
+
769
+ if (filter !== undefined) {
770
+ localVarQueryParameter['filter'] = filter;
771
+ }
772
+
773
+ if (search !== undefined) {
774
+ localVarQueryParameter['search'] = search;
775
+ }
776
+
777
+ if (order !== undefined) {
778
+ localVarQueryParameter['order'] = order;
779
+ }
780
+
781
+ if (expand !== undefined) {
782
+ localVarQueryParameter['expand'] = expand;
783
+ }
784
+
785
+ if (filters !== undefined) {
786
+ localVarQueryParameter['filters'] = filters;
787
+ }
788
+
789
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
790
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
791
+ }
792
+
793
+
794
+
795
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
796
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
797
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
798
+
799
+ return {
800
+ url: toPathString(localVarUrlObj),
801
+ options: localVarRequestOptions,
802
+ };
803
+ },
804
+ /**
805
+ * Get new access token, new refresh token.
806
+ * @summary Refresh token by customer
807
+ * @param {RefreshTokenDto} refreshTokenDto
808
+ * @param {string} [cookie] HTTP only cookie that was sent during login.
809
+ * @param {*} [options] Override http request option.
810
+ * @throws {RequiredError}
811
+ */
812
+ refreshToken: async (refreshTokenDto: RefreshTokenDto, cookie?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
813
+ // verify required parameter 'refreshTokenDto' is not null or undefined
814
+ assertParamExists('refreshToken', 'refreshTokenDto', refreshTokenDto)
815
+ const localVarPath = `/v1/customers/refresh-token`;
816
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
817
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
818
+ let baseOptions;
819
+ let baseAccessToken;
820
+ if (configuration) {
821
+ baseOptions = configuration.baseOptions;
822
+ baseAccessToken = configuration.accessToken;
823
+ }
824
+
825
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
826
+ const localVarHeaderParameter = {} as any;
827
+ const localVarQueryParameter = {} as any;
828
+
829
+ if (cookie !== undefined && cookie !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
830
+ localVarHeaderParameter['Cookie'] = String(cookie ? cookie : baseAccessToken);
831
+ }
832
+
833
+
834
+
835
+ localVarHeaderParameter['Content-Type'] = 'application/json';
836
+
837
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
838
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
839
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
840
+ localVarRequestOptions.data = serializeDataIfNeeded(refreshTokenDto, localVarRequestOptions, configuration)
841
+
842
+ return {
843
+ url: toPathString(localVarUrlObj),
844
+ options: localVarRequestOptions,
845
+ };
846
+ },
847
+ /**
848
+ * Request a token to change the email address for the customer.
849
+ * @summary Request customer email change
850
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
851
+ * @param {RequestChangeEmailByCustomerRequestDto} requestChangeEmailByCustomerRequestDto
852
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
853
+ * @param {*} [options] Override http request option.
854
+ * @throws {RequiredError}
855
+ */
856
+ requestChangeEmailByCustomer: async (customerCode: string, requestChangeEmailByCustomerRequestDto: RequestChangeEmailByCustomerRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
857
+ // verify required parameter 'customerCode' is not null or undefined
858
+ assertParamExists('requestChangeEmailByCustomer', 'customerCode', customerCode)
859
+ // verify required parameter 'requestChangeEmailByCustomerRequestDto' is not null or undefined
860
+ assertParamExists('requestChangeEmailByCustomer', 'requestChangeEmailByCustomerRequestDto', requestChangeEmailByCustomerRequestDto)
861
+ const localVarPath = `/v1/customers/{customerCode}/request-email-change`
862
+ .replace(`{${"customerCode"}}`, encodeURIComponent(String(customerCode)));
863
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
864
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
865
+ let baseOptions;
866
+ let baseAccessToken;
867
+ if (configuration) {
868
+ baseOptions = configuration.baseOptions;
869
+ baseAccessToken = configuration.accessToken;
870
+ }
871
+
872
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
873
+ const localVarHeaderParameter = {} as any;
874
+ const localVarQueryParameter = {} as any;
875
+
876
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
877
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
878
+ }
879
+
880
+
881
+
882
+ localVarHeaderParameter['Content-Type'] = 'application/json';
883
+
884
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
885
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
886
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
887
+ localVarRequestOptions.data = serializeDataIfNeeded(requestChangeEmailByCustomerRequestDto, localVarRequestOptions, configuration)
888
+
889
+ return {
890
+ url: toPathString(localVarUrlObj),
891
+ options: localVarRequestOptions,
892
+ };
893
+ },
894
+ /**
895
+ * Change customer\'s password using the token provided by the reset password endpoint.
896
+ * @summary Change password by customer
897
+ * @param {ResetPasswordByCustomerRequestDto} resetPasswordByCustomerRequestDto
898
+ * @param {*} [options] Override http request option.
899
+ * @throws {RequiredError}
900
+ */
901
+ resetPassword: async (resetPasswordByCustomerRequestDto: ResetPasswordByCustomerRequestDto, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
902
+ // verify required parameter 'resetPasswordByCustomerRequestDto' is not null or undefined
903
+ assertParamExists('resetPassword', 'resetPasswordByCustomerRequestDto', resetPasswordByCustomerRequestDto)
904
+ const localVarPath = `/v1/customers/reset-password`;
905
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
906
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
907
+ let baseOptions;
908
+ let baseAccessToken;
909
+ if (configuration) {
910
+ baseOptions = configuration.baseOptions;
911
+ baseAccessToken = configuration.accessToken;
912
+ }
913
+
914
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
915
+ const localVarHeaderParameter = {} as any;
916
+ const localVarQueryParameter = {} as any;
917
+
918
+
919
+
920
+ localVarHeaderParameter['Content-Type'] = 'application/json';
921
+
922
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
923
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
924
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
925
+ localVarRequestOptions.data = serializeDataIfNeeded(resetPasswordByCustomerRequestDto, localVarRequestOptions, configuration)
926
+
927
+ return {
928
+ url: toPathString(localVarUrlObj),
929
+ options: localVarRequestOptions,
930
+ };
931
+ },
932
+ /**
933
+ * Respond to the auth challenge by customer to get new access token, refresh token after successful login.
934
+ * @summary Respond to auth challenge
935
+ * @param {RespondToAuthChallengeRequestDto} respondToAuthChallengeRequestDto
936
+ * @param {*} [options] Override http request option.
937
+ * @throws {RequiredError}
938
+ */
939
+ respondToAuthChallenge: async (respondToAuthChallengeRequestDto: RespondToAuthChallengeRequestDto, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
940
+ // verify required parameter 'respondToAuthChallengeRequestDto' is not null or undefined
941
+ assertParamExists('respondToAuthChallenge', 'respondToAuthChallengeRequestDto', respondToAuthChallengeRequestDto)
942
+ const localVarPath = `/v1/customers/auth/respond`;
943
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
944
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
945
+ let baseOptions;
946
+ let baseAccessToken;
947
+ if (configuration) {
948
+ baseOptions = configuration.baseOptions;
949
+ baseAccessToken = configuration.accessToken;
950
+ }
951
+
952
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
953
+ const localVarHeaderParameter = {} as any;
954
+ const localVarQueryParameter = {} as any;
955
+
956
+
957
+
958
+ localVarHeaderParameter['Content-Type'] = 'application/json';
959
+
960
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
961
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
962
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
963
+ localVarRequestOptions.data = serializeDataIfNeeded(respondToAuthChallengeRequestDto, localVarRequestOptions, configuration)
964
+
965
+ return {
966
+ url: toPathString(localVarUrlObj),
967
+ options: localVarRequestOptions,
968
+ };
969
+ },
970
+ /**
971
+ * Update customer details like phone, names, addresses etc. To change email, please use Request customer email change endpoint instead.
972
+ * @summary Update customer details
973
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
974
+ * @param {UpdateCustomerRequestDto} updateCustomerRequestDto
975
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
976
+ * @param {*} [options] Override http request option.
977
+ * @throws {RequiredError}
978
+ */
979
+ updateCustomer: async (customerCode: string, updateCustomerRequestDto: UpdateCustomerRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
980
+ // verify required parameter 'customerCode' is not null or undefined
981
+ assertParamExists('updateCustomer', 'customerCode', customerCode)
982
+ // verify required parameter 'updateCustomerRequestDto' is not null or undefined
983
+ assertParamExists('updateCustomer', 'updateCustomerRequestDto', updateCustomerRequestDto)
984
+ const localVarPath = `/v1/customers/{customerCode}`
985
+ .replace(`{${"customerCode"}}`, encodeURIComponent(String(customerCode)));
986
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
987
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
988
+ let baseOptions;
989
+ let baseAccessToken;
990
+ if (configuration) {
991
+ baseOptions = configuration.baseOptions;
992
+ baseAccessToken = configuration.accessToken;
993
+ }
994
+
995
+ const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
996
+ const localVarHeaderParameter = {} as any;
997
+ const localVarQueryParameter = {} as any;
998
+
999
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
1000
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
1001
+ }
1002
+
1003
+
1004
+
1005
+ localVarHeaderParameter['Content-Type'] = 'application/json';
1006
+
1007
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
1008
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1009
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
1010
+ localVarRequestOptions.data = serializeDataIfNeeded(updateCustomerRequestDto, localVarRequestOptions, configuration)
1011
+
1012
+ return {
1013
+ url: toPathString(localVarUrlObj),
1014
+ options: localVarRequestOptions,
1015
+ };
1016
+ },
1017
+ /**
1018
+ * API to upload and attach documents to an account.
1019
+ * @summary Upload account documents
1020
+ * @param {string} customerCode
1021
+ * @param {UploadAccountDocumentsRequestDto} uploadAccountDocumentsRequestDto
1022
+ * @param {*} [options] Override http request option.
1023
+ * @throws {RequiredError}
1024
+ */
1025
+ uploadAccountDocuments: async (customerCode: string, uploadAccountDocumentsRequestDto: UploadAccountDocumentsRequestDto, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
1026
+ // verify required parameter 'customerCode' is not null or undefined
1027
+ assertParamExists('uploadAccountDocuments', 'customerCode', customerCode)
1028
+ // verify required parameter 'uploadAccountDocumentsRequestDto' is not null or undefined
1029
+ assertParamExists('uploadAccountDocuments', 'uploadAccountDocumentsRequestDto', uploadAccountDocumentsRequestDto)
1030
+ const localVarPath = `/v1/customers/{customerCode}/documents`
1031
+ .replace(`{${"customerCode"}}`, encodeURIComponent(String(customerCode)));
1032
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1033
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
1034
+ let baseOptions;
1035
+ let baseAccessToken;
1036
+ if (configuration) {
1037
+ baseOptions = configuration.baseOptions;
1038
+ baseAccessToken = configuration.accessToken;
1039
+ }
1040
+
1041
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
1042
+ const localVarHeaderParameter = {} as any;
1043
+ const localVarQueryParameter = {} as any;
1044
+
1045
+
1046
+
1047
+ localVarHeaderParameter['Content-Type'] = 'application/json';
1048
+
1049
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
1050
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1051
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
1052
+ localVarRequestOptions.data = serializeDataIfNeeded(uploadAccountDocumentsRequestDto, localVarRequestOptions, configuration)
1053
+
1054
+ return {
1055
+ url: toPathString(localVarUrlObj),
1056
+ options: localVarRequestOptions,
1057
+ };
1058
+ },
1059
+ /**
1060
+ * Verify the change email token that is sent by calling the request change email endpoint.
1061
+ * @summary Verify the change email token
1062
+ * @param {VerifyChangeEmailTokenRequestDto} verifyChangeEmailTokenRequestDto
1063
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1064
+ * @param {*} [options] Override http request option.
1065
+ * @throws {RequiredError}
1066
+ */
1067
+ verifyChangeEmailToken: async (verifyChangeEmailTokenRequestDto: VerifyChangeEmailTokenRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
1068
+ // verify required parameter 'verifyChangeEmailTokenRequestDto' is not null or undefined
1069
+ assertParamExists('verifyChangeEmailToken', 'verifyChangeEmailTokenRequestDto', verifyChangeEmailTokenRequestDto)
1070
+ const localVarPath = `/v1/customers/verify-change-email`;
1071
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1072
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
1073
+ let baseOptions;
1074
+ let baseAccessToken;
1075
+ if (configuration) {
1076
+ baseOptions = configuration.baseOptions;
1077
+ baseAccessToken = configuration.accessToken;
1078
+ }
1079
+
1080
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
1081
+ const localVarHeaderParameter = {} as any;
1082
+ const localVarQueryParameter = {} as any;
1083
+
1084
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
1085
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
1086
+ }
1087
+
1088
+
1089
+
1090
+ localVarHeaderParameter['Content-Type'] = 'application/json';
1091
+
1092
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
1093
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1094
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
1095
+ localVarRequestOptions.data = serializeDataIfNeeded(verifyChangeEmailTokenRequestDto, localVarRequestOptions, configuration)
1096
+
1097
+ return {
1098
+ url: toPathString(localVarUrlObj),
1099
+ options: localVarRequestOptions,
1100
+ };
1101
+ },
1102
+ /**
1103
+ * Verify the invite sent to the customer via email.
1104
+ * @summary Verify customer\'s invite token
1105
+ * @param {string} inviteToken Invite token sent to the customer
1106
+ * @param {*} [options] Override http request option.
1107
+ * @throws {RequiredError}
1108
+ */
1109
+ verifyInvite: async (inviteToken: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
1110
+ // verify required parameter 'inviteToken' is not null or undefined
1111
+ assertParamExists('verifyInvite', 'inviteToken', inviteToken)
1112
+ const localVarPath = `/v1/customers/invites/verify`;
1113
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1114
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
1115
+ let baseOptions;
1116
+ let baseAccessToken;
1117
+ if (configuration) {
1118
+ baseOptions = configuration.baseOptions;
1119
+ baseAccessToken = configuration.accessToken;
1120
+ }
1121
+
1122
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
1123
+ const localVarHeaderParameter = {} as any;
1124
+ const localVarQueryParameter = {} as any;
1125
+
1126
+ if (inviteToken !== undefined) {
1127
+ localVarQueryParameter['inviteToken'] = inviteToken;
1128
+ }
1129
+
1130
+
1131
+
1132
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
1133
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1134
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
1135
+
1136
+ return {
1137
+ url: toPathString(localVarUrlObj),
1138
+ options: localVarRequestOptions,
1139
+ };
1140
+ },
1141
+ /**
1142
+ * Verify the reset password token that is sent by calling the \'forgot password\' endpoint.
1143
+ * @summary Verify a reset password token
1144
+ * @param {string} resetToken reset password token
1145
+ * @param {*} [options] Override http request option.
1146
+ * @throws {RequiredError}
1147
+ */
1148
+ verifyResetPasswordToken: async (resetToken: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
1149
+ // verify required parameter 'resetToken' is not null or undefined
1150
+ assertParamExists('verifyResetPasswordToken', 'resetToken', resetToken)
1151
+ const localVarPath = `/v1/customers/verify-reset-password`;
1152
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1153
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
1154
+ let baseOptions;
1155
+ let baseAccessToken;
1156
+ if (configuration) {
1157
+ baseOptions = configuration.baseOptions;
1158
+ baseAccessToken = configuration.accessToken;
1159
+ }
1160
+
1161
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
1162
+ const localVarHeaderParameter = {} as any;
1163
+ const localVarQueryParameter = {} as any;
1164
+
1165
+ if (resetToken !== undefined) {
1166
+ localVarQueryParameter['resetToken'] = resetToken;
1167
+ }
1168
+
1169
+
1170
+
1171
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
1172
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1173
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
1174
+
1175
+ return {
1176
+ url: toPathString(localVarUrlObj),
1177
+ options: localVarRequestOptions,
1178
+ };
1179
+ },
1180
+ }
1181
+ };
1182
+
1183
+ /**
1184
+ * CustomerControllerRestApi - functional programming interface
1185
+ * @export
1186
+ */
1187
+ export const CustomerControllerRestApiFp = function(configuration?: Configuration) {
1188
+ const localVarAxiosParamCreator = CustomerControllerRestApiAxiosParamCreator(configuration)
1189
+ return {
1190
+ /**
1191
+ * Change customer\'s email using the token provided by the request email change endpoint.
1192
+ * @summary Change customer email
1193
+ * @param {ChangeCustomerEmailRequestDto} changeCustomerEmailRequestDto
1194
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1195
+ * @param {*} [options] Override http request option.
1196
+ * @throws {RequiredError}
1197
+ */
1198
+ async changeCustomerEmail(changeCustomerEmailRequestDto: ChangeCustomerEmailRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UpdateCustomerResponseClass>> {
1199
+ const localVarAxiosArgs = await localVarAxiosParamCreator.changeCustomerEmail(changeCustomerEmailRequestDto, authorization, options);
1200
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1201
+ },
1202
+ /**
1203
+ * Change the customer password. Please use forgot-password endpoint if current password is lost.
1204
+ * @summary Change customer password
1205
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1206
+ * @param {ChangePasswordRequestDto} changePasswordRequestDto
1207
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1208
+ * @param {*} [options] Override http request option.
1209
+ * @throws {RequiredError}
1210
+ */
1211
+ async changePassword(customerCode: string, changePasswordRequestDto: ChangePasswordRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChangePasswordResponseClass>> {
1212
+ const localVarAxiosArgs = await localVarAxiosParamCreator.changePassword(customerCode, changePasswordRequestDto, authorization, options);
1213
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1214
+ },
1215
+ /**
1216
+ * Request to complete a payment change by customer.
1217
+ * @summary Request payment setup complete
1218
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1219
+ * @param {CompletePaymentSetupPspRequest} completePaymentSetupPspRequest
1220
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1221
+ * @param {*} [options] Override http request option.
1222
+ * @throws {RequiredError}
1223
+ */
1224
+ async completePaymentSetup(customerCode: string, completePaymentSetupPspRequest: CompletePaymentSetupPspRequest, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CompletePaymentSetupResponseClass>> {
1225
+ const localVarAxiosArgs = await localVarAxiosParamCreator.completePaymentSetup(customerCode, completePaymentSetupPspRequest, authorization, options);
1226
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1227
+ },
1228
+ /**
1229
+ * Register a customer using the invite token sent to customer\'s email address. Customer can set a new password for his account created during booking a policy.
1230
+ * @summary Register a customer after invite
1231
+ * @param {CreateCustomerRequestDto} createCustomerRequestDto
1232
+ * @param {*} [options] Override http request option.
1233
+ * @throws {RequiredError}
1234
+ */
1235
+ async createCustomer(createCustomerRequestDto: CreateCustomerRequestDto, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateCustomerResponseClass>> {
1236
+ const localVarAxiosArgs = await localVarAxiosParamCreator.createCustomer(createCustomerRequestDto, options);
1237
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1238
+ },
1239
+ /**
1240
+ * Send a customer a reset-password token via email.
1241
+ * @summary Forgot password by customer
1242
+ * @param {ForgotPasswordRequestDto} forgotPasswordRequestDto
1243
+ * @param {*} [options] Override http request option.
1244
+ * @throws {RequiredError}
1245
+ */
1246
+ async forgotPassword(forgotPasswordRequestDto: ForgotPasswordRequestDto, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
1247
+ const localVarAxiosArgs = await localVarAxiosParamCreator.forgotPassword(forgotPasswordRequestDto, options);
1248
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1249
+ },
1250
+ /**
1251
+ * Get customer details.
1252
+ * @summary Get customer details
1253
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1254
+ * @param {string} [expand] Fields to expand response by - [account]
1255
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1256
+ * @param {*} [options] Override http request option.
1257
+ * @throws {RequiredError}
1258
+ */
1259
+ async getCustomer(customerCode: string, expand?: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetCustomerResponseClass>> {
1260
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getCustomer(customerCode, expand, authorization, options);
1261
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1262
+ },
1263
+ /**
1264
+ * Get a presigned download url for document.
1265
+ * @summary Get a download url for document
1266
+ * @param {string} documentCode The document code.
1267
+ * @param {string} customerCode
1268
+ * @param {GetCustomerDocumentDownloadUrlRequestDto} [contentDisposition] Content disposition override. Default will be depending on the document type.
1269
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1270
+ * @param {*} [options] Override http request option.
1271
+ * @throws {RequiredError}
1272
+ */
1273
+ async getCustomerDocumentDownloadUrl(documentCode: string, customerCode: string, contentDisposition?: GetCustomerDocumentDownloadUrlRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetCustomerDocumentDownloadUrlResponseClass>> {
1274
+ const localVarAxiosArgs = await localVarAxiosParamCreator.getCustomerDocumentDownloadUrl(documentCode, customerCode, contentDisposition, authorization, options);
1275
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1276
+ },
1277
+ /**
1278
+ * Start auth process to get new access token, refresh token after successful login.
1279
+ * @summary Initiate auth by customer
1280
+ * @param {InitiateAuthRequestDto} initiateAuthRequestDto
1281
+ * @param {*} [options] Override http request option.
1282
+ * @throws {RequiredError}
1283
+ */
1284
+ async initiateAuth(initiateAuthRequestDto: InitiateAuthRequestDto, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InitiateAuthResponseClass>> {
1285
+ const localVarAxiosArgs = await localVarAxiosParamCreator.initiateAuth(initiateAuthRequestDto, options);
1286
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1287
+ },
1288
+ /**
1289
+ * Request to initiate a payment change by customer.
1290
+ * @summary Request payment setup initiation
1291
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1292
+ * @param {InitiatePaymentSetupRequestDto} initiatePaymentSetupRequestDto
1293
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1294
+ * @param {*} [options] Override http request option.
1295
+ * @throws {RequiredError}
1296
+ */
1297
+ async initiatePaymentSetup(customerCode: string, initiatePaymentSetupRequestDto: InitiatePaymentSetupRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InitiatePaymentSetupResponseClass>> {
1298
+ const localVarAxiosArgs = await localVarAxiosParamCreator.initiatePaymentSetup(customerCode, initiatePaymentSetupRequestDto, authorization, options);
1299
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1300
+ },
1301
+ /**
1302
+ * Send a customer an invite via email to register. An account should have been created before inviting the customer. To invite users without accounts and policies is not yet supported.
1303
+ * @summary Invite a customer by self
1304
+ * @param {InviteByCustomerRequestDto} inviteByCustomerRequestDto
1305
+ * @param {string} [authorization] Bearer Token: provided by the Emil Insurance Suite\&#39;s Auth login endpoint under the name accessToken.
1306
+ * @param {*} [options] Override http request option.
1307
+ * @throws {RequiredError}
1308
+ */
1309
+ async inviteByCustomer(inviteByCustomerRequestDto: InviteByCustomerRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InviteByCustomerResponseClass>> {
1310
+ const localVarAxiosArgs = await localVarAxiosParamCreator.inviteByCustomer(inviteByCustomerRequestDto, authorization, options);
1311
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1312
+ },
1313
+ /**
1314
+ * Send a customer an invite via email to register. An account should have been created before inviting the customer. To invite users without accounts and policies is not yet supported. **Required Permissions** \"customer-management.customers.create\"
1315
+ * @summary Invite a customer by tenant
1316
+ * @param {InviteByTenantRequestDto} inviteByTenantRequestDto
1317
+ * @param {string} [authorization] Bearer Token: provided by the Emil Insurance Suite\&#39;s Auth login endpoint under the name accessToken.
1318
+ * @param {*} [options] Override http request option.
1319
+ * @throws {RequiredError}
1320
+ */
1321
+ async inviteByTenant(inviteByTenantRequestDto: InviteByTenantRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InviteByTenantResponseClass>> {
1322
+ const localVarAxiosArgs = await localVarAxiosParamCreator.inviteByTenant(inviteByTenantRequestDto, authorization, options);
1323
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1324
+ },
1325
+ /**
1326
+ * Get customer list.
1327
+ * @summary Get customers list
1328
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1329
+ * @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.
1330
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
1331
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
1332
+ * @param {string} [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.
1333
+ * @param {string} [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.
1334
+ * @param {string} [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.
1335
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1336
+ * @param {*} [options] Override http request option.
1337
+ * @throws {RequiredError}
1338
+ */
1339
+ async listCustomers(pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<object>> {
1340
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listCustomers(pageSize, pageToken, filter, search, order, expand, filters, authorization, options);
1341
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1342
+ },
1343
+ /**
1344
+ * List all the documents of a customer.
1345
+ * @summary List documents of a customer
1346
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1347
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1348
+ * @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.
1349
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
1350
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
1351
+ * @param {string} [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.
1352
+ * @param {string} [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.
1353
+ * @param {string} [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.
1354
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1355
+ * @param {*} [options] Override http request option.
1356
+ * @throws {RequiredError}
1357
+ */
1358
+ async listDocuments(customerCode: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListDocumentsResponseClass>> {
1359
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listDocuments(customerCode, pageSize, pageToken, filter, search, order, expand, filters, authorization, options);
1360
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1361
+ },
1362
+ /**
1363
+ * List all the invoices of a customer.
1364
+ * @summary List invoices of a customer
1365
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1366
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1367
+ * @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.
1368
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
1369
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
1370
+ * @param {string} [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.
1371
+ * @param {string} [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.
1372
+ * @param {string} [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.
1373
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1374
+ * @param {*} [options] Override http request option.
1375
+ * @throws {RequiredError}
1376
+ */
1377
+ async listInvoices(customerCode: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListInvoicesResponseClass>> {
1378
+ const localVarAxiosArgs = await localVarAxiosParamCreator.listInvoices(customerCode, pageSize, pageToken, filter, search, order, expand, filters, authorization, options);
1379
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1380
+ },
1381
+ /**
1382
+ * Get new access token, new refresh token.
1383
+ * @summary Refresh token by customer
1384
+ * @param {RefreshTokenDto} refreshTokenDto
1385
+ * @param {string} [cookie] HTTP only cookie that was sent during login.
1386
+ * @param {*} [options] Override http request option.
1387
+ * @throws {RequiredError}
1388
+ */
1389
+ async refreshToken(refreshTokenDto: RefreshTokenDto, cookie?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
1390
+ const localVarAxiosArgs = await localVarAxiosParamCreator.refreshToken(refreshTokenDto, cookie, options);
1391
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1392
+ },
1393
+ /**
1394
+ * Request a token to change the email address for the customer.
1395
+ * @summary Request customer email change
1396
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1397
+ * @param {RequestChangeEmailByCustomerRequestDto} requestChangeEmailByCustomerRequestDto
1398
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1399
+ * @param {*} [options] Override http request option.
1400
+ * @throws {RequiredError}
1401
+ */
1402
+ async requestChangeEmailByCustomer(customerCode: string, requestChangeEmailByCustomerRequestDto: RequestChangeEmailByCustomerRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<RequestChangeEmailByCustomerResponseClass>> {
1403
+ const localVarAxiosArgs = await localVarAxiosParamCreator.requestChangeEmailByCustomer(customerCode, requestChangeEmailByCustomerRequestDto, authorization, options);
1404
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1405
+ },
1406
+ /**
1407
+ * Change customer\'s password using the token provided by the reset password endpoint.
1408
+ * @summary Change password by customer
1409
+ * @param {ResetPasswordByCustomerRequestDto} resetPasswordByCustomerRequestDto
1410
+ * @param {*} [options] Override http request option.
1411
+ * @throws {RequiredError}
1412
+ */
1413
+ async resetPassword(resetPasswordByCustomerRequestDto: ResetPasswordByCustomerRequestDto, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
1414
+ const localVarAxiosArgs = await localVarAxiosParamCreator.resetPassword(resetPasswordByCustomerRequestDto, options);
1415
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1416
+ },
1417
+ /**
1418
+ * Respond to the auth challenge by customer to get new access token, refresh token after successful login.
1419
+ * @summary Respond to auth challenge
1420
+ * @param {RespondToAuthChallengeRequestDto} respondToAuthChallengeRequestDto
1421
+ * @param {*} [options] Override http request option.
1422
+ * @throws {RequiredError}
1423
+ */
1424
+ async respondToAuthChallenge(respondToAuthChallengeRequestDto: RespondToAuthChallengeRequestDto, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<RespondToAuthChallengeClass>> {
1425
+ const localVarAxiosArgs = await localVarAxiosParamCreator.respondToAuthChallenge(respondToAuthChallengeRequestDto, options);
1426
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1427
+ },
1428
+ /**
1429
+ * Update customer details like phone, names, addresses etc. To change email, please use Request customer email change endpoint instead.
1430
+ * @summary Update customer details
1431
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1432
+ * @param {UpdateCustomerRequestDto} updateCustomerRequestDto
1433
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1434
+ * @param {*} [options] Override http request option.
1435
+ * @throws {RequiredError}
1436
+ */
1437
+ async updateCustomer(customerCode: string, updateCustomerRequestDto: UpdateCustomerRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UpdateCustomerResponseClass>> {
1438
+ const localVarAxiosArgs = await localVarAxiosParamCreator.updateCustomer(customerCode, updateCustomerRequestDto, authorization, options);
1439
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1440
+ },
1441
+ /**
1442
+ * API to upload and attach documents to an account.
1443
+ * @summary Upload account documents
1444
+ * @param {string} customerCode
1445
+ * @param {UploadAccountDocumentsRequestDto} uploadAccountDocumentsRequestDto
1446
+ * @param {*} [options] Override http request option.
1447
+ * @throws {RequiredError}
1448
+ */
1449
+ async uploadAccountDocuments(customerCode: string, uploadAccountDocumentsRequestDto: UploadAccountDocumentsRequestDto, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreatePresignedPostResponseClass>> {
1450
+ const localVarAxiosArgs = await localVarAxiosParamCreator.uploadAccountDocuments(customerCode, uploadAccountDocumentsRequestDto, options);
1451
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1452
+ },
1453
+ /**
1454
+ * Verify the change email token that is sent by calling the request change email endpoint.
1455
+ * @summary Verify the change email token
1456
+ * @param {VerifyChangeEmailTokenRequestDto} verifyChangeEmailTokenRequestDto
1457
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1458
+ * @param {*} [options] Override http request option.
1459
+ * @throws {RequiredError}
1460
+ */
1461
+ async verifyChangeEmailToken(verifyChangeEmailTokenRequestDto: VerifyChangeEmailTokenRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<VerifyChangeEmailTokenResponseClass>> {
1462
+ const localVarAxiosArgs = await localVarAxiosParamCreator.verifyChangeEmailToken(verifyChangeEmailTokenRequestDto, authorization, options);
1463
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1464
+ },
1465
+ /**
1466
+ * Verify the invite sent to the customer via email.
1467
+ * @summary Verify customer\'s invite token
1468
+ * @param {string} inviteToken Invite token sent to the customer
1469
+ * @param {*} [options] Override http request option.
1470
+ * @throws {RequiredError}
1471
+ */
1472
+ async verifyInvite(inviteToken: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<VerifyCustomerInviteResponseClass>> {
1473
+ const localVarAxiosArgs = await localVarAxiosParamCreator.verifyInvite(inviteToken, options);
1474
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1475
+ },
1476
+ /**
1477
+ * Verify the reset password token that is sent by calling the \'forgot password\' endpoint.
1478
+ * @summary Verify a reset password token
1479
+ * @param {string} resetToken reset password token
1480
+ * @param {*} [options] Override http request option.
1481
+ * @throws {RequiredError}
1482
+ */
1483
+ async verifyResetPasswordToken(resetToken: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<VerifyResetPasswordTokenResponseClass>> {
1484
+ const localVarAxiosArgs = await localVarAxiosParamCreator.verifyResetPasswordToken(resetToken, options);
1485
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
1486
+ },
1487
+ }
1488
+ };
1489
+
1490
+ /**
1491
+ * CustomerControllerRestApi - factory interface
1492
+ * @export
1493
+ */
1494
+ export const CustomerControllerRestApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
1495
+ const localVarFp = CustomerControllerRestApiFp(configuration)
1496
+ return {
1497
+ /**
1498
+ * Change customer\'s email using the token provided by the request email change endpoint.
1499
+ * @summary Change customer email
1500
+ * @param {ChangeCustomerEmailRequestDto} changeCustomerEmailRequestDto
1501
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1502
+ * @param {*} [options] Override http request option.
1503
+ * @throws {RequiredError}
1504
+ */
1505
+ changeCustomerEmail(changeCustomerEmailRequestDto: ChangeCustomerEmailRequestDto, authorization?: string, options?: any): AxiosPromise<UpdateCustomerResponseClass> {
1506
+ return localVarFp.changeCustomerEmail(changeCustomerEmailRequestDto, authorization, options).then((request) => request(axios, basePath));
1507
+ },
1508
+ /**
1509
+ * Change the customer password. Please use forgot-password endpoint if current password is lost.
1510
+ * @summary Change customer password
1511
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1512
+ * @param {ChangePasswordRequestDto} changePasswordRequestDto
1513
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1514
+ * @param {*} [options] Override http request option.
1515
+ * @throws {RequiredError}
1516
+ */
1517
+ changePassword(customerCode: string, changePasswordRequestDto: ChangePasswordRequestDto, authorization?: string, options?: any): AxiosPromise<ChangePasswordResponseClass> {
1518
+ return localVarFp.changePassword(customerCode, changePasswordRequestDto, authorization, options).then((request) => request(axios, basePath));
1519
+ },
1520
+ /**
1521
+ * Request to complete a payment change by customer.
1522
+ * @summary Request payment setup complete
1523
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1524
+ * @param {CompletePaymentSetupPspRequest} completePaymentSetupPspRequest
1525
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1526
+ * @param {*} [options] Override http request option.
1527
+ * @throws {RequiredError}
1528
+ */
1529
+ completePaymentSetup(customerCode: string, completePaymentSetupPspRequest: CompletePaymentSetupPspRequest, authorization?: string, options?: any): AxiosPromise<CompletePaymentSetupResponseClass> {
1530
+ return localVarFp.completePaymentSetup(customerCode, completePaymentSetupPspRequest, authorization, options).then((request) => request(axios, basePath));
1531
+ },
1532
+ /**
1533
+ * Register a customer using the invite token sent to customer\'s email address. Customer can set a new password for his account created during booking a policy.
1534
+ * @summary Register a customer after invite
1535
+ * @param {CreateCustomerRequestDto} createCustomerRequestDto
1536
+ * @param {*} [options] Override http request option.
1537
+ * @throws {RequiredError}
1538
+ */
1539
+ createCustomer(createCustomerRequestDto: CreateCustomerRequestDto, options?: any): AxiosPromise<CreateCustomerResponseClass> {
1540
+ return localVarFp.createCustomer(createCustomerRequestDto, options).then((request) => request(axios, basePath));
1541
+ },
1542
+ /**
1543
+ * Send a customer a reset-password token via email.
1544
+ * @summary Forgot password by customer
1545
+ * @param {ForgotPasswordRequestDto} forgotPasswordRequestDto
1546
+ * @param {*} [options] Override http request option.
1547
+ * @throws {RequiredError}
1548
+ */
1549
+ forgotPassword(forgotPasswordRequestDto: ForgotPasswordRequestDto, options?: any): AxiosPromise<void> {
1550
+ return localVarFp.forgotPassword(forgotPasswordRequestDto, options).then((request) => request(axios, basePath));
1551
+ },
1552
+ /**
1553
+ * Get customer details.
1554
+ * @summary Get customer details
1555
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1556
+ * @param {string} [expand] Fields to expand response by - [account]
1557
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1558
+ * @param {*} [options] Override http request option.
1559
+ * @throws {RequiredError}
1560
+ */
1561
+ getCustomer(customerCode: string, expand?: string, authorization?: string, options?: any): AxiosPromise<GetCustomerResponseClass> {
1562
+ return localVarFp.getCustomer(customerCode, expand, authorization, options).then((request) => request(axios, basePath));
1563
+ },
1564
+ /**
1565
+ * Get a presigned download url for document.
1566
+ * @summary Get a download url for document
1567
+ * @param {string} documentCode The document code.
1568
+ * @param {string} customerCode
1569
+ * @param {GetCustomerDocumentDownloadUrlRequestDto} [contentDisposition] Content disposition override. Default will be depending on the document type.
1570
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1571
+ * @param {*} [options] Override http request option.
1572
+ * @throws {RequiredError}
1573
+ */
1574
+ getCustomerDocumentDownloadUrl(documentCode: string, customerCode: string, contentDisposition?: GetCustomerDocumentDownloadUrlRequestDto, authorization?: string, options?: any): AxiosPromise<GetCustomerDocumentDownloadUrlResponseClass> {
1575
+ return localVarFp.getCustomerDocumentDownloadUrl(documentCode, customerCode, contentDisposition, authorization, options).then((request) => request(axios, basePath));
1576
+ },
1577
+ /**
1578
+ * Start auth process to get new access token, refresh token after successful login.
1579
+ * @summary Initiate auth by customer
1580
+ * @param {InitiateAuthRequestDto} initiateAuthRequestDto
1581
+ * @param {*} [options] Override http request option.
1582
+ * @throws {RequiredError}
1583
+ */
1584
+ initiateAuth(initiateAuthRequestDto: InitiateAuthRequestDto, options?: any): AxiosPromise<InitiateAuthResponseClass> {
1585
+ return localVarFp.initiateAuth(initiateAuthRequestDto, options).then((request) => request(axios, basePath));
1586
+ },
1587
+ /**
1588
+ * Request to initiate a payment change by customer.
1589
+ * @summary Request payment setup initiation
1590
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1591
+ * @param {InitiatePaymentSetupRequestDto} initiatePaymentSetupRequestDto
1592
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1593
+ * @param {*} [options] Override http request option.
1594
+ * @throws {RequiredError}
1595
+ */
1596
+ initiatePaymentSetup(customerCode: string, initiatePaymentSetupRequestDto: InitiatePaymentSetupRequestDto, authorization?: string, options?: any): AxiosPromise<InitiatePaymentSetupResponseClass> {
1597
+ return localVarFp.initiatePaymentSetup(customerCode, initiatePaymentSetupRequestDto, authorization, options).then((request) => request(axios, basePath));
1598
+ },
1599
+ /**
1600
+ * Send a customer an invite via email to register. An account should have been created before inviting the customer. To invite users without accounts and policies is not yet supported.
1601
+ * @summary Invite a customer by self
1602
+ * @param {InviteByCustomerRequestDto} inviteByCustomerRequestDto
1603
+ * @param {string} [authorization] Bearer Token: provided by the Emil Insurance Suite\&#39;s Auth login endpoint under the name accessToken.
1604
+ * @param {*} [options] Override http request option.
1605
+ * @throws {RequiredError}
1606
+ */
1607
+ inviteByCustomer(inviteByCustomerRequestDto: InviteByCustomerRequestDto, authorization?: string, options?: any): AxiosPromise<InviteByCustomerResponseClass> {
1608
+ return localVarFp.inviteByCustomer(inviteByCustomerRequestDto, authorization, options).then((request) => request(axios, basePath));
1609
+ },
1610
+ /**
1611
+ * Send a customer an invite via email to register. An account should have been created before inviting the customer. To invite users without accounts and policies is not yet supported. **Required Permissions** \"customer-management.customers.create\"
1612
+ * @summary Invite a customer by tenant
1613
+ * @param {InviteByTenantRequestDto} inviteByTenantRequestDto
1614
+ * @param {string} [authorization] Bearer Token: provided by the Emil Insurance Suite\&#39;s Auth login endpoint under the name accessToken.
1615
+ * @param {*} [options] Override http request option.
1616
+ * @throws {RequiredError}
1617
+ */
1618
+ inviteByTenant(inviteByTenantRequestDto: InviteByTenantRequestDto, authorization?: string, options?: any): AxiosPromise<InviteByTenantResponseClass> {
1619
+ return localVarFp.inviteByTenant(inviteByTenantRequestDto, authorization, options).then((request) => request(axios, basePath));
1620
+ },
1621
+ /**
1622
+ * Get customer list.
1623
+ * @summary Get customers list
1624
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1625
+ * @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.
1626
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
1627
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
1628
+ * @param {string} [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.
1629
+ * @param {string} [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.
1630
+ * @param {string} [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.
1631
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1632
+ * @param {*} [options] Override http request option.
1633
+ * @throws {RequiredError}
1634
+ */
1635
+ listCustomers(pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, authorization?: string, options?: any): AxiosPromise<object> {
1636
+ return localVarFp.listCustomers(pageSize, pageToken, filter, search, order, expand, filters, authorization, options).then((request) => request(axios, basePath));
1637
+ },
1638
+ /**
1639
+ * List all the documents of a customer.
1640
+ * @summary List documents of a customer
1641
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1642
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1643
+ * @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.
1644
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
1645
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
1646
+ * @param {string} [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.
1647
+ * @param {string} [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.
1648
+ * @param {string} [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.
1649
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1650
+ * @param {*} [options] Override http request option.
1651
+ * @throws {RequiredError}
1652
+ */
1653
+ listDocuments(customerCode: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, authorization?: string, options?: any): AxiosPromise<ListDocumentsResponseClass> {
1654
+ return localVarFp.listDocuments(customerCode, pageSize, pageToken, filter, search, order, expand, filters, authorization, options).then((request) => request(axios, basePath));
1655
+ },
1656
+ /**
1657
+ * List all the invoices of a customer.
1658
+ * @summary List invoices of a customer
1659
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1660
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
1661
+ * @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.
1662
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
1663
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
1664
+ * @param {string} [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.
1665
+ * @param {string} [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.
1666
+ * @param {string} [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.
1667
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1668
+ * @param {*} [options] Override http request option.
1669
+ * @throws {RequiredError}
1670
+ */
1671
+ listInvoices(customerCode: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, authorization?: string, options?: any): AxiosPromise<ListInvoicesResponseClass> {
1672
+ return localVarFp.listInvoices(customerCode, pageSize, pageToken, filter, search, order, expand, filters, authorization, options).then((request) => request(axios, basePath));
1673
+ },
1674
+ /**
1675
+ * Get new access token, new refresh token.
1676
+ * @summary Refresh token by customer
1677
+ * @param {RefreshTokenDto} refreshTokenDto
1678
+ * @param {string} [cookie] HTTP only cookie that was sent during login.
1679
+ * @param {*} [options] Override http request option.
1680
+ * @throws {RequiredError}
1681
+ */
1682
+ refreshToken(refreshTokenDto: RefreshTokenDto, cookie?: string, options?: any): AxiosPromise<void> {
1683
+ return localVarFp.refreshToken(refreshTokenDto, cookie, options).then((request) => request(axios, basePath));
1684
+ },
1685
+ /**
1686
+ * Request a token to change the email address for the customer.
1687
+ * @summary Request customer email change
1688
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1689
+ * @param {RequestChangeEmailByCustomerRequestDto} requestChangeEmailByCustomerRequestDto
1690
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1691
+ * @param {*} [options] Override http request option.
1692
+ * @throws {RequiredError}
1693
+ */
1694
+ requestChangeEmailByCustomer(customerCode: string, requestChangeEmailByCustomerRequestDto: RequestChangeEmailByCustomerRequestDto, authorization?: string, options?: any): AxiosPromise<RequestChangeEmailByCustomerResponseClass> {
1695
+ return localVarFp.requestChangeEmailByCustomer(customerCode, requestChangeEmailByCustomerRequestDto, authorization, options).then((request) => request(axios, basePath));
1696
+ },
1697
+ /**
1698
+ * Change customer\'s password using the token provided by the reset password endpoint.
1699
+ * @summary Change password by customer
1700
+ * @param {ResetPasswordByCustomerRequestDto} resetPasswordByCustomerRequestDto
1701
+ * @param {*} [options] Override http request option.
1702
+ * @throws {RequiredError}
1703
+ */
1704
+ resetPassword(resetPasswordByCustomerRequestDto: ResetPasswordByCustomerRequestDto, options?: any): AxiosPromise<void> {
1705
+ return localVarFp.resetPassword(resetPasswordByCustomerRequestDto, options).then((request) => request(axios, basePath));
1706
+ },
1707
+ /**
1708
+ * Respond to the auth challenge by customer to get new access token, refresh token after successful login.
1709
+ * @summary Respond to auth challenge
1710
+ * @param {RespondToAuthChallengeRequestDto} respondToAuthChallengeRequestDto
1711
+ * @param {*} [options] Override http request option.
1712
+ * @throws {RequiredError}
1713
+ */
1714
+ respondToAuthChallenge(respondToAuthChallengeRequestDto: RespondToAuthChallengeRequestDto, options?: any): AxiosPromise<RespondToAuthChallengeClass> {
1715
+ return localVarFp.respondToAuthChallenge(respondToAuthChallengeRequestDto, options).then((request) => request(axios, basePath));
1716
+ },
1717
+ /**
1718
+ * Update customer details like phone, names, addresses etc. To change email, please use Request customer email change endpoint instead.
1719
+ * @summary Update customer details
1720
+ * @param {string} customerCode The customer code or \&quot;me\&quot; for the currently logged in customer.
1721
+ * @param {UpdateCustomerRequestDto} updateCustomerRequestDto
1722
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1723
+ * @param {*} [options] Override http request option.
1724
+ * @throws {RequiredError}
1725
+ */
1726
+ updateCustomer(customerCode: string, updateCustomerRequestDto: UpdateCustomerRequestDto, authorization?: string, options?: any): AxiosPromise<UpdateCustomerResponseClass> {
1727
+ return localVarFp.updateCustomer(customerCode, updateCustomerRequestDto, authorization, options).then((request) => request(axios, basePath));
1728
+ },
1729
+ /**
1730
+ * API to upload and attach documents to an account.
1731
+ * @summary Upload account documents
1732
+ * @param {string} customerCode
1733
+ * @param {UploadAccountDocumentsRequestDto} uploadAccountDocumentsRequestDto
1734
+ * @param {*} [options] Override http request option.
1735
+ * @throws {RequiredError}
1736
+ */
1737
+ uploadAccountDocuments(customerCode: string, uploadAccountDocumentsRequestDto: UploadAccountDocumentsRequestDto, options?: any): AxiosPromise<CreatePresignedPostResponseClass> {
1738
+ return localVarFp.uploadAccountDocuments(customerCode, uploadAccountDocumentsRequestDto, options).then((request) => request(axios, basePath));
1739
+ },
1740
+ /**
1741
+ * Verify the change email token that is sent by calling the request change email endpoint.
1742
+ * @summary Verify the change email token
1743
+ * @param {VerifyChangeEmailTokenRequestDto} verifyChangeEmailTokenRequestDto
1744
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
1745
+ * @param {*} [options] Override http request option.
1746
+ * @throws {RequiredError}
1747
+ */
1748
+ verifyChangeEmailToken(verifyChangeEmailTokenRequestDto: VerifyChangeEmailTokenRequestDto, authorization?: string, options?: any): AxiosPromise<VerifyChangeEmailTokenResponseClass> {
1749
+ return localVarFp.verifyChangeEmailToken(verifyChangeEmailTokenRequestDto, authorization, options).then((request) => request(axios, basePath));
1750
+ },
1751
+ /**
1752
+ * Verify the invite sent to the customer via email.
1753
+ * @summary Verify customer\'s invite token
1754
+ * @param {string} inviteToken Invite token sent to the customer
1755
+ * @param {*} [options] Override http request option.
1756
+ * @throws {RequiredError}
1757
+ */
1758
+ verifyInvite(inviteToken: string, options?: any): AxiosPromise<VerifyCustomerInviteResponseClass> {
1759
+ return localVarFp.verifyInvite(inviteToken, options).then((request) => request(axios, basePath));
1760
+ },
1761
+ /**
1762
+ * Verify the reset password token that is sent by calling the \'forgot password\' endpoint.
1763
+ * @summary Verify a reset password token
1764
+ * @param {string} resetToken reset password token
1765
+ * @param {*} [options] Override http request option.
1766
+ * @throws {RequiredError}
1767
+ */
1768
+ verifyResetPasswordToken(resetToken: string, options?: any): AxiosPromise<VerifyResetPasswordTokenResponseClass> {
1769
+ return localVarFp.verifyResetPasswordToken(resetToken, options).then((request) => request(axios, basePath));
1770
+ },
1771
+ };
1772
+ };
1773
+
1774
+ /**
1775
+ * Request parameters for changeCustomerEmail operation in CustomerControllerRestApi.
1776
+ * @export
1777
+ * @interface CustomerControllerRestApiChangeCustomerEmailRequest
1778
+ */
1779
+ export interface CustomerControllerRestApiChangeCustomerEmailRequest {
1780
+ /**
1781
+ *
1782
+ * @type {ChangeCustomerEmailRequestDto}
1783
+ * @memberof CustomerControllerRestApiChangeCustomerEmail
1784
+ */
1785
+ readonly changeCustomerEmailRequestDto: ChangeCustomerEmailRequestDto
1786
+
1787
+ /**
1788
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1789
+ * @type {string}
1790
+ * @memberof CustomerControllerRestApiChangeCustomerEmail
1791
+ */
1792
+ readonly authorization?: string
1793
+ }
1794
+
1795
+ /**
1796
+ * Request parameters for changePassword operation in CustomerControllerRestApi.
1797
+ * @export
1798
+ * @interface CustomerControllerRestApiChangePasswordRequest
1799
+ */
1800
+ export interface CustomerControllerRestApiChangePasswordRequest {
1801
+ /**
1802
+ * The customer code or \&quot;me\&quot; for the currently logged in customer.
1803
+ * @type {string}
1804
+ * @memberof CustomerControllerRestApiChangePassword
1805
+ */
1806
+ readonly customerCode: string
1807
+
1808
+ /**
1809
+ *
1810
+ * @type {ChangePasswordRequestDto}
1811
+ * @memberof CustomerControllerRestApiChangePassword
1812
+ */
1813
+ readonly changePasswordRequestDto: ChangePasswordRequestDto
1814
+
1815
+ /**
1816
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1817
+ * @type {string}
1818
+ * @memberof CustomerControllerRestApiChangePassword
1819
+ */
1820
+ readonly authorization?: string
1821
+ }
1822
+
1823
+ /**
1824
+ * Request parameters for completePaymentSetup operation in CustomerControllerRestApi.
1825
+ * @export
1826
+ * @interface CustomerControllerRestApiCompletePaymentSetupRequest
1827
+ */
1828
+ export interface CustomerControllerRestApiCompletePaymentSetupRequest {
1829
+ /**
1830
+ * The customer code or \&quot;me\&quot; for the currently logged in customer.
1831
+ * @type {string}
1832
+ * @memberof CustomerControllerRestApiCompletePaymentSetup
1833
+ */
1834
+ readonly customerCode: string
1835
+
1836
+ /**
1837
+ *
1838
+ * @type {CompletePaymentSetupPspRequest}
1839
+ * @memberof CustomerControllerRestApiCompletePaymentSetup
1840
+ */
1841
+ readonly completePaymentSetupPspRequest: CompletePaymentSetupPspRequest
1842
+
1843
+ /**
1844
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1845
+ * @type {string}
1846
+ * @memberof CustomerControllerRestApiCompletePaymentSetup
1847
+ */
1848
+ readonly authorization?: string
1849
+ }
1850
+
1851
+ /**
1852
+ * Request parameters for createCustomer operation in CustomerControllerRestApi.
1853
+ * @export
1854
+ * @interface CustomerControllerRestApiCreateCustomerRequest
1855
+ */
1856
+ export interface CustomerControllerRestApiCreateCustomerRequest {
1857
+ /**
1858
+ *
1859
+ * @type {CreateCustomerRequestDto}
1860
+ * @memberof CustomerControllerRestApiCreateCustomer
1861
+ */
1862
+ readonly createCustomerRequestDto: CreateCustomerRequestDto
1863
+ }
1864
+
1865
+ /**
1866
+ * Request parameters for forgotPassword operation in CustomerControllerRestApi.
1867
+ * @export
1868
+ * @interface CustomerControllerRestApiForgotPasswordRequest
1869
+ */
1870
+ export interface CustomerControllerRestApiForgotPasswordRequest {
1871
+ /**
1872
+ *
1873
+ * @type {ForgotPasswordRequestDto}
1874
+ * @memberof CustomerControllerRestApiForgotPassword
1875
+ */
1876
+ readonly forgotPasswordRequestDto: ForgotPasswordRequestDto
1877
+ }
1878
+
1879
+ /**
1880
+ * Request parameters for getCustomer operation in CustomerControllerRestApi.
1881
+ * @export
1882
+ * @interface CustomerControllerRestApiGetCustomerRequest
1883
+ */
1884
+ export interface CustomerControllerRestApiGetCustomerRequest {
1885
+ /**
1886
+ * The customer code or \&quot;me\&quot; for the currently logged in customer.
1887
+ * @type {string}
1888
+ * @memberof CustomerControllerRestApiGetCustomer
1889
+ */
1890
+ readonly customerCode: string
1891
+
1892
+ /**
1893
+ * Fields to expand response by - [account]
1894
+ * @type {string}
1895
+ * @memberof CustomerControllerRestApiGetCustomer
1896
+ */
1897
+ readonly expand?: string
1898
+
1899
+ /**
1900
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1901
+ * @type {string}
1902
+ * @memberof CustomerControllerRestApiGetCustomer
1903
+ */
1904
+ readonly authorization?: string
1905
+ }
1906
+
1907
+ /**
1908
+ * Request parameters for getCustomerDocumentDownloadUrl operation in CustomerControllerRestApi.
1909
+ * @export
1910
+ * @interface CustomerControllerRestApiGetCustomerDocumentDownloadUrlRequest
1911
+ */
1912
+ export interface CustomerControllerRestApiGetCustomerDocumentDownloadUrlRequest {
1913
+ /**
1914
+ * The document code.
1915
+ * @type {string}
1916
+ * @memberof CustomerControllerRestApiGetCustomerDocumentDownloadUrl
1917
+ */
1918
+ readonly documentCode: string
1919
+
1920
+ /**
1921
+ *
1922
+ * @type {string}
1923
+ * @memberof CustomerControllerRestApiGetCustomerDocumentDownloadUrl
1924
+ */
1925
+ readonly customerCode: string
1926
+
1927
+ /**
1928
+ * Content disposition override. Default will be depending on the document type.
1929
+ * @type {GetCustomerDocumentDownloadUrlRequestDto}
1930
+ * @memberof CustomerControllerRestApiGetCustomerDocumentDownloadUrl
1931
+ */
1932
+ readonly contentDisposition?: GetCustomerDocumentDownloadUrlRequestDto
1933
+
1934
+ /**
1935
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1936
+ * @type {string}
1937
+ * @memberof CustomerControllerRestApiGetCustomerDocumentDownloadUrl
1938
+ */
1939
+ readonly authorization?: string
1940
+ }
1941
+
1942
+ /**
1943
+ * Request parameters for initiateAuth operation in CustomerControllerRestApi.
1944
+ * @export
1945
+ * @interface CustomerControllerRestApiInitiateAuthRequest
1946
+ */
1947
+ export interface CustomerControllerRestApiInitiateAuthRequest {
1948
+ /**
1949
+ *
1950
+ * @type {InitiateAuthRequestDto}
1951
+ * @memberof CustomerControllerRestApiInitiateAuth
1952
+ */
1953
+ readonly initiateAuthRequestDto: InitiateAuthRequestDto
1954
+ }
1955
+
1956
+ /**
1957
+ * Request parameters for initiatePaymentSetup operation in CustomerControllerRestApi.
1958
+ * @export
1959
+ * @interface CustomerControllerRestApiInitiatePaymentSetupRequest
1960
+ */
1961
+ export interface CustomerControllerRestApiInitiatePaymentSetupRequest {
1962
+ /**
1963
+ * The customer code or \&quot;me\&quot; for the currently logged in customer.
1964
+ * @type {string}
1965
+ * @memberof CustomerControllerRestApiInitiatePaymentSetup
1966
+ */
1967
+ readonly customerCode: string
1968
+
1969
+ /**
1970
+ *
1971
+ * @type {InitiatePaymentSetupRequestDto}
1972
+ * @memberof CustomerControllerRestApiInitiatePaymentSetup
1973
+ */
1974
+ readonly initiatePaymentSetupRequestDto: InitiatePaymentSetupRequestDto
1975
+
1976
+ /**
1977
+ * Bearer Token: provided by the login endpoint under the name accessToken.
1978
+ * @type {string}
1979
+ * @memberof CustomerControllerRestApiInitiatePaymentSetup
1980
+ */
1981
+ readonly authorization?: string
1982
+ }
1983
+
1984
+ /**
1985
+ * Request parameters for inviteByCustomer operation in CustomerControllerRestApi.
1986
+ * @export
1987
+ * @interface CustomerControllerRestApiInviteByCustomerRequest
1988
+ */
1989
+ export interface CustomerControllerRestApiInviteByCustomerRequest {
1990
+ /**
1991
+ *
1992
+ * @type {InviteByCustomerRequestDto}
1993
+ * @memberof CustomerControllerRestApiInviteByCustomer
1994
+ */
1995
+ readonly inviteByCustomerRequestDto: InviteByCustomerRequestDto
1996
+
1997
+ /**
1998
+ * Bearer Token: provided by the Emil Insurance Suite\&#39;s Auth login endpoint under the name accessToken.
1999
+ * @type {string}
2000
+ * @memberof CustomerControllerRestApiInviteByCustomer
2001
+ */
2002
+ readonly authorization?: string
2003
+ }
2004
+
2005
+ /**
2006
+ * Request parameters for inviteByTenant operation in CustomerControllerRestApi.
2007
+ * @export
2008
+ * @interface CustomerControllerRestApiInviteByTenantRequest
2009
+ */
2010
+ export interface CustomerControllerRestApiInviteByTenantRequest {
2011
+ /**
2012
+ *
2013
+ * @type {InviteByTenantRequestDto}
2014
+ * @memberof CustomerControllerRestApiInviteByTenant
2015
+ */
2016
+ readonly inviteByTenantRequestDto: InviteByTenantRequestDto
2017
+
2018
+ /**
2019
+ * Bearer Token: provided by the Emil Insurance Suite\&#39;s Auth login endpoint under the name accessToken.
2020
+ * @type {string}
2021
+ * @memberof CustomerControllerRestApiInviteByTenant
2022
+ */
2023
+ readonly authorization?: string
2024
+ }
2025
+
2026
+ /**
2027
+ * Request parameters for listCustomers operation in CustomerControllerRestApi.
2028
+ * @export
2029
+ * @interface CustomerControllerRestApiListCustomersRequest
2030
+ */
2031
+ export interface CustomerControllerRestApiListCustomersRequest {
2032
+ /**
2033
+ * A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
2034
+ * @type {number}
2035
+ * @memberof CustomerControllerRestApiListCustomers
2036
+ */
2037
+ readonly pageSize?: number
2038
+
2039
+ /**
2040
+ * 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.
2041
+ * @type {string}
2042
+ * @memberof CustomerControllerRestApiListCustomers
2043
+ */
2044
+ readonly pageToken?: string
2045
+
2046
+ /**
2047
+ * Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
2048
+ * @type {string}
2049
+ * @memberof CustomerControllerRestApiListCustomers
2050
+ */
2051
+ readonly filter?: string
2052
+
2053
+ /**
2054
+ * To search the list by any field, pass search&#x3D;xxx to fetch the result.
2055
+ * @type {string}
2056
+ * @memberof CustomerControllerRestApiListCustomers
2057
+ */
2058
+ readonly search?: string
2059
+
2060
+ /**
2061
+ * 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.
2062
+ * @type {string}
2063
+ * @memberof CustomerControllerRestApiListCustomers
2064
+ */
2065
+ readonly order?: string
2066
+
2067
+ /**
2068
+ * 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.
2069
+ * @type {string}
2070
+ * @memberof CustomerControllerRestApiListCustomers
2071
+ */
2072
+ readonly expand?: string
2073
+
2074
+ /**
2075
+ * 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.
2076
+ * @type {string}
2077
+ * @memberof CustomerControllerRestApiListCustomers
2078
+ */
2079
+ readonly filters?: string
2080
+
2081
+ /**
2082
+ * Bearer Token: provided by the login endpoint under the name accessToken.
2083
+ * @type {string}
2084
+ * @memberof CustomerControllerRestApiListCustomers
2085
+ */
2086
+ readonly authorization?: string
2087
+ }
2088
+
2089
+ /**
2090
+ * Request parameters for listDocuments operation in CustomerControllerRestApi.
2091
+ * @export
2092
+ * @interface CustomerControllerRestApiListDocumentsRequest
2093
+ */
2094
+ export interface CustomerControllerRestApiListDocumentsRequest {
2095
+ /**
2096
+ * The customer code or \&quot;me\&quot; for the currently logged in customer.
2097
+ * @type {string}
2098
+ * @memberof CustomerControllerRestApiListDocuments
2099
+ */
2100
+ readonly customerCode: string
2101
+
2102
+ /**
2103
+ * A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
2104
+ * @type {number}
2105
+ * @memberof CustomerControllerRestApiListDocuments
2106
+ */
2107
+ readonly pageSize?: number
2108
+
2109
+ /**
2110
+ * 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.
2111
+ * @type {string}
2112
+ * @memberof CustomerControllerRestApiListDocuments
2113
+ */
2114
+ readonly pageToken?: string
2115
+
2116
+ /**
2117
+ * Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
2118
+ * @type {string}
2119
+ * @memberof CustomerControllerRestApiListDocuments
2120
+ */
2121
+ readonly filter?: string
2122
+
2123
+ /**
2124
+ * To search the list by any field, pass search&#x3D;xxx to fetch the result.
2125
+ * @type {string}
2126
+ * @memberof CustomerControllerRestApiListDocuments
2127
+ */
2128
+ readonly search?: string
2129
+
2130
+ /**
2131
+ * 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.
2132
+ * @type {string}
2133
+ * @memberof CustomerControllerRestApiListDocuments
2134
+ */
2135
+ readonly order?: string
2136
+
2137
+ /**
2138
+ * 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.
2139
+ * @type {string}
2140
+ * @memberof CustomerControllerRestApiListDocuments
2141
+ */
2142
+ readonly expand?: string
2143
+
2144
+ /**
2145
+ * 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.
2146
+ * @type {string}
2147
+ * @memberof CustomerControllerRestApiListDocuments
2148
+ */
2149
+ readonly filters?: string
2150
+
2151
+ /**
2152
+ * Bearer Token: provided by the login endpoint under the name accessToken.
2153
+ * @type {string}
2154
+ * @memberof CustomerControllerRestApiListDocuments
2155
+ */
2156
+ readonly authorization?: string
2157
+ }
2158
+
2159
+ /**
2160
+ * Request parameters for listInvoices operation in CustomerControllerRestApi.
2161
+ * @export
2162
+ * @interface CustomerControllerRestApiListInvoicesRequest
2163
+ */
2164
+ export interface CustomerControllerRestApiListInvoicesRequest {
2165
+ /**
2166
+ * The customer code or \&quot;me\&quot; for the currently logged in customer.
2167
+ * @type {string}
2168
+ * @memberof CustomerControllerRestApiListInvoices
2169
+ */
2170
+ readonly customerCode: string
2171
+
2172
+ /**
2173
+ * A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
2174
+ * @type {number}
2175
+ * @memberof CustomerControllerRestApiListInvoices
2176
+ */
2177
+ readonly pageSize?: number
2178
+
2179
+ /**
2180
+ * 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.
2181
+ * @type {string}
2182
+ * @memberof CustomerControllerRestApiListInvoices
2183
+ */
2184
+ readonly pageToken?: string
2185
+
2186
+ /**
2187
+ * Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
2188
+ * @type {string}
2189
+ * @memberof CustomerControllerRestApiListInvoices
2190
+ */
2191
+ readonly filter?: string
2192
+
2193
+ /**
2194
+ * To search the list by any field, pass search&#x3D;xxx to fetch the result.
2195
+ * @type {string}
2196
+ * @memberof CustomerControllerRestApiListInvoices
2197
+ */
2198
+ readonly search?: string
2199
+
2200
+ /**
2201
+ * 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.
2202
+ * @type {string}
2203
+ * @memberof CustomerControllerRestApiListInvoices
2204
+ */
2205
+ readonly order?: string
2206
+
2207
+ /**
2208
+ * 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.
2209
+ * @type {string}
2210
+ * @memberof CustomerControllerRestApiListInvoices
2211
+ */
2212
+ readonly expand?: string
2213
+
2214
+ /**
2215
+ * 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.
2216
+ * @type {string}
2217
+ * @memberof CustomerControllerRestApiListInvoices
2218
+ */
2219
+ readonly filters?: string
2220
+
2221
+ /**
2222
+ * Bearer Token: provided by the login endpoint under the name accessToken.
2223
+ * @type {string}
2224
+ * @memberof CustomerControllerRestApiListInvoices
2225
+ */
2226
+ readonly authorization?: string
2227
+ }
2228
+
2229
+ /**
2230
+ * Request parameters for refreshToken operation in CustomerControllerRestApi.
2231
+ * @export
2232
+ * @interface CustomerControllerRestApiRefreshTokenRequest
2233
+ */
2234
+ export interface CustomerControllerRestApiRefreshTokenRequest {
2235
+ /**
2236
+ *
2237
+ * @type {RefreshTokenDto}
2238
+ * @memberof CustomerControllerRestApiRefreshToken
2239
+ */
2240
+ readonly refreshTokenDto: RefreshTokenDto
2241
+
2242
+ /**
2243
+ * HTTP only cookie that was sent during login.
2244
+ * @type {string}
2245
+ * @memberof CustomerControllerRestApiRefreshToken
2246
+ */
2247
+ readonly cookie?: string
2248
+ }
2249
+
2250
+ /**
2251
+ * Request parameters for requestChangeEmailByCustomer operation in CustomerControllerRestApi.
2252
+ * @export
2253
+ * @interface CustomerControllerRestApiRequestChangeEmailByCustomerRequest
2254
+ */
2255
+ export interface CustomerControllerRestApiRequestChangeEmailByCustomerRequest {
2256
+ /**
2257
+ * The customer code or \&quot;me\&quot; for the currently logged in customer.
2258
+ * @type {string}
2259
+ * @memberof CustomerControllerRestApiRequestChangeEmailByCustomer
2260
+ */
2261
+ readonly customerCode: string
2262
+
2263
+ /**
2264
+ *
2265
+ * @type {RequestChangeEmailByCustomerRequestDto}
2266
+ * @memberof CustomerControllerRestApiRequestChangeEmailByCustomer
2267
+ */
2268
+ readonly requestChangeEmailByCustomerRequestDto: RequestChangeEmailByCustomerRequestDto
2269
+
2270
+ /**
2271
+ * Bearer Token: provided by the login endpoint under the name accessToken.
2272
+ * @type {string}
2273
+ * @memberof CustomerControllerRestApiRequestChangeEmailByCustomer
2274
+ */
2275
+ readonly authorization?: string
2276
+ }
2277
+
2278
+ /**
2279
+ * Request parameters for resetPassword operation in CustomerControllerRestApi.
2280
+ * @export
2281
+ * @interface CustomerControllerRestApiResetPasswordRequest
2282
+ */
2283
+ export interface CustomerControllerRestApiResetPasswordRequest {
2284
+ /**
2285
+ *
2286
+ * @type {ResetPasswordByCustomerRequestDto}
2287
+ * @memberof CustomerControllerRestApiResetPassword
2288
+ */
2289
+ readonly resetPasswordByCustomerRequestDto: ResetPasswordByCustomerRequestDto
2290
+ }
2291
+
2292
+ /**
2293
+ * Request parameters for respondToAuthChallenge operation in CustomerControllerRestApi.
2294
+ * @export
2295
+ * @interface CustomerControllerRestApiRespondToAuthChallengeRequest
2296
+ */
2297
+ export interface CustomerControllerRestApiRespondToAuthChallengeRequest {
2298
+ /**
2299
+ *
2300
+ * @type {RespondToAuthChallengeRequestDto}
2301
+ * @memberof CustomerControllerRestApiRespondToAuthChallenge
2302
+ */
2303
+ readonly respondToAuthChallengeRequestDto: RespondToAuthChallengeRequestDto
2304
+ }
2305
+
2306
+ /**
2307
+ * Request parameters for updateCustomer operation in CustomerControllerRestApi.
2308
+ * @export
2309
+ * @interface CustomerControllerRestApiUpdateCustomerRequest
2310
+ */
2311
+ export interface CustomerControllerRestApiUpdateCustomerRequest {
2312
+ /**
2313
+ * The customer code or \&quot;me\&quot; for the currently logged in customer.
2314
+ * @type {string}
2315
+ * @memberof CustomerControllerRestApiUpdateCustomer
2316
+ */
2317
+ readonly customerCode: string
2318
+
2319
+ /**
2320
+ *
2321
+ * @type {UpdateCustomerRequestDto}
2322
+ * @memberof CustomerControllerRestApiUpdateCustomer
2323
+ */
2324
+ readonly updateCustomerRequestDto: UpdateCustomerRequestDto
2325
+
2326
+ /**
2327
+ * Bearer Token: provided by the login endpoint under the name accessToken.
2328
+ * @type {string}
2329
+ * @memberof CustomerControllerRestApiUpdateCustomer
2330
+ */
2331
+ readonly authorization?: string
2332
+ }
2333
+
2334
+ /**
2335
+ * Request parameters for uploadAccountDocuments operation in CustomerControllerRestApi.
2336
+ * @export
2337
+ * @interface CustomerControllerRestApiUploadAccountDocumentsRequest
2338
+ */
2339
+ export interface CustomerControllerRestApiUploadAccountDocumentsRequest {
2340
+ /**
2341
+ *
2342
+ * @type {string}
2343
+ * @memberof CustomerControllerRestApiUploadAccountDocuments
2344
+ */
2345
+ readonly customerCode: string
2346
+
2347
+ /**
2348
+ *
2349
+ * @type {UploadAccountDocumentsRequestDto}
2350
+ * @memberof CustomerControllerRestApiUploadAccountDocuments
2351
+ */
2352
+ readonly uploadAccountDocumentsRequestDto: UploadAccountDocumentsRequestDto
2353
+ }
2354
+
2355
+ /**
2356
+ * Request parameters for verifyChangeEmailToken operation in CustomerControllerRestApi.
2357
+ * @export
2358
+ * @interface CustomerControllerRestApiVerifyChangeEmailTokenRequest
2359
+ */
2360
+ export interface CustomerControllerRestApiVerifyChangeEmailTokenRequest {
2361
+ /**
2362
+ *
2363
+ * @type {VerifyChangeEmailTokenRequestDto}
2364
+ * @memberof CustomerControllerRestApiVerifyChangeEmailToken
2365
+ */
2366
+ readonly verifyChangeEmailTokenRequestDto: VerifyChangeEmailTokenRequestDto
2367
+
2368
+ /**
2369
+ * Bearer Token: provided by the login endpoint under the name accessToken.
2370
+ * @type {string}
2371
+ * @memberof CustomerControllerRestApiVerifyChangeEmailToken
2372
+ */
2373
+ readonly authorization?: string
2374
+ }
2375
+
2376
+ /**
2377
+ * Request parameters for verifyInvite operation in CustomerControllerRestApi.
2378
+ * @export
2379
+ * @interface CustomerControllerRestApiVerifyInviteRequest
2380
+ */
2381
+ export interface CustomerControllerRestApiVerifyInviteRequest {
2382
+ /**
2383
+ * Invite token sent to the customer
2384
+ * @type {string}
2385
+ * @memberof CustomerControllerRestApiVerifyInvite
2386
+ */
2387
+ readonly inviteToken: string
2388
+ }
2389
+
2390
+ /**
2391
+ * Request parameters for verifyResetPasswordToken operation in CustomerControllerRestApi.
2392
+ * @export
2393
+ * @interface CustomerControllerRestApiVerifyResetPasswordTokenRequest
2394
+ */
2395
+ export interface CustomerControllerRestApiVerifyResetPasswordTokenRequest {
2396
+ /**
2397
+ * reset password token
2398
+ * @type {string}
2399
+ * @memberof CustomerControllerRestApiVerifyResetPasswordToken
2400
+ */
2401
+ readonly resetToken: string
2402
+ }
2403
+
2404
+ /**
2405
+ * CustomerControllerRestApi - object-oriented interface
2406
+ * @export
2407
+ * @class CustomerControllerRestApi
2408
+ * @extends {BaseAPI}
2409
+ */
2410
+ export class CustomerControllerRestApi extends BaseAPI {
2411
+ /**
2412
+ * Change customer\'s email using the token provided by the request email change endpoint.
2413
+ * @summary Change customer email
2414
+ * @param {CustomerControllerRestApiChangeCustomerEmailRequest} requestParameters Request parameters.
2415
+ * @param {*} [options] Override http request option.
2416
+ * @throws {RequiredError}
2417
+ * @memberof CustomerControllerRestApi
2418
+ */
2419
+ public changeCustomerEmail(requestParameters: CustomerControllerRestApiChangeCustomerEmailRequest, options?: AxiosRequestConfig) {
2420
+ return CustomerControllerRestApiFp(this.configuration).changeCustomerEmail(requestParameters.changeCustomerEmailRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2421
+ }
2422
+
2423
+ /**
2424
+ * Change the customer password. Please use forgot-password endpoint if current password is lost.
2425
+ * @summary Change customer password
2426
+ * @param {CustomerControllerRestApiChangePasswordRequest} requestParameters Request parameters.
2427
+ * @param {*} [options] Override http request option.
2428
+ * @throws {RequiredError}
2429
+ * @memberof CustomerControllerRestApi
2430
+ */
2431
+ public changePassword(requestParameters: CustomerControllerRestApiChangePasswordRequest, options?: AxiosRequestConfig) {
2432
+ return CustomerControllerRestApiFp(this.configuration).changePassword(requestParameters.customerCode, requestParameters.changePasswordRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2433
+ }
2434
+
2435
+ /**
2436
+ * Request to complete a payment change by customer.
2437
+ * @summary Request payment setup complete
2438
+ * @param {CustomerControllerRestApiCompletePaymentSetupRequest} requestParameters Request parameters.
2439
+ * @param {*} [options] Override http request option.
2440
+ * @throws {RequiredError}
2441
+ * @memberof CustomerControllerRestApi
2442
+ */
2443
+ public completePaymentSetup(requestParameters: CustomerControllerRestApiCompletePaymentSetupRequest, options?: AxiosRequestConfig) {
2444
+ return CustomerControllerRestApiFp(this.configuration).completePaymentSetup(requestParameters.customerCode, requestParameters.completePaymentSetupPspRequest, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2445
+ }
2446
+
2447
+ /**
2448
+ * Register a customer using the invite token sent to customer\'s email address. Customer can set a new password for his account created during booking a policy.
2449
+ * @summary Register a customer after invite
2450
+ * @param {CustomerControllerRestApiCreateCustomerRequest} requestParameters Request parameters.
2451
+ * @param {*} [options] Override http request option.
2452
+ * @throws {RequiredError}
2453
+ * @memberof CustomerControllerRestApi
2454
+ */
2455
+ public createCustomer(requestParameters: CustomerControllerRestApiCreateCustomerRequest, options?: AxiosRequestConfig) {
2456
+ return CustomerControllerRestApiFp(this.configuration).createCustomer(requestParameters.createCustomerRequestDto, options).then((request) => request(this.axios, this.basePath));
2457
+ }
2458
+
2459
+ /**
2460
+ * Send a customer a reset-password token via email.
2461
+ * @summary Forgot password by customer
2462
+ * @param {CustomerControllerRestApiForgotPasswordRequest} requestParameters Request parameters.
2463
+ * @param {*} [options] Override http request option.
2464
+ * @throws {RequiredError}
2465
+ * @memberof CustomerControllerRestApi
2466
+ */
2467
+ public forgotPassword(requestParameters: CustomerControllerRestApiForgotPasswordRequest, options?: AxiosRequestConfig) {
2468
+ return CustomerControllerRestApiFp(this.configuration).forgotPassword(requestParameters.forgotPasswordRequestDto, options).then((request) => request(this.axios, this.basePath));
2469
+ }
2470
+
2471
+ /**
2472
+ * Get customer details.
2473
+ * @summary Get customer details
2474
+ * @param {CustomerControllerRestApiGetCustomerRequest} requestParameters Request parameters.
2475
+ * @param {*} [options] Override http request option.
2476
+ * @throws {RequiredError}
2477
+ * @memberof CustomerControllerRestApi
2478
+ */
2479
+ public getCustomer(requestParameters: CustomerControllerRestApiGetCustomerRequest, options?: AxiosRequestConfig) {
2480
+ return CustomerControllerRestApiFp(this.configuration).getCustomer(requestParameters.customerCode, requestParameters.expand, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2481
+ }
2482
+
2483
+ /**
2484
+ * Get a presigned download url for document.
2485
+ * @summary Get a download url for document
2486
+ * @param {CustomerControllerRestApiGetCustomerDocumentDownloadUrlRequest} requestParameters Request parameters.
2487
+ * @param {*} [options] Override http request option.
2488
+ * @throws {RequiredError}
2489
+ * @memberof CustomerControllerRestApi
2490
+ */
2491
+ public getCustomerDocumentDownloadUrl(requestParameters: CustomerControllerRestApiGetCustomerDocumentDownloadUrlRequest, options?: AxiosRequestConfig) {
2492
+ return CustomerControllerRestApiFp(this.configuration).getCustomerDocumentDownloadUrl(requestParameters.documentCode, requestParameters.customerCode, requestParameters.contentDisposition, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2493
+ }
2494
+
2495
+ /**
2496
+ * Start auth process to get new access token, refresh token after successful login.
2497
+ * @summary Initiate auth by customer
2498
+ * @param {CustomerControllerRestApiInitiateAuthRequest} requestParameters Request parameters.
2499
+ * @param {*} [options] Override http request option.
2500
+ * @throws {RequiredError}
2501
+ * @memberof CustomerControllerRestApi
2502
+ */
2503
+ public initiateAuth(requestParameters: CustomerControllerRestApiInitiateAuthRequest, options?: AxiosRequestConfig) {
2504
+ return CustomerControllerRestApiFp(this.configuration).initiateAuth(requestParameters.initiateAuthRequestDto, options).then((request) => request(this.axios, this.basePath));
2505
+ }
2506
+
2507
+ /**
2508
+ * Request to initiate a payment change by customer.
2509
+ * @summary Request payment setup initiation
2510
+ * @param {CustomerControllerRestApiInitiatePaymentSetupRequest} requestParameters Request parameters.
2511
+ * @param {*} [options] Override http request option.
2512
+ * @throws {RequiredError}
2513
+ * @memberof CustomerControllerRestApi
2514
+ */
2515
+ public initiatePaymentSetup(requestParameters: CustomerControllerRestApiInitiatePaymentSetupRequest, options?: AxiosRequestConfig) {
2516
+ return CustomerControllerRestApiFp(this.configuration).initiatePaymentSetup(requestParameters.customerCode, requestParameters.initiatePaymentSetupRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2517
+ }
2518
+
2519
+ /**
2520
+ * Send a customer an invite via email to register. An account should have been created before inviting the customer. To invite users without accounts and policies is not yet supported.
2521
+ * @summary Invite a customer by self
2522
+ * @param {CustomerControllerRestApiInviteByCustomerRequest} requestParameters Request parameters.
2523
+ * @param {*} [options] Override http request option.
2524
+ * @throws {RequiredError}
2525
+ * @memberof CustomerControllerRestApi
2526
+ */
2527
+ public inviteByCustomer(requestParameters: CustomerControllerRestApiInviteByCustomerRequest, options?: AxiosRequestConfig) {
2528
+ return CustomerControllerRestApiFp(this.configuration).inviteByCustomer(requestParameters.inviteByCustomerRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2529
+ }
2530
+
2531
+ /**
2532
+ * Send a customer an invite via email to register. An account should have been created before inviting the customer. To invite users without accounts and policies is not yet supported. **Required Permissions** \"customer-management.customers.create\"
2533
+ * @summary Invite a customer by tenant
2534
+ * @param {CustomerControllerRestApiInviteByTenantRequest} requestParameters Request parameters.
2535
+ * @param {*} [options] Override http request option.
2536
+ * @throws {RequiredError}
2537
+ * @memberof CustomerControllerRestApi
2538
+ */
2539
+ public inviteByTenant(requestParameters: CustomerControllerRestApiInviteByTenantRequest, options?: AxiosRequestConfig) {
2540
+ return CustomerControllerRestApiFp(this.configuration).inviteByTenant(requestParameters.inviteByTenantRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2541
+ }
2542
+
2543
+ /**
2544
+ * Get customer list.
2545
+ * @summary Get customers list
2546
+ * @param {CustomerControllerRestApiListCustomersRequest} requestParameters Request parameters.
2547
+ * @param {*} [options] Override http request option.
2548
+ * @throws {RequiredError}
2549
+ * @memberof CustomerControllerRestApi
2550
+ */
2551
+ public listCustomers(requestParameters: CustomerControllerRestApiListCustomersRequest = {}, options?: AxiosRequestConfig) {
2552
+ return CustomerControllerRestApiFp(this.configuration).listCustomers(requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2553
+ }
2554
+
2555
+ /**
2556
+ * List all the documents of a customer.
2557
+ * @summary List documents of a customer
2558
+ * @param {CustomerControllerRestApiListDocumentsRequest} requestParameters Request parameters.
2559
+ * @param {*} [options] Override http request option.
2560
+ * @throws {RequiredError}
2561
+ * @memberof CustomerControllerRestApi
2562
+ */
2563
+ public listDocuments(requestParameters: CustomerControllerRestApiListDocumentsRequest, options?: AxiosRequestConfig) {
2564
+ return CustomerControllerRestApiFp(this.configuration).listDocuments(requestParameters.customerCode, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2565
+ }
2566
+
2567
+ /**
2568
+ * List all the invoices of a customer.
2569
+ * @summary List invoices of a customer
2570
+ * @param {CustomerControllerRestApiListInvoicesRequest} requestParameters Request parameters.
2571
+ * @param {*} [options] Override http request option.
2572
+ * @throws {RequiredError}
2573
+ * @memberof CustomerControllerRestApi
2574
+ */
2575
+ public listInvoices(requestParameters: CustomerControllerRestApiListInvoicesRequest, options?: AxiosRequestConfig) {
2576
+ return CustomerControllerRestApiFp(this.configuration).listInvoices(requestParameters.customerCode, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2577
+ }
2578
+
2579
+ /**
2580
+ * Get new access token, new refresh token.
2581
+ * @summary Refresh token by customer
2582
+ * @param {CustomerControllerRestApiRefreshTokenRequest} requestParameters Request parameters.
2583
+ * @param {*} [options] Override http request option.
2584
+ * @throws {RequiredError}
2585
+ * @memberof CustomerControllerRestApi
2586
+ */
2587
+ public refreshToken(requestParameters: CustomerControllerRestApiRefreshTokenRequest, options?: AxiosRequestConfig) {
2588
+ return CustomerControllerRestApiFp(this.configuration).refreshToken(requestParameters.refreshTokenDto, requestParameters.cookie, options).then((request) => request(this.axios, this.basePath));
2589
+ }
2590
+
2591
+ /**
2592
+ * Request a token to change the email address for the customer.
2593
+ * @summary Request customer email change
2594
+ * @param {CustomerControllerRestApiRequestChangeEmailByCustomerRequest} requestParameters Request parameters.
2595
+ * @param {*} [options] Override http request option.
2596
+ * @throws {RequiredError}
2597
+ * @memberof CustomerControllerRestApi
2598
+ */
2599
+ public requestChangeEmailByCustomer(requestParameters: CustomerControllerRestApiRequestChangeEmailByCustomerRequest, options?: AxiosRequestConfig) {
2600
+ return CustomerControllerRestApiFp(this.configuration).requestChangeEmailByCustomer(requestParameters.customerCode, requestParameters.requestChangeEmailByCustomerRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2601
+ }
2602
+
2603
+ /**
2604
+ * Change customer\'s password using the token provided by the reset password endpoint.
2605
+ * @summary Change password by customer
2606
+ * @param {CustomerControllerRestApiResetPasswordRequest} requestParameters Request parameters.
2607
+ * @param {*} [options] Override http request option.
2608
+ * @throws {RequiredError}
2609
+ * @memberof CustomerControllerRestApi
2610
+ */
2611
+ public resetPassword(requestParameters: CustomerControllerRestApiResetPasswordRequest, options?: AxiosRequestConfig) {
2612
+ return CustomerControllerRestApiFp(this.configuration).resetPassword(requestParameters.resetPasswordByCustomerRequestDto, options).then((request) => request(this.axios, this.basePath));
2613
+ }
2614
+
2615
+ /**
2616
+ * Respond to the auth challenge by customer to get new access token, refresh token after successful login.
2617
+ * @summary Respond to auth challenge
2618
+ * @param {CustomerControllerRestApiRespondToAuthChallengeRequest} requestParameters Request parameters.
2619
+ * @param {*} [options] Override http request option.
2620
+ * @throws {RequiredError}
2621
+ * @memberof CustomerControllerRestApi
2622
+ */
2623
+ public respondToAuthChallenge(requestParameters: CustomerControllerRestApiRespondToAuthChallengeRequest, options?: AxiosRequestConfig) {
2624
+ return CustomerControllerRestApiFp(this.configuration).respondToAuthChallenge(requestParameters.respondToAuthChallengeRequestDto, options).then((request) => request(this.axios, this.basePath));
2625
+ }
2626
+
2627
+ /**
2628
+ * Update customer details like phone, names, addresses etc. To change email, please use Request customer email change endpoint instead.
2629
+ * @summary Update customer details
2630
+ * @param {CustomerControllerRestApiUpdateCustomerRequest} requestParameters Request parameters.
2631
+ * @param {*} [options] Override http request option.
2632
+ * @throws {RequiredError}
2633
+ * @memberof CustomerControllerRestApi
2634
+ */
2635
+ public updateCustomer(requestParameters: CustomerControllerRestApiUpdateCustomerRequest, options?: AxiosRequestConfig) {
2636
+ return CustomerControllerRestApiFp(this.configuration).updateCustomer(requestParameters.customerCode, requestParameters.updateCustomerRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2637
+ }
2638
+
2639
+ /**
2640
+ * API to upload and attach documents to an account.
2641
+ * @summary Upload account documents
2642
+ * @param {CustomerControllerRestApiUploadAccountDocumentsRequest} requestParameters Request parameters.
2643
+ * @param {*} [options] Override http request option.
2644
+ * @throws {RequiredError}
2645
+ * @memberof CustomerControllerRestApi
2646
+ */
2647
+ public uploadAccountDocuments(requestParameters: CustomerControllerRestApiUploadAccountDocumentsRequest, options?: AxiosRequestConfig) {
2648
+ return CustomerControllerRestApiFp(this.configuration).uploadAccountDocuments(requestParameters.customerCode, requestParameters.uploadAccountDocumentsRequestDto, options).then((request) => request(this.axios, this.basePath));
2649
+ }
2650
+
2651
+ /**
2652
+ * Verify the change email token that is sent by calling the request change email endpoint.
2653
+ * @summary Verify the change email token
2654
+ * @param {CustomerControllerRestApiVerifyChangeEmailTokenRequest} requestParameters Request parameters.
2655
+ * @param {*} [options] Override http request option.
2656
+ * @throws {RequiredError}
2657
+ * @memberof CustomerControllerRestApi
2658
+ */
2659
+ public verifyChangeEmailToken(requestParameters: CustomerControllerRestApiVerifyChangeEmailTokenRequest, options?: AxiosRequestConfig) {
2660
+ return CustomerControllerRestApiFp(this.configuration).verifyChangeEmailToken(requestParameters.verifyChangeEmailTokenRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
2661
+ }
2662
+
2663
+ /**
2664
+ * Verify the invite sent to the customer via email.
2665
+ * @summary Verify customer\'s invite token
2666
+ * @param {CustomerControllerRestApiVerifyInviteRequest} requestParameters Request parameters.
2667
+ * @param {*} [options] Override http request option.
2668
+ * @throws {RequiredError}
2669
+ * @memberof CustomerControllerRestApi
2670
+ */
2671
+ public verifyInvite(requestParameters: CustomerControllerRestApiVerifyInviteRequest, options?: AxiosRequestConfig) {
2672
+ return CustomerControllerRestApiFp(this.configuration).verifyInvite(requestParameters.inviteToken, options).then((request) => request(this.axios, this.basePath));
2673
+ }
2674
+
2675
+ /**
2676
+ * Verify the reset password token that is sent by calling the \'forgot password\' endpoint.
2677
+ * @summary Verify a reset password token
2678
+ * @param {CustomerControllerRestApiVerifyResetPasswordTokenRequest} requestParameters Request parameters.
2679
+ * @param {*} [options] Override http request option.
2680
+ * @throws {RequiredError}
2681
+ * @memberof CustomerControllerRestApi
2682
+ */
2683
+ public verifyResetPasswordToken(requestParameters: CustomerControllerRestApiVerifyResetPasswordTokenRequest, options?: AxiosRequestConfig) {
2684
+ return CustomerControllerRestApiFp(this.configuration).verifyResetPasswordToken(requestParameters.resetToken, options).then((request) => request(this.axios, this.basePath));
2685
+ }
2686
+ }