@channelpayments/node-sdk 1.182.0 → 1.184.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/apis/ChannelPaymentsApi.d.ts +9 -1
- package/dist/cjs/apis/ChannelPaymentsApi.js +70 -0
- package/dist/cjs/models/BillingAddressDto.d.ts +56 -0
- package/dist/cjs/models/{BuyerAddressDto.js → BillingAddressDto.js} +16 -18
- package/dist/cjs/models/CheckoutSessionBaseEntity.d.ts +185 -0
- package/dist/cjs/models/CheckoutSessionBaseEntity.js +127 -0
- package/dist/cjs/models/CheckoutSessionEntity.d.ts +11 -5
- package/dist/cjs/models/CheckoutSessionEntity.js +4 -2
- package/dist/cjs/models/CheckoutSessionItemBaseEntity.d.ts +80 -0
- package/dist/cjs/models/CheckoutSessionItemBaseEntity.js +69 -0
- package/dist/cjs/models/CreateCheckoutSessionPaymentMethodDto.d.ts +12 -0
- package/dist/cjs/models/CreateCheckoutSessionPaymentMethodDto.js +4 -0
- package/dist/cjs/models/CreateCheckoutSessionTransactionDto.d.ts +4 -4
- package/dist/cjs/models/CreateCheckoutSessionTransactionDto.js +4 -4
- package/dist/cjs/models/FeeDetailsEntity.d.ts +53 -0
- package/dist/cjs/models/FeeDetailsEntity.js +66 -0
- package/dist/cjs/models/MerchantFeeDetailsEntity.d.ts +39 -0
- package/dist/cjs/models/MerchantFeeDetailsEntity.js +53 -0
- package/dist/cjs/models/PaymentMethodFeeDetailsEntity.d.ts +54 -0
- package/dist/cjs/models/PaymentMethodFeeDetailsEntity.js +65 -0
- package/dist/cjs/models/TransactionEntity.d.ts +3 -9
- package/dist/cjs/models/TransactionEntity.js +3 -5
- package/dist/cjs/models/TransactionPaymentInstrumentBaseEntity.d.ts +136 -0
- package/dist/cjs/models/{PaymentMethodBaseEntity.js → TransactionPaymentInstrumentBaseEntity.js} +14 -14
- package/dist/cjs/models/index.d.ts +7 -2
- package/dist/cjs/models/index.js +7 -2
- package/dist/cjs/runtime.js +1 -1
- package/dist/mjs/apis/ChannelPaymentsApi.d.ts +9 -1
- package/dist/mjs/apis/ChannelPaymentsApi.js +69 -1
- package/dist/mjs/models/BillingAddressDto.d.ts +56 -0
- package/dist/mjs/models/{BuyerAddressDto.js → BillingAddressDto.js} +12 -14
- package/dist/mjs/models/CheckoutSessionBaseEntity.d.ts +185 -0
- package/dist/mjs/models/CheckoutSessionBaseEntity.js +120 -0
- package/dist/mjs/models/CheckoutSessionEntity.d.ts +11 -5
- package/dist/mjs/models/CheckoutSessionEntity.js +4 -2
- package/dist/mjs/models/CheckoutSessionItemBaseEntity.d.ts +80 -0
- package/dist/mjs/models/CheckoutSessionItemBaseEntity.js +63 -0
- package/dist/mjs/models/CreateCheckoutSessionPaymentMethodDto.d.ts +12 -0
- package/dist/mjs/models/CreateCheckoutSessionPaymentMethodDto.js +4 -0
- package/dist/mjs/models/CreateCheckoutSessionTransactionDto.d.ts +4 -4
- package/dist/mjs/models/CreateCheckoutSessionTransactionDto.js +4 -4
- package/dist/mjs/models/FeeDetailsEntity.d.ts +53 -0
- package/dist/mjs/models/FeeDetailsEntity.js +59 -0
- package/dist/mjs/models/MerchantFeeDetailsEntity.d.ts +39 -0
- package/dist/mjs/models/MerchantFeeDetailsEntity.js +47 -0
- package/dist/mjs/models/PaymentMethodFeeDetailsEntity.d.ts +54 -0
- package/dist/mjs/models/PaymentMethodFeeDetailsEntity.js +58 -0
- package/dist/mjs/models/TransactionEntity.d.ts +3 -9
- package/dist/mjs/models/TransactionEntity.js +3 -5
- package/dist/mjs/models/TransactionPaymentInstrumentBaseEntity.d.ts +136 -0
- package/dist/mjs/models/{PaymentMethodBaseEntity.js → TransactionPaymentInstrumentBaseEntity.js} +9 -9
- package/dist/mjs/models/index.d.ts +7 -2
- package/dist/mjs/models/index.js +7 -2
- package/dist/mjs/runtime.js +1 -1
- package/package.json +1 -1
- package/dist/cjs/models/BuyerAddressDto.d.ts +0 -56
- package/dist/cjs/models/PaymentMethodBaseEntity.d.ts +0 -136
- package/dist/mjs/models/BuyerAddressDto.d.ts +0 -56
- package/dist/mjs/models/PaymentMethodBaseEntity.d.ts +0 -136
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Channel Payments API
|
|
6
|
+
*
|
|
7
|
+
* NOTE: This class is auto generated. Do not edit the class manually.
|
|
8
|
+
*
|
|
9
|
+
*/
|
|
10
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11
|
+
exports.instanceOfCheckoutSessionItemBaseEntity = instanceOfCheckoutSessionItemBaseEntity;
|
|
12
|
+
exports.CheckoutSessionItemBaseEntityFromJSON = CheckoutSessionItemBaseEntityFromJSON;
|
|
13
|
+
exports.CheckoutSessionItemBaseEntityFromJSONTyped = CheckoutSessionItemBaseEntityFromJSONTyped;
|
|
14
|
+
exports.CheckoutSessionItemBaseEntityToJSON = CheckoutSessionItemBaseEntityToJSON;
|
|
15
|
+
const runtime_1 = require("../runtime");
|
|
16
|
+
/**
|
|
17
|
+
* Check if a given object implements the CheckoutSessionItemBaseEntity interface.
|
|
18
|
+
*/
|
|
19
|
+
function instanceOfCheckoutSessionItemBaseEntity(value) {
|
|
20
|
+
let isInstance = true;
|
|
21
|
+
isInstance = isInstance && "itemId" in value;
|
|
22
|
+
isInstance = isInstance && "sessionId" in value;
|
|
23
|
+
isInstance = isInstance && "description" in value;
|
|
24
|
+
isInstance = isInstance && "quantity" in value;
|
|
25
|
+
isInstance = isInstance && "unitPrice" in value;
|
|
26
|
+
isInstance = isInstance && "total" in value;
|
|
27
|
+
return isInstance;
|
|
28
|
+
}
|
|
29
|
+
function CheckoutSessionItemBaseEntityFromJSON(json) {
|
|
30
|
+
return CheckoutSessionItemBaseEntityFromJSONTyped(json, false);
|
|
31
|
+
}
|
|
32
|
+
function CheckoutSessionItemBaseEntityFromJSONTyped(json, ignoreDiscriminator) {
|
|
33
|
+
if ((json === undefined) || (json === null)) {
|
|
34
|
+
return json;
|
|
35
|
+
}
|
|
36
|
+
const typed = {
|
|
37
|
+
'itemId': json['itemId'],
|
|
38
|
+
'sessionId': json['sessionId'],
|
|
39
|
+
'description': json['description'],
|
|
40
|
+
'quantity': json['quantity'],
|
|
41
|
+
'unitPrice': json['unitPrice'],
|
|
42
|
+
'total': json['total'],
|
|
43
|
+
'subtotal': !(0, runtime_1.exists)(json, 'subtotal') ? undefined : json['subtotal'],
|
|
44
|
+
'discountTotal': !(0, runtime_1.exists)(json, 'discountTotal') ? undefined : json['discountTotal'],
|
|
45
|
+
'taxTotal': !(0, runtime_1.exists)(json, 'taxTotal') ? undefined : json['taxTotal'],
|
|
46
|
+
'feesTotal': !(0, runtime_1.exists)(json, 'feesTotal') ? undefined : json['feesTotal'],
|
|
47
|
+
};
|
|
48
|
+
return (0, runtime_1.removeNullUndefined)(typed);
|
|
49
|
+
}
|
|
50
|
+
function CheckoutSessionItemBaseEntityToJSON(value) {
|
|
51
|
+
if (value === undefined) {
|
|
52
|
+
return undefined;
|
|
53
|
+
}
|
|
54
|
+
if (value === null) {
|
|
55
|
+
return null;
|
|
56
|
+
}
|
|
57
|
+
return {
|
|
58
|
+
'itemId': value.itemId,
|
|
59
|
+
'sessionId': value.sessionId,
|
|
60
|
+
'description': value.description,
|
|
61
|
+
'quantity': value.quantity,
|
|
62
|
+
'unitPrice': value.unitPrice,
|
|
63
|
+
'total': value.total,
|
|
64
|
+
'subtotal': value.subtotal,
|
|
65
|
+
'discountTotal': value.discountTotal,
|
|
66
|
+
'taxTotal': value.taxTotal,
|
|
67
|
+
'feesTotal': value.feesTotal,
|
|
68
|
+
};
|
|
69
|
+
}
|
|
@@ -34,6 +34,18 @@ export interface CreateCheckoutSessionPaymentMethodDto {
|
|
|
34
34
|
* @memberof CreateCheckoutSessionPaymentMethodDto
|
|
35
35
|
*/
|
|
36
36
|
expirationDate?: string;
|
|
37
|
+
/**
|
|
38
|
+
* The ID of the stored payment method to use. Must be unset if number, expirationDate, and securityCode are provided.
|
|
39
|
+
* @type {string}
|
|
40
|
+
* @memberof CreateCheckoutSessionPaymentMethodDto
|
|
41
|
+
*/
|
|
42
|
+
paymentMethodId?: string;
|
|
43
|
+
/**
|
|
44
|
+
* Whether or not to store the payment method for future use.
|
|
45
|
+
* @type {boolean}
|
|
46
|
+
* @memberof CreateCheckoutSessionPaymentMethodDto
|
|
47
|
+
*/
|
|
48
|
+
store?: boolean;
|
|
37
49
|
/**
|
|
38
50
|
* The routing number of the ACH transaction. Must be unset if method is CARD.
|
|
39
51
|
* @type {string}
|
|
@@ -49,6 +49,8 @@ function CreateCheckoutSessionPaymentMethodDtoFromJSONTyped(json, ignoreDiscrimi
|
|
|
49
49
|
'number': !(0, runtime_1.exists)(json, 'number') ? undefined : json['number'],
|
|
50
50
|
'securityCode': !(0, runtime_1.exists)(json, 'securityCode') ? undefined : json['securityCode'],
|
|
51
51
|
'expirationDate': !(0, runtime_1.exists)(json, 'expirationDate') ? undefined : json['expirationDate'],
|
|
52
|
+
'paymentMethodId': !(0, runtime_1.exists)(json, 'paymentMethodId') ? undefined : json['paymentMethodId'],
|
|
53
|
+
'store': !(0, runtime_1.exists)(json, 'store') ? undefined : json['store'],
|
|
52
54
|
'abaNumber': !(0, runtime_1.exists)(json, 'abaNumber') ? undefined : json['abaNumber'],
|
|
53
55
|
'accountNumber': !(0, runtime_1.exists)(json, 'accountNumber') ? undefined : json['accountNumber'],
|
|
54
56
|
'accountType': !(0, runtime_1.exists)(json, 'accountType') ? undefined : json['accountType'],
|
|
@@ -67,6 +69,8 @@ function CreateCheckoutSessionPaymentMethodDtoToJSON(value) {
|
|
|
67
69
|
'number': value.number,
|
|
68
70
|
'securityCode': value.securityCode,
|
|
69
71
|
'expirationDate': value.expirationDate,
|
|
72
|
+
'paymentMethodId': value.paymentMethodId,
|
|
73
|
+
'store': value.store,
|
|
70
74
|
'abaNumber': value.abaNumber,
|
|
71
75
|
'accountNumber': value.accountNumber,
|
|
72
76
|
'accountType': value.accountType,
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* NOTE: This class is auto generated. Do not edit the class manually.
|
|
5
5
|
*
|
|
6
6
|
*/
|
|
7
|
-
import type {
|
|
7
|
+
import type { BillingAddressDto } from './BillingAddressDto';
|
|
8
8
|
import type { CreateCheckoutSessionPaymentMethodDto } from './CreateCheckoutSessionPaymentMethodDto';
|
|
9
9
|
/**
|
|
10
10
|
*
|
|
@@ -37,11 +37,11 @@ export interface CreateCheckoutSessionTransactionDto {
|
|
|
37
37
|
*/
|
|
38
38
|
email: string;
|
|
39
39
|
/**
|
|
40
|
-
* The address
|
|
41
|
-
* @type {
|
|
40
|
+
* The billing address.
|
|
41
|
+
* @type {BillingAddressDto}
|
|
42
42
|
* @memberof CreateCheckoutSessionTransactionDto
|
|
43
43
|
*/
|
|
44
|
-
|
|
44
|
+
billingAddress: BillingAddressDto;
|
|
45
45
|
/**
|
|
46
46
|
* The payment method used for the checkout session.
|
|
47
47
|
* @type {CreateCheckoutSessionPaymentMethodDto}
|
|
@@ -13,7 +13,7 @@ exports.CreateCheckoutSessionTransactionDtoFromJSON = CreateCheckoutSessionTrans
|
|
|
13
13
|
exports.CreateCheckoutSessionTransactionDtoFromJSONTyped = CreateCheckoutSessionTransactionDtoFromJSONTyped;
|
|
14
14
|
exports.CreateCheckoutSessionTransactionDtoToJSON = CreateCheckoutSessionTransactionDtoToJSON;
|
|
15
15
|
const runtime_1 = require("../runtime");
|
|
16
|
-
const
|
|
16
|
+
const BillingAddressDto_1 = require("./BillingAddressDto");
|
|
17
17
|
const CreateCheckoutSessionPaymentMethodDto_1 = require("./CreateCheckoutSessionPaymentMethodDto");
|
|
18
18
|
/**
|
|
19
19
|
* Check if a given object implements the CreateCheckoutSessionTransactionDto interface.
|
|
@@ -24,7 +24,7 @@ function instanceOfCreateCheckoutSessionTransactionDto(value) {
|
|
|
24
24
|
isInstance = isInstance && "givenName" in value;
|
|
25
25
|
isInstance = isInstance && "familyName" in value;
|
|
26
26
|
isInstance = isInstance && "email" in value;
|
|
27
|
-
isInstance = isInstance && "
|
|
27
|
+
isInstance = isInstance && "billingAddress" in value;
|
|
28
28
|
isInstance = isInstance && "paymentMethod" in value;
|
|
29
29
|
return isInstance;
|
|
30
30
|
}
|
|
@@ -40,7 +40,7 @@ function CreateCheckoutSessionTransactionDtoFromJSONTyped(json, ignoreDiscrimina
|
|
|
40
40
|
'givenName': json['givenName'],
|
|
41
41
|
'familyName': json['familyName'],
|
|
42
42
|
'email': json['email'],
|
|
43
|
-
'
|
|
43
|
+
'billingAddress': (0, BillingAddressDto_1.BillingAddressDtoFromJSON)(json['billingAddress']),
|
|
44
44
|
'paymentMethod': (0, CreateCheckoutSessionPaymentMethodDto_1.CreateCheckoutSessionPaymentMethodDtoFromJSON)(json['paymentMethod']),
|
|
45
45
|
};
|
|
46
46
|
return (0, runtime_1.removeNullUndefined)(typed);
|
|
@@ -57,7 +57,7 @@ function CreateCheckoutSessionTransactionDtoToJSON(value) {
|
|
|
57
57
|
'givenName': value.givenName,
|
|
58
58
|
'familyName': value.familyName,
|
|
59
59
|
'email': value.email,
|
|
60
|
-
'
|
|
60
|
+
'billingAddress': (0, BillingAddressDto_1.BillingAddressDtoToJSON)(value.billingAddress),
|
|
61
61
|
'paymentMethod': (0, CreateCheckoutSessionPaymentMethodDto_1.CreateCheckoutSessionPaymentMethodDtoToJSON)(value.paymentMethod),
|
|
62
62
|
};
|
|
63
63
|
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Channel Payments API
|
|
3
|
+
*
|
|
4
|
+
* NOTE: This class is auto generated. Do not edit the class manually.
|
|
5
|
+
*
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
*
|
|
9
|
+
* @export
|
|
10
|
+
* @interface FeeDetailsEntity
|
|
11
|
+
*/
|
|
12
|
+
export interface FeeDetailsEntity {
|
|
13
|
+
/**
|
|
14
|
+
* The type of the transaction fee.
|
|
15
|
+
* @type {string}
|
|
16
|
+
* @memberof FeeDetailsEntity
|
|
17
|
+
*/
|
|
18
|
+
type: FeeDetailsEntityTypeEnum;
|
|
19
|
+
/**
|
|
20
|
+
* The type of charge for the transaction fee.
|
|
21
|
+
* @type {string}
|
|
22
|
+
* @memberof FeeDetailsEntity
|
|
23
|
+
*/
|
|
24
|
+
chargeType: FeeDetailsEntityChargeTypeEnum;
|
|
25
|
+
/**
|
|
26
|
+
* The amount of the transaction fee.
|
|
27
|
+
* @type {number}
|
|
28
|
+
* @memberof FeeDetailsEntity
|
|
29
|
+
*/
|
|
30
|
+
amount: number;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* @export
|
|
34
|
+
*/
|
|
35
|
+
export declare const FeeDetailsEntityTypeEnum: {
|
|
36
|
+
readonly ConvenienceFee: "CONVENIENCE_FEE";
|
|
37
|
+
};
|
|
38
|
+
export type FeeDetailsEntityTypeEnum = typeof FeeDetailsEntityTypeEnum[keyof typeof FeeDetailsEntityTypeEnum];
|
|
39
|
+
/**
|
|
40
|
+
* @export
|
|
41
|
+
*/
|
|
42
|
+
export declare const FeeDetailsEntityChargeTypeEnum: {
|
|
43
|
+
readonly IncludedInAmount: "INCLUDED_IN_AMOUNT";
|
|
44
|
+
readonly ChargedSeparately: "CHARGED_SEPARATELY";
|
|
45
|
+
};
|
|
46
|
+
export type FeeDetailsEntityChargeTypeEnum = typeof FeeDetailsEntityChargeTypeEnum[keyof typeof FeeDetailsEntityChargeTypeEnum];
|
|
47
|
+
/**
|
|
48
|
+
* Check if a given object implements the FeeDetailsEntity interface.
|
|
49
|
+
*/
|
|
50
|
+
export declare function instanceOfFeeDetailsEntity(value: object): boolean;
|
|
51
|
+
export declare function FeeDetailsEntityFromJSON(json: any): FeeDetailsEntity;
|
|
52
|
+
export declare function FeeDetailsEntityFromJSONTyped(json: any, ignoreDiscriminator: boolean): FeeDetailsEntity;
|
|
53
|
+
export declare function FeeDetailsEntityToJSON(value?: FeeDetailsEntity | null): any;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Channel Payments API
|
|
6
|
+
*
|
|
7
|
+
* NOTE: This class is auto generated. Do not edit the class manually.
|
|
8
|
+
*
|
|
9
|
+
*/
|
|
10
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11
|
+
exports.FeeDetailsEntityChargeTypeEnum = exports.FeeDetailsEntityTypeEnum = void 0;
|
|
12
|
+
exports.instanceOfFeeDetailsEntity = instanceOfFeeDetailsEntity;
|
|
13
|
+
exports.FeeDetailsEntityFromJSON = FeeDetailsEntityFromJSON;
|
|
14
|
+
exports.FeeDetailsEntityFromJSONTyped = FeeDetailsEntityFromJSONTyped;
|
|
15
|
+
exports.FeeDetailsEntityToJSON = FeeDetailsEntityToJSON;
|
|
16
|
+
const runtime_1 = require("../runtime");
|
|
17
|
+
/**
|
|
18
|
+
* @export
|
|
19
|
+
*/
|
|
20
|
+
exports.FeeDetailsEntityTypeEnum = {
|
|
21
|
+
ConvenienceFee: 'CONVENIENCE_FEE'
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* @export
|
|
25
|
+
*/
|
|
26
|
+
exports.FeeDetailsEntityChargeTypeEnum = {
|
|
27
|
+
IncludedInAmount: 'INCLUDED_IN_AMOUNT',
|
|
28
|
+
ChargedSeparately: 'CHARGED_SEPARATELY'
|
|
29
|
+
};
|
|
30
|
+
/**
|
|
31
|
+
* Check if a given object implements the FeeDetailsEntity interface.
|
|
32
|
+
*/
|
|
33
|
+
function instanceOfFeeDetailsEntity(value) {
|
|
34
|
+
let isInstance = true;
|
|
35
|
+
isInstance = isInstance && "type" in value;
|
|
36
|
+
isInstance = isInstance && "chargeType" in value;
|
|
37
|
+
isInstance = isInstance && "amount" in value;
|
|
38
|
+
return isInstance;
|
|
39
|
+
}
|
|
40
|
+
function FeeDetailsEntityFromJSON(json) {
|
|
41
|
+
return FeeDetailsEntityFromJSONTyped(json, false);
|
|
42
|
+
}
|
|
43
|
+
function FeeDetailsEntityFromJSONTyped(json, ignoreDiscriminator) {
|
|
44
|
+
if ((json === undefined) || (json === null)) {
|
|
45
|
+
return json;
|
|
46
|
+
}
|
|
47
|
+
const typed = {
|
|
48
|
+
'type': json['type'],
|
|
49
|
+
'chargeType': json['chargeType'],
|
|
50
|
+
'amount': json['amount'],
|
|
51
|
+
};
|
|
52
|
+
return (0, runtime_1.removeNullUndefined)(typed);
|
|
53
|
+
}
|
|
54
|
+
function FeeDetailsEntityToJSON(value) {
|
|
55
|
+
if (value === undefined) {
|
|
56
|
+
return undefined;
|
|
57
|
+
}
|
|
58
|
+
if (value === null) {
|
|
59
|
+
return null;
|
|
60
|
+
}
|
|
61
|
+
return {
|
|
62
|
+
'type': value.type,
|
|
63
|
+
'chargeType': value.chargeType,
|
|
64
|
+
'amount': value.amount,
|
|
65
|
+
};
|
|
66
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Channel Payments API
|
|
3
|
+
*
|
|
4
|
+
* NOTE: This class is auto generated. Do not edit the class manually.
|
|
5
|
+
*
|
|
6
|
+
*/
|
|
7
|
+
import type { PaymentMethodFeeDetailsEntity } from './PaymentMethodFeeDetailsEntity';
|
|
8
|
+
/**
|
|
9
|
+
*
|
|
10
|
+
* @export
|
|
11
|
+
* @interface MerchantFeeDetailsEntity
|
|
12
|
+
*/
|
|
13
|
+
export interface MerchantFeeDetailsEntity {
|
|
14
|
+
/**
|
|
15
|
+
* The ID of the merchant.
|
|
16
|
+
* @type {string}
|
|
17
|
+
* @memberof MerchantFeeDetailsEntity
|
|
18
|
+
*/
|
|
19
|
+
merchantId: string;
|
|
20
|
+
/**
|
|
21
|
+
* The merchant specified total of the transaction.
|
|
22
|
+
* @type {string}
|
|
23
|
+
* @memberof MerchantFeeDetailsEntity
|
|
24
|
+
*/
|
|
25
|
+
subtotal: string;
|
|
26
|
+
/**
|
|
27
|
+
* The details of the payment method fees.
|
|
28
|
+
* @type {Array<PaymentMethodFeeDetailsEntity>}
|
|
29
|
+
* @memberof MerchantFeeDetailsEntity
|
|
30
|
+
*/
|
|
31
|
+
feeDetails: Array<PaymentMethodFeeDetailsEntity>;
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Check if a given object implements the MerchantFeeDetailsEntity interface.
|
|
35
|
+
*/
|
|
36
|
+
export declare function instanceOfMerchantFeeDetailsEntity(value: object): boolean;
|
|
37
|
+
export declare function MerchantFeeDetailsEntityFromJSON(json: any): MerchantFeeDetailsEntity;
|
|
38
|
+
export declare function MerchantFeeDetailsEntityFromJSONTyped(json: any, ignoreDiscriminator: boolean): MerchantFeeDetailsEntity;
|
|
39
|
+
export declare function MerchantFeeDetailsEntityToJSON(value?: MerchantFeeDetailsEntity | null): any;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Channel Payments API
|
|
6
|
+
*
|
|
7
|
+
* NOTE: This class is auto generated. Do not edit the class manually.
|
|
8
|
+
*
|
|
9
|
+
*/
|
|
10
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11
|
+
exports.instanceOfMerchantFeeDetailsEntity = instanceOfMerchantFeeDetailsEntity;
|
|
12
|
+
exports.MerchantFeeDetailsEntityFromJSON = MerchantFeeDetailsEntityFromJSON;
|
|
13
|
+
exports.MerchantFeeDetailsEntityFromJSONTyped = MerchantFeeDetailsEntityFromJSONTyped;
|
|
14
|
+
exports.MerchantFeeDetailsEntityToJSON = MerchantFeeDetailsEntityToJSON;
|
|
15
|
+
const runtime_1 = require("../runtime");
|
|
16
|
+
const PaymentMethodFeeDetailsEntity_1 = require("./PaymentMethodFeeDetailsEntity");
|
|
17
|
+
/**
|
|
18
|
+
* Check if a given object implements the MerchantFeeDetailsEntity interface.
|
|
19
|
+
*/
|
|
20
|
+
function instanceOfMerchantFeeDetailsEntity(value) {
|
|
21
|
+
let isInstance = true;
|
|
22
|
+
isInstance = isInstance && "merchantId" in value;
|
|
23
|
+
isInstance = isInstance && "subtotal" in value;
|
|
24
|
+
isInstance = isInstance && "feeDetails" in value;
|
|
25
|
+
return isInstance;
|
|
26
|
+
}
|
|
27
|
+
function MerchantFeeDetailsEntityFromJSON(json) {
|
|
28
|
+
return MerchantFeeDetailsEntityFromJSONTyped(json, false);
|
|
29
|
+
}
|
|
30
|
+
function MerchantFeeDetailsEntityFromJSONTyped(json, ignoreDiscriminator) {
|
|
31
|
+
if ((json === undefined) || (json === null)) {
|
|
32
|
+
return json;
|
|
33
|
+
}
|
|
34
|
+
const typed = {
|
|
35
|
+
'merchantId': json['merchantId'],
|
|
36
|
+
'subtotal': json['subtotal'],
|
|
37
|
+
'feeDetails': (json['feeDetails'].map(PaymentMethodFeeDetailsEntity_1.PaymentMethodFeeDetailsEntityFromJSON)),
|
|
38
|
+
};
|
|
39
|
+
return (0, runtime_1.removeNullUndefined)(typed);
|
|
40
|
+
}
|
|
41
|
+
function MerchantFeeDetailsEntityToJSON(value) {
|
|
42
|
+
if (value === undefined) {
|
|
43
|
+
return undefined;
|
|
44
|
+
}
|
|
45
|
+
if (value === null) {
|
|
46
|
+
return null;
|
|
47
|
+
}
|
|
48
|
+
return {
|
|
49
|
+
'merchantId': value.merchantId,
|
|
50
|
+
'subtotal': value.subtotal,
|
|
51
|
+
'feeDetails': (value.feeDetails.map(PaymentMethodFeeDetailsEntity_1.PaymentMethodFeeDetailsEntityToJSON)),
|
|
52
|
+
};
|
|
53
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Channel Payments API
|
|
3
|
+
*
|
|
4
|
+
* NOTE: This class is auto generated. Do not edit the class manually.
|
|
5
|
+
*
|
|
6
|
+
*/
|
|
7
|
+
import type { FeeDetailsEntity } from './FeeDetailsEntity';
|
|
8
|
+
/**
|
|
9
|
+
*
|
|
10
|
+
* @export
|
|
11
|
+
* @interface PaymentMethodFeeDetailsEntity
|
|
12
|
+
*/
|
|
13
|
+
export interface PaymentMethodFeeDetailsEntity {
|
|
14
|
+
/**
|
|
15
|
+
* The payment method used for the transaction fee calculation.
|
|
16
|
+
* @type {string}
|
|
17
|
+
* @memberof PaymentMethodFeeDetailsEntity
|
|
18
|
+
*/
|
|
19
|
+
method: PaymentMethodFeeDetailsEntityMethodEnum;
|
|
20
|
+
/**
|
|
21
|
+
* The details of the transaction fees.
|
|
22
|
+
* @type {Array<FeeDetailsEntity>}
|
|
23
|
+
* @memberof PaymentMethodFeeDetailsEntity
|
|
24
|
+
*/
|
|
25
|
+
fees: Array<FeeDetailsEntity>;
|
|
26
|
+
/**
|
|
27
|
+
* The total amount of fees applied.
|
|
28
|
+
* @type {number}
|
|
29
|
+
* @memberof PaymentMethodFeeDetailsEntity
|
|
30
|
+
*/
|
|
31
|
+
feesTotal: number;
|
|
32
|
+
/**
|
|
33
|
+
* The adjusted total after applying the fees.
|
|
34
|
+
* @type {number}
|
|
35
|
+
* @memberof PaymentMethodFeeDetailsEntity
|
|
36
|
+
*/
|
|
37
|
+
adjustedTotal: number;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* @export
|
|
41
|
+
*/
|
|
42
|
+
export declare const PaymentMethodFeeDetailsEntityMethodEnum: {
|
|
43
|
+
readonly Ach: "ACH";
|
|
44
|
+
readonly Bank: "BANK";
|
|
45
|
+
readonly Card: "CARD";
|
|
46
|
+
};
|
|
47
|
+
export type PaymentMethodFeeDetailsEntityMethodEnum = typeof PaymentMethodFeeDetailsEntityMethodEnum[keyof typeof PaymentMethodFeeDetailsEntityMethodEnum];
|
|
48
|
+
/**
|
|
49
|
+
* Check if a given object implements the PaymentMethodFeeDetailsEntity interface.
|
|
50
|
+
*/
|
|
51
|
+
export declare function instanceOfPaymentMethodFeeDetailsEntity(value: object): boolean;
|
|
52
|
+
export declare function PaymentMethodFeeDetailsEntityFromJSON(json: any): PaymentMethodFeeDetailsEntity;
|
|
53
|
+
export declare function PaymentMethodFeeDetailsEntityFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaymentMethodFeeDetailsEntity;
|
|
54
|
+
export declare function PaymentMethodFeeDetailsEntityToJSON(value?: PaymentMethodFeeDetailsEntity | null): any;
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Channel Payments API
|
|
6
|
+
*
|
|
7
|
+
* NOTE: This class is auto generated. Do not edit the class manually.
|
|
8
|
+
*
|
|
9
|
+
*/
|
|
10
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11
|
+
exports.PaymentMethodFeeDetailsEntityMethodEnum = void 0;
|
|
12
|
+
exports.instanceOfPaymentMethodFeeDetailsEntity = instanceOfPaymentMethodFeeDetailsEntity;
|
|
13
|
+
exports.PaymentMethodFeeDetailsEntityFromJSON = PaymentMethodFeeDetailsEntityFromJSON;
|
|
14
|
+
exports.PaymentMethodFeeDetailsEntityFromJSONTyped = PaymentMethodFeeDetailsEntityFromJSONTyped;
|
|
15
|
+
exports.PaymentMethodFeeDetailsEntityToJSON = PaymentMethodFeeDetailsEntityToJSON;
|
|
16
|
+
const runtime_1 = require("../runtime");
|
|
17
|
+
const FeeDetailsEntity_1 = require("./FeeDetailsEntity");
|
|
18
|
+
/**
|
|
19
|
+
* @export
|
|
20
|
+
*/
|
|
21
|
+
exports.PaymentMethodFeeDetailsEntityMethodEnum = {
|
|
22
|
+
Ach: 'ACH',
|
|
23
|
+
Bank: 'BANK',
|
|
24
|
+
Card: 'CARD'
|
|
25
|
+
};
|
|
26
|
+
/**
|
|
27
|
+
* Check if a given object implements the PaymentMethodFeeDetailsEntity interface.
|
|
28
|
+
*/
|
|
29
|
+
function instanceOfPaymentMethodFeeDetailsEntity(value) {
|
|
30
|
+
let isInstance = true;
|
|
31
|
+
isInstance = isInstance && "method" in value;
|
|
32
|
+
isInstance = isInstance && "fees" in value;
|
|
33
|
+
isInstance = isInstance && "feesTotal" in value;
|
|
34
|
+
isInstance = isInstance && "adjustedTotal" in value;
|
|
35
|
+
return isInstance;
|
|
36
|
+
}
|
|
37
|
+
function PaymentMethodFeeDetailsEntityFromJSON(json) {
|
|
38
|
+
return PaymentMethodFeeDetailsEntityFromJSONTyped(json, false);
|
|
39
|
+
}
|
|
40
|
+
function PaymentMethodFeeDetailsEntityFromJSONTyped(json, ignoreDiscriminator) {
|
|
41
|
+
if ((json === undefined) || (json === null)) {
|
|
42
|
+
return json;
|
|
43
|
+
}
|
|
44
|
+
const typed = {
|
|
45
|
+
'method': json['method'],
|
|
46
|
+
'fees': (json['fees'].map(FeeDetailsEntity_1.FeeDetailsEntityFromJSON)),
|
|
47
|
+
'feesTotal': json['feesTotal'],
|
|
48
|
+
'adjustedTotal': json['adjustedTotal'],
|
|
49
|
+
};
|
|
50
|
+
return (0, runtime_1.removeNullUndefined)(typed);
|
|
51
|
+
}
|
|
52
|
+
function PaymentMethodFeeDetailsEntityToJSON(value) {
|
|
53
|
+
if (value === undefined) {
|
|
54
|
+
return undefined;
|
|
55
|
+
}
|
|
56
|
+
if (value === null) {
|
|
57
|
+
return null;
|
|
58
|
+
}
|
|
59
|
+
return {
|
|
60
|
+
'method': value.method,
|
|
61
|
+
'fees': (value.fees.map(FeeDetailsEntity_1.FeeDetailsEntityToJSON)),
|
|
62
|
+
'feesTotal': value.feesTotal,
|
|
63
|
+
'adjustedTotal': value.adjustedTotal,
|
|
64
|
+
};
|
|
65
|
+
}
|
|
@@ -4,9 +4,9 @@
|
|
|
4
4
|
* NOTE: This class is auto generated. Do not edit the class manually.
|
|
5
5
|
*
|
|
6
6
|
*/
|
|
7
|
-
import type { PaymentMethodBaseEntity } from './PaymentMethodBaseEntity';
|
|
8
7
|
import type { TagEntity } from './TagEntity';
|
|
9
8
|
import type { TransactionFeeDetailsEntity } from './TransactionFeeDetailsEntity';
|
|
9
|
+
import type { TransactionPaymentInstrumentBaseEntity } from './TransactionPaymentInstrumentBaseEntity';
|
|
10
10
|
/**
|
|
11
11
|
*
|
|
12
12
|
* @export
|
|
@@ -81,10 +81,10 @@ export interface TransactionEntity {
|
|
|
81
81
|
secCode?: TransactionEntitySecCodeEnum;
|
|
82
82
|
/**
|
|
83
83
|
* The payment method of the transaction.
|
|
84
|
-
* @type {
|
|
84
|
+
* @type {TransactionPaymentInstrumentBaseEntity}
|
|
85
85
|
* @memberof TransactionEntity
|
|
86
86
|
*/
|
|
87
|
-
paymentMethod?:
|
|
87
|
+
paymentMethod?: TransactionPaymentInstrumentBaseEntity;
|
|
88
88
|
/**
|
|
89
89
|
* The raw response code of the transaction.
|
|
90
90
|
* @type {string}
|
|
@@ -247,12 +247,6 @@ export interface TransactionEntity {
|
|
|
247
247
|
* @memberof TransactionEntity
|
|
248
248
|
*/
|
|
249
249
|
tags?: Array<TagEntity>;
|
|
250
|
-
/**
|
|
251
|
-
*
|
|
252
|
-
* @type {string}
|
|
253
|
-
* @memberof TransactionEntity
|
|
254
|
-
*/
|
|
255
|
-
declineReason?: string;
|
|
256
250
|
}
|
|
257
251
|
/**
|
|
258
252
|
* @export
|
|
@@ -14,9 +14,9 @@ exports.TransactionEntityFromJSON = TransactionEntityFromJSON;
|
|
|
14
14
|
exports.TransactionEntityFromJSONTyped = TransactionEntityFromJSONTyped;
|
|
15
15
|
exports.TransactionEntityToJSON = TransactionEntityToJSON;
|
|
16
16
|
const runtime_1 = require("../runtime");
|
|
17
|
-
const PaymentMethodBaseEntity_1 = require("./PaymentMethodBaseEntity");
|
|
18
17
|
const TagEntity_1 = require("./TagEntity");
|
|
19
18
|
const TransactionFeeDetailsEntity_1 = require("./TransactionFeeDetailsEntity");
|
|
19
|
+
const TransactionPaymentInstrumentBaseEntity_1 = require("./TransactionPaymentInstrumentBaseEntity");
|
|
20
20
|
/**
|
|
21
21
|
* @export
|
|
22
22
|
*/
|
|
@@ -97,7 +97,7 @@ function TransactionEntityFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
97
97
|
'feeDetails': !(0, runtime_1.exists)(json, 'feeDetails') ? undefined : (json['feeDetails'].map(TransactionFeeDetailsEntity_1.TransactionFeeDetailsEntityFromJSON)),
|
|
98
98
|
'currency': !(0, runtime_1.exists)(json, 'currency') ? undefined : json['currency'],
|
|
99
99
|
'secCode': !(0, runtime_1.exists)(json, 'secCode') ? undefined : json['secCode'],
|
|
100
|
-
'paymentMethod': !(0, runtime_1.exists)(json, 'paymentMethod') ? undefined : (0,
|
|
100
|
+
'paymentMethod': !(0, runtime_1.exists)(json, 'paymentMethod') ? undefined : (0, TransactionPaymentInstrumentBaseEntity_1.TransactionPaymentInstrumentBaseEntityFromJSON)(json['paymentMethod']),
|
|
101
101
|
'rawResponseCode': !(0, runtime_1.exists)(json, 'rawResponseCode') ? undefined : json['rawResponseCode'],
|
|
102
102
|
'rawResponseDescription': !(0, runtime_1.exists)(json, 'rawResponseDescription') ? undefined : json['rawResponseDescription'],
|
|
103
103
|
'avsResponseCode': !(0, runtime_1.exists)(json, 'avsResponseCode') ? undefined : json['avsResponseCode'],
|
|
@@ -125,7 +125,6 @@ function TransactionEntityFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
125
125
|
'settledAt': !(0, runtime_1.exists)(json, 'settledAt') ? undefined : (new Date(json['settledAt'])),
|
|
126
126
|
'returnedAt': !(0, runtime_1.exists)(json, 'returnedAt') ? undefined : (new Date(json['returnedAt'])),
|
|
127
127
|
'tags': !(0, runtime_1.exists)(json, 'tags') ? undefined : (json['tags'].map(TagEntity_1.TagEntityFromJSON)),
|
|
128
|
-
'declineReason': !(0, runtime_1.exists)(json, 'declineReason') ? undefined : json['declineReason'],
|
|
129
128
|
};
|
|
130
129
|
return (0, runtime_1.removeNullUndefined)(typed);
|
|
131
130
|
}
|
|
@@ -148,7 +147,7 @@ function TransactionEntityToJSON(value) {
|
|
|
148
147
|
'feeDetails': value.feeDetails === undefined ? undefined : (value.feeDetails.map(TransactionFeeDetailsEntity_1.TransactionFeeDetailsEntityToJSON)),
|
|
149
148
|
'currency': value.currency,
|
|
150
149
|
'secCode': value.secCode,
|
|
151
|
-
'paymentMethod': (0,
|
|
150
|
+
'paymentMethod': (0, TransactionPaymentInstrumentBaseEntity_1.TransactionPaymentInstrumentBaseEntityToJSON)(value.paymentMethod),
|
|
152
151
|
'rawResponseCode': value.rawResponseCode,
|
|
153
152
|
'rawResponseDescription': value.rawResponseDescription,
|
|
154
153
|
'avsResponseCode': value.avsResponseCode,
|
|
@@ -176,6 +175,5 @@ function TransactionEntityToJSON(value) {
|
|
|
176
175
|
'settledAt': value.settledAt === undefined ? undefined : (value.settledAt.toISOString()),
|
|
177
176
|
'returnedAt': value.returnedAt === undefined ? undefined : (value.returnedAt.toISOString()),
|
|
178
177
|
'tags': value.tags === undefined ? undefined : (value.tags.map(TagEntity_1.TagEntityToJSON)),
|
|
179
|
-
'declineReason': value.declineReason,
|
|
180
178
|
};
|
|
181
179
|
}
|