@emilgroup/insurance-sdk-node 1.0.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 +97 -0
- package/.openapi-generator/VERSION +1 -0
- package/.openapi-generator-ignore +23 -0
- package/README.md +51 -0
- package/api/insured-object-types-api.ts +236 -0
- package/api/insured-objects-api.ts +446 -0
- package/api/leads-api.ts +402 -0
- package/api/policies-api.ts +580 -0
- package/api/products-api.ts +3027 -0
- package/api.ts +44 -0
- package/base.ts +189 -0
- package/common.ts +138 -0
- package/configuration.ts +109 -0
- package/dist/api/insured-object-types-api.d.ts +141 -0
- package/dist/api/insured-object-types-api.js +258 -0
- package/dist/api/insured-objects-api.d.ts +254 -0
- package/dist/api/insured-objects-api.js +443 -0
- package/dist/api/leads-api.d.ts +225 -0
- package/dist/api/leads-api.js +427 -0
- package/dist/api/policies-api.d.ts +329 -0
- package/dist/api/policies-api.js +548 -0
- package/dist/api/products-api.d.ts +1683 -0
- package/dist/api/products-api.js +2521 -0
- package/dist/api.d.ts +20 -0
- package/dist/api.js +40 -0
- package/dist/base.d.ts +69 -0
- package/dist/base.js +252 -0
- package/dist/common.d.ts +66 -0
- package/dist/common.js +244 -0
- package/dist/configuration.d.ts +90 -0
- package/dist/configuration.js +44 -0
- package/dist/index.d.ts +15 -0
- package/dist/index.js +35 -0
- package/dist/models/calculate-custom-premium-request-dto.d.ts +34 -0
- package/dist/models/calculate-custom-premium-request-dto.js +19 -0
- package/dist/models/calculate-premium-request-dto.d.ts +31 -0
- package/dist/models/calculate-premium-request-dto.js +15 -0
- package/dist/models/create-account-request-dto.d.ts +84 -0
- package/dist/models/create-account-request-dto.js +15 -0
- package/dist/models/create-bank-account-request-dto.d.ts +30 -0
- package/dist/models/create-bank-account-request-dto.js +15 -0
- package/dist/models/create-claim-request-dto.d.ts +83 -0
- package/dist/models/create-claim-request-dto.js +25 -0
- package/dist/models/create-custom-application-request-dto.d.ts +40 -0
- package/dist/models/create-custom-application-request-dto.js +19 -0
- package/dist/models/create-dummy-policy-request-dto.d.ts +31 -0
- package/dist/models/create-dummy-policy-request-dto.js +15 -0
- package/dist/models/create-insured-object-request-dto.d.ts +42 -0
- package/dist/models/create-insured-object-request-dto.js +15 -0
- package/dist/models/create-insured-object-response-class.d.ts +25 -0
- package/dist/models/create-insured-object-response-class.js +15 -0
- package/dist/models/create-lead-request-dto.d.ts +71 -0
- package/dist/models/create-lead-request-dto.js +22 -0
- package/dist/models/create-policy-request-dto.d.ts +37 -0
- package/dist/models/create-policy-request-dto.js +15 -0
- package/dist/models/create-policy-response-class.d.ts +25 -0
- package/dist/models/create-policy-response-class.js +15 -0
- package/dist/models/create-premium-formula-request-dto.d.ts +65 -0
- package/dist/models/create-premium-formula-request-dto.js +25 -0
- package/dist/models/create-premium-formula-response-class.d.ts +25 -0
- package/dist/models/create-premium-formula-response-class.js +15 -0
- package/dist/models/create-product-field-request-dto.d.ts +113 -0
- package/dist/models/create-product-field-request-dto.js +20 -0
- package/dist/models/create-product-field-response-class.d.ts +25 -0
- package/dist/models/create-product-field-response-class.js +15 -0
- package/dist/models/create-product-request-dto.d.ts +57 -0
- package/dist/models/create-product-request-dto.js +30 -0
- package/dist/models/create-product-response-class.d.ts +25 -0
- package/dist/models/create-product-response-class.js +15 -0
- package/dist/models/csv-product-factor-dto.d.ts +48 -0
- package/dist/models/csv-product-factor-dto.js +15 -0
- package/dist/models/delete-request-dto.d.ts +24 -0
- package/dist/models/delete-request-dto.js +15 -0
- package/dist/models/get-insured-object-request-dto.d.ts +24 -0
- package/dist/models/get-insured-object-request-dto.js +15 -0
- package/dist/models/get-insured-object-response-class.d.ts +25 -0
- package/dist/models/get-insured-object-response-class.js +15 -0
- package/dist/models/get-policy-request-dto.d.ts +30 -0
- package/dist/models/get-policy-request-dto.js +15 -0
- package/dist/models/get-policy-response-class.d.ts +25 -0
- package/dist/models/get-policy-response-class.js +15 -0
- package/dist/models/get-premium-formula-request-dto.d.ts +24 -0
- package/dist/models/get-premium-formula-request-dto.js +15 -0
- package/dist/models/get-premium-formula-response-class.d.ts +25 -0
- package/dist/models/get-premium-formula-response-class.js +15 -0
- package/dist/models/get-product-factor-response-class.d.ts +32 -0
- package/dist/models/get-product-factor-response-class.js +15 -0
- package/dist/models/get-product-factor-value-request-dto.d.ts +42 -0
- package/dist/models/get-product-factor-value-request-dto.js +15 -0
- package/dist/models/get-product-factor-value-response-class.d.ts +25 -0
- package/dist/models/get-product-factor-value-response-class.js +15 -0
- package/dist/models/get-product-field-request-dto.d.ts +24 -0
- package/dist/models/get-product-field-request-dto.js +15 -0
- package/dist/models/get-product-field-response-class.d.ts +25 -0
- package/dist/models/get-product-field-response-class.js +15 -0
- package/dist/models/get-product-request-dto.d.ts +36 -0
- package/dist/models/get-product-request-dto.js +15 -0
- package/dist/models/get-product-response-class.d.ts +25 -0
- package/dist/models/get-product-response-class.js +15 -0
- package/dist/models/get-product-version-request-dto.d.ts +24 -0
- package/dist/models/get-product-version-request-dto.js +15 -0
- package/dist/models/get-product-version-response-class.d.ts +25 -0
- package/dist/models/get-product-version-response-class.js +15 -0
- package/dist/models/grouped-product-factor-class.d.ts +37 -0
- package/dist/models/grouped-product-factor-class.js +15 -0
- package/dist/models/grouped-product-factor-value-class.d.ts +36 -0
- package/dist/models/grouped-product-factor-value-class.js +15 -0
- package/dist/models/grouped-product-factors-response-class.d.ts +25 -0
- package/dist/models/grouped-product-factors-response-class.js +15 -0
- package/dist/models/grpc-create-policy-request-dto.d.ts +37 -0
- package/dist/models/grpc-create-policy-request-dto.js +15 -0
- package/dist/models/index.d.ts +79 -0
- package/dist/models/index.js +95 -0
- package/dist/models/insured-object-class.d.ts +67 -0
- package/dist/models/insured-object-class.js +15 -0
- package/dist/models/insured-object-type-class.d.ts +48 -0
- package/dist/models/insured-object-type-class.js +15 -0
- package/dist/models/list-insured-object-types-response-class.d.ts +31 -0
- package/dist/models/list-insured-object-types-response-class.js +15 -0
- package/dist/models/list-insured-objects-response-class.d.ts +30 -0
- package/dist/models/list-insured-objects-response-class.js +15 -0
- package/dist/models/list-policies-response-class.d.ts +31 -0
- package/dist/models/list-policies-response-class.js +15 -0
- package/dist/models/list-premium-formulas-response-class.d.ts +31 -0
- package/dist/models/list-premium-formulas-response-class.js +15 -0
- package/dist/models/list-product-factors-response-class.d.ts +31 -0
- package/dist/models/list-product-factors-response-class.js +15 -0
- package/dist/models/list-product-field-types-response-class.d.ts +30 -0
- package/dist/models/list-product-field-types-response-class.js +15 -0
- package/dist/models/list-product-fields-response-class.d.ts +31 -0
- package/dist/models/list-product-fields-response-class.js +15 -0
- package/dist/models/list-products-response-class.d.ts +31 -0
- package/dist/models/list-products-response-class.js +15 -0
- package/dist/models/list-request-dto.d.ts +54 -0
- package/dist/models/list-request-dto.js +15 -0
- package/dist/models/policy-class.d.ts +86 -0
- package/dist/models/policy-class.js +15 -0
- package/dist/models/policy-object-class.d.ts +42 -0
- package/dist/models/policy-object-class.js +15 -0
- package/dist/models/policy-object-dto.d.ts +30 -0
- package/dist/models/policy-object-dto.js +15 -0
- package/dist/models/policy-premium-class.d.ts +43 -0
- package/dist/models/policy-premium-class.js +15 -0
- package/dist/models/policy-premium-item-class.d.ts +49 -0
- package/dist/models/policy-premium-item-class.js +15 -0
- package/dist/models/policy-version-class.d.ts +55 -0
- package/dist/models/policy-version-class.js +15 -0
- package/dist/models/premium-formula-class.d.ts +79 -0
- package/dist/models/premium-formula-class.js +15 -0
- package/dist/models/product-class.d.ts +74 -0
- package/dist/models/product-class.js +15 -0
- package/dist/models/product-factor-class.d.ts +68 -0
- package/dist/models/product-factor-class.js +15 -0
- package/dist/models/product-factor-value-class.d.ts +80 -0
- package/dist/models/product-factor-value-class.js +15 -0
- package/dist/models/product-field-class.d.ts +114 -0
- package/dist/models/product-field-class.js +15 -0
- package/dist/models/product-version-class.d.ts +54 -0
- package/dist/models/product-version-class.js +15 -0
- package/dist/models/store-product-factors-request-dto.d.ts +31 -0
- package/dist/models/store-product-factors-request-dto.js +15 -0
- package/dist/models/store-product-factors-response-class.d.ts +25 -0
- package/dist/models/store-product-factors-response-class.js +15 -0
- package/dist/models/timeslice-class.d.ts +62 -0
- package/dist/models/timeslice-class.js +15 -0
- package/dist/models/update-insured-object-request-dto.d.ts +48 -0
- package/dist/models/update-insured-object-request-dto.js +15 -0
- package/dist/models/update-lead-request-dto.d.ts +71 -0
- package/dist/models/update-lead-request-dto.js +22 -0
- package/dist/models/update-policy-request-dto.d.ts +43 -0
- package/dist/models/update-policy-request-dto.js +15 -0
- package/dist/models/update-policy-response-class.d.ts +25 -0
- package/dist/models/update-policy-response-class.js +15 -0
- package/dist/models/update-premium-formula-request-dto.d.ts +71 -0
- package/dist/models/update-premium-formula-request-dto.js +25 -0
- package/dist/models/update-premium-formula-response-class.d.ts +25 -0
- package/dist/models/update-premium-formula-response-class.js +15 -0
- package/dist/models/update-product-field-request-dto.d.ts +119 -0
- package/dist/models/update-product-field-request-dto.js +20 -0
- package/dist/models/update-product-field-response-class.d.ts +25 -0
- package/dist/models/update-product-field-response-class.js +15 -0
- package/dist/models/update-product-request-dto.d.ts +42 -0
- package/dist/models/update-product-request-dto.js +15 -0
- package/dist/models/update-product-response-class.d.ts +25 -0
- package/dist/models/update-product-response-class.js +15 -0
- package/dist/models/update-product-version-request-dto.d.ts +43 -0
- package/dist/models/update-product-version-request-dto.js +22 -0
- package/dist/models/update-product-version-response-class.d.ts +25 -0
- package/dist/models/update-product-version-response-class.js +15 -0
- package/dist/models/uploaded-document-dto.d.ts +24 -0
- package/dist/models/uploaded-document-dto.js +15 -0
- package/dist/models/validate-product-factors-request-dto.d.ts +31 -0
- package/dist/models/validate-product-factors-request-dto.js +15 -0
- package/git_push.sh +57 -0
- package/index.ts +19 -0
- package/models/calculate-custom-premium-request-dto.ts +43 -0
- package/models/calculate-premium-request-dto.ts +37 -0
- package/models/create-account-request-dto.ts +90 -0
- package/models/create-bank-account-request-dto.ts +36 -0
- package/models/create-claim-request-dto.ts +93 -0
- package/models/create-custom-application-request-dto.ts +49 -0
- package/models/create-dummy-policy-request-dto.ts +37 -0
- package/models/create-insured-object-request-dto.ts +48 -0
- package/models/create-insured-object-response-class.ts +31 -0
- package/models/create-lead-request-dto.ts +80 -0
- package/models/create-policy-request-dto.ts +43 -0
- package/models/create-policy-response-class.ts +31 -0
- package/models/create-premium-formula-request-dto.ts +75 -0
- package/models/create-premium-formula-response-class.ts +31 -0
- package/models/create-product-field-request-dto.ts +122 -0
- package/models/create-product-field-response-class.ts +31 -0
- package/models/create-product-request-dto.ts +66 -0
- package/models/create-product-response-class.ts +31 -0
- package/models/csv-product-factor-dto.ts +54 -0
- package/models/delete-request-dto.ts +30 -0
- package/models/get-insured-object-request-dto.ts +30 -0
- package/models/get-insured-object-response-class.ts +31 -0
- package/models/get-policy-request-dto.ts +36 -0
- package/models/get-policy-response-class.ts +31 -0
- package/models/get-premium-formula-request-dto.ts +30 -0
- package/models/get-premium-formula-response-class.ts +31 -0
- package/models/get-product-factor-response-class.ts +38 -0
- package/models/get-product-factor-value-request-dto.ts +48 -0
- package/models/get-product-factor-value-response-class.ts +31 -0
- package/models/get-product-field-request-dto.ts +30 -0
- package/models/get-product-field-response-class.ts +31 -0
- package/models/get-product-request-dto.ts +42 -0
- package/models/get-product-response-class.ts +31 -0
- package/models/get-product-version-request-dto.ts +30 -0
- package/models/get-product-version-response-class.ts +31 -0
- package/models/grouped-product-factor-class.ts +43 -0
- package/models/grouped-product-factor-value-class.ts +42 -0
- package/models/grouped-product-factors-response-class.ts +31 -0
- package/models/grpc-create-policy-request-dto.ts +43 -0
- package/models/index.ts +79 -0
- package/models/insured-object-class.ts +73 -0
- package/models/insured-object-type-class.ts +54 -0
- package/models/list-insured-object-types-response-class.ts +37 -0
- package/models/list-insured-objects-response-class.ts +36 -0
- package/models/list-policies-response-class.ts +37 -0
- package/models/list-premium-formulas-response-class.ts +37 -0
- package/models/list-product-factors-response-class.ts +37 -0
- package/models/list-product-field-types-response-class.ts +36 -0
- package/models/list-product-fields-response-class.ts +37 -0
- package/models/list-products-response-class.ts +37 -0
- package/models/list-request-dto.ts +60 -0
- package/models/policy-class.ts +92 -0
- package/models/policy-object-class.ts +48 -0
- package/models/policy-object-dto.ts +36 -0
- package/models/policy-premium-class.ts +49 -0
- package/models/policy-premium-item-class.ts +55 -0
- package/models/policy-version-class.ts +61 -0
- package/models/premium-formula-class.ts +85 -0
- package/models/product-class.ts +80 -0
- package/models/product-factor-class.ts +74 -0
- package/models/product-factor-value-class.ts +86 -0
- package/models/product-field-class.ts +120 -0
- package/models/product-version-class.ts +60 -0
- package/models/store-product-factors-request-dto.ts +37 -0
- package/models/store-product-factors-response-class.ts +31 -0
- package/models/timeslice-class.ts +68 -0
- package/models/update-insured-object-request-dto.ts +54 -0
- package/models/update-lead-request-dto.ts +80 -0
- package/models/update-policy-request-dto.ts +49 -0
- package/models/update-policy-response-class.ts +31 -0
- package/models/update-premium-formula-request-dto.ts +81 -0
- package/models/update-premium-formula-response-class.ts +31 -0
- package/models/update-product-field-request-dto.ts +128 -0
- package/models/update-product-field-response-class.ts +31 -0
- package/models/update-product-request-dto.ts +48 -0
- package/models/update-product-response-class.ts +31 -0
- package/models/update-product-version-request-dto.ts +52 -0
- package/models/update-product-version-response-class.ts +31 -0
- package/models/uploaded-document-dto.ts +30 -0
- package/models/validate-product-factors-request-dto.ts +37 -0
- package/package.json +29 -0
- package/tsconfig.json +22 -0
|
@@ -0,0 +1,446 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* EMIL InsuranceService
|
|
5
|
+
* The EMIL InsuranceService API description
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0
|
|
8
|
+
*
|
|
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 { CreateInsuredObjectRequestDto } from '../models';
|
|
25
|
+
// @ts-ignore
|
|
26
|
+
import { CreateInsuredObjectResponseClass } from '../models';
|
|
27
|
+
// @ts-ignore
|
|
28
|
+
import { GetInsuredObjectResponseClass } from '../models';
|
|
29
|
+
// @ts-ignore
|
|
30
|
+
import { ListInsuredObjectsResponseClass } from '../models';
|
|
31
|
+
// URLSearchParams not necessarily used
|
|
32
|
+
// @ts-ignore
|
|
33
|
+
import { URL, URLSearchParams } from 'url';
|
|
34
|
+
const FormData = require('form-data');
|
|
35
|
+
/**
|
|
36
|
+
* InsuredObjectsApi - axios parameter creator
|
|
37
|
+
* @export
|
|
38
|
+
*/
|
|
39
|
+
export const InsuredObjectsApiAxiosParamCreator = function (configuration?: Configuration) {
|
|
40
|
+
return {
|
|
41
|
+
/**
|
|
42
|
+
* Creates an insured object.
|
|
43
|
+
* @summary Create the insured object
|
|
44
|
+
* @param {CreateInsuredObjectRequestDto} createInsuredObjectRequestDto
|
|
45
|
+
* @param {string} [authorization] Bearer Token
|
|
46
|
+
* @param {*} [options] Override http request option.
|
|
47
|
+
* @throws {RequiredError}
|
|
48
|
+
*/
|
|
49
|
+
createInsuredObject: async (createInsuredObjectRequestDto: CreateInsuredObjectRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
50
|
+
// verify required parameter 'createInsuredObjectRequestDto' is not null or undefined
|
|
51
|
+
assertParamExists('createInsuredObject', 'createInsuredObjectRequestDto', createInsuredObjectRequestDto)
|
|
52
|
+
const localVarPath = `/insuranceservice/v1/insured-objects`;
|
|
53
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
54
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
55
|
+
let baseOptions;
|
|
56
|
+
let baseAccessToken;
|
|
57
|
+
if (configuration) {
|
|
58
|
+
baseOptions = configuration.baseOptions;
|
|
59
|
+
baseAccessToken = configuration.accessToken;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
|
|
63
|
+
const localVarHeaderParameter = {} as any;
|
|
64
|
+
const localVarQueryParameter = {} as any;
|
|
65
|
+
|
|
66
|
+
// authentication bearer required
|
|
67
|
+
// http bearer authentication required
|
|
68
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
69
|
+
|
|
70
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
71
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
77
|
+
|
|
78
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
79
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
80
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
81
|
+
localVarRequestOptions.data = serializeDataIfNeeded(createInsuredObjectRequestDto, localVarRequestOptions, configuration)
|
|
82
|
+
|
|
83
|
+
return {
|
|
84
|
+
url: toPathString(localVarUrlObj),
|
|
85
|
+
options: localVarRequestOptions,
|
|
86
|
+
};
|
|
87
|
+
},
|
|
88
|
+
/**
|
|
89
|
+
* Retrieves the details of the insured object that was previously created. Supply the unique insured object id that was returned when you created it and Emil Api will return the corresponding insured object information.
|
|
90
|
+
* @summary Retrieve the insured object
|
|
91
|
+
* @param {string} id
|
|
92
|
+
* @param {string} [authorization] Bearer Token
|
|
93
|
+
* @param {*} [options] Override http request option.
|
|
94
|
+
* @throws {RequiredError}
|
|
95
|
+
*/
|
|
96
|
+
getInsuredObject: async (id: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
97
|
+
// verify required parameter 'id' is not null or undefined
|
|
98
|
+
assertParamExists('getInsuredObject', 'id', id)
|
|
99
|
+
const localVarPath = `/insuranceservice/v1/insured-objects/{id}`
|
|
100
|
+
.replace(`{${"id"}}`, encodeURIComponent(String(id)));
|
|
101
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
102
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
103
|
+
let baseOptions;
|
|
104
|
+
let baseAccessToken;
|
|
105
|
+
if (configuration) {
|
|
106
|
+
baseOptions = configuration.baseOptions;
|
|
107
|
+
baseAccessToken = configuration.accessToken;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
111
|
+
const localVarHeaderParameter = {} as any;
|
|
112
|
+
const localVarQueryParameter = {} as any;
|
|
113
|
+
|
|
114
|
+
// authentication bearer required
|
|
115
|
+
// http bearer authentication required
|
|
116
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
117
|
+
|
|
118
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
119
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
|
|
124
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
125
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
126
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
127
|
+
|
|
128
|
+
return {
|
|
129
|
+
url: toPathString(localVarUrlObj),
|
|
130
|
+
options: localVarRequestOptions,
|
|
131
|
+
};
|
|
132
|
+
},
|
|
133
|
+
/**
|
|
134
|
+
* Returns a list of insured objects you have previously created. The insured objects are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
135
|
+
* @summary List insured objects
|
|
136
|
+
* @param {string} [authorization] Bearer Token
|
|
137
|
+
* @param {number} [pageSize] Page size
|
|
138
|
+
* @param {string} [pageToken] Page token
|
|
139
|
+
* @param {string} [filter] List filter
|
|
140
|
+
* @param {string} [search] Search query
|
|
141
|
+
* @param {string} [order] Ordering criteria
|
|
142
|
+
* @param {string} [expand] Extra fields to fetch
|
|
143
|
+
* @param {*} [options] Override http request option.
|
|
144
|
+
* @throws {RequiredError}
|
|
145
|
+
*/
|
|
146
|
+
listInsuredObjects: async (authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
147
|
+
const localVarPath = `/insuranceservice/v1/insured-objects`;
|
|
148
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
149
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
150
|
+
let baseOptions;
|
|
151
|
+
let baseAccessToken;
|
|
152
|
+
if (configuration) {
|
|
153
|
+
baseOptions = configuration.baseOptions;
|
|
154
|
+
baseAccessToken = configuration.accessToken;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
158
|
+
const localVarHeaderParameter = {} as any;
|
|
159
|
+
const localVarQueryParameter = {} as any;
|
|
160
|
+
|
|
161
|
+
// authentication bearer required
|
|
162
|
+
// http bearer authentication required
|
|
163
|
+
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
164
|
+
|
|
165
|
+
if (pageSize !== undefined) {
|
|
166
|
+
localVarQueryParameter['pageSize'] = pageSize;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
if (pageToken !== undefined) {
|
|
170
|
+
localVarQueryParameter['pageToken'] = pageToken;
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
if (filter !== undefined) {
|
|
174
|
+
localVarQueryParameter['filter'] = filter;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
if (search !== undefined) {
|
|
178
|
+
localVarQueryParameter['search'] = search;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
if (order !== undefined) {
|
|
182
|
+
localVarQueryParameter['order'] = order;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
if (expand !== undefined) {
|
|
186
|
+
localVarQueryParameter['expand'] = expand;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
190
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
|
|
194
|
+
|
|
195
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
196
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
197
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
198
|
+
|
|
199
|
+
return {
|
|
200
|
+
url: toPathString(localVarUrlObj),
|
|
201
|
+
options: localVarRequestOptions,
|
|
202
|
+
};
|
|
203
|
+
},
|
|
204
|
+
}
|
|
205
|
+
};
|
|
206
|
+
|
|
207
|
+
/**
|
|
208
|
+
* InsuredObjectsApi - functional programming interface
|
|
209
|
+
* @export
|
|
210
|
+
*/
|
|
211
|
+
export const InsuredObjectsApiFp = function(configuration?: Configuration) {
|
|
212
|
+
const localVarAxiosParamCreator = InsuredObjectsApiAxiosParamCreator(configuration)
|
|
213
|
+
return {
|
|
214
|
+
/**
|
|
215
|
+
* Creates an insured object.
|
|
216
|
+
* @summary Create the insured object
|
|
217
|
+
* @param {CreateInsuredObjectRequestDto} createInsuredObjectRequestDto
|
|
218
|
+
* @param {string} [authorization] Bearer Token
|
|
219
|
+
* @param {*} [options] Override http request option.
|
|
220
|
+
* @throws {RequiredError}
|
|
221
|
+
*/
|
|
222
|
+
async createInsuredObject(createInsuredObjectRequestDto: CreateInsuredObjectRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateInsuredObjectResponseClass>> {
|
|
223
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.createInsuredObject(createInsuredObjectRequestDto, authorization, options);
|
|
224
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
225
|
+
},
|
|
226
|
+
/**
|
|
227
|
+
* Retrieves the details of the insured object that was previously created. Supply the unique insured object id that was returned when you created it and Emil Api will return the corresponding insured object information.
|
|
228
|
+
* @summary Retrieve the insured object
|
|
229
|
+
* @param {string} id
|
|
230
|
+
* @param {string} [authorization] Bearer Token
|
|
231
|
+
* @param {*} [options] Override http request option.
|
|
232
|
+
* @throws {RequiredError}
|
|
233
|
+
*/
|
|
234
|
+
async getInsuredObject(id: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetInsuredObjectResponseClass>> {
|
|
235
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getInsuredObject(id, authorization, options);
|
|
236
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
237
|
+
},
|
|
238
|
+
/**
|
|
239
|
+
* Returns a list of insured objects you have previously created. The insured objects are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
240
|
+
* @summary List insured objects
|
|
241
|
+
* @param {string} [authorization] Bearer Token
|
|
242
|
+
* @param {number} [pageSize] Page size
|
|
243
|
+
* @param {string} [pageToken] Page token
|
|
244
|
+
* @param {string} [filter] List filter
|
|
245
|
+
* @param {string} [search] Search query
|
|
246
|
+
* @param {string} [order] Ordering criteria
|
|
247
|
+
* @param {string} [expand] Extra fields to fetch
|
|
248
|
+
* @param {*} [options] Override http request option.
|
|
249
|
+
* @throws {RequiredError}
|
|
250
|
+
*/
|
|
251
|
+
async listInsuredObjects(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ListInsuredObjectsResponseClass>> {
|
|
252
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.listInsuredObjects(authorization, pageSize, pageToken, filter, search, order, expand, options);
|
|
253
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
254
|
+
},
|
|
255
|
+
}
|
|
256
|
+
};
|
|
257
|
+
|
|
258
|
+
/**
|
|
259
|
+
* InsuredObjectsApi - factory interface
|
|
260
|
+
* @export
|
|
261
|
+
*/
|
|
262
|
+
export const InsuredObjectsApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
|
|
263
|
+
const localVarFp = InsuredObjectsApiFp(configuration)
|
|
264
|
+
return {
|
|
265
|
+
/**
|
|
266
|
+
* Creates an insured object.
|
|
267
|
+
* @summary Create the insured object
|
|
268
|
+
* @param {CreateInsuredObjectRequestDto} createInsuredObjectRequestDto
|
|
269
|
+
* @param {string} [authorization] Bearer Token
|
|
270
|
+
* @param {*} [options] Override http request option.
|
|
271
|
+
* @throws {RequiredError}
|
|
272
|
+
*/
|
|
273
|
+
createInsuredObject(createInsuredObjectRequestDto: CreateInsuredObjectRequestDto, authorization?: string, options?: any): AxiosPromise<CreateInsuredObjectResponseClass> {
|
|
274
|
+
return localVarFp.createInsuredObject(createInsuredObjectRequestDto, authorization, options).then((request) => request(axios, basePath));
|
|
275
|
+
},
|
|
276
|
+
/**
|
|
277
|
+
* Retrieves the details of the insured object that was previously created. Supply the unique insured object id that was returned when you created it and Emil Api will return the corresponding insured object information.
|
|
278
|
+
* @summary Retrieve the insured object
|
|
279
|
+
* @param {string} id
|
|
280
|
+
* @param {string} [authorization] Bearer Token
|
|
281
|
+
* @param {*} [options] Override http request option.
|
|
282
|
+
* @throws {RequiredError}
|
|
283
|
+
*/
|
|
284
|
+
getInsuredObject(id: string, authorization?: string, options?: any): AxiosPromise<GetInsuredObjectResponseClass> {
|
|
285
|
+
return localVarFp.getInsuredObject(id, authorization, options).then((request) => request(axios, basePath));
|
|
286
|
+
},
|
|
287
|
+
/**
|
|
288
|
+
* Returns a list of insured objects you have previously created. The insured objects are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
289
|
+
* @summary List insured objects
|
|
290
|
+
* @param {string} [authorization] Bearer Token
|
|
291
|
+
* @param {number} [pageSize] Page size
|
|
292
|
+
* @param {string} [pageToken] Page token
|
|
293
|
+
* @param {string} [filter] List filter
|
|
294
|
+
* @param {string} [search] Search query
|
|
295
|
+
* @param {string} [order] Ordering criteria
|
|
296
|
+
* @param {string} [expand] Extra fields to fetch
|
|
297
|
+
* @param {*} [options] Override http request option.
|
|
298
|
+
* @throws {RequiredError}
|
|
299
|
+
*/
|
|
300
|
+
listInsuredObjects(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, options?: any): AxiosPromise<ListInsuredObjectsResponseClass> {
|
|
301
|
+
return localVarFp.listInsuredObjects(authorization, pageSize, pageToken, filter, search, order, expand, options).then((request) => request(axios, basePath));
|
|
302
|
+
},
|
|
303
|
+
};
|
|
304
|
+
};
|
|
305
|
+
|
|
306
|
+
/**
|
|
307
|
+
* Request parameters for createInsuredObject operation in InsuredObjectsApi.
|
|
308
|
+
* @export
|
|
309
|
+
* @interface InsuredObjectsApiCreateInsuredObjectRequest
|
|
310
|
+
*/
|
|
311
|
+
export interface InsuredObjectsApiCreateInsuredObjectRequest {
|
|
312
|
+
/**
|
|
313
|
+
*
|
|
314
|
+
* @type {CreateInsuredObjectRequestDto}
|
|
315
|
+
* @memberof InsuredObjectsApiCreateInsuredObject
|
|
316
|
+
*/
|
|
317
|
+
readonly createInsuredObjectRequestDto: CreateInsuredObjectRequestDto
|
|
318
|
+
|
|
319
|
+
/**
|
|
320
|
+
* Bearer Token
|
|
321
|
+
* @type {string}
|
|
322
|
+
* @memberof InsuredObjectsApiCreateInsuredObject
|
|
323
|
+
*/
|
|
324
|
+
readonly authorization?: string
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
/**
|
|
328
|
+
* Request parameters for getInsuredObject operation in InsuredObjectsApi.
|
|
329
|
+
* @export
|
|
330
|
+
* @interface InsuredObjectsApiGetInsuredObjectRequest
|
|
331
|
+
*/
|
|
332
|
+
export interface InsuredObjectsApiGetInsuredObjectRequest {
|
|
333
|
+
/**
|
|
334
|
+
*
|
|
335
|
+
* @type {string}
|
|
336
|
+
* @memberof InsuredObjectsApiGetInsuredObject
|
|
337
|
+
*/
|
|
338
|
+
readonly id: string
|
|
339
|
+
|
|
340
|
+
/**
|
|
341
|
+
* Bearer Token
|
|
342
|
+
* @type {string}
|
|
343
|
+
* @memberof InsuredObjectsApiGetInsuredObject
|
|
344
|
+
*/
|
|
345
|
+
readonly authorization?: string
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
/**
|
|
349
|
+
* Request parameters for listInsuredObjects operation in InsuredObjectsApi.
|
|
350
|
+
* @export
|
|
351
|
+
* @interface InsuredObjectsApiListInsuredObjectsRequest
|
|
352
|
+
*/
|
|
353
|
+
export interface InsuredObjectsApiListInsuredObjectsRequest {
|
|
354
|
+
/**
|
|
355
|
+
* Bearer Token
|
|
356
|
+
* @type {string}
|
|
357
|
+
* @memberof InsuredObjectsApiListInsuredObjects
|
|
358
|
+
*/
|
|
359
|
+
readonly authorization?: string
|
|
360
|
+
|
|
361
|
+
/**
|
|
362
|
+
* Page size
|
|
363
|
+
* @type {number}
|
|
364
|
+
* @memberof InsuredObjectsApiListInsuredObjects
|
|
365
|
+
*/
|
|
366
|
+
readonly pageSize?: number
|
|
367
|
+
|
|
368
|
+
/**
|
|
369
|
+
* Page token
|
|
370
|
+
* @type {string}
|
|
371
|
+
* @memberof InsuredObjectsApiListInsuredObjects
|
|
372
|
+
*/
|
|
373
|
+
readonly pageToken?: string
|
|
374
|
+
|
|
375
|
+
/**
|
|
376
|
+
* List filter
|
|
377
|
+
* @type {string}
|
|
378
|
+
* @memberof InsuredObjectsApiListInsuredObjects
|
|
379
|
+
*/
|
|
380
|
+
readonly filter?: string
|
|
381
|
+
|
|
382
|
+
/**
|
|
383
|
+
* Search query
|
|
384
|
+
* @type {string}
|
|
385
|
+
* @memberof InsuredObjectsApiListInsuredObjects
|
|
386
|
+
*/
|
|
387
|
+
readonly search?: string
|
|
388
|
+
|
|
389
|
+
/**
|
|
390
|
+
* Ordering criteria
|
|
391
|
+
* @type {string}
|
|
392
|
+
* @memberof InsuredObjectsApiListInsuredObjects
|
|
393
|
+
*/
|
|
394
|
+
readonly order?: string
|
|
395
|
+
|
|
396
|
+
/**
|
|
397
|
+
* Extra fields to fetch
|
|
398
|
+
* @type {string}
|
|
399
|
+
* @memberof InsuredObjectsApiListInsuredObjects
|
|
400
|
+
*/
|
|
401
|
+
readonly expand?: string
|
|
402
|
+
}
|
|
403
|
+
|
|
404
|
+
/**
|
|
405
|
+
* InsuredObjectsApi - object-oriented interface
|
|
406
|
+
* @export
|
|
407
|
+
* @class InsuredObjectsApi
|
|
408
|
+
* @extends {BaseAPI}
|
|
409
|
+
*/
|
|
410
|
+
export class InsuredObjectsApi extends BaseAPI {
|
|
411
|
+
/**
|
|
412
|
+
* Creates an insured object.
|
|
413
|
+
* @summary Create the insured object
|
|
414
|
+
* @param {InsuredObjectsApiCreateInsuredObjectRequest} requestParameters Request parameters.
|
|
415
|
+
* @param {*} [options] Override http request option.
|
|
416
|
+
* @throws {RequiredError}
|
|
417
|
+
* @memberof InsuredObjectsApi
|
|
418
|
+
*/
|
|
419
|
+
public createInsuredObject(requestParameters: InsuredObjectsApiCreateInsuredObjectRequest, options?: AxiosRequestConfig) {
|
|
420
|
+
return InsuredObjectsApiFp(this.configuration).createInsuredObject(requestParameters.createInsuredObjectRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
421
|
+
}
|
|
422
|
+
|
|
423
|
+
/**
|
|
424
|
+
* Retrieves the details of the insured object that was previously created. Supply the unique insured object id that was returned when you created it and Emil Api will return the corresponding insured object information.
|
|
425
|
+
* @summary Retrieve the insured object
|
|
426
|
+
* @param {InsuredObjectsApiGetInsuredObjectRequest} requestParameters Request parameters.
|
|
427
|
+
* @param {*} [options] Override http request option.
|
|
428
|
+
* @throws {RequiredError}
|
|
429
|
+
* @memberof InsuredObjectsApi
|
|
430
|
+
*/
|
|
431
|
+
public getInsuredObject(requestParameters: InsuredObjectsApiGetInsuredObjectRequest, options?: AxiosRequestConfig) {
|
|
432
|
+
return InsuredObjectsApiFp(this.configuration).getInsuredObject(requestParameters.id, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
433
|
+
}
|
|
434
|
+
|
|
435
|
+
/**
|
|
436
|
+
* Returns a list of insured objects you have previously created. The insured objects are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
437
|
+
* @summary List insured objects
|
|
438
|
+
* @param {InsuredObjectsApiListInsuredObjectsRequest} requestParameters Request parameters.
|
|
439
|
+
* @param {*} [options] Override http request option.
|
|
440
|
+
* @throws {RequiredError}
|
|
441
|
+
* @memberof InsuredObjectsApi
|
|
442
|
+
*/
|
|
443
|
+
public listInsuredObjects(requestParameters: InsuredObjectsApiListInsuredObjectsRequest = {}, options?: AxiosRequestConfig) {
|
|
444
|
+
return InsuredObjectsApiFp(this.configuration).listInsuredObjects(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, options).then((request) => request(this.axios, this.basePath));
|
|
445
|
+
}
|
|
446
|
+
}
|