@finverse/sdk-typescript 0.0.39 → 0.0.42

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.
Files changed (3) hide show
  1. package/dist/api.d.ts +187 -204
  2. package/dist/api.js +126 -160
  3. package/package.json +1 -1
package/dist/api.d.ts CHANGED
@@ -412,6 +412,69 @@ export interface CreateCustomerResponse {
412
412
  */
413
413
  webhook_uris?: Array<string>;
414
414
  }
415
+ /**
416
+ *
417
+ * @export
418
+ * @interface CreateMandateRequest
419
+ */
420
+ export interface CreateMandateRequest {
421
+ /**
422
+ *
423
+ * @type {MandateRecipient}
424
+ * @memberof CreateMandateRequest
425
+ */
426
+ recipient: MandateRecipient;
427
+ /**
428
+ *
429
+ * @type {CreateMandateSender}
430
+ * @memberof CreateMandateRequest
431
+ */
432
+ sender: CreateMandateSender;
433
+ /**
434
+ *
435
+ * @type {MandateDetails}
436
+ * @memberof CreateMandateRequest
437
+ */
438
+ mandate_details: MandateDetails;
439
+ }
440
+ /**
441
+ *
442
+ * @export
443
+ * @interface CreateMandateResponse
444
+ */
445
+ export interface CreateMandateResponse {
446
+ /**
447
+ * Finverse Mandate ID
448
+ * @type {string}
449
+ * @memberof CreateMandateResponse
450
+ */
451
+ mandate_id?: string;
452
+ }
453
+ /**
454
+ *
455
+ * @export
456
+ * @interface CreateMandateSender
457
+ */
458
+ export interface CreateMandateSender {
459
+ /**
460
+ *
461
+ * @type {string}
462
+ * @memberof CreateMandateSender
463
+ */
464
+ name?: string;
465
+ /**
466
+ * Customer App\'s user ID, representing the end-user making the payment.
467
+ * @type {string}
468
+ * @memberof CreateMandateSender
469
+ */
470
+ user_id: string;
471
+ /**
472
+ * Customer App\'s reference ID, representing the sender\'s account or billing reference number.
473
+ * @type {string}
474
+ * @memberof CreateMandateSender
475
+ */
476
+ sender_reference_id?: string;
477
+ }
415
478
  /**
416
479
  *
417
480
  * @export
@@ -829,84 +892,84 @@ export interface GetLoginIdentityHistoryResponse {
829
892
  /**
830
893
  *
831
894
  * @export
832
- * @interface GetMandateSender
833
- */
834
- export interface GetMandateSender {
835
- /**
836
- *
837
- * @type {string}
838
- * @memberof GetMandateSender
839
- */
840
- name?: string;
841
- /**
842
- * Customer App\'s user ID, representing the end-user making the payment.
843
- * @type {string}
844
- * @memberof GetMandateSender
845
- */
846
- user_id: string;
847
- /**
848
- * Customer App\'s reference ID, representing the sender\'s account or billing reference number.
849
- * @type {string}
850
- * @memberof GetMandateSender
851
- */
852
- sender_reference_id?: string;
853
- /**
854
- *
855
- * @type {PaymentAccount}
856
- * @memberof GetMandateSender
857
- */
858
- sender_account: PaymentAccount;
859
- }
860
- /**
861
- *
862
- * @export
863
- * @interface GetMandatesResponse
895
+ * @interface GetMandateResponse
864
896
  */
865
- export interface GetMandatesResponse {
897
+ export interface GetMandateResponse {
866
898
  /**
867
899
  * Timestamp in ISO format (YYYY-MM-DDTHH:MM:SS.SSSZ)
868
900
  * @type {string}
869
- * @memberof GetMandatesResponse
901
+ * @memberof GetMandateResponse
870
902
  */
871
903
  last_update: string;
872
904
  /**
873
905
  * Finverse Mandate ID (ULID)
874
906
  * @type {string}
875
- * @memberof GetMandatesResponse
907
+ * @memberof GetMandateResponse
876
908
  */
877
909
  mandate_id: string;
878
910
  /**
879
911
  * Mandate status
880
912
  * @type {string}
881
- * @memberof GetMandatesResponse
913
+ * @memberof GetMandateResponse
882
914
  */
883
- mandate_status: GetMandatesResponseMandateStatusEnum;
915
+ mandate_status: GetMandateResponseMandateStatusEnum;
884
916
  /**
885
917
  *
886
918
  * @type {MandateRecipient}
887
- * @memberof GetMandatesResponse
919
+ * @memberof GetMandateResponse
888
920
  */
889
921
  recipient: MandateRecipient;
890
922
  /**
891
923
  *
892
924
  * @type {GetMandateSender}
893
- * @memberof GetMandatesResponse
925
+ * @memberof GetMandateResponse
894
926
  */
895
927
  sender: GetMandateSender;
896
928
  /**
897
929
  *
898
930
  * @type {MandateDetails}
899
- * @memberof GetMandatesResponse
931
+ * @memberof GetMandateResponse
900
932
  */
901
933
  mandate_details: MandateDetails;
902
934
  }
903
- export declare const GetMandatesResponseMandateStatusEnum: {
935
+ export declare const GetMandateResponseMandateStatusEnum: {
904
936
  readonly Created: "CREATED";
905
937
  readonly Used: "USED";
906
938
  readonly Submitted: "SUBMITTED";
907
939
  readonly Error: "ERROR";
908
940
  };
909
- export declare type GetMandatesResponseMandateStatusEnum = typeof GetMandatesResponseMandateStatusEnum[keyof typeof GetMandatesResponseMandateStatusEnum];
941
+ export declare type GetMandateResponseMandateStatusEnum = typeof GetMandateResponseMandateStatusEnum[keyof typeof GetMandateResponseMandateStatusEnum];
942
+ /**
943
+ *
944
+ * @export
945
+ * @interface GetMandateSender
946
+ */
947
+ export interface GetMandateSender {
948
+ /**
949
+ *
950
+ * @type {string}
951
+ * @memberof GetMandateSender
952
+ */
953
+ name?: string;
954
+ /**
955
+ * Customer App\'s user ID, representing the end-user making the payment.
956
+ * @type {string}
957
+ * @memberof GetMandateSender
958
+ */
959
+ user_id: string;
960
+ /**
961
+ * Customer App\'s reference ID, representing the sender\'s account or billing reference number.
962
+ * @type {string}
963
+ * @memberof GetMandateSender
964
+ */
965
+ sender_reference_id?: string;
966
+ /**
967
+ *
968
+ * @type {PaymentAccount}
969
+ * @memberof GetMandateSender
970
+ */
971
+ sender_account: PaymentAccount;
972
+ }
910
973
  /**
911
974
  *
912
975
  * @export
@@ -2516,69 +2579,6 @@ export declare const PaymentScheduleFrequencyEnum: {
2516
2579
  readonly Yearly: "YEARLY";
2517
2580
  };
2518
2581
  export declare type PaymentScheduleFrequencyEnum = typeof PaymentScheduleFrequencyEnum[keyof typeof PaymentScheduleFrequencyEnum];
2519
- /**
2520
- *
2521
- * @export
2522
- * @interface PostMandateSender
2523
- */
2524
- export interface PostMandateSender {
2525
- /**
2526
- *
2527
- * @type {string}
2528
- * @memberof PostMandateSender
2529
- */
2530
- name?: string;
2531
- /**
2532
- * Customer App\'s user ID, representing the end-user making the payment.
2533
- * @type {string}
2534
- * @memberof PostMandateSender
2535
- */
2536
- user_id: string;
2537
- /**
2538
- * Customer App\'s reference ID, representing the sender\'s account or billing reference number.
2539
- * @type {string}
2540
- * @memberof PostMandateSender
2541
- */
2542
- sender_reference_id?: string;
2543
- }
2544
- /**
2545
- *
2546
- * @export
2547
- * @interface PostMandatesRequest
2548
- */
2549
- export interface PostMandatesRequest {
2550
- /**
2551
- *
2552
- * @type {MandateRecipient}
2553
- * @memberof PostMandatesRequest
2554
- */
2555
- recipient: MandateRecipient;
2556
- /**
2557
- *
2558
- * @type {PostMandateSender}
2559
- * @memberof PostMandatesRequest
2560
- */
2561
- sender: PostMandateSender;
2562
- /**
2563
- *
2564
- * @type {MandateDetails}
2565
- * @memberof PostMandatesRequest
2566
- */
2567
- mandate_details: MandateDetails;
2568
- }
2569
- /**
2570
- *
2571
- * @export
2572
- * @interface PostMandatesResponse
2573
- */
2574
- export interface PostMandatesResponse {
2575
- /**
2576
- * Finverse Mandate ID
2577
- * @type {string}
2578
- * @memberof PostMandatesResponse
2579
- */
2580
- mandate_id?: string;
2581
- }
2582
2582
  /**
2583
2583
  *
2584
2584
  * @export
@@ -3025,13 +3025,21 @@ export declare type TransactionLimitsPeriodEnum = typeof TransactionLimitsPeriod
3025
3025
  * @export
3026
3026
  */
3027
3027
  export declare const CustomerApiAxiosParamCreator: (configuration?: Configuration) => {
3028
+ /**
3029
+ * CREATE Mandate
3030
+ * @param {CreateMandateRequest} createMandateRequest request body for creating mandate
3031
+ * @param {*} [options] Override http request option.
3032
+ * @throws {RequiredError}
3033
+ */
3034
+ createMandate: (createMandateRequest: CreateMandateRequest, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3028
3035
  /**
3029
3036
  * Create new Payment
3030
3037
  * @param {CreatePaymentRequest} createPaymentRequest request body for creating payment
3038
+ * @param {string} [idempotencyKey] A random key provided by the customer, per unique payment. If missing we will generate a random one. The purpose for the Idempotency key is to allow safe retrying without the operation being performed multiple times.
3031
3039
  * @param {*} [options] Override http request option.
3032
3040
  * @throws {RequiredError}
3033
3041
  */
3034
- createPayment: (createPaymentRequest: CreatePaymentRequest, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3042
+ createPayment: (createPaymentRequest: CreatePaymentRequest, idempotencyKey?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3035
3043
  /**
3036
3044
  * Create a new payment instruction to be used when linking to perform new payment
3037
3045
  * @param {CustomerPaymentInstruction} paymentInstruction Request body for starting a new Link
@@ -3068,12 +3076,12 @@ export declare const CustomerApiAxiosParamCreator: (configuration?: Configuratio
3068
3076
  */
3069
3077
  getLoginIdentityHistory: (loginIdentityId: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3070
3078
  /**
3071
- * Get Mandates details by mandate_id
3079
+ * Get Mandate details by mandate_id
3072
3080
  * @param {string} mandateId mandate id
3073
3081
  * @param {*} [options] Override http request option.
3074
3082
  * @throws {RequiredError}
3075
3083
  */
3076
- getMandates: (mandateId: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3084
+ getMandate: (mandateId: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3077
3085
  /**
3078
3086
  * Get Payment details by payment_id
3079
3087
  * @param {string} paymentId payment id
@@ -3098,13 +3106,6 @@ export declare const CustomerApiAxiosParamCreator: (configuration?: Configuratio
3098
3106
  * @throws {RequiredError}
3099
3107
  */
3100
3108
  listInstitutions: (country?: string, countries?: Array<string>, productsSupported?: string, institutionType?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3101
- /**
3102
- * CREATE Mandates
3103
- * @param {PostMandatesRequest} postMandatesRequest request body for creating mandate
3104
- * @param {*} [options] Override http request option.
3105
- * @throws {RequiredError}
3106
- */
3107
- postMandates: (postMandatesRequest: PostMandatesRequest, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3108
3109
  /**
3109
3110
  * Refresh an access token
3110
3111
  * @param {RefreshRequest} refreshRequest The refresh token
@@ -3118,13 +3119,21 @@ export declare const CustomerApiAxiosParamCreator: (configuration?: Configuratio
3118
3119
  * @export
3119
3120
  */
3120
3121
  export declare const CustomerApiFp: (configuration?: Configuration) => {
3122
+ /**
3123
+ * CREATE Mandate
3124
+ * @param {CreateMandateRequest} createMandateRequest request body for creating mandate
3125
+ * @param {*} [options] Override http request option.
3126
+ * @throws {RequiredError}
3127
+ */
3128
+ createMandate(createMandateRequest: CreateMandateRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateMandateResponse>>;
3121
3129
  /**
3122
3130
  * Create new Payment
3123
3131
  * @param {CreatePaymentRequest} createPaymentRequest request body for creating payment
3132
+ * @param {string} [idempotencyKey] A random key provided by the customer, per unique payment. If missing we will generate a random one. The purpose for the Idempotency key is to allow safe retrying without the operation being performed multiple times.
3124
3133
  * @param {*} [options] Override http request option.
3125
3134
  * @throws {RequiredError}
3126
3135
  */
3127
- createPayment(createPaymentRequest: CreatePaymentRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreatePaymentResponse>>;
3136
+ createPayment(createPaymentRequest: CreatePaymentRequest, idempotencyKey?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreatePaymentResponse>>;
3128
3137
  /**
3129
3138
  * Create a new payment instruction to be used when linking to perform new payment
3130
3139
  * @param {CustomerPaymentInstruction} paymentInstruction Request body for starting a new Link
@@ -3161,12 +3170,12 @@ export declare const CustomerApiFp: (configuration?: Configuration) => {
3161
3170
  */
3162
3171
  getLoginIdentityHistory(loginIdentityId: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetLoginIdentityHistoryResponse>>;
3163
3172
  /**
3164
- * Get Mandates details by mandate_id
3173
+ * Get Mandate details by mandate_id
3165
3174
  * @param {string} mandateId mandate id
3166
3175
  * @param {*} [options] Override http request option.
3167
3176
  * @throws {RequiredError}
3168
3177
  */
3169
- getMandates(mandateId: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetMandatesResponse>>;
3178
+ getMandate(mandateId: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetMandateResponse>>;
3170
3179
  /**
3171
3180
  * Get Payment details by payment_id
3172
3181
  * @param {string} paymentId payment id
@@ -3191,13 +3200,6 @@ export declare const CustomerApiFp: (configuration?: Configuration) => {
3191
3200
  * @throws {RequiredError}
3192
3201
  */
3193
3202
  listInstitutions(country?: string, countries?: Array<string>, productsSupported?: string, institutionType?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<Institution>>>;
3194
- /**
3195
- * CREATE Mandates
3196
- * @param {PostMandatesRequest} postMandatesRequest request body for creating mandate
3197
- * @param {*} [options] Override http request option.
3198
- * @throws {RequiredError}
3199
- */
3200
- postMandates(postMandatesRequest: PostMandatesRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PostMandatesResponse>>;
3201
3203
  /**
3202
3204
  * Refresh an access token
3203
3205
  * @param {RefreshRequest} refreshRequest The refresh token
@@ -3211,13 +3213,21 @@ export declare const CustomerApiFp: (configuration?: Configuration) => {
3211
3213
  * @export
3212
3214
  */
3213
3215
  export declare const CustomerApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
3216
+ /**
3217
+ * CREATE Mandate
3218
+ * @param {CreateMandateRequest} createMandateRequest request body for creating mandate
3219
+ * @param {*} [options] Override http request option.
3220
+ * @throws {RequiredError}
3221
+ */
3222
+ createMandate(createMandateRequest: CreateMandateRequest, options?: any): AxiosPromise<CreateMandateResponse>;
3214
3223
  /**
3215
3224
  * Create new Payment
3216
3225
  * @param {CreatePaymentRequest} createPaymentRequest request body for creating payment
3226
+ * @param {string} [idempotencyKey] A random key provided by the customer, per unique payment. If missing we will generate a random one. The purpose for the Idempotency key is to allow safe retrying without the operation being performed multiple times.
3217
3227
  * @param {*} [options] Override http request option.
3218
3228
  * @throws {RequiredError}
3219
3229
  */
3220
- createPayment(createPaymentRequest: CreatePaymentRequest, options?: any): AxiosPromise<CreatePaymentResponse>;
3230
+ createPayment(createPaymentRequest: CreatePaymentRequest, idempotencyKey?: string, options?: any): AxiosPromise<CreatePaymentResponse>;
3221
3231
  /**
3222
3232
  * Create a new payment instruction to be used when linking to perform new payment
3223
3233
  * @param {CustomerPaymentInstruction} paymentInstruction Request body for starting a new Link
@@ -3254,12 +3264,12 @@ export declare const CustomerApiFactory: (configuration?: Configuration, basePat
3254
3264
  */
3255
3265
  getLoginIdentityHistory(loginIdentityId: string, options?: any): AxiosPromise<GetLoginIdentityHistoryResponse>;
3256
3266
  /**
3257
- * Get Mandates details by mandate_id
3267
+ * Get Mandate details by mandate_id
3258
3268
  * @param {string} mandateId mandate id
3259
3269
  * @param {*} [options] Override http request option.
3260
3270
  * @throws {RequiredError}
3261
3271
  */
3262
- getMandates(mandateId: string, options?: any): AxiosPromise<GetMandatesResponse>;
3272
+ getMandate(mandateId: string, options?: any): AxiosPromise<GetMandateResponse>;
3263
3273
  /**
3264
3274
  * Get Payment details by payment_id
3265
3275
  * @param {string} paymentId payment id
@@ -3284,13 +3294,6 @@ export declare const CustomerApiFactory: (configuration?: Configuration, basePat
3284
3294
  * @throws {RequiredError}
3285
3295
  */
3286
3296
  listInstitutions(country?: string, countries?: Array<string>, productsSupported?: string, institutionType?: string, options?: any): AxiosPromise<Array<Institution>>;
3287
- /**
3288
- * CREATE Mandates
3289
- * @param {PostMandatesRequest} postMandatesRequest request body for creating mandate
3290
- * @param {*} [options] Override http request option.
3291
- * @throws {RequiredError}
3292
- */
3293
- postMandates(postMandatesRequest: PostMandatesRequest, options?: any): AxiosPromise<PostMandatesResponse>;
3294
3297
  /**
3295
3298
  * Refresh an access token
3296
3299
  * @param {RefreshRequest} refreshRequest The refresh token
@@ -3305,14 +3308,23 @@ export declare const CustomerApiFactory: (configuration?: Configuration, basePat
3305
3308
  * @interface CustomerApi
3306
3309
  */
3307
3310
  export interface CustomerApiInterface {
3311
+ /**
3312
+ * CREATE Mandate
3313
+ * @param {CreateMandateRequest} createMandateRequest request body for creating mandate
3314
+ * @param {*} [options] Override http request option.
3315
+ * @throws {RequiredError}
3316
+ * @memberof CustomerApiInterface
3317
+ */
3318
+ createMandate(createMandateRequest: CreateMandateRequest, options?: AxiosRequestConfig): AxiosPromise<CreateMandateResponse>;
3308
3319
  /**
3309
3320
  * Create new Payment
3310
3321
  * @param {CreatePaymentRequest} createPaymentRequest request body for creating payment
3322
+ * @param {string} [idempotencyKey] A random key provided by the customer, per unique payment. If missing we will generate a random one. The purpose for the Idempotency key is to allow safe retrying without the operation being performed multiple times.
3311
3323
  * @param {*} [options] Override http request option.
3312
3324
  * @throws {RequiredError}
3313
3325
  * @memberof CustomerApiInterface
3314
3326
  */
3315
- createPayment(createPaymentRequest: CreatePaymentRequest, options?: AxiosRequestConfig): AxiosPromise<CreatePaymentResponse>;
3327
+ createPayment(createPaymentRequest: CreatePaymentRequest, idempotencyKey?: string, options?: AxiosRequestConfig): AxiosPromise<CreatePaymentResponse>;
3316
3328
  /**
3317
3329
  * Create a new payment instruction to be used when linking to perform new payment
3318
3330
  * @param {CustomerPaymentInstruction} paymentInstruction Request body for starting a new Link
@@ -3354,13 +3366,13 @@ export interface CustomerApiInterface {
3354
3366
  */
3355
3367
  getLoginIdentityHistory(loginIdentityId: string, options?: AxiosRequestConfig): AxiosPromise<GetLoginIdentityHistoryResponse>;
3356
3368
  /**
3357
- * Get Mandates details by mandate_id
3369
+ * Get Mandate details by mandate_id
3358
3370
  * @param {string} mandateId mandate id
3359
3371
  * @param {*} [options] Override http request option.
3360
3372
  * @throws {RequiredError}
3361
3373
  * @memberof CustomerApiInterface
3362
3374
  */
3363
- getMandates(mandateId: string, options?: AxiosRequestConfig): AxiosPromise<GetMandatesResponse>;
3375
+ getMandate(mandateId: string, options?: AxiosRequestConfig): AxiosPromise<GetMandateResponse>;
3364
3376
  /**
3365
3377
  * Get Payment details by payment_id
3366
3378
  * @param {string} paymentId payment id
@@ -3388,14 +3400,6 @@ export interface CustomerApiInterface {
3388
3400
  * @memberof CustomerApiInterface
3389
3401
  */
3390
3402
  listInstitutions(country?: string, countries?: Array<string>, productsSupported?: string, institutionType?: string, options?: AxiosRequestConfig): AxiosPromise<Array<Institution>>;
3391
- /**
3392
- * CREATE Mandates
3393
- * @param {PostMandatesRequest} postMandatesRequest request body for creating mandate
3394
- * @param {*} [options] Override http request option.
3395
- * @throws {RequiredError}
3396
- * @memberof CustomerApiInterface
3397
- */
3398
- postMandates(postMandatesRequest: PostMandatesRequest, options?: AxiosRequestConfig): AxiosPromise<PostMandatesResponse>;
3399
3403
  /**
3400
3404
  * Refresh an access token
3401
3405
  * @param {RefreshRequest} refreshRequest The refresh token
@@ -3412,14 +3416,23 @@ export interface CustomerApiInterface {
3412
3416
  * @extends {BaseAPI}
3413
3417
  */
3414
3418
  export declare class CustomerApi extends BaseAPI implements CustomerApiInterface {
3419
+ /**
3420
+ * CREATE Mandate
3421
+ * @param {CreateMandateRequest} createMandateRequest request body for creating mandate
3422
+ * @param {*} [options] Override http request option.
3423
+ * @throws {RequiredError}
3424
+ * @memberof CustomerApi
3425
+ */
3426
+ createMandate(createMandateRequest: CreateMandateRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateMandateResponse>>;
3415
3427
  /**
3416
3428
  * Create new Payment
3417
3429
  * @param {CreatePaymentRequest} createPaymentRequest request body for creating payment
3430
+ * @param {string} [idempotencyKey] A random key provided by the customer, per unique payment. If missing we will generate a random one. The purpose for the Idempotency key is to allow safe retrying without the operation being performed multiple times.
3418
3431
  * @param {*} [options] Override http request option.
3419
3432
  * @throws {RequiredError}
3420
3433
  * @memberof CustomerApi
3421
3434
  */
3422
- createPayment(createPaymentRequest: CreatePaymentRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreatePaymentResponse>>;
3435
+ createPayment(createPaymentRequest: CreatePaymentRequest, idempotencyKey?: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreatePaymentResponse>>;
3423
3436
  /**
3424
3437
  * Create a new payment instruction to be used when linking to perform new payment
3425
3438
  * @param {CustomerPaymentInstruction} paymentInstruction Request body for starting a new Link
@@ -3461,13 +3474,13 @@ export declare class CustomerApi extends BaseAPI implements CustomerApiInterface
3461
3474
  */
3462
3475
  getLoginIdentityHistory(loginIdentityId: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetLoginIdentityHistoryResponse>>;
3463
3476
  /**
3464
- * Get Mandates details by mandate_id
3477
+ * Get Mandate details by mandate_id
3465
3478
  * @param {string} mandateId mandate id
3466
3479
  * @param {*} [options] Override http request option.
3467
3480
  * @throws {RequiredError}
3468
3481
  * @memberof CustomerApi
3469
3482
  */
3470
- getMandates(mandateId: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetMandatesResponse>>;
3483
+ getMandate(mandateId: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetMandateResponse>>;
3471
3484
  /**
3472
3485
  * Get Payment details by payment_id
3473
3486
  * @param {string} paymentId payment id
@@ -3495,14 +3508,6 @@ export declare class CustomerApi extends BaseAPI implements CustomerApiInterface
3495
3508
  * @memberof CustomerApi
3496
3509
  */
3497
3510
  listInstitutions(country?: string, countries?: Array<string>, productsSupported?: string, institutionType?: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<Institution[]>>;
3498
- /**
3499
- * CREATE Mandates
3500
- * @param {PostMandatesRequest} postMandatesRequest request body for creating mandate
3501
- * @param {*} [options] Override http request option.
3502
- * @throws {RequiredError}
3503
- * @memberof CustomerApi
3504
- */
3505
- postMandates(postMandatesRequest: PostMandatesRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<PostMandatesResponse>>;
3506
3511
  /**
3507
3512
  * Refresh an access token
3508
3513
  * @param {RefreshRequest} refreshRequest The refresh token
@@ -3796,16 +3801,11 @@ export declare const LoginIdentityApiAxiosParamCreator: (configuration?: Configu
3796
3801
  getBalanceHistory: (accountId: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3797
3802
  /**
3798
3803
  * Download composite statement
3804
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
3799
3805
  * @param {*} [options] Override http request option.
3800
3806
  * @throws {RequiredError}
3801
3807
  */
3802
- getCompositeStatement: (options?: AxiosRequestConfig) => Promise<RequestArgs>;
3803
- /**
3804
- * Get composite statement link for download
3805
- * @param {*} [options] Override http request option.
3806
- * @throws {RequiredError}
3807
- */
3808
- getCompositeStatementLink: (options?: AxiosRequestConfig) => Promise<RequestArgs>;
3808
+ getCompositeStatement: (redirect?: boolean, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3809
3809
  /**
3810
3810
  * \\[BETA] Get a list of identity data for a given login identity
3811
3811
  * @param {*} [options] Override http request option.
@@ -3827,12 +3827,13 @@ export declare const LoginIdentityApiAxiosParamCreator: (configuration?: Configu
3827
3827
  /**
3828
3828
  * Download statement
3829
3829
  * @param {string} statementId The statement id
3830
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
3830
3831
  * @param {*} [options] Override http request option.
3831
3832
  * @throws {RequiredError}
3832
3833
  */
3833
- getStatement: (statementId: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3834
+ getStatement: (statementId: string, redirect?: boolean, options?: AxiosRequestConfig) => Promise<RequestArgs>;
3834
3835
  /**
3835
- * Get statement link for download
3836
+ * (Deprecated) Get statement link for download
3836
3837
  * @param {string} statementId The statement id
3837
3838
  * @param {*} [options] Override http request option.
3838
3839
  * @throws {RequiredError}
@@ -3915,16 +3916,11 @@ export declare const LoginIdentityApiFp: (configuration?: Configuration) => {
3915
3916
  getBalanceHistory(accountId: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetBalanceHistoryResponse>>;
3916
3917
  /**
3917
3918
  * Download composite statement
3919
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
3918
3920
  * @param {*} [options] Override http request option.
3919
3921
  * @throws {RequiredError}
3920
3922
  */
3921
- getCompositeStatement(options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
3922
- /**
3923
- * Get composite statement link for download
3924
- * @param {*} [options] Override http request option.
3925
- * @throws {RequiredError}
3926
- */
3927
- getCompositeStatementLink(options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CompositeStatementLink>>;
3923
+ getCompositeStatement(redirect?: boolean, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CompositeStatementLink>>;
3928
3924
  /**
3929
3925
  * \\[BETA] Get a list of identity data for a given login identity
3930
3926
  * @param {*} [options] Override http request option.
@@ -3946,12 +3942,13 @@ export declare const LoginIdentityApiFp: (configuration?: Configuration) => {
3946
3942
  /**
3947
3943
  * Download statement
3948
3944
  * @param {string} statementId The statement id
3945
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
3949
3946
  * @param {*} [options] Override http request option.
3950
3947
  * @throws {RequiredError}
3951
3948
  */
3952
- getStatement(statementId: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
3949
+ getStatement(statementId: string, redirect?: boolean, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetStatementLinkResponse>>;
3953
3950
  /**
3954
- * Get statement link for download
3951
+ * (Deprecated) Get statement link for download
3955
3952
  * @param {string} statementId The statement id
3956
3953
  * @param {*} [options] Override http request option.
3957
3954
  * @throws {RequiredError}
@@ -4034,16 +4031,11 @@ export declare const LoginIdentityApiFactory: (configuration?: Configuration, ba
4034
4031
  getBalanceHistory(accountId: string, options?: any): AxiosPromise<GetBalanceHistoryResponse>;
4035
4032
  /**
4036
4033
  * Download composite statement
4034
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
4037
4035
  * @param {*} [options] Override http request option.
4038
4036
  * @throws {RequiredError}
4039
4037
  */
4040
- getCompositeStatement(options?: any): AxiosPromise<void>;
4041
- /**
4042
- * Get composite statement link for download
4043
- * @param {*} [options] Override http request option.
4044
- * @throws {RequiredError}
4045
- */
4046
- getCompositeStatementLink(options?: any): AxiosPromise<CompositeStatementLink>;
4038
+ getCompositeStatement(redirect?: boolean, options?: any): AxiosPromise<CompositeStatementLink>;
4047
4039
  /**
4048
4040
  * \\[BETA] Get a list of identity data for a given login identity
4049
4041
  * @param {*} [options] Override http request option.
@@ -4065,12 +4057,13 @@ export declare const LoginIdentityApiFactory: (configuration?: Configuration, ba
4065
4057
  /**
4066
4058
  * Download statement
4067
4059
  * @param {string} statementId The statement id
4060
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
4068
4061
  * @param {*} [options] Override http request option.
4069
4062
  * @throws {RequiredError}
4070
4063
  */
4071
- getStatement(statementId: string, options?: any): AxiosPromise<void>;
4064
+ getStatement(statementId: string, redirect?: boolean, options?: any): AxiosPromise<GetStatementLinkResponse>;
4072
4065
  /**
4073
- * Get statement link for download
4066
+ * (Deprecated) Get statement link for download
4074
4067
  * @param {string} statementId The statement id
4075
4068
  * @param {*} [options] Override http request option.
4076
4069
  * @throws {RequiredError}
@@ -4159,18 +4152,12 @@ export interface LoginIdentityApiInterface {
4159
4152
  getBalanceHistory(accountId: string, options?: AxiosRequestConfig): AxiosPromise<GetBalanceHistoryResponse>;
4160
4153
  /**
4161
4154
  * Download composite statement
4155
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
4162
4156
  * @param {*} [options] Override http request option.
4163
4157
  * @throws {RequiredError}
4164
4158
  * @memberof LoginIdentityApiInterface
4165
4159
  */
4166
- getCompositeStatement(options?: AxiosRequestConfig): AxiosPromise<void>;
4167
- /**
4168
- * Get composite statement link for download
4169
- * @param {*} [options] Override http request option.
4170
- * @throws {RequiredError}
4171
- * @memberof LoginIdentityApiInterface
4172
- */
4173
- getCompositeStatementLink(options?: AxiosRequestConfig): AxiosPromise<CompositeStatementLink>;
4160
+ getCompositeStatement(redirect?: boolean, options?: AxiosRequestConfig): AxiosPromise<CompositeStatementLink>;
4174
4161
  /**
4175
4162
  * \\[BETA] Get a list of identity data for a given login identity
4176
4163
  * @param {*} [options] Override http request option.
@@ -4195,13 +4182,14 @@ export interface LoginIdentityApiInterface {
4195
4182
  /**
4196
4183
  * Download statement
4197
4184
  * @param {string} statementId The statement id
4185
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
4198
4186
  * @param {*} [options] Override http request option.
4199
4187
  * @throws {RequiredError}
4200
4188
  * @memberof LoginIdentityApiInterface
4201
4189
  */
4202
- getStatement(statementId: string, options?: AxiosRequestConfig): AxiosPromise<void>;
4190
+ getStatement(statementId: string, redirect?: boolean, options?: AxiosRequestConfig): AxiosPromise<GetStatementLinkResponse>;
4203
4191
  /**
4204
- * Get statement link for download
4192
+ * (Deprecated) Get statement link for download
4205
4193
  * @param {string} statementId The statement id
4206
4194
  * @param {*} [options] Override http request option.
4207
4195
  * @throws {RequiredError}
@@ -4297,18 +4285,12 @@ export declare class LoginIdentityApi extends BaseAPI implements LoginIdentityAp
4297
4285
  getBalanceHistory(accountId: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetBalanceHistoryResponse>>;
4298
4286
  /**
4299
4287
  * Download composite statement
4288
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
4300
4289
  * @param {*} [options] Override http request option.
4301
4290
  * @throws {RequiredError}
4302
4291
  * @memberof LoginIdentityApi
4303
4292
  */
4304
- getCompositeStatement(options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void>>;
4305
- /**
4306
- * Get composite statement link for download
4307
- * @param {*} [options] Override http request option.
4308
- * @throws {RequiredError}
4309
- * @memberof LoginIdentityApi
4310
- */
4311
- getCompositeStatementLink(options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CompositeStatementLink>>;
4293
+ getCompositeStatement(redirect?: boolean, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CompositeStatementLink>>;
4312
4294
  /**
4313
4295
  * \\[BETA] Get a list of identity data for a given login identity
4314
4296
  * @param {*} [options] Override http request option.
@@ -4333,13 +4315,14 @@ export declare class LoginIdentityApi extends BaseAPI implements LoginIdentityAp
4333
4315
  /**
4334
4316
  * Download statement
4335
4317
  * @param {string} statementId The statement id
4318
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
4336
4319
  * @param {*} [options] Override http request option.
4337
4320
  * @throws {RequiredError}
4338
4321
  * @memberof LoginIdentityApi
4339
4322
  */
4340
- getStatement(statementId: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void>>;
4323
+ getStatement(statementId: string, redirect?: boolean, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetStatementLinkResponse>>;
4341
4324
  /**
4342
- * Get statement link for download
4325
+ * (Deprecated) Get statement link for download
4343
4326
  * @param {string} statementId The statement id
4344
4327
  * @param {*} [options] Override http request option.
4345
4328
  * @throws {RequiredError}
package/dist/api.js CHANGED
@@ -22,7 +22,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
22
22
  });
23
23
  };
24
24
  Object.defineProperty(exports, "__esModule", { value: true });
25
- exports.PublicApi = exports.PublicApiFactory = exports.PublicApiFp = exports.PublicApiAxiosParamCreator = exports.LoginIdentityApi = exports.LoginIdentityApiFactory = exports.LoginIdentityApiFp = exports.LoginIdentityApiAxiosParamCreator = exports.LinkApi = exports.LinkApiFactory = exports.LinkApiFp = exports.LinkApiAxiosParamCreator = exports.CustomerApi = exports.CustomerApiFactory = exports.CustomerApiFp = exports.CustomerApiAxiosParamCreator = exports.TransactionLimitsPeriodEnum = exports.PaymentScheduleFrequencyEnum = exports.PaymentInstructionTypeEnum = exports.LinkTokenRequestAutomaticDataRefreshEnum = exports.LinkTokenRequestUiModeEnum = exports.GetPaymentResponseStatusEnum = exports.GetPaymentResponseTypeEnum = exports.GetMandatesResponseMandateStatusEnum = exports.CustomerPaymentInstructionTypeEnum = exports.CreatePaymentRequestTypeEnum = void 0;
25
+ exports.PublicApi = exports.PublicApiFactory = exports.PublicApiFp = exports.PublicApiAxiosParamCreator = exports.LoginIdentityApi = exports.LoginIdentityApiFactory = exports.LoginIdentityApiFp = exports.LoginIdentityApiAxiosParamCreator = exports.LinkApi = exports.LinkApiFactory = exports.LinkApiFp = exports.LinkApiAxiosParamCreator = exports.CustomerApi = exports.CustomerApiFactory = exports.CustomerApiFp = exports.CustomerApiAxiosParamCreator = exports.TransactionLimitsPeriodEnum = exports.PaymentScheduleFrequencyEnum = exports.PaymentInstructionTypeEnum = exports.LinkTokenRequestAutomaticDataRefreshEnum = exports.LinkTokenRequestUiModeEnum = exports.GetPaymentResponseStatusEnum = exports.GetPaymentResponseTypeEnum = exports.GetMandateResponseMandateStatusEnum = exports.CustomerPaymentInstructionTypeEnum = exports.CreatePaymentRequestTypeEnum = void 0;
26
26
  const axios_1 = require("axios");
27
27
  // Some imports not used depending on template conditions
28
28
  // @ts-ignore
@@ -36,7 +36,7 @@ exports.CreatePaymentRequestTypeEnum = {
36
36
  exports.CustomerPaymentInstructionTypeEnum = {
37
37
  DebitAuthorization: 'DEBIT_AUTHORIZATION',
38
38
  };
39
- exports.GetMandatesResponseMandateStatusEnum = {
39
+ exports.GetMandateResponseMandateStatusEnum = {
40
40
  Created: 'CREATED',
41
41
  Used: 'USED',
42
42
  Submitted: 'SUBMITTED',
@@ -89,13 +89,46 @@ exports.TransactionLimitsPeriodEnum = {
89
89
  */
90
90
  exports.CustomerApiAxiosParamCreator = function (configuration) {
91
91
  return {
92
+ /**
93
+ * CREATE Mandate
94
+ * @param {CreateMandateRequest} createMandateRequest request body for creating mandate
95
+ * @param {*} [options] Override http request option.
96
+ * @throws {RequiredError}
97
+ */
98
+ createMandate: (createMandateRequest, options = {}) => __awaiter(this, void 0, void 0, function* () {
99
+ // verify required parameter 'createMandateRequest' is not null or undefined
100
+ common_1.assertParamExists('createMandate', 'createMandateRequest', createMandateRequest);
101
+ const localVarPath = `/mandates`;
102
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
103
+ const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
104
+ let baseOptions;
105
+ if (configuration) {
106
+ baseOptions = configuration.baseOptions;
107
+ }
108
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
109
+ const localVarHeaderParameter = {};
110
+ const localVarQueryParameter = {};
111
+ // authentication Oauth2 required
112
+ // oauth required
113
+ yield common_1.setOAuthToObject(localVarHeaderParameter, 'Oauth2', [], configuration);
114
+ localVarHeaderParameter['Content-Type'] = 'application/json';
115
+ common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
116
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
117
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
118
+ localVarRequestOptions.data = common_1.serializeDataIfNeeded(createMandateRequest, localVarRequestOptions, configuration);
119
+ return {
120
+ url: common_1.toPathString(localVarUrlObj),
121
+ options: localVarRequestOptions,
122
+ };
123
+ }),
92
124
  /**
93
125
  * Create new Payment
94
126
  * @param {CreatePaymentRequest} createPaymentRequest request body for creating payment
127
+ * @param {string} [idempotencyKey] A random key provided by the customer, per unique payment. If missing we will generate a random one. The purpose for the Idempotency key is to allow safe retrying without the operation being performed multiple times.
95
128
  * @param {*} [options] Override http request option.
96
129
  * @throws {RequiredError}
97
130
  */
98
- createPayment: (createPaymentRequest, options = {}) => __awaiter(this, void 0, void 0, function* () {
131
+ createPayment: (createPaymentRequest, idempotencyKey, options = {}) => __awaiter(this, void 0, void 0, function* () {
99
132
  // verify required parameter 'createPaymentRequest' is not null or undefined
100
133
  common_1.assertParamExists('createPayment', 'createPaymentRequest', createPaymentRequest);
101
134
  const localVarPath = `/payments`;
@@ -111,6 +144,9 @@ exports.CustomerApiAxiosParamCreator = function (configuration) {
111
144
  // authentication Oauth2 required
112
145
  // oauth required
113
146
  yield common_1.setOAuthToObject(localVarHeaderParameter, 'Oauth2', [], configuration);
147
+ if (idempotencyKey !== undefined && idempotencyKey !== null) {
148
+ localVarHeaderParameter['Idempotency-Key'] = String(idempotencyKey);
149
+ }
114
150
  localVarHeaderParameter['Content-Type'] = 'application/json';
115
151
  common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
116
152
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -276,14 +312,14 @@ exports.CustomerApiAxiosParamCreator = function (configuration) {
276
312
  };
277
313
  }),
278
314
  /**
279
- * Get Mandates details by mandate_id
315
+ * Get Mandate details by mandate_id
280
316
  * @param {string} mandateId mandate id
281
317
  * @param {*} [options] Override http request option.
282
318
  * @throws {RequiredError}
283
319
  */
284
- getMandates: (mandateId, options = {}) => __awaiter(this, void 0, void 0, function* () {
320
+ getMandate: (mandateId, options = {}) => __awaiter(this, void 0, void 0, function* () {
285
321
  // verify required parameter 'mandateId' is not null or undefined
286
- common_1.assertParamExists('getMandates', 'mandateId', mandateId);
322
+ common_1.assertParamExists('getMandate', 'mandateId', mandateId);
287
323
  const localVarPath = `/mandates/{mandateId}`.replace(`{${'mandateId'}}`, encodeURIComponent(String(mandateId)));
288
324
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
289
325
  const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
@@ -408,38 +444,6 @@ exports.CustomerApiAxiosParamCreator = function (configuration) {
408
444
  options: localVarRequestOptions,
409
445
  };
410
446
  }),
411
- /**
412
- * CREATE Mandates
413
- * @param {PostMandatesRequest} postMandatesRequest request body for creating mandate
414
- * @param {*} [options] Override http request option.
415
- * @throws {RequiredError}
416
- */
417
- postMandates: (postMandatesRequest, options = {}) => __awaiter(this, void 0, void 0, function* () {
418
- // verify required parameter 'postMandatesRequest' is not null or undefined
419
- common_1.assertParamExists('postMandates', 'postMandatesRequest', postMandatesRequest);
420
- const localVarPath = `/mandates`;
421
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
422
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
423
- let baseOptions;
424
- if (configuration) {
425
- baseOptions = configuration.baseOptions;
426
- }
427
- const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
428
- const localVarHeaderParameter = {};
429
- const localVarQueryParameter = {};
430
- // authentication Oauth2 required
431
- // oauth required
432
- yield common_1.setOAuthToObject(localVarHeaderParameter, 'Oauth2', [], configuration);
433
- localVarHeaderParameter['Content-Type'] = 'application/json';
434
- common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
435
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
436
- localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
437
- localVarRequestOptions.data = common_1.serializeDataIfNeeded(postMandatesRequest, localVarRequestOptions, configuration);
438
- return {
439
- url: common_1.toPathString(localVarUrlObj),
440
- options: localVarRequestOptions,
441
- };
442
- }),
443
447
  /**
444
448
  * Refresh an access token
445
449
  * @param {RefreshRequest} refreshRequest The refresh token
@@ -481,15 +485,28 @@ exports.CustomerApiAxiosParamCreator = function (configuration) {
481
485
  exports.CustomerApiFp = function (configuration) {
482
486
  const localVarAxiosParamCreator = exports.CustomerApiAxiosParamCreator(configuration);
483
487
  return {
488
+ /**
489
+ * CREATE Mandate
490
+ * @param {CreateMandateRequest} createMandateRequest request body for creating mandate
491
+ * @param {*} [options] Override http request option.
492
+ * @throws {RequiredError}
493
+ */
494
+ createMandate(createMandateRequest, options) {
495
+ return __awaiter(this, void 0, void 0, function* () {
496
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.createMandate(createMandateRequest, options);
497
+ return common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
498
+ });
499
+ },
484
500
  /**
485
501
  * Create new Payment
486
502
  * @param {CreatePaymentRequest} createPaymentRequest request body for creating payment
503
+ * @param {string} [idempotencyKey] A random key provided by the customer, per unique payment. If missing we will generate a random one. The purpose for the Idempotency key is to allow safe retrying without the operation being performed multiple times.
487
504
  * @param {*} [options] Override http request option.
488
505
  * @throws {RequiredError}
489
506
  */
490
- createPayment(createPaymentRequest, options) {
507
+ createPayment(createPaymentRequest, idempotencyKey, options) {
491
508
  return __awaiter(this, void 0, void 0, function* () {
492
- const localVarAxiosArgs = yield localVarAxiosParamCreator.createPayment(createPaymentRequest, options);
509
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.createPayment(createPaymentRequest, idempotencyKey, options);
493
510
  return common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
494
511
  });
495
512
  },
@@ -554,14 +571,14 @@ exports.CustomerApiFp = function (configuration) {
554
571
  });
555
572
  },
556
573
  /**
557
- * Get Mandates details by mandate_id
574
+ * Get Mandate details by mandate_id
558
575
  * @param {string} mandateId mandate id
559
576
  * @param {*} [options] Override http request option.
560
577
  * @throws {RequiredError}
561
578
  */
562
- getMandates(mandateId, options) {
579
+ getMandate(mandateId, options) {
563
580
  return __awaiter(this, void 0, void 0, function* () {
564
- const localVarAxiosArgs = yield localVarAxiosParamCreator.getMandates(mandateId, options);
581
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getMandate(mandateId, options);
565
582
  return common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
566
583
  });
567
584
  },
@@ -604,18 +621,6 @@ exports.CustomerApiFp = function (configuration) {
604
621
  return common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
605
622
  });
606
623
  },
607
- /**
608
- * CREATE Mandates
609
- * @param {PostMandatesRequest} postMandatesRequest request body for creating mandate
610
- * @param {*} [options] Override http request option.
611
- * @throws {RequiredError}
612
- */
613
- postMandates(postMandatesRequest, options) {
614
- return __awaiter(this, void 0, void 0, function* () {
615
- const localVarAxiosArgs = yield localVarAxiosParamCreator.postMandates(postMandatesRequest, options);
616
- return common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
617
- });
618
- },
619
624
  /**
620
625
  * Refresh an access token
621
626
  * @param {RefreshRequest} refreshRequest The refresh token
@@ -637,14 +642,26 @@ exports.CustomerApiFp = function (configuration) {
637
642
  exports.CustomerApiFactory = function (configuration, basePath, axios) {
638
643
  const localVarFp = exports.CustomerApiFp(configuration);
639
644
  return {
645
+ /**
646
+ * CREATE Mandate
647
+ * @param {CreateMandateRequest} createMandateRequest request body for creating mandate
648
+ * @param {*} [options] Override http request option.
649
+ * @throws {RequiredError}
650
+ */
651
+ createMandate(createMandateRequest, options) {
652
+ return localVarFp.createMandate(createMandateRequest, options).then((request) => request(axios, basePath));
653
+ },
640
654
  /**
641
655
  * Create new Payment
642
656
  * @param {CreatePaymentRequest} createPaymentRequest request body for creating payment
657
+ * @param {string} [idempotencyKey] A random key provided by the customer, per unique payment. If missing we will generate a random one. The purpose for the Idempotency key is to allow safe retrying without the operation being performed multiple times.
643
658
  * @param {*} [options] Override http request option.
644
659
  * @throws {RequiredError}
645
660
  */
646
- createPayment(createPaymentRequest, options) {
647
- return localVarFp.createPayment(createPaymentRequest, options).then((request) => request(axios, basePath));
661
+ createPayment(createPaymentRequest, idempotencyKey, options) {
662
+ return localVarFp
663
+ .createPayment(createPaymentRequest, idempotencyKey, options)
664
+ .then((request) => request(axios, basePath));
648
665
  },
649
666
  /**
650
667
  * Create a new payment instruction to be used when linking to perform new payment
@@ -694,13 +711,13 @@ exports.CustomerApiFactory = function (configuration, basePath, axios) {
694
711
  return localVarFp.getLoginIdentityHistory(loginIdentityId, options).then((request) => request(axios, basePath));
695
712
  },
696
713
  /**
697
- * Get Mandates details by mandate_id
714
+ * Get Mandate details by mandate_id
698
715
  * @param {string} mandateId mandate id
699
716
  * @param {*} [options] Override http request option.
700
717
  * @throws {RequiredError}
701
718
  */
702
- getMandates(mandateId, options) {
703
- return localVarFp.getMandates(mandateId, options).then((request) => request(axios, basePath));
719
+ getMandate(mandateId, options) {
720
+ return localVarFp.getMandate(mandateId, options).then((request) => request(axios, basePath));
704
721
  },
705
722
  /**
706
723
  * Get Payment details by payment_id
@@ -736,15 +753,6 @@ exports.CustomerApiFactory = function (configuration, basePath, axios) {
736
753
  .listInstitutions(country, countries, productsSupported, institutionType, options)
737
754
  .then((request) => request(axios, basePath));
738
755
  },
739
- /**
740
- * CREATE Mandates
741
- * @param {PostMandatesRequest} postMandatesRequest request body for creating mandate
742
- * @param {*} [options] Override http request option.
743
- * @throws {RequiredError}
744
- */
745
- postMandates(postMandatesRequest, options) {
746
- return localVarFp.postMandates(postMandatesRequest, options).then((request) => request(axios, basePath));
747
- },
748
756
  /**
749
757
  * Refresh an access token
750
758
  * @param {RefreshRequest} refreshRequest The refresh token
@@ -763,16 +771,29 @@ exports.CustomerApiFactory = function (configuration, basePath, axios) {
763
771
  * @extends {BaseAPI}
764
772
  */
765
773
  class CustomerApi extends base_1.BaseAPI {
774
+ /**
775
+ * CREATE Mandate
776
+ * @param {CreateMandateRequest} createMandateRequest request body for creating mandate
777
+ * @param {*} [options] Override http request option.
778
+ * @throws {RequiredError}
779
+ * @memberof CustomerApi
780
+ */
781
+ createMandate(createMandateRequest, options) {
782
+ return exports.CustomerApiFp(this.configuration)
783
+ .createMandate(createMandateRequest, options)
784
+ .then((request) => request(this.axios, this.basePath));
785
+ }
766
786
  /**
767
787
  * Create new Payment
768
788
  * @param {CreatePaymentRequest} createPaymentRequest request body for creating payment
789
+ * @param {string} [idempotencyKey] A random key provided by the customer, per unique payment. If missing we will generate a random one. The purpose for the Idempotency key is to allow safe retrying without the operation being performed multiple times.
769
790
  * @param {*} [options] Override http request option.
770
791
  * @throws {RequiredError}
771
792
  * @memberof CustomerApi
772
793
  */
773
- createPayment(createPaymentRequest, options) {
794
+ createPayment(createPaymentRequest, idempotencyKey, options) {
774
795
  return exports.CustomerApiFp(this.configuration)
775
- .createPayment(createPaymentRequest, options)
796
+ .createPayment(createPaymentRequest, idempotencyKey, options)
776
797
  .then((request) => request(this.axios, this.basePath));
777
798
  }
778
799
  /**
@@ -836,15 +857,15 @@ class CustomerApi extends base_1.BaseAPI {
836
857
  .then((request) => request(this.axios, this.basePath));
837
858
  }
838
859
  /**
839
- * Get Mandates details by mandate_id
860
+ * Get Mandate details by mandate_id
840
861
  * @param {string} mandateId mandate id
841
862
  * @param {*} [options] Override http request option.
842
863
  * @throws {RequiredError}
843
864
  * @memberof CustomerApi
844
865
  */
845
- getMandates(mandateId, options) {
866
+ getMandate(mandateId, options) {
846
867
  return exports.CustomerApiFp(this.configuration)
847
- .getMandates(mandateId, options)
868
+ .getMandate(mandateId, options)
848
869
  .then((request) => request(this.axios, this.basePath));
849
870
  }
850
871
  /**
@@ -886,18 +907,6 @@ class CustomerApi extends base_1.BaseAPI {
886
907
  .listInstitutions(country, countries, productsSupported, institutionType, options)
887
908
  .then((request) => request(this.axios, this.basePath));
888
909
  }
889
- /**
890
- * CREATE Mandates
891
- * @param {PostMandatesRequest} postMandatesRequest request body for creating mandate
892
- * @param {*} [options] Override http request option.
893
- * @throws {RequiredError}
894
- * @memberof CustomerApi
895
- */
896
- postMandates(postMandatesRequest, options) {
897
- return exports.CustomerApiFp(this.configuration)
898
- .postMandates(postMandatesRequest, options)
899
- .then((request) => request(this.axios, this.basePath));
900
- }
901
910
  /**
902
911
  * Refresh an access token
903
912
  * @param {RefreshRequest} refreshRequest The refresh token
@@ -1476,10 +1485,11 @@ exports.LoginIdentityApiAxiosParamCreator = function (configuration) {
1476
1485
  }),
1477
1486
  /**
1478
1487
  * Download composite statement
1488
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
1479
1489
  * @param {*} [options] Override http request option.
1480
1490
  * @throws {RequiredError}
1481
1491
  */
1482
- getCompositeStatement: (options = {}) => __awaiter(this, void 0, void 0, function* () {
1492
+ getCompositeStatement: (redirect, options = {}) => __awaiter(this, void 0, void 0, function* () {
1483
1493
  const localVarPath = `/composite_statement`;
1484
1494
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
1485
1495
  const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
@@ -1493,33 +1503,9 @@ exports.LoginIdentityApiAxiosParamCreator = function (configuration) {
1493
1503
  // authentication Oauth2 required
1494
1504
  // oauth required
1495
1505
  yield common_1.setOAuthToObject(localVarHeaderParameter, 'Oauth2', [], configuration);
1496
- common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
1497
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1498
- localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
1499
- return {
1500
- url: common_1.toPathString(localVarUrlObj),
1501
- options: localVarRequestOptions,
1502
- };
1503
- }),
1504
- /**
1505
- * Get composite statement link for download
1506
- * @param {*} [options] Override http request option.
1507
- * @throws {RequiredError}
1508
- */
1509
- getCompositeStatementLink: (options = {}) => __awaiter(this, void 0, void 0, function* () {
1510
- const localVarPath = `/composite_statement_link`;
1511
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
1512
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1513
- let baseOptions;
1514
- if (configuration) {
1515
- baseOptions = configuration.baseOptions;
1506
+ if (redirect !== undefined) {
1507
+ localVarQueryParameter['redirect'] = redirect;
1516
1508
  }
1517
- const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
1518
- const localVarHeaderParameter = {};
1519
- const localVarQueryParameter = {};
1520
- // authentication Oauth2 required
1521
- // oauth required
1522
- yield common_1.setOAuthToObject(localVarHeaderParameter, 'Oauth2', [], configuration);
1523
1509
  common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
1524
1510
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1525
1511
  localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
@@ -1612,10 +1598,11 @@ exports.LoginIdentityApiAxiosParamCreator = function (configuration) {
1612
1598
  /**
1613
1599
  * Download statement
1614
1600
  * @param {string} statementId The statement id
1601
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
1615
1602
  * @param {*} [options] Override http request option.
1616
1603
  * @throws {RequiredError}
1617
1604
  */
1618
- getStatement: (statementId, options = {}) => __awaiter(this, void 0, void 0, function* () {
1605
+ getStatement: (statementId, redirect, options = {}) => __awaiter(this, void 0, void 0, function* () {
1619
1606
  // verify required parameter 'statementId' is not null or undefined
1620
1607
  common_1.assertParamExists('getStatement', 'statementId', statementId);
1621
1608
  const localVarPath = `/statements/{statementId}`.replace(`{${'statementId'}}`, encodeURIComponent(String(statementId)));
@@ -1631,6 +1618,9 @@ exports.LoginIdentityApiAxiosParamCreator = function (configuration) {
1631
1618
  // authentication Oauth2 required
1632
1619
  // oauth required
1633
1620
  yield common_1.setOAuthToObject(localVarHeaderParameter, 'Oauth2', [], configuration);
1621
+ if (redirect !== undefined) {
1622
+ localVarQueryParameter['redirect'] = redirect;
1623
+ }
1634
1624
  common_1.setSearchParams(localVarUrlObj, localVarQueryParameter);
1635
1625
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1636
1626
  localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
@@ -1640,7 +1630,7 @@ exports.LoginIdentityApiAxiosParamCreator = function (configuration) {
1640
1630
  };
1641
1631
  }),
1642
1632
  /**
1643
- * Get statement link for download
1633
+ * (Deprecated) Get statement link for download
1644
1634
  * @param {string} statementId The statement id
1645
1635
  * @param {*} [options] Override http request option.
1646
1636
  * @throws {RequiredError}
@@ -1893,23 +1883,13 @@ exports.LoginIdentityApiFp = function (configuration) {
1893
1883
  },
1894
1884
  /**
1895
1885
  * Download composite statement
1886
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
1896
1887
  * @param {*} [options] Override http request option.
1897
1888
  * @throws {RequiredError}
1898
1889
  */
1899
- getCompositeStatement(options) {
1890
+ getCompositeStatement(redirect, options) {
1900
1891
  return __awaiter(this, void 0, void 0, function* () {
1901
- const localVarAxiosArgs = yield localVarAxiosParamCreator.getCompositeStatement(options);
1902
- return common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1903
- });
1904
- },
1905
- /**
1906
- * Get composite statement link for download
1907
- * @param {*} [options] Override http request option.
1908
- * @throws {RequiredError}
1909
- */
1910
- getCompositeStatementLink(options) {
1911
- return __awaiter(this, void 0, void 0, function* () {
1912
- const localVarAxiosArgs = yield localVarAxiosParamCreator.getCompositeStatementLink(options);
1892
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getCompositeStatement(redirect, options);
1913
1893
  return common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1914
1894
  });
1915
1895
  },
@@ -1949,17 +1929,18 @@ exports.LoginIdentityApiFp = function (configuration) {
1949
1929
  /**
1950
1930
  * Download statement
1951
1931
  * @param {string} statementId The statement id
1932
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
1952
1933
  * @param {*} [options] Override http request option.
1953
1934
  * @throws {RequiredError}
1954
1935
  */
1955
- getStatement(statementId, options) {
1936
+ getStatement(statementId, redirect, options) {
1956
1937
  return __awaiter(this, void 0, void 0, function* () {
1957
- const localVarAxiosArgs = yield localVarAxiosParamCreator.getStatement(statementId, options);
1938
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getStatement(statementId, redirect, options);
1958
1939
  return common_1.createRequestFunction(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
1959
1940
  });
1960
1941
  },
1961
1942
  /**
1962
- * Get statement link for download
1943
+ * (Deprecated) Get statement link for download
1963
1944
  * @param {string} statementId The statement id
1964
1945
  * @param {*} [options] Override http request option.
1965
1946
  * @throws {RequiredError}
@@ -2085,19 +2066,12 @@ exports.LoginIdentityApiFactory = function (configuration, basePath, axios) {
2085
2066
  },
2086
2067
  /**
2087
2068
  * Download composite statement
2069
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
2088
2070
  * @param {*} [options] Override http request option.
2089
2071
  * @throws {RequiredError}
2090
2072
  */
2091
- getCompositeStatement(options) {
2092
- return localVarFp.getCompositeStatement(options).then((request) => request(axios, basePath));
2093
- },
2094
- /**
2095
- * Get composite statement link for download
2096
- * @param {*} [options] Override http request option.
2097
- * @throws {RequiredError}
2098
- */
2099
- getCompositeStatementLink(options) {
2100
- return localVarFp.getCompositeStatementLink(options).then((request) => request(axios, basePath));
2073
+ getCompositeStatement(redirect, options) {
2074
+ return localVarFp.getCompositeStatement(redirect, options).then((request) => request(axios, basePath));
2101
2075
  },
2102
2076
  /**
2103
2077
  * \\[BETA] Get a list of identity data for a given login identity
@@ -2126,14 +2100,15 @@ exports.LoginIdentityApiFactory = function (configuration, basePath, axios) {
2126
2100
  /**
2127
2101
  * Download statement
2128
2102
  * @param {string} statementId The statement id
2103
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
2129
2104
  * @param {*} [options] Override http request option.
2130
2105
  * @throws {RequiredError}
2131
2106
  */
2132
- getStatement(statementId, options) {
2133
- return localVarFp.getStatement(statementId, options).then((request) => request(axios, basePath));
2107
+ getStatement(statementId, redirect, options) {
2108
+ return localVarFp.getStatement(statementId, redirect, options).then((request) => request(axios, basePath));
2134
2109
  },
2135
2110
  /**
2136
- * Get statement link for download
2111
+ * (Deprecated) Get statement link for download
2137
2112
  * @param {string} statementId The statement id
2138
2113
  * @param {*} [options] Override http request option.
2139
2114
  * @throws {RequiredError}
@@ -2260,24 +2235,14 @@ class LoginIdentityApi extends base_1.BaseAPI {
2260
2235
  }
2261
2236
  /**
2262
2237
  * Download composite statement
2238
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
2263
2239
  * @param {*} [options] Override http request option.
2264
2240
  * @throws {RequiredError}
2265
2241
  * @memberof LoginIdentityApi
2266
2242
  */
2267
- getCompositeStatement(options) {
2268
- return exports.LoginIdentityApiFp(this.configuration)
2269
- .getCompositeStatement(options)
2270
- .then((request) => request(this.axios, this.basePath));
2271
- }
2272
- /**
2273
- * Get composite statement link for download
2274
- * @param {*} [options] Override http request option.
2275
- * @throws {RequiredError}
2276
- * @memberof LoginIdentityApi
2277
- */
2278
- getCompositeStatementLink(options) {
2243
+ getCompositeStatement(redirect, options) {
2279
2244
  return exports.LoginIdentityApiFp(this.configuration)
2280
- .getCompositeStatementLink(options)
2245
+ .getCompositeStatement(redirect, options)
2281
2246
  .then((request) => request(this.axios, this.basePath));
2282
2247
  }
2283
2248
  /**
@@ -2316,17 +2281,18 @@ class LoginIdentityApi extends base_1.BaseAPI {
2316
2281
  /**
2317
2282
  * Download statement
2318
2283
  * @param {string} statementId The statement id
2284
+ * @param {boolean} [redirect] when true, response will be http redirect; otherwise it will be json response with the download link
2319
2285
  * @param {*} [options] Override http request option.
2320
2286
  * @throws {RequiredError}
2321
2287
  * @memberof LoginIdentityApi
2322
2288
  */
2323
- getStatement(statementId, options) {
2289
+ getStatement(statementId, redirect, options) {
2324
2290
  return exports.LoginIdentityApiFp(this.configuration)
2325
- .getStatement(statementId, options)
2291
+ .getStatement(statementId, redirect, options)
2326
2292
  .then((request) => request(this.axios, this.basePath));
2327
2293
  }
2328
2294
  /**
2329
- * Get statement link for download
2295
+ * (Deprecated) Get statement link for download
2330
2296
  * @param {string} statementId The statement id
2331
2297
  * @param {*} [options] Override http request option.
2332
2298
  * @throws {RequiredError}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@finverse/sdk-typescript",
3
- "version": "0.0.39",
3
+ "version": "0.0.42",
4
4
  "description": "OpenAPI client for @finverse/sdk-typescript",
5
5
  "author": "OpenAPI-Generator Contributors",
6
6
  "keywords": [