@emilgroup/insurance-sdk 1.24.1 → 1.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.openapi-generator/FILES +4 -0
- package/README.md +2 -2
- package/api/leads-api.ts +326 -0
- package/api/premium-formulas-api.ts +107 -0
- package/api/products-api.ts +122 -4
- package/dist/api/leads-api.d.ts +176 -0
- package/dist/api/leads-api.js +285 -0
- package/dist/api/premium-formulas-api.d.ts +57 -0
- package/dist/api/premium-formulas-api.js +93 -0
- package/dist/api/products-api.d.ts +68 -4
- package/dist/api/products-api.js +103 -3
- package/dist/models/create-lead-async-response-class.d.ts +24 -0
- package/dist/models/create-lead-async-response-class.js +15 -0
- package/dist/models/create-lead-policy-request-dto.d.ts +1 -1
- package/dist/models/create-lead-request-dto.d.ts +7 -7
- package/dist/models/create-lead-sync-response-class.d.ts +24 -0
- package/dist/models/create-lead-sync-response-class.js +15 -0
- package/dist/models/create-premium-formula-request-dto.d.ts +12 -0
- package/dist/models/empty-response-class.d.ts +24 -0
- package/dist/models/empty-response-class.js +15 -0
- package/dist/models/get-product-request-dto.d.ts +10 -4
- package/dist/models/grpc-patch-lead-request-dto.d.ts +1 -1
- package/dist/models/grpc-update-lead-request-dto.d.ts +7 -7
- package/dist/models/index.d.ts +4 -0
- package/dist/models/index.js +4 -0
- package/dist/models/lead-class.d.ts +6 -0
- package/dist/models/list-leads-response-class.d.ts +12 -0
- package/dist/models/list-policies-response-class.d.ts +12 -0
- package/dist/models/patch-lead-request-dto.d.ts +1 -1
- package/dist/models/policy-object-dto.d.ts +1 -1
- package/dist/models/premium-formula-class.d.ts +12 -0
- package/dist/models/shared-create-lead-policy-request-dto.d.ts +1 -1
- package/dist/models/shared-lead-policy-object-dto.d.ts +1 -1
- package/dist/models/shared-update-premium-formula-request-dto.d.ts +12 -0
- package/dist/models/swap-premium-formulas-order-request-dto.d.ts +30 -0
- package/dist/models/swap-premium-formulas-order-request-dto.js +15 -0
- package/dist/models/update-lead-request-dto.d.ts +7 -7
- package/dist/models/update-premium-formula-request-dto.d.ts +12 -0
- package/models/create-lead-async-response-class.ts +30 -0
- package/models/create-lead-policy-request-dto.ts +1 -1
- package/models/create-lead-request-dto.ts +7 -7
- package/models/create-lead-sync-response-class.ts +30 -0
- package/models/create-premium-formula-request-dto.ts +12 -0
- package/models/empty-response-class.ts +30 -0
- package/models/get-product-request-dto.ts +10 -4
- package/models/grpc-patch-lead-request-dto.ts +1 -1
- package/models/grpc-update-lead-request-dto.ts +7 -7
- package/models/index.ts +4 -0
- package/models/lead-class.ts +6 -0
- package/models/list-leads-response-class.ts +12 -0
- package/models/list-policies-response-class.ts +12 -0
- package/models/patch-lead-request-dto.ts +1 -1
- package/models/policy-object-dto.ts +1 -1
- package/models/premium-formula-class.ts +12 -0
- package/models/shared-create-lead-policy-request-dto.ts +1 -1
- package/models/shared-lead-policy-object-dto.ts +1 -1
- package/models/shared-update-premium-formula-request-dto.ts +12 -0
- package/models/swap-premium-formulas-order-request-dto.ts +36 -0
- package/models/update-lead-request-dto.ts +7 -7
- package/models/update-premium-formula-request-dto.ts +12 -0
- package/package.json +1 -1
package/.openapi-generator/FILES
CHANGED
|
@@ -29,11 +29,13 @@ models/create-custom-application-request-dto.ts
|
|
|
29
29
|
models/create-dummy-policy-request-dto.ts
|
|
30
30
|
models/create-insured-object-request-dto.ts
|
|
31
31
|
models/create-insured-object-response-class.ts
|
|
32
|
+
models/create-lead-async-response-class.ts
|
|
32
33
|
models/create-lead-policy-request-dto.ts
|
|
33
34
|
models/create-lead-request-dto.ts
|
|
34
35
|
models/create-lead-response-class.ts
|
|
35
36
|
models/create-lead-status-request-dto.ts
|
|
36
37
|
models/create-lead-status-response-class.ts
|
|
38
|
+
models/create-lead-sync-response-class.ts
|
|
37
39
|
models/create-named-range-request-dto.ts
|
|
38
40
|
models/create-named-range-response-class.ts
|
|
39
41
|
models/create-named-request-s3-data-class.ts
|
|
@@ -49,6 +51,7 @@ models/create-product-response-class.ts
|
|
|
49
51
|
models/csv-product-factor-dto.ts
|
|
50
52
|
models/delete-request-dto.ts
|
|
51
53
|
models/delete-response-class.ts
|
|
54
|
+
models/empty-response-class.ts
|
|
52
55
|
models/get-insured-object-response-class.ts
|
|
53
56
|
models/get-lead-response-class.ts
|
|
54
57
|
models/get-lead-status-response-class.ts
|
|
@@ -126,6 +129,7 @@ models/store-product-factors-request-dto.ts
|
|
|
126
129
|
models/store-product-factors-response-class.ts
|
|
127
130
|
models/suspend-policy-request-dto.ts
|
|
128
131
|
models/suspend-policy-response-class.ts
|
|
132
|
+
models/swap-premium-formulas-order-request-dto.ts
|
|
129
133
|
models/terminate-policy-request-dto.ts
|
|
130
134
|
models/terminate-policy-response-class.ts
|
|
131
135
|
models/timeslice-class.ts
|
package/README.md
CHANGED
|
@@ -17,11 +17,11 @@ Although this package can be used in both TypeScript and JavaScript, it is inten
|
|
|
17
17
|
Navigate to the folder of your consuming project and run one of the following commands:
|
|
18
18
|
|
|
19
19
|
```
|
|
20
|
-
npm install @emilgroup/insurance-sdk@1.
|
|
20
|
+
npm install @emilgroup/insurance-sdk@1.25.0 --save
|
|
21
21
|
```
|
|
22
22
|
or
|
|
23
23
|
```
|
|
24
|
-
yarn add @emilgroup/insurance-sdk@1.
|
|
24
|
+
yarn add @emilgroup/insurance-sdk@1.25.0
|
|
25
25
|
```
|
|
26
26
|
|
|
27
27
|
And then you can import `PoliciesApi`.
|
package/api/leads-api.ts
CHANGED
|
@@ -21,10 +21,14 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj
|
|
|
21
21
|
// @ts-ignore
|
|
22
22
|
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from '../base';
|
|
23
23
|
// @ts-ignore
|
|
24
|
+
import { CreateLeadAsyncResponseClass } from '../models';
|
|
25
|
+
// @ts-ignore
|
|
24
26
|
import { CreateLeadRequestDto } from '../models';
|
|
25
27
|
// @ts-ignore
|
|
26
28
|
import { CreateLeadResponseClass } from '../models';
|
|
27
29
|
// @ts-ignore
|
|
30
|
+
import { CreateLeadSyncResponseClass } from '../models';
|
|
31
|
+
// @ts-ignore
|
|
28
32
|
import { GetLeadResponseClass } from '../models';
|
|
29
33
|
// @ts-ignore
|
|
30
34
|
import { ListLeadsResponseClass } from '../models';
|
|
@@ -77,6 +81,100 @@ export const LeadsApiAxiosParamCreator = function (configuration?: Configuration
|
|
|
77
81
|
|
|
78
82
|
|
|
79
83
|
|
|
84
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
85
|
+
|
|
86
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
87
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
88
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
89
|
+
localVarRequestOptions.data = serializeDataIfNeeded(createLeadRequestDto, localVarRequestOptions, configuration)
|
|
90
|
+
|
|
91
|
+
return {
|
|
92
|
+
url: toPathString(localVarUrlObj),
|
|
93
|
+
options: localVarRequestOptions,
|
|
94
|
+
};
|
|
95
|
+
},
|
|
96
|
+
/**
|
|
97
|
+
* This will send the lead to the queue for creation. Should be used when creating multiple leads at the same time - also called \'batch processing\'.
|
|
98
|
+
* @summary Create the lead asynchronously
|
|
99
|
+
* @param {CreateLeadRequestDto} createLeadRequestDto
|
|
100
|
+
* @param {string} [authorization] Bearer Token
|
|
101
|
+
* @param {*} [options] Override http request option.
|
|
102
|
+
* @throws {RequiredError}
|
|
103
|
+
*/
|
|
104
|
+
createLeadAsync: async (createLeadRequestDto: CreateLeadRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
105
|
+
// verify required parameter 'createLeadRequestDto' is not null or undefined
|
|
106
|
+
assertParamExists('createLeadAsync', 'createLeadRequestDto', createLeadRequestDto)
|
|
107
|
+
const localVarPath = `/insuranceservice/v1/leads-async`;
|
|
108
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
109
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
110
|
+
let baseOptions;
|
|
111
|
+
let baseAccessToken;
|
|
112
|
+
if (configuration) {
|
|
113
|
+
baseOptions = configuration.baseOptions;
|
|
114
|
+
baseAccessToken = configuration.accessToken;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
|
|
118
|
+
const localVarHeaderParameter = {} as any;
|
|
119
|
+
const localVarQueryParameter = {} as any;
|
|
120
|
+
|
|
121
|
+
// authentication bearer required
|
|
122
|
+
// http bearer authentication required
|
|
123
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
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(createLeadRequestDto, localVarRequestOptions, configuration)
|
|
137
|
+
|
|
138
|
+
return {
|
|
139
|
+
url: toPathString(localVarUrlObj),
|
|
140
|
+
options: localVarRequestOptions,
|
|
141
|
+
};
|
|
142
|
+
},
|
|
143
|
+
/**
|
|
144
|
+
* This endpoint initiates the creation of a lead, which is the initial step in a comprehensive workflow responsible for the creation of an account, policy, and banking information. Unlike the standard lead creation endpoint, this variant ensures that the process waits until the entire workflow is successfully completed before providing a response.
|
|
145
|
+
* @summary Create the lead
|
|
146
|
+
* @param {CreateLeadRequestDto} createLeadRequestDto
|
|
147
|
+
* @param {string} [authorization] Bearer Token
|
|
148
|
+
* @param {*} [options] Override http request option.
|
|
149
|
+
* @throws {RequiredError}
|
|
150
|
+
*/
|
|
151
|
+
createLeadSync: async (createLeadRequestDto: CreateLeadRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
152
|
+
// verify required parameter 'createLeadRequestDto' is not null or undefined
|
|
153
|
+
assertParamExists('createLeadSync', 'createLeadRequestDto', createLeadRequestDto)
|
|
154
|
+
const localVarPath = `/insuranceservice/v1/leads-sync`;
|
|
155
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
156
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
157
|
+
let baseOptions;
|
|
158
|
+
let baseAccessToken;
|
|
159
|
+
if (configuration) {
|
|
160
|
+
baseOptions = configuration.baseOptions;
|
|
161
|
+
baseAccessToken = configuration.accessToken;
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
|
|
165
|
+
const localVarHeaderParameter = {} as any;
|
|
166
|
+
const localVarQueryParameter = {} as any;
|
|
167
|
+
|
|
168
|
+
// authentication bearer required
|
|
169
|
+
// http bearer authentication required
|
|
170
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
171
|
+
|
|
172
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
173
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
|
|
177
|
+
|
|
80
178
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
81
179
|
|
|
82
180
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
@@ -300,6 +398,57 @@ export const LeadsApiAxiosParamCreator = function (configuration?: Configuration
|
|
|
300
398
|
|
|
301
399
|
|
|
302
400
|
|
|
401
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
402
|
+
|
|
403
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
404
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
405
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
406
|
+
localVarRequestOptions.data = serializeDataIfNeeded(updateLeadRequestDto, localVarRequestOptions, configuration)
|
|
407
|
+
|
|
408
|
+
return {
|
|
409
|
+
url: toPathString(localVarUrlObj),
|
|
410
|
+
options: localVarRequestOptions,
|
|
411
|
+
};
|
|
412
|
+
},
|
|
413
|
+
/**
|
|
414
|
+
* Updates the specified lead by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
|
|
415
|
+
* @summary Update the lead
|
|
416
|
+
* @param {string} code Unique identifier for the object.
|
|
417
|
+
* @param {UpdateLeadRequestDto} updateLeadRequestDto
|
|
418
|
+
* @param {string} [authorization] Bearer Token
|
|
419
|
+
* @param {*} [options] Override http request option.
|
|
420
|
+
* @throws {RequiredError}
|
|
421
|
+
*/
|
|
422
|
+
updateLeadSync: async (code: string, updateLeadRequestDto: UpdateLeadRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
423
|
+
// verify required parameter 'code' is not null or undefined
|
|
424
|
+
assertParamExists('updateLeadSync', 'code', code)
|
|
425
|
+
// verify required parameter 'updateLeadRequestDto' is not null or undefined
|
|
426
|
+
assertParamExists('updateLeadSync', 'updateLeadRequestDto', updateLeadRequestDto)
|
|
427
|
+
const localVarPath = `/insuranceservice/v1/leads-sync/{code}`
|
|
428
|
+
.replace(`{${"code"}}`, encodeURIComponent(String(code)));
|
|
429
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
430
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
431
|
+
let baseOptions;
|
|
432
|
+
let baseAccessToken;
|
|
433
|
+
if (configuration) {
|
|
434
|
+
baseOptions = configuration.baseOptions;
|
|
435
|
+
baseAccessToken = configuration.accessToken;
|
|
436
|
+
}
|
|
437
|
+
|
|
438
|
+
const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
|
|
439
|
+
const localVarHeaderParameter = {} as any;
|
|
440
|
+
const localVarQueryParameter = {} as any;
|
|
441
|
+
|
|
442
|
+
// authentication bearer required
|
|
443
|
+
// http bearer authentication required
|
|
444
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
445
|
+
|
|
446
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
447
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
|
|
451
|
+
|
|
303
452
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
304
453
|
|
|
305
454
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
@@ -334,6 +483,30 @@ export const LeadsApiFp = function(configuration?: Configuration) {
|
|
|
334
483
|
const localVarAxiosArgs = await localVarAxiosParamCreator.createLead(createLeadRequestDto, authorization, options);
|
|
335
484
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
336
485
|
},
|
|
486
|
+
/**
|
|
487
|
+
* This will send the lead to the queue for creation. Should be used when creating multiple leads at the same time - also called \'batch processing\'.
|
|
488
|
+
* @summary Create the lead asynchronously
|
|
489
|
+
* @param {CreateLeadRequestDto} createLeadRequestDto
|
|
490
|
+
* @param {string} [authorization] Bearer Token
|
|
491
|
+
* @param {*} [options] Override http request option.
|
|
492
|
+
* @throws {RequiredError}
|
|
493
|
+
*/
|
|
494
|
+
async createLeadAsync(createLeadRequestDto: CreateLeadRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateLeadAsyncResponseClass>> {
|
|
495
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.createLeadAsync(createLeadRequestDto, authorization, options);
|
|
496
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
497
|
+
},
|
|
498
|
+
/**
|
|
499
|
+
* This endpoint initiates the creation of a lead, which is the initial step in a comprehensive workflow responsible for the creation of an account, policy, and banking information. Unlike the standard lead creation endpoint, this variant ensures that the process waits until the entire workflow is successfully completed before providing a response.
|
|
500
|
+
* @summary Create the lead
|
|
501
|
+
* @param {CreateLeadRequestDto} createLeadRequestDto
|
|
502
|
+
* @param {string} [authorization] Bearer Token
|
|
503
|
+
* @param {*} [options] Override http request option.
|
|
504
|
+
* @throws {RequiredError}
|
|
505
|
+
*/
|
|
506
|
+
async createLeadSync(createLeadRequestDto: CreateLeadRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateLeadSyncResponseClass>> {
|
|
507
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.createLeadSync(createLeadRequestDto, authorization, options);
|
|
508
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
509
|
+
},
|
|
337
510
|
/**
|
|
338
511
|
* Retrieves the details of the lead that was previously created. Supply the unique lead code that was returned when you created it and Emil Api will return the corresponding lead information.
|
|
339
512
|
* @summary Retrieve the lead
|
|
@@ -390,6 +563,19 @@ export const LeadsApiFp = function(configuration?: Configuration) {
|
|
|
390
563
|
const localVarAxiosArgs = await localVarAxiosParamCreator.updateLead(code, updateLeadRequestDto, authorization, options);
|
|
391
564
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
392
565
|
},
|
|
566
|
+
/**
|
|
567
|
+
* Updates the specified lead by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
|
|
568
|
+
* @summary Update the lead
|
|
569
|
+
* @param {string} code Unique identifier for the object.
|
|
570
|
+
* @param {UpdateLeadRequestDto} updateLeadRequestDto
|
|
571
|
+
* @param {string} [authorization] Bearer Token
|
|
572
|
+
* @param {*} [options] Override http request option.
|
|
573
|
+
* @throws {RequiredError}
|
|
574
|
+
*/
|
|
575
|
+
async updateLeadSync(code: string, updateLeadRequestDto: UpdateLeadRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UpdateLeadResponseClass>> {
|
|
576
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.updateLeadSync(code, updateLeadRequestDto, authorization, options);
|
|
577
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
578
|
+
},
|
|
393
579
|
}
|
|
394
580
|
};
|
|
395
581
|
|
|
@@ -411,6 +597,28 @@ export const LeadsApiFactory = function (configuration?: Configuration, basePath
|
|
|
411
597
|
createLead(createLeadRequestDto: CreateLeadRequestDto, authorization?: string, options?: any): AxiosPromise<CreateLeadResponseClass> {
|
|
412
598
|
return localVarFp.createLead(createLeadRequestDto, authorization, options).then((request) => request(axios, basePath));
|
|
413
599
|
},
|
|
600
|
+
/**
|
|
601
|
+
* This will send the lead to the queue for creation. Should be used when creating multiple leads at the same time - also called \'batch processing\'.
|
|
602
|
+
* @summary Create the lead asynchronously
|
|
603
|
+
* @param {CreateLeadRequestDto} createLeadRequestDto
|
|
604
|
+
* @param {string} [authorization] Bearer Token
|
|
605
|
+
* @param {*} [options] Override http request option.
|
|
606
|
+
* @throws {RequiredError}
|
|
607
|
+
*/
|
|
608
|
+
createLeadAsync(createLeadRequestDto: CreateLeadRequestDto, authorization?: string, options?: any): AxiosPromise<CreateLeadAsyncResponseClass> {
|
|
609
|
+
return localVarFp.createLeadAsync(createLeadRequestDto, authorization, options).then((request) => request(axios, basePath));
|
|
610
|
+
},
|
|
611
|
+
/**
|
|
612
|
+
* This endpoint initiates the creation of a lead, which is the initial step in a comprehensive workflow responsible for the creation of an account, policy, and banking information. Unlike the standard lead creation endpoint, this variant ensures that the process waits until the entire workflow is successfully completed before providing a response.
|
|
613
|
+
* @summary Create the lead
|
|
614
|
+
* @param {CreateLeadRequestDto} createLeadRequestDto
|
|
615
|
+
* @param {string} [authorization] Bearer Token
|
|
616
|
+
* @param {*} [options] Override http request option.
|
|
617
|
+
* @throws {RequiredError}
|
|
618
|
+
*/
|
|
619
|
+
createLeadSync(createLeadRequestDto: CreateLeadRequestDto, authorization?: string, options?: any): AxiosPromise<CreateLeadSyncResponseClass> {
|
|
620
|
+
return localVarFp.createLeadSync(createLeadRequestDto, authorization, options).then((request) => request(axios, basePath));
|
|
621
|
+
},
|
|
414
622
|
/**
|
|
415
623
|
* Retrieves the details of the lead that was previously created. Supply the unique lead code that was returned when you created it and Emil Api will return the corresponding lead information.
|
|
416
624
|
* @summary Retrieve the lead
|
|
@@ -463,6 +671,18 @@ export const LeadsApiFactory = function (configuration?: Configuration, basePath
|
|
|
463
671
|
updateLead(code: string, updateLeadRequestDto: UpdateLeadRequestDto, authorization?: string, options?: any): AxiosPromise<UpdateLeadResponseClass> {
|
|
464
672
|
return localVarFp.updateLead(code, updateLeadRequestDto, authorization, options).then((request) => request(axios, basePath));
|
|
465
673
|
},
|
|
674
|
+
/**
|
|
675
|
+
* Updates the specified lead by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
|
|
676
|
+
* @summary Update the lead
|
|
677
|
+
* @param {string} code Unique identifier for the object.
|
|
678
|
+
* @param {UpdateLeadRequestDto} updateLeadRequestDto
|
|
679
|
+
* @param {string} [authorization] Bearer Token
|
|
680
|
+
* @param {*} [options] Override http request option.
|
|
681
|
+
* @throws {RequiredError}
|
|
682
|
+
*/
|
|
683
|
+
updateLeadSync(code: string, updateLeadRequestDto: UpdateLeadRequestDto, authorization?: string, options?: any): AxiosPromise<UpdateLeadResponseClass> {
|
|
684
|
+
return localVarFp.updateLeadSync(code, updateLeadRequestDto, authorization, options).then((request) => request(axios, basePath));
|
|
685
|
+
},
|
|
466
686
|
};
|
|
467
687
|
};
|
|
468
688
|
|
|
@@ -487,6 +707,48 @@ export interface LeadsApiCreateLeadRequest {
|
|
|
487
707
|
readonly authorization?: string
|
|
488
708
|
}
|
|
489
709
|
|
|
710
|
+
/**
|
|
711
|
+
* Request parameters for createLeadAsync operation in LeadsApi.
|
|
712
|
+
* @export
|
|
713
|
+
* @interface LeadsApiCreateLeadAsyncRequest
|
|
714
|
+
*/
|
|
715
|
+
export interface LeadsApiCreateLeadAsyncRequest {
|
|
716
|
+
/**
|
|
717
|
+
*
|
|
718
|
+
* @type {CreateLeadRequestDto}
|
|
719
|
+
* @memberof LeadsApiCreateLeadAsync
|
|
720
|
+
*/
|
|
721
|
+
readonly createLeadRequestDto: CreateLeadRequestDto
|
|
722
|
+
|
|
723
|
+
/**
|
|
724
|
+
* Bearer Token
|
|
725
|
+
* @type {string}
|
|
726
|
+
* @memberof LeadsApiCreateLeadAsync
|
|
727
|
+
*/
|
|
728
|
+
readonly authorization?: string
|
|
729
|
+
}
|
|
730
|
+
|
|
731
|
+
/**
|
|
732
|
+
* Request parameters for createLeadSync operation in LeadsApi.
|
|
733
|
+
* @export
|
|
734
|
+
* @interface LeadsApiCreateLeadSyncRequest
|
|
735
|
+
*/
|
|
736
|
+
export interface LeadsApiCreateLeadSyncRequest {
|
|
737
|
+
/**
|
|
738
|
+
*
|
|
739
|
+
* @type {CreateLeadRequestDto}
|
|
740
|
+
* @memberof LeadsApiCreateLeadSync
|
|
741
|
+
*/
|
|
742
|
+
readonly createLeadRequestDto: CreateLeadRequestDto
|
|
743
|
+
|
|
744
|
+
/**
|
|
745
|
+
* Bearer Token
|
|
746
|
+
* @type {string}
|
|
747
|
+
* @memberof LeadsApiCreateLeadSync
|
|
748
|
+
*/
|
|
749
|
+
readonly authorization?: string
|
|
750
|
+
}
|
|
751
|
+
|
|
490
752
|
/**
|
|
491
753
|
* Request parameters for getLead operation in LeadsApi.
|
|
492
754
|
* @export
|
|
@@ -627,6 +889,34 @@ export interface LeadsApiUpdateLeadRequest {
|
|
|
627
889
|
readonly authorization?: string
|
|
628
890
|
}
|
|
629
891
|
|
|
892
|
+
/**
|
|
893
|
+
* Request parameters for updateLeadSync operation in LeadsApi.
|
|
894
|
+
* @export
|
|
895
|
+
* @interface LeadsApiUpdateLeadSyncRequest
|
|
896
|
+
*/
|
|
897
|
+
export interface LeadsApiUpdateLeadSyncRequest {
|
|
898
|
+
/**
|
|
899
|
+
* Unique identifier for the object.
|
|
900
|
+
* @type {string}
|
|
901
|
+
* @memberof LeadsApiUpdateLeadSync
|
|
902
|
+
*/
|
|
903
|
+
readonly code: string
|
|
904
|
+
|
|
905
|
+
/**
|
|
906
|
+
*
|
|
907
|
+
* @type {UpdateLeadRequestDto}
|
|
908
|
+
* @memberof LeadsApiUpdateLeadSync
|
|
909
|
+
*/
|
|
910
|
+
readonly updateLeadRequestDto: UpdateLeadRequestDto
|
|
911
|
+
|
|
912
|
+
/**
|
|
913
|
+
* Bearer Token
|
|
914
|
+
* @type {string}
|
|
915
|
+
* @memberof LeadsApiUpdateLeadSync
|
|
916
|
+
*/
|
|
917
|
+
readonly authorization?: string
|
|
918
|
+
}
|
|
919
|
+
|
|
630
920
|
/**
|
|
631
921
|
* LeadsApi - object-oriented interface
|
|
632
922
|
* @export
|
|
@@ -646,6 +936,30 @@ export class LeadsApi extends BaseAPI {
|
|
|
646
936
|
return LeadsApiFp(this.configuration).createLead(requestParameters.createLeadRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
647
937
|
}
|
|
648
938
|
|
|
939
|
+
/**
|
|
940
|
+
* This will send the lead to the queue for creation. Should be used when creating multiple leads at the same time - also called \'batch processing\'.
|
|
941
|
+
* @summary Create the lead asynchronously
|
|
942
|
+
* @param {LeadsApiCreateLeadAsyncRequest} requestParameters Request parameters.
|
|
943
|
+
* @param {*} [options] Override http request option.
|
|
944
|
+
* @throws {RequiredError}
|
|
945
|
+
* @memberof LeadsApi
|
|
946
|
+
*/
|
|
947
|
+
public createLeadAsync(requestParameters: LeadsApiCreateLeadAsyncRequest, options?: AxiosRequestConfig) {
|
|
948
|
+
return LeadsApiFp(this.configuration).createLeadAsync(requestParameters.createLeadRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
949
|
+
}
|
|
950
|
+
|
|
951
|
+
/**
|
|
952
|
+
* This endpoint initiates the creation of a lead, which is the initial step in a comprehensive workflow responsible for the creation of an account, policy, and banking information. Unlike the standard lead creation endpoint, this variant ensures that the process waits until the entire workflow is successfully completed before providing a response.
|
|
953
|
+
* @summary Create the lead
|
|
954
|
+
* @param {LeadsApiCreateLeadSyncRequest} requestParameters Request parameters.
|
|
955
|
+
* @param {*} [options] Override http request option.
|
|
956
|
+
* @throws {RequiredError}
|
|
957
|
+
* @memberof LeadsApi
|
|
958
|
+
*/
|
|
959
|
+
public createLeadSync(requestParameters: LeadsApiCreateLeadSyncRequest, options?: AxiosRequestConfig) {
|
|
960
|
+
return LeadsApiFp(this.configuration).createLeadSync(requestParameters.createLeadRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
961
|
+
}
|
|
962
|
+
|
|
649
963
|
/**
|
|
650
964
|
* Retrieves the details of the lead that was previously created. Supply the unique lead code that was returned when you created it and Emil Api will return the corresponding lead information.
|
|
651
965
|
* @summary Retrieve the lead
|
|
@@ -693,4 +1007,16 @@ export class LeadsApi extends BaseAPI {
|
|
|
693
1007
|
public updateLead(requestParameters: LeadsApiUpdateLeadRequest, options?: AxiosRequestConfig) {
|
|
694
1008
|
return LeadsApiFp(this.configuration).updateLead(requestParameters.code, requestParameters.updateLeadRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
695
1009
|
}
|
|
1010
|
+
|
|
1011
|
+
/**
|
|
1012
|
+
* Updates the specified lead by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
|
|
1013
|
+
* @summary Update the lead
|
|
1014
|
+
* @param {LeadsApiUpdateLeadSyncRequest} requestParameters Request parameters.
|
|
1015
|
+
* @param {*} [options] Override http request option.
|
|
1016
|
+
* @throws {RequiredError}
|
|
1017
|
+
* @memberof LeadsApi
|
|
1018
|
+
*/
|
|
1019
|
+
public updateLeadSync(requestParameters: LeadsApiUpdateLeadSyncRequest, options?: AxiosRequestConfig) {
|
|
1020
|
+
return LeadsApiFp(this.configuration).updateLeadSync(requestParameters.code, requestParameters.updateLeadRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
1021
|
+
}
|
|
696
1022
|
}
|
|
@@ -27,10 +27,14 @@ import { CreatePremiumFormulaResponseClass } from '../models';
|
|
|
27
27
|
// @ts-ignore
|
|
28
28
|
import { DeleteResponseClass } from '../models';
|
|
29
29
|
// @ts-ignore
|
|
30
|
+
import { EmptyResponseClass } from '../models';
|
|
31
|
+
// @ts-ignore
|
|
30
32
|
import { GetPremiumFormulaResponseClass } from '../models';
|
|
31
33
|
// @ts-ignore
|
|
32
34
|
import { ListPremiumFormulasResponseClass } from '../models';
|
|
33
35
|
// @ts-ignore
|
|
36
|
+
import { SwapPremiumFormulasOrderRequestDto } from '../models';
|
|
37
|
+
// @ts-ignore
|
|
34
38
|
import { UpdatePremiumFormulaRequestDto } from '../models';
|
|
35
39
|
// @ts-ignore
|
|
36
40
|
import { UpdatePremiumFormulaResponseClass } from '../models';
|
|
@@ -248,6 +252,53 @@ export const PremiumFormulasApiAxiosParamCreator = function (configuration?: Con
|
|
|
248
252
|
options: localVarRequestOptions,
|
|
249
253
|
};
|
|
250
254
|
},
|
|
255
|
+
/**
|
|
256
|
+
* Swaps premium formulas order.
|
|
257
|
+
* @summary Swaps premium formulas order
|
|
258
|
+
* @param {SwapPremiumFormulasOrderRequestDto} swapPremiumFormulasOrderRequestDto
|
|
259
|
+
* @param {string} [authorization] Bearer Token
|
|
260
|
+
* @param {*} [options] Override http request option.
|
|
261
|
+
* @throws {RequiredError}
|
|
262
|
+
*/
|
|
263
|
+
swapPremiumFormulasOrder: async (swapPremiumFormulasOrderRequestDto: SwapPremiumFormulasOrderRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
264
|
+
// verify required parameter 'swapPremiumFormulasOrderRequestDto' is not null or undefined
|
|
265
|
+
assertParamExists('swapPremiumFormulasOrder', 'swapPremiumFormulasOrderRequestDto', swapPremiumFormulasOrderRequestDto)
|
|
266
|
+
const localVarPath = `/insuranceservice/v1/premium-formulas/reorder`;
|
|
267
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
268
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
269
|
+
let baseOptions;
|
|
270
|
+
let baseAccessToken;
|
|
271
|
+
if (configuration) {
|
|
272
|
+
baseOptions = configuration.baseOptions;
|
|
273
|
+
baseAccessToken = configuration.accessToken;
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
|
|
277
|
+
const localVarHeaderParameter = {} as any;
|
|
278
|
+
const localVarQueryParameter = {} as any;
|
|
279
|
+
|
|
280
|
+
// authentication bearer required
|
|
281
|
+
// http bearer authentication required
|
|
282
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
283
|
+
|
|
284
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
285
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
|
|
289
|
+
|
|
290
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
291
|
+
|
|
292
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
293
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
294
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
295
|
+
localVarRequestOptions.data = serializeDataIfNeeded(swapPremiumFormulasOrderRequestDto, localVarRequestOptions, configuration)
|
|
296
|
+
|
|
297
|
+
return {
|
|
298
|
+
url: toPathString(localVarUrlObj),
|
|
299
|
+
options: localVarRequestOptions,
|
|
300
|
+
};
|
|
301
|
+
},
|
|
251
302
|
/**
|
|
252
303
|
* Updates the specified premium formula by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
|
|
253
304
|
* @summary Update the premium formula
|
|
@@ -362,6 +413,18 @@ export const PremiumFormulasApiFp = function(configuration?: Configuration) {
|
|
|
362
413
|
const localVarAxiosArgs = await localVarAxiosParamCreator.listPremiumFormulas(authorization, pageSize, pageToken, filter, search, order, expand, options);
|
|
363
414
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
364
415
|
},
|
|
416
|
+
/**
|
|
417
|
+
* Swaps premium formulas order.
|
|
418
|
+
* @summary Swaps premium formulas order
|
|
419
|
+
* @param {SwapPremiumFormulasOrderRequestDto} swapPremiumFormulasOrderRequestDto
|
|
420
|
+
* @param {string} [authorization] Bearer Token
|
|
421
|
+
* @param {*} [options] Override http request option.
|
|
422
|
+
* @throws {RequiredError}
|
|
423
|
+
*/
|
|
424
|
+
async swapPremiumFormulasOrder(swapPremiumFormulasOrderRequestDto: SwapPremiumFormulasOrderRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<EmptyResponseClass>> {
|
|
425
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.swapPremiumFormulasOrder(swapPremiumFormulasOrderRequestDto, authorization, options);
|
|
426
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
427
|
+
},
|
|
365
428
|
/**
|
|
366
429
|
* Updates the specified premium formula by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
|
|
367
430
|
* @summary Update the premium formula
|
|
@@ -434,6 +497,17 @@ export const PremiumFormulasApiFactory = function (configuration?: Configuration
|
|
|
434
497
|
listPremiumFormulas(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, options?: any): AxiosPromise<ListPremiumFormulasResponseClass> {
|
|
435
498
|
return localVarFp.listPremiumFormulas(authorization, pageSize, pageToken, filter, search, order, expand, options).then((request) => request(axios, basePath));
|
|
436
499
|
},
|
|
500
|
+
/**
|
|
501
|
+
* Swaps premium formulas order.
|
|
502
|
+
* @summary Swaps premium formulas order
|
|
503
|
+
* @param {SwapPremiumFormulasOrderRequestDto} swapPremiumFormulasOrderRequestDto
|
|
504
|
+
* @param {string} [authorization] Bearer Token
|
|
505
|
+
* @param {*} [options] Override http request option.
|
|
506
|
+
* @throws {RequiredError}
|
|
507
|
+
*/
|
|
508
|
+
swapPremiumFormulasOrder(swapPremiumFormulasOrderRequestDto: SwapPremiumFormulasOrderRequestDto, authorization?: string, options?: any): AxiosPromise<EmptyResponseClass> {
|
|
509
|
+
return localVarFp.swapPremiumFormulasOrder(swapPremiumFormulasOrderRequestDto, authorization, options).then((request) => request(axios, basePath));
|
|
510
|
+
},
|
|
437
511
|
/**
|
|
438
512
|
* Updates the specified premium formula by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
|
|
439
513
|
* @summary Update the premium formula
|
|
@@ -568,6 +642,27 @@ export interface PremiumFormulasApiListPremiumFormulasRequest {
|
|
|
568
642
|
readonly expand?: string
|
|
569
643
|
}
|
|
570
644
|
|
|
645
|
+
/**
|
|
646
|
+
* Request parameters for swapPremiumFormulasOrder operation in PremiumFormulasApi.
|
|
647
|
+
* @export
|
|
648
|
+
* @interface PremiumFormulasApiSwapPremiumFormulasOrderRequest
|
|
649
|
+
*/
|
|
650
|
+
export interface PremiumFormulasApiSwapPremiumFormulasOrderRequest {
|
|
651
|
+
/**
|
|
652
|
+
*
|
|
653
|
+
* @type {SwapPremiumFormulasOrderRequestDto}
|
|
654
|
+
* @memberof PremiumFormulasApiSwapPremiumFormulasOrder
|
|
655
|
+
*/
|
|
656
|
+
readonly swapPremiumFormulasOrderRequestDto: SwapPremiumFormulasOrderRequestDto
|
|
657
|
+
|
|
658
|
+
/**
|
|
659
|
+
* Bearer Token
|
|
660
|
+
* @type {string}
|
|
661
|
+
* @memberof PremiumFormulasApiSwapPremiumFormulasOrder
|
|
662
|
+
*/
|
|
663
|
+
readonly authorization?: string
|
|
664
|
+
}
|
|
665
|
+
|
|
571
666
|
/**
|
|
572
667
|
* Request parameters for updatePremiumFormula operation in PremiumFormulasApi.
|
|
573
668
|
* @export
|
|
@@ -651,6 +746,18 @@ export class PremiumFormulasApi extends BaseAPI {
|
|
|
651
746
|
return PremiumFormulasApiFp(this.configuration).listPremiumFormulas(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, options).then((request) => request(this.axios, this.basePath));
|
|
652
747
|
}
|
|
653
748
|
|
|
749
|
+
/**
|
|
750
|
+
* Swaps premium formulas order.
|
|
751
|
+
* @summary Swaps premium formulas order
|
|
752
|
+
* @param {PremiumFormulasApiSwapPremiumFormulasOrderRequest} requestParameters Request parameters.
|
|
753
|
+
* @param {*} [options] Override http request option.
|
|
754
|
+
* @throws {RequiredError}
|
|
755
|
+
* @memberof PremiumFormulasApi
|
|
756
|
+
*/
|
|
757
|
+
public swapPremiumFormulasOrder(requestParameters: PremiumFormulasApiSwapPremiumFormulasOrderRequest, options?: AxiosRequestConfig) {
|
|
758
|
+
return PremiumFormulasApiFp(this.configuration).swapPremiumFormulasOrder(requestParameters.swapPremiumFormulasOrderRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
759
|
+
}
|
|
760
|
+
|
|
654
761
|
/**
|
|
655
762
|
* Updates the specified premium formula by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
|
|
656
763
|
* @summary Update the premium formula
|