@emilgroup/customer-sdk-node 1.12.0 → 1.13.1
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 +3 -0
- package/README.md +2 -2
- package/api/claims-api.ts +126 -0
- package/api/invites-api.ts +16 -14
- package/api/payments-api.ts +6 -20
- package/dist/api/claims-api.d.ts +74 -0
- package/dist/api/claims-api.js +94 -0
- package/dist/api/invites-api.d.ts +9 -8
- package/dist/api/invites-api.js +12 -12
- package/dist/api/payments-api.d.ts +3 -12
- package/dist/api/payments-api.js +6 -12
- package/dist/models/currency-class.d.ts +48 -0
- package/dist/models/currency-class.js +15 -0
- package/dist/models/get-customer-claim-response-class.d.ts +25 -0
- package/dist/models/get-customer-claim-response-class.js +15 -0
- package/dist/models/index.d.ts +3 -0
- package/dist/models/index.js +3 -0
- package/dist/models/invite-by-tenant-request-dto.d.ts +24 -0
- package/dist/models/invite-by-tenant-request-dto.js +15 -0
- package/dist/models/invoice-class.d.ts +7 -0
- package/dist/models/policy-object-class.d.ts +18 -0
- package/dist/models/terminate-customer-policy-request-dto.d.ts +1 -1
- package/models/currency-class.ts +54 -0
- package/models/get-customer-claim-response-class.ts +31 -0
- package/models/index.ts +3 -0
- package/models/invite-by-tenant-request-dto.ts +30 -0
- package/models/invoice-class.ts +7 -0
- package/models/policy-object-class.ts +18 -0
- package/models/terminate-customer-policy-request-dto.ts +1 -1
- package/package.json +2 -2
package/.openapi-generator/FILES
CHANGED
|
@@ -31,10 +31,12 @@ models/create-customer-claim-response-class.ts
|
|
|
31
31
|
models/create-customer-request-dto.ts
|
|
32
32
|
models/create-customer-response-class.ts
|
|
33
33
|
models/create-presigned-post-response-class.ts
|
|
34
|
+
models/currency-class.ts
|
|
34
35
|
models/customer-class.ts
|
|
35
36
|
models/customer-document-class.ts
|
|
36
37
|
models/customer-product-class.ts
|
|
37
38
|
models/forgot-password-request-dto.ts
|
|
39
|
+
models/get-customer-claim-response-class.ts
|
|
38
40
|
models/get-customer-document-download-url-response-class.ts
|
|
39
41
|
models/get-customer-response-class.ts
|
|
40
42
|
models/get-policy-response-class.ts
|
|
@@ -47,6 +49,7 @@ models/initiate-payment-setup-response-class.ts
|
|
|
47
49
|
models/initiate-stripe-payment-setup-response-class.ts
|
|
48
50
|
models/invite-by-customer-request-dto.ts
|
|
49
51
|
models/invite-by-customer-response-class.ts
|
|
52
|
+
models/invite-by-tenant-request-dto.ts
|
|
50
53
|
models/invite-by-tenant-response-class.ts
|
|
51
54
|
models/invite-class.ts
|
|
52
55
|
models/invoice-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/customer-sdk-node@1.
|
|
20
|
+
npm install @emilgroup/customer-sdk-node@1.13.1 --save
|
|
21
21
|
```
|
|
22
22
|
or
|
|
23
23
|
```
|
|
24
|
-
yarn add @emilgroup/customer-sdk-node@1.
|
|
24
|
+
yarn add @emilgroup/customer-sdk-node@1.13.1
|
|
25
25
|
```
|
|
26
26
|
|
|
27
27
|
And then you can import `CustomersApi`.
|
package/api/claims-api.ts
CHANGED
|
@@ -27,6 +27,8 @@ import { CreateCustomerClaimResponseClass } from '../models';
|
|
|
27
27
|
// @ts-ignore
|
|
28
28
|
import { CreatePresignedPostResponseClass } from '../models';
|
|
29
29
|
// @ts-ignore
|
|
30
|
+
import { GetCustomerClaimResponseClass } from '../models';
|
|
31
|
+
// @ts-ignore
|
|
30
32
|
import { ListCustomerClaimsResponseClass } from '../models';
|
|
31
33
|
// @ts-ignore
|
|
32
34
|
import { UpdateCustomerClaimRequestDto } from '../models';
|
|
@@ -96,6 +98,56 @@ export const ClaimsApiAxiosParamCreator = function (configuration?: Configuratio
|
|
|
96
98
|
options: localVarRequestOptions,
|
|
97
99
|
};
|
|
98
100
|
},
|
|
101
|
+
/**
|
|
102
|
+
* Get claim for customer.
|
|
103
|
+
* @summary Get claim
|
|
104
|
+
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
105
|
+
* @param {string} claimCode The claim code to identify a claim.
|
|
106
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
107
|
+
* @param {string} [authorization2] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
108
|
+
* @param {*} [options] Override http request option.
|
|
109
|
+
* @throws {RequiredError}
|
|
110
|
+
*/
|
|
111
|
+
getCustomerClaim: async (customerCode: string, claimCode: string, authorization?: string, authorization2?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
112
|
+
// verify required parameter 'customerCode' is not null or undefined
|
|
113
|
+
assertParamExists('getCustomerClaim', 'customerCode', customerCode)
|
|
114
|
+
// verify required parameter 'claimCode' is not null or undefined
|
|
115
|
+
assertParamExists('getCustomerClaim', 'claimCode', claimCode)
|
|
116
|
+
const localVarPath = `/v1/customers/{customerCode}/claims/{claimCode}`
|
|
117
|
+
.replace(`{${"customerCode"}}`, encodeURIComponent(String(customerCode)))
|
|
118
|
+
.replace(`{${"claimCode"}}`, encodeURIComponent(String(claimCode)));
|
|
119
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
120
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
121
|
+
let baseOptions;
|
|
122
|
+
let baseAccessToken;
|
|
123
|
+
if (configuration) {
|
|
124
|
+
baseOptions = configuration.baseOptions;
|
|
125
|
+
baseAccessToken = configuration.accessToken;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
129
|
+
const localVarHeaderParameter = {} as any;
|
|
130
|
+
const localVarQueryParameter = {} as any;
|
|
131
|
+
|
|
132
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
133
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
if (authorization2 !== undefined && authorization2 !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
137
|
+
localVarHeaderParameter['Authorization'] = String(authorization2 ? authorization2 : baseAccessToken);
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
143
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
144
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
145
|
+
|
|
146
|
+
return {
|
|
147
|
+
url: toPathString(localVarUrlObj),
|
|
148
|
+
options: localVarRequestOptions,
|
|
149
|
+
};
|
|
150
|
+
},
|
|
99
151
|
/**
|
|
100
152
|
* List claims by customer.
|
|
101
153
|
* @summary List claims
|
|
@@ -308,6 +360,20 @@ export const ClaimsApiFp = function(configuration?: Configuration) {
|
|
|
308
360
|
const localVarAxiosArgs = await localVarAxiosParamCreator.createCustomerClaim(customerCode, createCustomerClaimRequestDto, authorization, authorization2, options);
|
|
309
361
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
310
362
|
},
|
|
363
|
+
/**
|
|
364
|
+
* Get claim for customer.
|
|
365
|
+
* @summary Get claim
|
|
366
|
+
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
367
|
+
* @param {string} claimCode The claim code to identify a claim.
|
|
368
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
369
|
+
* @param {string} [authorization2] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
370
|
+
* @param {*} [options] Override http request option.
|
|
371
|
+
* @throws {RequiredError}
|
|
372
|
+
*/
|
|
373
|
+
async getCustomerClaim(customerCode: string, claimCode: string, authorization?: string, authorization2?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetCustomerClaimResponseClass>> {
|
|
374
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getCustomerClaim(customerCode, claimCode, authorization, authorization2, options);
|
|
375
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
376
|
+
},
|
|
311
377
|
/**
|
|
312
378
|
* List claims by customer.
|
|
313
379
|
* @summary List claims
|
|
@@ -380,6 +446,19 @@ export const ClaimsApiFactory = function (configuration?: Configuration, basePat
|
|
|
380
446
|
createCustomerClaim(customerCode: string, createCustomerClaimRequestDto: CreateCustomerClaimRequestDto, authorization?: string, authorization2?: string, options?: any): AxiosPromise<CreateCustomerClaimResponseClass> {
|
|
381
447
|
return localVarFp.createCustomerClaim(customerCode, createCustomerClaimRequestDto, authorization, authorization2, options).then((request) => request(axios, basePath));
|
|
382
448
|
},
|
|
449
|
+
/**
|
|
450
|
+
* Get claim for customer.
|
|
451
|
+
* @summary Get claim
|
|
452
|
+
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
453
|
+
* @param {string} claimCode The claim code to identify a claim.
|
|
454
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
455
|
+
* @param {string} [authorization2] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
456
|
+
* @param {*} [options] Override http request option.
|
|
457
|
+
* @throws {RequiredError}
|
|
458
|
+
*/
|
|
459
|
+
getCustomerClaim(customerCode: string, claimCode: string, authorization?: string, authorization2?: string, options?: any): AxiosPromise<GetCustomerClaimResponseClass> {
|
|
460
|
+
return localVarFp.getCustomerClaim(customerCode, claimCode, authorization, authorization2, options).then((request) => request(axios, basePath));
|
|
461
|
+
},
|
|
383
462
|
/**
|
|
384
463
|
* List claims by customer.
|
|
385
464
|
* @summary List claims
|
|
@@ -464,6 +543,41 @@ export interface ClaimsApiCreateCustomerClaimRequest {
|
|
|
464
543
|
readonly authorization2?: string
|
|
465
544
|
}
|
|
466
545
|
|
|
546
|
+
/**
|
|
547
|
+
* Request parameters for getCustomerClaim operation in ClaimsApi.
|
|
548
|
+
* @export
|
|
549
|
+
* @interface ClaimsApiGetCustomerClaimRequest
|
|
550
|
+
*/
|
|
551
|
+
export interface ClaimsApiGetCustomerClaimRequest {
|
|
552
|
+
/**
|
|
553
|
+
* The customer code or \"me\" for the currently logged in customer.
|
|
554
|
+
* @type {string}
|
|
555
|
+
* @memberof ClaimsApiGetCustomerClaim
|
|
556
|
+
*/
|
|
557
|
+
readonly customerCode: string
|
|
558
|
+
|
|
559
|
+
/**
|
|
560
|
+
* The claim code to identify a claim.
|
|
561
|
+
* @type {string}
|
|
562
|
+
* @memberof ClaimsApiGetCustomerClaim
|
|
563
|
+
*/
|
|
564
|
+
readonly claimCode: string
|
|
565
|
+
|
|
566
|
+
/**
|
|
567
|
+
* Bearer Token: provided by the login endpoint under the name accessToken.
|
|
568
|
+
* @type {string}
|
|
569
|
+
* @memberof ClaimsApiGetCustomerClaim
|
|
570
|
+
*/
|
|
571
|
+
readonly authorization?: string
|
|
572
|
+
|
|
573
|
+
/**
|
|
574
|
+
* Bearer Token: provided by the login endpoint under the name accessToken.
|
|
575
|
+
* @type {string}
|
|
576
|
+
* @memberof ClaimsApiGetCustomerClaim
|
|
577
|
+
*/
|
|
578
|
+
readonly authorization2?: string
|
|
579
|
+
}
|
|
580
|
+
|
|
467
581
|
/**
|
|
468
582
|
* Request parameters for listCustomerClaims operation in ClaimsApi.
|
|
469
583
|
* @export
|
|
@@ -637,6 +751,18 @@ export class ClaimsApi extends BaseAPI {
|
|
|
637
751
|
return ClaimsApiFp(this.configuration).createCustomerClaim(requestParameters.customerCode, requestParameters.createCustomerClaimRequestDto, requestParameters.authorization, requestParameters.authorization2, options).then((request) => request(this.axios, this.basePath));
|
|
638
752
|
}
|
|
639
753
|
|
|
754
|
+
/**
|
|
755
|
+
* Get claim for customer.
|
|
756
|
+
* @summary Get claim
|
|
757
|
+
* @param {ClaimsApiGetCustomerClaimRequest} requestParameters Request parameters.
|
|
758
|
+
* @param {*} [options] Override http request option.
|
|
759
|
+
* @throws {RequiredError}
|
|
760
|
+
* @memberof ClaimsApi
|
|
761
|
+
*/
|
|
762
|
+
public getCustomerClaim(requestParameters: ClaimsApiGetCustomerClaimRequest, options?: AxiosRequestConfig) {
|
|
763
|
+
return ClaimsApiFp(this.configuration).getCustomerClaim(requestParameters.customerCode, requestParameters.claimCode, requestParameters.authorization, requestParameters.authorization2, options).then((request) => request(this.axios, this.basePath));
|
|
764
|
+
}
|
|
765
|
+
|
|
640
766
|
/**
|
|
641
767
|
* List claims by customer.
|
|
642
768
|
* @summary List claims
|
package/api/invites-api.ts
CHANGED
|
@@ -29,6 +29,8 @@ import { InviteByCustomerRequestDto } from '../models';
|
|
|
29
29
|
// @ts-ignore
|
|
30
30
|
import { InviteByCustomerResponseClass } from '../models';
|
|
31
31
|
// @ts-ignore
|
|
32
|
+
import { InviteByTenantRequestDto } from '../models';
|
|
33
|
+
// @ts-ignore
|
|
32
34
|
import { InviteByTenantResponseClass } from '../models';
|
|
33
35
|
// @ts-ignore
|
|
34
36
|
import { VerifyCustomerInviteResponseClass } from '../models';
|
|
@@ -126,14 +128,14 @@ export const InvitesApiAxiosParamCreator = function (configuration?: Configurati
|
|
|
126
128
|
/**
|
|
127
129
|
* 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.
|
|
128
130
|
* @summary Invite a customer by tenant
|
|
129
|
-
* @param {
|
|
131
|
+
* @param {InviteByTenantRequestDto} inviteByTenantRequestDto
|
|
130
132
|
* @param {string} [authorization] Bearer Token: provided by the Emil Insurance Suite\'s Auth login endpoint under the name accessToken.
|
|
131
133
|
* @param {*} [options] Override http request option.
|
|
132
134
|
* @throws {RequiredError}
|
|
133
135
|
*/
|
|
134
|
-
inviteByTenant: async (
|
|
135
|
-
// verify required parameter '
|
|
136
|
-
assertParamExists('inviteByTenant', '
|
|
136
|
+
inviteByTenant: async (inviteByTenantRequestDto: InviteByTenantRequestDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
137
|
+
// verify required parameter 'inviteByTenantRequestDto' is not null or undefined
|
|
138
|
+
assertParamExists('inviteByTenant', 'inviteByTenantRequestDto', inviteByTenantRequestDto)
|
|
137
139
|
const localVarPath = `/v1/customers/invites/by-tenant`;
|
|
138
140
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
139
141
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
@@ -159,7 +161,7 @@ export const InvitesApiAxiosParamCreator = function (configuration?: Configurati
|
|
|
159
161
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
160
162
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
161
163
|
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
162
|
-
localVarRequestOptions.data = serializeDataIfNeeded(
|
|
164
|
+
localVarRequestOptions.data = serializeDataIfNeeded(inviteByTenantRequestDto, localVarRequestOptions, configuration)
|
|
163
165
|
|
|
164
166
|
return {
|
|
165
167
|
url: toPathString(localVarUrlObj),
|
|
@@ -241,13 +243,13 @@ export const InvitesApiFp = function(configuration?: Configuration) {
|
|
|
241
243
|
/**
|
|
242
244
|
* 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.
|
|
243
245
|
* @summary Invite a customer by tenant
|
|
244
|
-
* @param {
|
|
246
|
+
* @param {InviteByTenantRequestDto} inviteByTenantRequestDto
|
|
245
247
|
* @param {string} [authorization] Bearer Token: provided by the Emil Insurance Suite\'s Auth login endpoint under the name accessToken.
|
|
246
248
|
* @param {*} [options] Override http request option.
|
|
247
249
|
* @throws {RequiredError}
|
|
248
250
|
*/
|
|
249
|
-
async inviteByTenant(
|
|
250
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.inviteByTenant(
|
|
251
|
+
async inviteByTenant(inviteByTenantRequestDto: InviteByTenantRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InviteByTenantResponseClass>> {
|
|
252
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.inviteByTenant(inviteByTenantRequestDto, authorization, options);
|
|
251
253
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
252
254
|
},
|
|
253
255
|
/**
|
|
@@ -295,13 +297,13 @@ export const InvitesApiFactory = function (configuration?: Configuration, basePa
|
|
|
295
297
|
/**
|
|
296
298
|
* 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.
|
|
297
299
|
* @summary Invite a customer by tenant
|
|
298
|
-
* @param {
|
|
300
|
+
* @param {InviteByTenantRequestDto} inviteByTenantRequestDto
|
|
299
301
|
* @param {string} [authorization] Bearer Token: provided by the Emil Insurance Suite\'s Auth login endpoint under the name accessToken.
|
|
300
302
|
* @param {*} [options] Override http request option.
|
|
301
303
|
* @throws {RequiredError}
|
|
302
304
|
*/
|
|
303
|
-
inviteByTenant(
|
|
304
|
-
return localVarFp.inviteByTenant(
|
|
305
|
+
inviteByTenant(inviteByTenantRequestDto: InviteByTenantRequestDto, authorization?: string, options?: any): AxiosPromise<InviteByTenantResponseClass> {
|
|
306
|
+
return localVarFp.inviteByTenant(inviteByTenantRequestDto, authorization, options).then((request) => request(axios, basePath));
|
|
305
307
|
},
|
|
306
308
|
/**
|
|
307
309
|
* Verify the invite sent to the customer via email.
|
|
@@ -359,10 +361,10 @@ export interface InvitesApiInviteByCustomerRequest {
|
|
|
359
361
|
export interface InvitesApiInviteByTenantRequest {
|
|
360
362
|
/**
|
|
361
363
|
*
|
|
362
|
-
* @type {
|
|
364
|
+
* @type {InviteByTenantRequestDto}
|
|
363
365
|
* @memberof InvitesApiInviteByTenant
|
|
364
366
|
*/
|
|
365
|
-
readonly
|
|
367
|
+
readonly inviteByTenantRequestDto: InviteByTenantRequestDto
|
|
366
368
|
|
|
367
369
|
/**
|
|
368
370
|
* Bearer Token: provided by the Emil Insurance Suite\'s Auth login endpoint under the name accessToken.
|
|
@@ -426,7 +428,7 @@ export class InvitesApi extends BaseAPI {
|
|
|
426
428
|
* @memberof InvitesApi
|
|
427
429
|
*/
|
|
428
430
|
public inviteByTenant(requestParameters: InvitesApiInviteByTenantRequest, options?: AxiosRequestConfig) {
|
|
429
|
-
return InvitesApiFp(this.configuration).inviteByTenant(requestParameters.
|
|
431
|
+
return InvitesApiFp(this.configuration).inviteByTenant(requestParameters.inviteByTenantRequestDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
430
432
|
}
|
|
431
433
|
|
|
432
434
|
/**
|
package/api/payments-api.ts
CHANGED
|
@@ -42,11 +42,10 @@ export const PaymentsApiAxiosParamCreator = function (configuration?: Configurat
|
|
|
42
42
|
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
43
43
|
* @param {CompletePaymentSetupPspRequest} completePaymentSetupPspRequest
|
|
44
44
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
45
|
-
* @param {string} [idempotencyKey] Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough. For more information about Idempotency, check out the documentation.
|
|
46
45
|
* @param {*} [options] Override http request option.
|
|
47
46
|
* @throws {RequiredError}
|
|
48
47
|
*/
|
|
49
|
-
completePaymentSetup: async (customerCode: string, completePaymentSetupPspRequest: CompletePaymentSetupPspRequest, authorization?: string,
|
|
48
|
+
completePaymentSetup: async (customerCode: string, completePaymentSetupPspRequest: CompletePaymentSetupPspRequest, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
50
49
|
// verify required parameter 'customerCode' is not null or undefined
|
|
51
50
|
assertParamExists('completePaymentSetup', 'customerCode', customerCode)
|
|
52
51
|
// verify required parameter 'completePaymentSetupPspRequest' is not null or undefined
|
|
@@ -70,10 +69,6 @@ export const PaymentsApiAxiosParamCreator = function (configuration?: Configurat
|
|
|
70
69
|
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
71
70
|
}
|
|
72
71
|
|
|
73
|
-
if (idempotencyKey !== undefined && idempotencyKey !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
74
|
-
localVarHeaderParameter['Idempotency-Key'] = String(idempotencyKey ? idempotencyKey : baseAccessToken);
|
|
75
|
-
}
|
|
76
|
-
|
|
77
72
|
|
|
78
73
|
|
|
79
74
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
@@ -145,12 +140,11 @@ export const PaymentsApiFp = function(configuration?: Configuration) {
|
|
|
145
140
|
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
146
141
|
* @param {CompletePaymentSetupPspRequest} completePaymentSetupPspRequest
|
|
147
142
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
148
|
-
* @param {string} [idempotencyKey] Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough. For more information about Idempotency, check out the documentation.
|
|
149
143
|
* @param {*} [options] Override http request option.
|
|
150
144
|
* @throws {RequiredError}
|
|
151
145
|
*/
|
|
152
|
-
async completePaymentSetup(customerCode: string, completePaymentSetupPspRequest: CompletePaymentSetupPspRequest, authorization?: string,
|
|
153
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.completePaymentSetup(customerCode, completePaymentSetupPspRequest, authorization,
|
|
146
|
+
async completePaymentSetup(customerCode: string, completePaymentSetupPspRequest: CompletePaymentSetupPspRequest, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CompletePaymentSetupResponseClass>> {
|
|
147
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.completePaymentSetup(customerCode, completePaymentSetupPspRequest, authorization, options);
|
|
154
148
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
155
149
|
},
|
|
156
150
|
/**
|
|
@@ -181,12 +175,11 @@ export const PaymentsApiFactory = function (configuration?: Configuration, baseP
|
|
|
181
175
|
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
182
176
|
* @param {CompletePaymentSetupPspRequest} completePaymentSetupPspRequest
|
|
183
177
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
184
|
-
* @param {string} [idempotencyKey] Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough. For more information about Idempotency, check out the documentation.
|
|
185
178
|
* @param {*} [options] Override http request option.
|
|
186
179
|
* @throws {RequiredError}
|
|
187
180
|
*/
|
|
188
|
-
completePaymentSetup(customerCode: string, completePaymentSetupPspRequest: CompletePaymentSetupPspRequest, authorization?: string,
|
|
189
|
-
return localVarFp.completePaymentSetup(customerCode, completePaymentSetupPspRequest, authorization,
|
|
181
|
+
completePaymentSetup(customerCode: string, completePaymentSetupPspRequest: CompletePaymentSetupPspRequest, authorization?: string, options?: any): AxiosPromise<CompletePaymentSetupResponseClass> {
|
|
182
|
+
return localVarFp.completePaymentSetup(customerCode, completePaymentSetupPspRequest, authorization, options).then((request) => request(axios, basePath));
|
|
190
183
|
},
|
|
191
184
|
/**
|
|
192
185
|
* Request to initiate a payment change by customer.
|
|
@@ -228,13 +221,6 @@ export interface PaymentsApiCompletePaymentSetupRequest {
|
|
|
228
221
|
* @memberof PaymentsApiCompletePaymentSetup
|
|
229
222
|
*/
|
|
230
223
|
readonly authorization?: string
|
|
231
|
-
|
|
232
|
-
/**
|
|
233
|
-
* Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough. For more information about Idempotency, check out the documentation.
|
|
234
|
-
* @type {string}
|
|
235
|
-
* @memberof PaymentsApiCompletePaymentSetup
|
|
236
|
-
*/
|
|
237
|
-
readonly idempotencyKey?: string
|
|
238
224
|
}
|
|
239
225
|
|
|
240
226
|
/**
|
|
@@ -274,7 +260,7 @@ export class PaymentsApi extends BaseAPI {
|
|
|
274
260
|
* @memberof PaymentsApi
|
|
275
261
|
*/
|
|
276
262
|
public completePaymentSetup(requestParameters: PaymentsApiCompletePaymentSetupRequest, options?: AxiosRequestConfig) {
|
|
277
|
-
return PaymentsApiFp(this.configuration).completePaymentSetup(requestParameters.customerCode, requestParameters.completePaymentSetupPspRequest, requestParameters.authorization,
|
|
263
|
+
return PaymentsApiFp(this.configuration).completePaymentSetup(requestParameters.customerCode, requestParameters.completePaymentSetupPspRequest, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
278
264
|
}
|
|
279
265
|
|
|
280
266
|
/**
|
package/dist/api/claims-api.d.ts
CHANGED
|
@@ -15,6 +15,7 @@ import { RequestArgs, BaseAPI } from '../base';
|
|
|
15
15
|
import { CreateCustomerClaimRequestDto } from '../models';
|
|
16
16
|
import { CreateCustomerClaimResponseClass } from '../models';
|
|
17
17
|
import { CreatePresignedPostResponseClass } from '../models';
|
|
18
|
+
import { GetCustomerClaimResponseClass } from '../models';
|
|
18
19
|
import { ListCustomerClaimsResponseClass } from '../models';
|
|
19
20
|
import { UpdateCustomerClaimRequestDto } from '../models';
|
|
20
21
|
import { UpdateCustomerClaimResponseClass } from '../models';
|
|
@@ -35,6 +36,17 @@ export declare const ClaimsApiAxiosParamCreator: (configuration?: Configuration)
|
|
|
35
36
|
* @throws {RequiredError}
|
|
36
37
|
*/
|
|
37
38
|
createCustomerClaim: (customerCode: string, createCustomerClaimRequestDto: CreateCustomerClaimRequestDto, authorization?: string, authorization2?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
39
|
+
/**
|
|
40
|
+
* Get claim for customer.
|
|
41
|
+
* @summary Get claim
|
|
42
|
+
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
43
|
+
* @param {string} claimCode The claim code to identify a claim.
|
|
44
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
45
|
+
* @param {string} [authorization2] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
46
|
+
* @param {*} [options] Override http request option.
|
|
47
|
+
* @throws {RequiredError}
|
|
48
|
+
*/
|
|
49
|
+
getCustomerClaim: (customerCode: string, claimCode: string, authorization?: string, authorization2?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
38
50
|
/**
|
|
39
51
|
* List claims by customer.
|
|
40
52
|
* @summary List claims
|
|
@@ -92,6 +104,17 @@ export declare const ClaimsApiFp: (configuration?: Configuration) => {
|
|
|
92
104
|
* @throws {RequiredError}
|
|
93
105
|
*/
|
|
94
106
|
createCustomerClaim(customerCode: string, createCustomerClaimRequestDto: CreateCustomerClaimRequestDto, authorization?: string, authorization2?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateCustomerClaimResponseClass>>;
|
|
107
|
+
/**
|
|
108
|
+
* Get claim for customer.
|
|
109
|
+
* @summary Get claim
|
|
110
|
+
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
111
|
+
* @param {string} claimCode The claim code to identify a claim.
|
|
112
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
113
|
+
* @param {string} [authorization2] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
114
|
+
* @param {*} [options] Override http request option.
|
|
115
|
+
* @throws {RequiredError}
|
|
116
|
+
*/
|
|
117
|
+
getCustomerClaim(customerCode: string, claimCode: string, authorization?: string, authorization2?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetCustomerClaimResponseClass>>;
|
|
95
118
|
/**
|
|
96
119
|
* List claims by customer.
|
|
97
120
|
* @summary List claims
|
|
@@ -149,6 +172,17 @@ export declare const ClaimsApiFactory: (configuration?: Configuration, basePath?
|
|
|
149
172
|
* @throws {RequiredError}
|
|
150
173
|
*/
|
|
151
174
|
createCustomerClaim(customerCode: string, createCustomerClaimRequestDto: CreateCustomerClaimRequestDto, authorization?: string, authorization2?: string, options?: any): AxiosPromise<CreateCustomerClaimResponseClass>;
|
|
175
|
+
/**
|
|
176
|
+
* Get claim for customer.
|
|
177
|
+
* @summary Get claim
|
|
178
|
+
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
179
|
+
* @param {string} claimCode The claim code to identify a claim.
|
|
180
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
181
|
+
* @param {string} [authorization2] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
182
|
+
* @param {*} [options] Override http request option.
|
|
183
|
+
* @throws {RequiredError}
|
|
184
|
+
*/
|
|
185
|
+
getCustomerClaim(customerCode: string, claimCode: string, authorization?: string, authorization2?: string, options?: any): AxiosPromise<GetCustomerClaimResponseClass>;
|
|
152
186
|
/**
|
|
153
187
|
* List claims by customer.
|
|
154
188
|
* @summary List claims
|
|
@@ -221,6 +255,37 @@ export interface ClaimsApiCreateCustomerClaimRequest {
|
|
|
221
255
|
*/
|
|
222
256
|
readonly authorization2?: string;
|
|
223
257
|
}
|
|
258
|
+
/**
|
|
259
|
+
* Request parameters for getCustomerClaim operation in ClaimsApi.
|
|
260
|
+
* @export
|
|
261
|
+
* @interface ClaimsApiGetCustomerClaimRequest
|
|
262
|
+
*/
|
|
263
|
+
export interface ClaimsApiGetCustomerClaimRequest {
|
|
264
|
+
/**
|
|
265
|
+
* The customer code or \"me\" for the currently logged in customer.
|
|
266
|
+
* @type {string}
|
|
267
|
+
* @memberof ClaimsApiGetCustomerClaim
|
|
268
|
+
*/
|
|
269
|
+
readonly customerCode: string;
|
|
270
|
+
/**
|
|
271
|
+
* The claim code to identify a claim.
|
|
272
|
+
* @type {string}
|
|
273
|
+
* @memberof ClaimsApiGetCustomerClaim
|
|
274
|
+
*/
|
|
275
|
+
readonly claimCode: string;
|
|
276
|
+
/**
|
|
277
|
+
* Bearer Token: provided by the login endpoint under the name accessToken.
|
|
278
|
+
* @type {string}
|
|
279
|
+
* @memberof ClaimsApiGetCustomerClaim
|
|
280
|
+
*/
|
|
281
|
+
readonly authorization?: string;
|
|
282
|
+
/**
|
|
283
|
+
* Bearer Token: provided by the login endpoint under the name accessToken.
|
|
284
|
+
* @type {string}
|
|
285
|
+
* @memberof ClaimsApiGetCustomerClaim
|
|
286
|
+
*/
|
|
287
|
+
readonly authorization2?: string;
|
|
288
|
+
}
|
|
224
289
|
/**
|
|
225
290
|
* Request parameters for listCustomerClaims operation in ClaimsApi.
|
|
226
291
|
* @export
|
|
@@ -372,6 +437,15 @@ export declare class ClaimsApi extends BaseAPI {
|
|
|
372
437
|
* @memberof ClaimsApi
|
|
373
438
|
*/
|
|
374
439
|
createCustomerClaim(requestParameters: ClaimsApiCreateCustomerClaimRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateCustomerClaimResponseClass, any>>;
|
|
440
|
+
/**
|
|
441
|
+
* Get claim for customer.
|
|
442
|
+
* @summary Get claim
|
|
443
|
+
* @param {ClaimsApiGetCustomerClaimRequest} requestParameters Request parameters.
|
|
444
|
+
* @param {*} [options] Override http request option.
|
|
445
|
+
* @throws {RequiredError}
|
|
446
|
+
* @memberof ClaimsApi
|
|
447
|
+
*/
|
|
448
|
+
getCustomerClaim(requestParameters: ClaimsApiGetCustomerClaimRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetCustomerClaimResponseClass, any>>;
|
|
375
449
|
/**
|
|
376
450
|
* List claims by customer.
|
|
377
451
|
* @summary List claims
|
package/dist/api/claims-api.js
CHANGED
|
@@ -143,6 +143,52 @@ var ClaimsApiAxiosParamCreator = function (configuration) {
|
|
|
143
143
|
});
|
|
144
144
|
});
|
|
145
145
|
},
|
|
146
|
+
/**
|
|
147
|
+
* Get claim for customer.
|
|
148
|
+
* @summary Get claim
|
|
149
|
+
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
150
|
+
* @param {string} claimCode The claim code to identify a claim.
|
|
151
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
152
|
+
* @param {string} [authorization2] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
153
|
+
* @param {*} [options] Override http request option.
|
|
154
|
+
* @throws {RequiredError}
|
|
155
|
+
*/
|
|
156
|
+
getCustomerClaim: function (customerCode, claimCode, authorization, authorization2, options) {
|
|
157
|
+
if (options === void 0) { options = {}; }
|
|
158
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
159
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
160
|
+
return __generator(this, function (_a) {
|
|
161
|
+
// verify required parameter 'customerCode' is not null or undefined
|
|
162
|
+
(0, common_1.assertParamExists)('getCustomerClaim', 'customerCode', customerCode);
|
|
163
|
+
// verify required parameter 'claimCode' is not null or undefined
|
|
164
|
+
(0, common_1.assertParamExists)('getCustomerClaim', 'claimCode', claimCode);
|
|
165
|
+
localVarPath = "/v1/customers/{customerCode}/claims/{claimCode}"
|
|
166
|
+
.replace("{".concat("customerCode", "}"), encodeURIComponent(String(customerCode)))
|
|
167
|
+
.replace("{".concat("claimCode", "}"), encodeURIComponent(String(claimCode)));
|
|
168
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
169
|
+
if (configuration) {
|
|
170
|
+
baseOptions = configuration.baseOptions;
|
|
171
|
+
baseAccessToken = configuration.accessToken;
|
|
172
|
+
}
|
|
173
|
+
localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
|
|
174
|
+
localVarHeaderParameter = {};
|
|
175
|
+
localVarQueryParameter = {};
|
|
176
|
+
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
177
|
+
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
178
|
+
}
|
|
179
|
+
if (authorization2 !== undefined && authorization2 !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
180
|
+
localVarHeaderParameter['Authorization'] = String(authorization2 ? authorization2 : baseAccessToken);
|
|
181
|
+
}
|
|
182
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
183
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
184
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
185
|
+
return [2 /*return*/, {
|
|
186
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
187
|
+
options: localVarRequestOptions,
|
|
188
|
+
}];
|
|
189
|
+
});
|
|
190
|
+
});
|
|
191
|
+
},
|
|
146
192
|
/**
|
|
147
193
|
* List claims by customer.
|
|
148
194
|
* @summary List claims
|
|
@@ -344,6 +390,29 @@ var ClaimsApiFp = function (configuration) {
|
|
|
344
390
|
});
|
|
345
391
|
});
|
|
346
392
|
},
|
|
393
|
+
/**
|
|
394
|
+
* Get claim for customer.
|
|
395
|
+
* @summary Get claim
|
|
396
|
+
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
397
|
+
* @param {string} claimCode The claim code to identify a claim.
|
|
398
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
399
|
+
* @param {string} [authorization2] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
400
|
+
* @param {*} [options] Override http request option.
|
|
401
|
+
* @throws {RequiredError}
|
|
402
|
+
*/
|
|
403
|
+
getCustomerClaim: function (customerCode, claimCode, authorization, authorization2, options) {
|
|
404
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
405
|
+
var localVarAxiosArgs;
|
|
406
|
+
return __generator(this, function (_a) {
|
|
407
|
+
switch (_a.label) {
|
|
408
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.getCustomerClaim(customerCode, claimCode, authorization, authorization2, options)];
|
|
409
|
+
case 1:
|
|
410
|
+
localVarAxiosArgs = _a.sent();
|
|
411
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
412
|
+
}
|
|
413
|
+
});
|
|
414
|
+
});
|
|
415
|
+
},
|
|
347
416
|
/**
|
|
348
417
|
* List claims by customer.
|
|
349
418
|
* @summary List claims
|
|
@@ -443,6 +512,19 @@ var ClaimsApiFactory = function (configuration, basePath, axios) {
|
|
|
443
512
|
createCustomerClaim: function (customerCode, createCustomerClaimRequestDto, authorization, authorization2, options) {
|
|
444
513
|
return localVarFp.createCustomerClaim(customerCode, createCustomerClaimRequestDto, authorization, authorization2, options).then(function (request) { return request(axios, basePath); });
|
|
445
514
|
},
|
|
515
|
+
/**
|
|
516
|
+
* Get claim for customer.
|
|
517
|
+
* @summary Get claim
|
|
518
|
+
* @param {string} customerCode The customer code or \"me\" for the currently logged in customer.
|
|
519
|
+
* @param {string} claimCode The claim code to identify a claim.
|
|
520
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
521
|
+
* @param {string} [authorization2] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
522
|
+
* @param {*} [options] Override http request option.
|
|
523
|
+
* @throws {RequiredError}
|
|
524
|
+
*/
|
|
525
|
+
getCustomerClaim: function (customerCode, claimCode, authorization, authorization2, options) {
|
|
526
|
+
return localVarFp.getCustomerClaim(customerCode, claimCode, authorization, authorization2, options).then(function (request) { return request(axios, basePath); });
|
|
527
|
+
},
|
|
446
528
|
/**
|
|
447
529
|
* List claims by customer.
|
|
448
530
|
* @summary List claims
|
|
@@ -515,6 +597,18 @@ var ClaimsApi = /** @class */ (function (_super) {
|
|
|
515
597
|
var _this = this;
|
|
516
598
|
return (0, exports.ClaimsApiFp)(this.configuration).createCustomerClaim(requestParameters.customerCode, requestParameters.createCustomerClaimRequestDto, requestParameters.authorization, requestParameters.authorization2, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
517
599
|
};
|
|
600
|
+
/**
|
|
601
|
+
* Get claim for customer.
|
|
602
|
+
* @summary Get claim
|
|
603
|
+
* @param {ClaimsApiGetCustomerClaimRequest} requestParameters Request parameters.
|
|
604
|
+
* @param {*} [options] Override http request option.
|
|
605
|
+
* @throws {RequiredError}
|
|
606
|
+
* @memberof ClaimsApi
|
|
607
|
+
*/
|
|
608
|
+
ClaimsApi.prototype.getCustomerClaim = function (requestParameters, options) {
|
|
609
|
+
var _this = this;
|
|
610
|
+
return (0, exports.ClaimsApiFp)(this.configuration).getCustomerClaim(requestParameters.customerCode, requestParameters.claimCode, requestParameters.authorization, requestParameters.authorization2, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
611
|
+
};
|
|
518
612
|
/**
|
|
519
613
|
* List claims by customer.
|
|
520
614
|
* @summary List claims
|