@channelpayments/node-sdk 1.49.0 → 1.50.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 +5 -5
- package/dist/cjs/apis/ChannelPaymentsApi.js +4 -4
- package/dist/cjs/models/PaymentMethodEntity1.d.ts +29 -5
- package/dist/cjs/models/PaymentMethodEntity1.js +16 -8
- package/dist/cjs/models/TransactionEntity.d.ts +69 -26
- package/dist/cjs/models/TransactionEntity.js +54 -29
- package/dist/cjs/models/TransactionsSearchEntity.d.ts +3 -3
- package/dist/cjs/models/TransactionsSearchEntity.js +3 -3
- package/dist/cjs/models/index.d.ts +0 -3
- package/dist/cjs/models/index.js +0 -3
- package/dist/mjs/apis/ChannelPaymentsApi.d.ts +5 -5
- package/dist/mjs/apis/ChannelPaymentsApi.js +5 -5
- package/dist/mjs/models/PaymentMethodEntity1.d.ts +29 -5
- package/dist/mjs/models/PaymentMethodEntity1.js +16 -8
- package/dist/mjs/models/TransactionEntity.d.ts +69 -26
- package/dist/mjs/models/TransactionEntity.js +54 -29
- package/dist/mjs/models/TransactionsSearchEntity.d.ts +3 -3
- package/dist/mjs/models/TransactionsSearchEntity.js +3 -3
- package/dist/mjs/models/index.d.ts +0 -3
- package/dist/mjs/models/index.js +0 -3
- package/package.json +1 -1
- package/dist/cjs/models/PaymentMethodEntity2.d.ts +0 -113
- package/dist/cjs/models/PaymentMethodEntity2.js +0 -82
- package/dist/cjs/models/PaymentServiceDetailsEntity.d.ts +0 -50
- package/dist/cjs/models/PaymentServiceDetailsEntity.js +0 -54
- package/dist/cjs/models/TransactionEntity1.d.ts +0 -241
- package/dist/cjs/models/TransactionEntity1.js +0 -150
- package/dist/mjs/models/PaymentMethodEntity2.d.ts +0 -113
- package/dist/mjs/models/PaymentMethodEntity2.js +0 -75
- package/dist/mjs/models/PaymentServiceDetailsEntity.d.ts +0 -50
- package/dist/mjs/models/PaymentServiceDetailsEntity.js +0 -47
- package/dist/mjs/models/TransactionEntity1.d.ts +0 -241
- package/dist/mjs/models/TransactionEntity1.js +0 -143
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*
|
|
6
6
|
*/
|
|
7
7
|
import * as runtime from '../runtime';
|
|
8
|
-
import type { BuyerEntity, BuyersSearchEntity, CaptureTransactionDto, CreateBuyerDto, CreatePaymentMethodDto, CreateTransactionDto, MerchantEntity, PaymentMethodEntity, PaymentMethodsSearchEntity, RefundTransactionDto,
|
|
8
|
+
import type { BuyerEntity, BuyersSearchEntity, CaptureTransactionDto, CreateBuyerDto, CreatePaymentMethodDto, CreateTransactionDto, MerchantEntity, PaymentMethodEntity, PaymentMethodsSearchEntity, RefundTransactionDto, TransactionEntity, TransactionRefundEntity, TransactionRefundsSearchEntity, TransactionsSearchEntity, UpdateBuyerDto } from '../models';
|
|
9
9
|
export interface DeleteBuyerRequest {
|
|
10
10
|
buyerId: string;
|
|
11
11
|
}
|
|
@@ -90,7 +90,7 @@ export declare class ChannelPaymentsApi extends runtime.BaseAPI {
|
|
|
90
90
|
* Attempts to capture an authorized transaction
|
|
91
91
|
* Capture transaction
|
|
92
92
|
*/
|
|
93
|
-
captureTransaction(requestParameters: CaptureTransactionDto): Promise<
|
|
93
|
+
captureTransaction(requestParameters: CaptureTransactionDto): Promise<TransactionEntity>;
|
|
94
94
|
/**
|
|
95
95
|
* Creates a new buyer.
|
|
96
96
|
* Create buyer.
|
|
@@ -100,7 +100,7 @@ export declare class ChannelPaymentsApi extends runtime.BaseAPI {
|
|
|
100
100
|
* Attempts to create a new transaction by specified intent for a given payment method
|
|
101
101
|
* Create transaction
|
|
102
102
|
*/
|
|
103
|
-
createTransaction(requestParameters: CreateTransactionDto): Promise<
|
|
103
|
+
createTransaction(requestParameters: CreateTransactionDto): Promise<TransactionEntity>;
|
|
104
104
|
/**
|
|
105
105
|
* Removes a buyer ID.
|
|
106
106
|
* Remove buyer.
|
|
@@ -140,7 +140,7 @@ export declare class ChannelPaymentsApi extends runtime.BaseAPI {
|
|
|
140
140
|
* Attempts to find a transaction by ID
|
|
141
141
|
* Find transaction
|
|
142
142
|
*/
|
|
143
|
-
getTransaction(requestParameters: GetTransactionRequest): Promise<
|
|
143
|
+
getTransaction(requestParameters: GetTransactionRequest): Promise<TransactionEntity>;
|
|
144
144
|
/**
|
|
145
145
|
* Attempts to refund a captured transaction
|
|
146
146
|
* Refund a transaction
|
|
@@ -180,7 +180,7 @@ export declare class ChannelPaymentsApi extends runtime.BaseAPI {
|
|
|
180
180
|
* Attempts to void an authorized transaction
|
|
181
181
|
* Void a transaction
|
|
182
182
|
*/
|
|
183
|
-
voidTransaction(requestParameters: VoidTransactionRequest): Promise<
|
|
183
|
+
voidTransaction(requestParameters: VoidTransactionRequest): Promise<TransactionEntity>;
|
|
184
184
|
}
|
|
185
185
|
/**
|
|
186
186
|
* @export
|
|
@@ -71,7 +71,7 @@ class ChannelPaymentsApi extends runtime.BaseAPI {
|
|
|
71
71
|
});
|
|
72
72
|
let response;
|
|
73
73
|
if (rawResponse.status === 201) {
|
|
74
|
-
response = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.
|
|
74
|
+
response = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.TransactionEntityFromJSON)(jsonValue));
|
|
75
75
|
}
|
|
76
76
|
if (rawResponse.status === 400) {
|
|
77
77
|
const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
|
|
@@ -184,7 +184,7 @@ class ChannelPaymentsApi extends runtime.BaseAPI {
|
|
|
184
184
|
});
|
|
185
185
|
let response;
|
|
186
186
|
if (rawResponse.status === 201) {
|
|
187
|
-
response = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.
|
|
187
|
+
response = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.TransactionEntityFromJSON)(jsonValue));
|
|
188
188
|
}
|
|
189
189
|
if (rawResponse.status === 400) {
|
|
190
190
|
const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
|
|
@@ -539,7 +539,7 @@ class ChannelPaymentsApi extends runtime.BaseAPI {
|
|
|
539
539
|
});
|
|
540
540
|
let response;
|
|
541
541
|
if (rawResponse.status === 200) {
|
|
542
|
-
response = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.
|
|
542
|
+
response = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.TransactionEntityFromJSON)(jsonValue));
|
|
543
543
|
}
|
|
544
544
|
if (rawResponse.status === 400) {
|
|
545
545
|
const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
|
|
@@ -1063,7 +1063,7 @@ class ChannelPaymentsApi extends runtime.BaseAPI {
|
|
|
1063
1063
|
});
|
|
1064
1064
|
let response;
|
|
1065
1065
|
if (rawResponse.status === 201) {
|
|
1066
|
-
response = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.
|
|
1066
|
+
response = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.TransactionEntityFromJSON)(jsonValue));
|
|
1067
1067
|
}
|
|
1068
1068
|
if (rawResponse.status === 400) {
|
|
1069
1069
|
const errorResponse = new runtime.JSONApiResponse(rawResponse, (jsonValue) => (0, models_1.ErrorEntityFromJSON)(jsonValue));
|
|
@@ -21,13 +21,13 @@ export interface PaymentMethodEntity1 {
|
|
|
21
21
|
* @type {string}
|
|
22
22
|
* @memberof PaymentMethodEntity1
|
|
23
23
|
*/
|
|
24
|
-
|
|
24
|
+
method: string;
|
|
25
25
|
/**
|
|
26
26
|
*
|
|
27
27
|
* @type {string}
|
|
28
28
|
* @memberof PaymentMethodEntity1
|
|
29
29
|
*/
|
|
30
|
-
|
|
30
|
+
externalPaymentMethodId?: string;
|
|
31
31
|
/**
|
|
32
32
|
*
|
|
33
33
|
* @type {string}
|
|
@@ -70,14 +70,38 @@ export interface PaymentMethodEntity1 {
|
|
|
70
70
|
* @memberof PaymentMethodEntity1
|
|
71
71
|
*/
|
|
72
72
|
cardType?: PaymentMethodEntity1CardTypeEnum;
|
|
73
|
+
/**
|
|
74
|
+
*
|
|
75
|
+
* @type {string}
|
|
76
|
+
* @memberof PaymentMethodEntity1
|
|
77
|
+
*/
|
|
78
|
+
accountName?: string;
|
|
79
|
+
/**
|
|
80
|
+
*
|
|
81
|
+
* @type {string}
|
|
82
|
+
* @memberof PaymentMethodEntity1
|
|
83
|
+
*/
|
|
84
|
+
accountNumber?: string;
|
|
85
|
+
/**
|
|
86
|
+
*
|
|
87
|
+
* @type {string}
|
|
88
|
+
* @memberof PaymentMethodEntity1
|
|
89
|
+
*/
|
|
90
|
+
accountType?: string;
|
|
91
|
+
/**
|
|
92
|
+
*
|
|
93
|
+
* @type {string}
|
|
94
|
+
* @memberof PaymentMethodEntity1
|
|
95
|
+
*/
|
|
96
|
+
aBANumber?: string;
|
|
73
97
|
}
|
|
74
98
|
/**
|
|
75
99
|
* @export
|
|
76
100
|
*/
|
|
77
101
|
export declare const PaymentMethodEntity1CardTypeEnum: {
|
|
78
|
-
readonly Credit: "
|
|
79
|
-
readonly Debit: "
|
|
80
|
-
readonly Prepaid: "
|
|
102
|
+
readonly Credit: "CREDIT";
|
|
103
|
+
readonly Debit: "DEBIT";
|
|
104
|
+
readonly Prepaid: "PREPAID";
|
|
81
105
|
};
|
|
82
106
|
export type PaymentMethodEntity1CardTypeEnum = typeof PaymentMethodEntity1CardTypeEnum[keyof typeof PaymentMethodEntity1CardTypeEnum];
|
|
83
107
|
/**
|
|
@@ -14,9 +14,9 @@ const runtime_1 = require("../runtime");
|
|
|
14
14
|
* @export
|
|
15
15
|
*/
|
|
16
16
|
exports.PaymentMethodEntity1CardTypeEnum = {
|
|
17
|
-
Credit: '
|
|
18
|
-
Debit: '
|
|
19
|
-
Prepaid: '
|
|
17
|
+
Credit: 'CREDIT',
|
|
18
|
+
Debit: 'DEBIT',
|
|
19
|
+
Prepaid: 'PREPAID'
|
|
20
20
|
};
|
|
21
21
|
/**
|
|
22
22
|
* Check if a given object implements the PaymentMethodEntity1 interface.
|
|
@@ -24,7 +24,7 @@ exports.PaymentMethodEntity1CardTypeEnum = {
|
|
|
24
24
|
function instanceOfPaymentMethodEntity1(value) {
|
|
25
25
|
let isInstance = true;
|
|
26
26
|
isInstance = isInstance && "paymentMethodId" in value;
|
|
27
|
-
isInstance = isInstance && "
|
|
27
|
+
isInstance = isInstance && "method" in value;
|
|
28
28
|
return isInstance;
|
|
29
29
|
}
|
|
30
30
|
exports.instanceOfPaymentMethodEntity1 = instanceOfPaymentMethodEntity1;
|
|
@@ -38,8 +38,8 @@ function PaymentMethodEntity1FromJSONTyped(json, ignoreDiscriminator) {
|
|
|
38
38
|
}
|
|
39
39
|
const typed = {
|
|
40
40
|
'paymentMethodId': json['paymentMethodId'],
|
|
41
|
-
'
|
|
42
|
-
'
|
|
41
|
+
'method': json['method'],
|
|
42
|
+
'externalPaymentMethodId': !(0, runtime_1.exists)(json, 'externalPaymentMethodId') ? undefined : json['externalPaymentMethodId'],
|
|
43
43
|
'label': !(0, runtime_1.exists)(json, 'label') ? undefined : json['label'],
|
|
44
44
|
'scheme': !(0, runtime_1.exists)(json, 'scheme') ? undefined : json['scheme'],
|
|
45
45
|
'expirationDate': !(0, runtime_1.exists)(json, 'expirationDate') ? undefined : json['expirationDate'],
|
|
@@ -47,6 +47,10 @@ function PaymentMethodEntity1FromJSONTyped(json, ignoreDiscriminator) {
|
|
|
47
47
|
'country': !(0, runtime_1.exists)(json, 'country') ? undefined : json['country'],
|
|
48
48
|
'bin': !(0, runtime_1.exists)(json, 'bin') ? undefined : json['bin'],
|
|
49
49
|
'cardType': !(0, runtime_1.exists)(json, 'cardType') ? undefined : json['cardType'],
|
|
50
|
+
'accountName': !(0, runtime_1.exists)(json, 'accountName') ? undefined : json['accountName'],
|
|
51
|
+
'accountNumber': !(0, runtime_1.exists)(json, 'accountNumber') ? undefined : json['accountNumber'],
|
|
52
|
+
'accountType': !(0, runtime_1.exists)(json, 'accountType') ? undefined : json['accountType'],
|
|
53
|
+
'aBANumber': !(0, runtime_1.exists)(json, 'ABANumber') ? undefined : json['ABANumber'],
|
|
50
54
|
};
|
|
51
55
|
return (0, runtime_1.removeNullUndefined)(typed);
|
|
52
56
|
}
|
|
@@ -60,8 +64,8 @@ function PaymentMethodEntity1ToJSON(value) {
|
|
|
60
64
|
}
|
|
61
65
|
return {
|
|
62
66
|
'paymentMethodId': value.paymentMethodId,
|
|
63
|
-
'
|
|
64
|
-
'
|
|
67
|
+
'method': value.method,
|
|
68
|
+
'externalPaymentMethodId': value.externalPaymentMethodId,
|
|
65
69
|
'label': value.label,
|
|
66
70
|
'scheme': value.scheme,
|
|
67
71
|
'expirationDate': value.expirationDate,
|
|
@@ -69,6 +73,10 @@ function PaymentMethodEntity1ToJSON(value) {
|
|
|
69
73
|
'country': value.country,
|
|
70
74
|
'bin': value.bin,
|
|
71
75
|
'cardType': value.cardType,
|
|
76
|
+
'accountName': value.accountName,
|
|
77
|
+
'accountNumber': value.accountNumber,
|
|
78
|
+
'accountType': value.accountType,
|
|
79
|
+
'ABANumber': value.aBANumber,
|
|
72
80
|
};
|
|
73
81
|
}
|
|
74
82
|
exports.PaymentMethodEntity1ToJSON = PaymentMethodEntity1ToJSON;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*
|
|
6
6
|
*/
|
|
7
7
|
import type { PaymentMethodEntity1 } from './PaymentMethodEntity1';
|
|
8
|
-
import type {
|
|
8
|
+
import type { PaymentsBuyerEntity } from './PaymentsBuyerEntity';
|
|
9
9
|
/**
|
|
10
10
|
*
|
|
11
11
|
* @export
|
|
@@ -17,7 +17,7 @@ export interface TransactionEntity {
|
|
|
17
17
|
* @type {string}
|
|
18
18
|
* @memberof TransactionEntity
|
|
19
19
|
*/
|
|
20
|
-
|
|
20
|
+
transactionIntegrationId: string;
|
|
21
21
|
/**
|
|
22
22
|
*
|
|
23
23
|
* @type {string}
|
|
@@ -29,19 +29,43 @@ export interface TransactionEntity {
|
|
|
29
29
|
* @type {string}
|
|
30
30
|
* @memberof TransactionEntity
|
|
31
31
|
*/
|
|
32
|
-
|
|
32
|
+
merchantId: string;
|
|
33
33
|
/**
|
|
34
34
|
*
|
|
35
35
|
* @type {string}
|
|
36
36
|
* @memberof TransactionEntity
|
|
37
37
|
*/
|
|
38
|
-
|
|
38
|
+
status: TransactionEntityStatusEnum;
|
|
39
|
+
/**
|
|
40
|
+
*
|
|
41
|
+
* @type {string}
|
|
42
|
+
* @memberof TransactionEntity
|
|
43
|
+
*/
|
|
44
|
+
intent: TransactionEntityIntentEnum;
|
|
45
|
+
/**
|
|
46
|
+
*
|
|
47
|
+
* @type {number}
|
|
48
|
+
* @memberof TransactionEntity
|
|
49
|
+
*/
|
|
50
|
+
amount: number;
|
|
51
|
+
/**
|
|
52
|
+
*
|
|
53
|
+
* @type {number}
|
|
54
|
+
* @memberof TransactionEntity
|
|
55
|
+
*/
|
|
56
|
+
netAmount: number;
|
|
39
57
|
/**
|
|
40
58
|
*
|
|
41
59
|
* @type {number}
|
|
42
60
|
* @memberof TransactionEntity
|
|
43
61
|
*/
|
|
44
|
-
|
|
62
|
+
fee: number;
|
|
63
|
+
/**
|
|
64
|
+
*
|
|
65
|
+
* @type {Array<string>}
|
|
66
|
+
* @memberof TransactionEntity
|
|
67
|
+
*/
|
|
68
|
+
feeDetails?: Array<string>;
|
|
45
69
|
/**
|
|
46
70
|
*
|
|
47
71
|
* @type {number}
|
|
@@ -74,28 +98,28 @@ export interface TransactionEntity {
|
|
|
74
98
|
paymentMethod?: PaymentMethodEntity1;
|
|
75
99
|
/**
|
|
76
100
|
*
|
|
77
|
-
* @type {
|
|
101
|
+
* @type {PaymentsBuyerEntity}
|
|
78
102
|
* @memberof TransactionEntity
|
|
79
103
|
*/
|
|
80
|
-
|
|
104
|
+
buyer?: PaymentsBuyerEntity;
|
|
81
105
|
/**
|
|
82
106
|
*
|
|
83
|
-
* @type {
|
|
107
|
+
* @type {string}
|
|
84
108
|
* @memberof TransactionEntity
|
|
85
109
|
*/
|
|
86
|
-
|
|
110
|
+
externalBuyerId?: string;
|
|
87
111
|
/**
|
|
88
112
|
*
|
|
89
113
|
* @type {Date}
|
|
90
114
|
* @memberof TransactionEntity
|
|
91
115
|
*/
|
|
92
|
-
|
|
116
|
+
createdAt?: Date;
|
|
93
117
|
/**
|
|
94
118
|
*
|
|
95
|
-
* @type {
|
|
119
|
+
* @type {Date}
|
|
96
120
|
* @memberof TransactionEntity
|
|
97
121
|
*/
|
|
98
|
-
|
|
122
|
+
updatedAt?: Date;
|
|
99
123
|
/**
|
|
100
124
|
*
|
|
101
125
|
* @type {boolean}
|
|
@@ -113,7 +137,7 @@ export interface TransactionEntity {
|
|
|
113
137
|
* @type {string}
|
|
114
138
|
* @memberof TransactionEntity
|
|
115
139
|
*/
|
|
116
|
-
|
|
140
|
+
rawResponseCode?: string;
|
|
117
141
|
/**
|
|
118
142
|
*
|
|
119
143
|
* @type {string}
|
|
@@ -125,19 +149,13 @@ export interface TransactionEntity {
|
|
|
125
149
|
* @type {string}
|
|
126
150
|
* @memberof TransactionEntity
|
|
127
151
|
*/
|
|
128
|
-
|
|
152
|
+
avsResponseCode?: string;
|
|
129
153
|
/**
|
|
130
154
|
*
|
|
131
155
|
* @type {string}
|
|
132
156
|
* @memberof TransactionEntity
|
|
133
157
|
*/
|
|
134
|
-
|
|
135
|
-
/**
|
|
136
|
-
*
|
|
137
|
-
* @type {object}
|
|
138
|
-
* @memberof TransactionEntity
|
|
139
|
-
*/
|
|
140
|
-
metadata?: object;
|
|
158
|
+
cvvResponseCode?: string;
|
|
141
159
|
/**
|
|
142
160
|
*
|
|
143
161
|
* @type {Date}
|
|
@@ -156,6 +174,24 @@ export interface TransactionEntity {
|
|
|
156
174
|
* @memberof TransactionEntity
|
|
157
175
|
*/
|
|
158
176
|
voidedAt?: Date;
|
|
177
|
+
/**
|
|
178
|
+
*
|
|
179
|
+
* @type {string}
|
|
180
|
+
* @memberof TransactionEntity
|
|
181
|
+
*/
|
|
182
|
+
externalTransactionId?: string;
|
|
183
|
+
/**
|
|
184
|
+
*
|
|
185
|
+
* @type {string}
|
|
186
|
+
* @memberof TransactionEntity
|
|
187
|
+
*/
|
|
188
|
+
buyerId?: string;
|
|
189
|
+
/**
|
|
190
|
+
*
|
|
191
|
+
* @type {string}
|
|
192
|
+
* @memberof TransactionEntity
|
|
193
|
+
*/
|
|
194
|
+
sECCode?: string;
|
|
159
195
|
}
|
|
160
196
|
/**
|
|
161
197
|
* @export
|
|
@@ -163,13 +199,18 @@ export interface TransactionEntity {
|
|
|
163
199
|
export declare const TransactionEntityStatusEnum: {
|
|
164
200
|
readonly Processing: "processing";
|
|
165
201
|
readonly BuyerApprovalPending: "buyerApprovalPending";
|
|
166
|
-
readonly
|
|
202
|
+
readonly Authorized: "authorized";
|
|
167
203
|
readonly AuthorizationFailed: "authorizationFailed";
|
|
168
|
-
readonly
|
|
204
|
+
readonly Declined: "declined";
|
|
169
205
|
readonly CapturePending: "capturePending";
|
|
170
|
-
readonly
|
|
171
|
-
readonly
|
|
172
|
-
readonly
|
|
206
|
+
readonly Captured: "captured";
|
|
207
|
+
readonly VoidPending: "voidPending";
|
|
208
|
+
readonly Voided: "voided";
|
|
209
|
+
readonly Held: "held";
|
|
210
|
+
readonly Submitted: "submitted";
|
|
211
|
+
readonly Transmitted: "transmitted";
|
|
212
|
+
readonly Settled: "settled";
|
|
213
|
+
readonly Returned: "returned";
|
|
173
214
|
};
|
|
174
215
|
export type TransactionEntityStatusEnum = typeof TransactionEntityStatusEnum[keyof typeof TransactionEntityStatusEnum];
|
|
175
216
|
/**
|
|
@@ -178,6 +219,8 @@ export type TransactionEntityStatusEnum = typeof TransactionEntityStatusEnum[key
|
|
|
178
219
|
export declare const TransactionEntityIntentEnum: {
|
|
179
220
|
readonly Capture: "capture";
|
|
180
221
|
readonly Authorize: "authorize";
|
|
222
|
+
readonly Debit: "debit";
|
|
223
|
+
readonly Credit: "credit";
|
|
181
224
|
};
|
|
182
225
|
export type TransactionEntityIntentEnum = typeof TransactionEntityIntentEnum[keyof typeof TransactionEntityIntentEnum];
|
|
183
226
|
/**
|
|
@@ -11,27 +11,34 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
11
11
|
exports.TransactionEntityToJSON = exports.TransactionEntityFromJSONTyped = exports.TransactionEntityFromJSON = exports.instanceOfTransactionEntity = exports.TransactionEntityCurrencyEnum = exports.TransactionEntityIntentEnum = exports.TransactionEntityStatusEnum = void 0;
|
|
12
12
|
const runtime_1 = require("../runtime");
|
|
13
13
|
const PaymentMethodEntity1_1 = require("./PaymentMethodEntity1");
|
|
14
|
-
const
|
|
14
|
+
const PaymentsBuyerEntity_1 = require("./PaymentsBuyerEntity");
|
|
15
15
|
/**
|
|
16
16
|
* @export
|
|
17
17
|
*/
|
|
18
18
|
exports.TransactionEntityStatusEnum = {
|
|
19
19
|
Processing: 'processing',
|
|
20
20
|
BuyerApprovalPending: 'buyerApprovalPending',
|
|
21
|
-
|
|
21
|
+
Authorized: 'authorized',
|
|
22
22
|
AuthorizationFailed: 'authorizationFailed',
|
|
23
|
-
|
|
23
|
+
Declined: 'declined',
|
|
24
24
|
CapturePending: 'capturePending',
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
25
|
+
Captured: 'captured',
|
|
26
|
+
VoidPending: 'voidPending',
|
|
27
|
+
Voided: 'voided',
|
|
28
|
+
Held: 'held',
|
|
29
|
+
Submitted: 'submitted',
|
|
30
|
+
Transmitted: 'transmitted',
|
|
31
|
+
Settled: 'settled',
|
|
32
|
+
Returned: 'returned'
|
|
28
33
|
};
|
|
29
34
|
/**
|
|
30
35
|
* @export
|
|
31
36
|
*/
|
|
32
37
|
exports.TransactionEntityIntentEnum = {
|
|
33
38
|
Capture: 'capture',
|
|
34
|
-
Authorize: 'authorize'
|
|
39
|
+
Authorize: 'authorize',
|
|
40
|
+
Debit: 'debit',
|
|
41
|
+
Credit: 'credit'
|
|
35
42
|
};
|
|
36
43
|
/**
|
|
37
44
|
* @export
|
|
@@ -46,8 +53,14 @@ exports.TransactionEntityCurrencyEnum = {
|
|
|
46
53
|
*/
|
|
47
54
|
function instanceOfTransactionEntity(value) {
|
|
48
55
|
let isInstance = true;
|
|
49
|
-
isInstance = isInstance && "
|
|
56
|
+
isInstance = isInstance && "transactionIntegrationId" in value;
|
|
50
57
|
isInstance = isInstance && "transactionId" in value;
|
|
58
|
+
isInstance = isInstance && "merchantId" in value;
|
|
59
|
+
isInstance = isInstance && "status" in value;
|
|
60
|
+
isInstance = isInstance && "intent" in value;
|
|
61
|
+
isInstance = isInstance && "amount" in value;
|
|
62
|
+
isInstance = isInstance && "netAmount" in value;
|
|
63
|
+
isInstance = isInstance && "fee" in value;
|
|
51
64
|
return isInstance;
|
|
52
65
|
}
|
|
53
66
|
exports.instanceOfTransactionEntity = instanceOfTransactionEntity;
|
|
@@ -60,30 +73,36 @@ function TransactionEntityFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
60
73
|
return json;
|
|
61
74
|
}
|
|
62
75
|
const typed = {
|
|
63
|
-
'
|
|
76
|
+
'transactionIntegrationId': json['transactionIntegrationId'],
|
|
64
77
|
'transactionId': json['transactionId'],
|
|
65
|
-
'
|
|
66
|
-
'
|
|
67
|
-
'
|
|
78
|
+
'merchantId': json['merchantId'],
|
|
79
|
+
'status': json['status'],
|
|
80
|
+
'intent': json['intent'],
|
|
81
|
+
'amount': json['amount'],
|
|
82
|
+
'netAmount': json['netAmount'],
|
|
83
|
+
'fee': json['fee'],
|
|
84
|
+
'feeDetails': !(0, runtime_1.exists)(json, 'feeDetails') ? undefined : json['feeDetails'],
|
|
68
85
|
'capturedAmount': !(0, runtime_1.exists)(json, 'capturedAmount') ? undefined : json['capturedAmount'],
|
|
69
86
|
'refundedAmount': !(0, runtime_1.exists)(json, 'refundedAmount') ? undefined : json['refundedAmount'],
|
|
70
87
|
'currency': !(0, runtime_1.exists)(json, 'currency') ? undefined : json['currency'],
|
|
71
88
|
'country': !(0, runtime_1.exists)(json, 'country') ? undefined : json['country'],
|
|
72
89
|
'paymentMethod': !(0, runtime_1.exists)(json, 'paymentMethod') ? undefined : (0, PaymentMethodEntity1_1.PaymentMethodEntity1FromJSON)(json['paymentMethod']),
|
|
73
|
-
'
|
|
74
|
-
'
|
|
75
|
-
'
|
|
76
|
-
'
|
|
90
|
+
'buyer': !(0, runtime_1.exists)(json, 'buyer') ? undefined : (0, PaymentsBuyerEntity_1.PaymentsBuyerEntityFromJSON)(json['buyer']),
|
|
91
|
+
'externalBuyerId': !(0, runtime_1.exists)(json, 'externalBuyerId') ? undefined : json['externalBuyerId'],
|
|
92
|
+
'createdAt': !(0, runtime_1.exists)(json, 'createdAt') ? undefined : (new Date(json['createdAt'])),
|
|
93
|
+
'updatedAt': !(0, runtime_1.exists)(json, 'updatedAt') ? undefined : (new Date(json['updatedAt'])),
|
|
77
94
|
'merchantInitiated': !(0, runtime_1.exists)(json, 'merchantInitiated') ? undefined : json['merchantInitiated'],
|
|
78
95
|
'schemeTransactionId': !(0, runtime_1.exists)(json, 'schemeTransactionId') ? undefined : json['schemeTransactionId'],
|
|
79
|
-
'
|
|
96
|
+
'rawResponseCode': !(0, runtime_1.exists)(json, 'rawResponseCode') ? undefined : json['rawResponseCode'],
|
|
80
97
|
'rawResponseDescription': !(0, runtime_1.exists)(json, 'rawResponseDescription') ? undefined : json['rawResponseDescription'],
|
|
81
|
-
'
|
|
82
|
-
'
|
|
83
|
-
'metadata': !(0, runtime_1.exists)(json, 'metadata') ? undefined : json['metadata'],
|
|
98
|
+
'avsResponseCode': !(0, runtime_1.exists)(json, 'avsResponseCode') ? undefined : json['avsResponseCode'],
|
|
99
|
+
'cvvResponseCode': !(0, runtime_1.exists)(json, 'cvvResponseCode') ? undefined : json['cvvResponseCode'],
|
|
84
100
|
'capturedAt': !(0, runtime_1.exists)(json, 'capturedAt') ? undefined : (new Date(json['capturedAt'])),
|
|
85
101
|
'authorizedAt': !(0, runtime_1.exists)(json, 'authorizedAt') ? undefined : (new Date(json['authorizedAt'])),
|
|
86
102
|
'voidedAt': !(0, runtime_1.exists)(json, 'voidedAt') ? undefined : (new Date(json['voidedAt'])),
|
|
103
|
+
'externalTransactionId': !(0, runtime_1.exists)(json, 'externalTransactionId') ? undefined : json['externalTransactionId'],
|
|
104
|
+
'buyerId': !(0, runtime_1.exists)(json, 'buyerId') ? undefined : json['buyerId'],
|
|
105
|
+
'sECCode': !(0, runtime_1.exists)(json, 'SECCode') ? undefined : json['SECCode'],
|
|
87
106
|
};
|
|
88
107
|
return (0, runtime_1.removeNullUndefined)(typed);
|
|
89
108
|
}
|
|
@@ -96,30 +115,36 @@ function TransactionEntityToJSON(value) {
|
|
|
96
115
|
return null;
|
|
97
116
|
}
|
|
98
117
|
return {
|
|
99
|
-
'
|
|
118
|
+
'transactionIntegrationId': value.transactionIntegrationId,
|
|
100
119
|
'transactionId': value.transactionId,
|
|
120
|
+
'merchantId': value.merchantId,
|
|
101
121
|
'status': value.status,
|
|
102
122
|
'intent': value.intent,
|
|
103
123
|
'amount': value.amount,
|
|
124
|
+
'netAmount': value.netAmount,
|
|
125
|
+
'fee': value.fee,
|
|
126
|
+
'feeDetails': value.feeDetails,
|
|
104
127
|
'capturedAmount': value.capturedAmount,
|
|
105
128
|
'refundedAmount': value.refundedAmount,
|
|
106
129
|
'currency': value.currency,
|
|
107
130
|
'country': value.country,
|
|
108
131
|
'paymentMethod': (0, PaymentMethodEntity1_1.PaymentMethodEntity1ToJSON)(value.paymentMethod),
|
|
109
|
-
'
|
|
110
|
-
'
|
|
111
|
-
'
|
|
112
|
-
'
|
|
132
|
+
'buyer': (0, PaymentsBuyerEntity_1.PaymentsBuyerEntityToJSON)(value.buyer),
|
|
133
|
+
'externalBuyerId': value.externalBuyerId,
|
|
134
|
+
'createdAt': value.createdAt === undefined ? undefined : (value.createdAt.toISOString()),
|
|
135
|
+
'updatedAt': value.updatedAt === undefined ? undefined : (value.updatedAt.toISOString()),
|
|
113
136
|
'merchantInitiated': value.merchantInitiated,
|
|
114
137
|
'schemeTransactionId': value.schemeTransactionId,
|
|
115
|
-
'
|
|
138
|
+
'rawResponseCode': value.rawResponseCode,
|
|
116
139
|
'rawResponseDescription': value.rawResponseDescription,
|
|
117
|
-
'
|
|
118
|
-
'
|
|
119
|
-
'metadata': value.metadata,
|
|
140
|
+
'avsResponseCode': value.avsResponseCode,
|
|
141
|
+
'cvvResponseCode': value.cvvResponseCode,
|
|
120
142
|
'capturedAt': value.capturedAt === undefined ? undefined : (value.capturedAt.toISOString()),
|
|
121
143
|
'authorizedAt': value.authorizedAt === undefined ? undefined : (value.authorizedAt.toISOString()),
|
|
122
144
|
'voidedAt': value.voidedAt === undefined ? undefined : (value.voidedAt.toISOString()),
|
|
145
|
+
'externalTransactionId': value.externalTransactionId,
|
|
146
|
+
'buyerId': value.buyerId,
|
|
147
|
+
'SECCode': value.sECCode,
|
|
123
148
|
};
|
|
124
149
|
}
|
|
125
150
|
exports.TransactionEntityToJSON = TransactionEntityToJSON;
|
|
@@ -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 { TransactionEntity } from './TransactionEntity';
|
|
8
8
|
/**
|
|
9
9
|
*
|
|
10
10
|
* @export
|
|
@@ -19,10 +19,10 @@ export interface TransactionsSearchEntity {
|
|
|
19
19
|
prevCursor: string;
|
|
20
20
|
/**
|
|
21
21
|
* The list of queried transactions
|
|
22
|
-
* @type {Array<
|
|
22
|
+
* @type {Array<TransactionEntity>}
|
|
23
23
|
* @memberof TransactionsSearchEntity
|
|
24
24
|
*/
|
|
25
|
-
transactions: Array<
|
|
25
|
+
transactions: Array<TransactionEntity>;
|
|
26
26
|
/**
|
|
27
27
|
* The number of records returned
|
|
28
28
|
* @type {number}
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11
11
|
exports.TransactionsSearchEntityToJSON = exports.TransactionsSearchEntityFromJSONTyped = exports.TransactionsSearchEntityFromJSON = exports.instanceOfTransactionsSearchEntity = void 0;
|
|
12
12
|
const runtime_1 = require("../runtime");
|
|
13
|
-
const
|
|
13
|
+
const TransactionEntity_1 = require("./TransactionEntity");
|
|
14
14
|
/**
|
|
15
15
|
* Check if a given object implements the TransactionsSearchEntity interface.
|
|
16
16
|
*/
|
|
@@ -32,7 +32,7 @@ function TransactionsSearchEntityFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
32
32
|
}
|
|
33
33
|
const typed = {
|
|
34
34
|
'prevCursor': json['prevCursor'],
|
|
35
|
-
'transactions': (json['transactions'].map(
|
|
35
|
+
'transactions': (json['transactions'].map(TransactionEntity_1.TransactionEntityFromJSON)),
|
|
36
36
|
'limit': json['limit'],
|
|
37
37
|
'nextCursor': !(0, runtime_1.exists)(json, 'nextCursor') ? undefined : json['nextCursor'],
|
|
38
38
|
'page': !(0, runtime_1.exists)(json, 'page') ? undefined : json['page'],
|
|
@@ -49,7 +49,7 @@ function TransactionsSearchEntityToJSON(value) {
|
|
|
49
49
|
}
|
|
50
50
|
return {
|
|
51
51
|
'prevCursor': value.prevCursor,
|
|
52
|
-
'transactions': (value.transactions.map(
|
|
52
|
+
'transactions': (value.transactions.map(TransactionEntity_1.TransactionEntityToJSON)),
|
|
53
53
|
'limit': value.limit,
|
|
54
54
|
'nextCursor': value.nextCursor,
|
|
55
55
|
'page': value.page,
|
|
@@ -55,11 +55,9 @@ export * from './MetadataRuleConditionEntity';
|
|
|
55
55
|
export * from './PaymentMethodDto';
|
|
56
56
|
export * from './PaymentMethodEntity';
|
|
57
57
|
export * from './PaymentMethodEntity1';
|
|
58
|
-
export * from './PaymentMethodEntity2';
|
|
59
58
|
export * from './PaymentMethodEntityBuyer';
|
|
60
59
|
export * from './PaymentMethodEntityCardDetails';
|
|
61
60
|
export * from './PaymentMethodsSearchEntity';
|
|
62
|
-
export * from './PaymentServiceDetailsEntity';
|
|
63
61
|
export * from './PaymentsBuyerEntity';
|
|
64
62
|
export * from './RefundTransactionDto';
|
|
65
63
|
export * from './RuleConditionsEntity';
|
|
@@ -67,7 +65,6 @@ export * from './RuleConditionsEntityAmount';
|
|
|
67
65
|
export * from './RuleConditionsEntityCfee';
|
|
68
66
|
export * from './RuleConnectorsEntity';
|
|
69
67
|
export * from './TransactionEntity';
|
|
70
|
-
export * from './TransactionEntity1';
|
|
71
68
|
export * from './TransactionRefundEntity';
|
|
72
69
|
export * from './TransactionRefundsSearchEntity';
|
|
73
70
|
export * from './TransactionsSearchEntity';
|
package/dist/cjs/models/index.js
CHANGED
|
@@ -73,11 +73,9 @@ __exportStar(require("./MetadataRuleConditionEntity"), exports);
|
|
|
73
73
|
__exportStar(require("./PaymentMethodDto"), exports);
|
|
74
74
|
__exportStar(require("./PaymentMethodEntity"), exports);
|
|
75
75
|
__exportStar(require("./PaymentMethodEntity1"), exports);
|
|
76
|
-
__exportStar(require("./PaymentMethodEntity2"), exports);
|
|
77
76
|
__exportStar(require("./PaymentMethodEntityBuyer"), exports);
|
|
78
77
|
__exportStar(require("./PaymentMethodEntityCardDetails"), exports);
|
|
79
78
|
__exportStar(require("./PaymentMethodsSearchEntity"), exports);
|
|
80
|
-
__exportStar(require("./PaymentServiceDetailsEntity"), exports);
|
|
81
79
|
__exportStar(require("./PaymentsBuyerEntity"), exports);
|
|
82
80
|
__exportStar(require("./RefundTransactionDto"), exports);
|
|
83
81
|
__exportStar(require("./RuleConditionsEntity"), exports);
|
|
@@ -85,7 +83,6 @@ __exportStar(require("./RuleConditionsEntityAmount"), exports);
|
|
|
85
83
|
__exportStar(require("./RuleConditionsEntityCfee"), exports);
|
|
86
84
|
__exportStar(require("./RuleConnectorsEntity"), exports);
|
|
87
85
|
__exportStar(require("./TransactionEntity"), exports);
|
|
88
|
-
__exportStar(require("./TransactionEntity1"), exports);
|
|
89
86
|
__exportStar(require("./TransactionRefundEntity"), exports);
|
|
90
87
|
__exportStar(require("./TransactionRefundsSearchEntity"), exports);
|
|
91
88
|
__exportStar(require("./TransactionsSearchEntity"), exports);
|