@spritz-finance/api-client 0.3.1 → 0.3.2
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.
|
@@ -199,6 +199,11 @@ interface BankAccountFragment_institution {
|
|
|
199
199
|
country: string;
|
|
200
200
|
currency: string;
|
|
201
201
|
}
|
|
202
|
+
interface BankAccountFragment_paymentAddresses {
|
|
203
|
+
__typename: "PaymentAddress";
|
|
204
|
+
network: string;
|
|
205
|
+
address: string;
|
|
206
|
+
}
|
|
202
207
|
interface BankAccountFragment {
|
|
203
208
|
__typename: "BankAccount";
|
|
204
209
|
id: string;
|
|
@@ -217,6 +222,7 @@ interface BankAccountFragment {
|
|
|
217
222
|
bankAccountDetails: BankAccountFragment_bankAccountDetails;
|
|
218
223
|
deliveryMethods: PaymentDeliveryMethod[];
|
|
219
224
|
institution: BankAccountFragment_institution | null;
|
|
225
|
+
paymentAddresses: BankAccountFragment_paymentAddresses[];
|
|
220
226
|
}
|
|
221
227
|
|
|
222
228
|
interface BillFragment_billAccountDetails {
|
|
@@ -242,6 +248,11 @@ interface BillFragment_institution {
|
|
|
242
248
|
name: string;
|
|
243
249
|
logo: string | null;
|
|
244
250
|
}
|
|
251
|
+
interface BillFragment_paymentAddresses {
|
|
252
|
+
__typename: "PaymentAddress";
|
|
253
|
+
network: string;
|
|
254
|
+
address: string;
|
|
255
|
+
}
|
|
245
256
|
interface BillFragment {
|
|
246
257
|
__typename: "Bill";
|
|
247
258
|
id: string;
|
|
@@ -257,6 +268,7 @@ interface BillFragment {
|
|
|
257
268
|
billAccountDetails: BillFragment_billAccountDetails | null;
|
|
258
269
|
dataSync: BillFragment_dataSync | null;
|
|
259
270
|
institution: BillFragment_institution | null;
|
|
271
|
+
paymentAddresses: BillFragment_paymentAddresses[];
|
|
260
272
|
}
|
|
261
273
|
|
|
262
274
|
interface CurrentUser_me {
|
|
@@ -638,6 +650,11 @@ interface UserBankAccounts_bankAccounts_institution {
|
|
|
638
650
|
country: string;
|
|
639
651
|
currency: string;
|
|
640
652
|
}
|
|
653
|
+
interface UserBankAccounts_bankAccounts_paymentAddresses {
|
|
654
|
+
__typename: "PaymentAddress";
|
|
655
|
+
network: string;
|
|
656
|
+
address: string;
|
|
657
|
+
}
|
|
641
658
|
interface UserBankAccounts_bankAccounts {
|
|
642
659
|
__typename: "BankAccount";
|
|
643
660
|
id: string;
|
|
@@ -656,6 +673,7 @@ interface UserBankAccounts_bankAccounts {
|
|
|
656
673
|
bankAccountDetails: UserBankAccounts_bankAccounts_bankAccountDetails;
|
|
657
674
|
deliveryMethods: PaymentDeliveryMethod[];
|
|
658
675
|
institution: UserBankAccounts_bankAccounts_institution | null;
|
|
676
|
+
paymentAddresses: UserBankAccounts_bankAccounts_paymentAddresses[];
|
|
659
677
|
}
|
|
660
678
|
interface UserBankAccounts {
|
|
661
679
|
bankAccounts: UserBankAccounts_bankAccounts[];
|
|
@@ -684,6 +702,11 @@ interface UserBills_bills_institution {
|
|
|
684
702
|
name: string;
|
|
685
703
|
logo: string | null;
|
|
686
704
|
}
|
|
705
|
+
interface UserBills_bills_paymentAddresses {
|
|
706
|
+
__typename: "PaymentAddress";
|
|
707
|
+
network: string;
|
|
708
|
+
address: string;
|
|
709
|
+
}
|
|
687
710
|
interface UserBills_bills {
|
|
688
711
|
__typename: "Bill";
|
|
689
712
|
id: string;
|
|
@@ -699,6 +722,7 @@ interface UserBills_bills {
|
|
|
699
722
|
billAccountDetails: UserBills_bills_billAccountDetails | null;
|
|
700
723
|
dataSync: UserBills_bills_dataSync | null;
|
|
701
724
|
institution: UserBills_bills_institution | null;
|
|
725
|
+
paymentAddresses: UserBills_bills_paymentAddresses[];
|
|
702
726
|
}
|
|
703
727
|
interface UserBills {
|
|
704
728
|
bills: UserBills_bills[];
|
|
@@ -887,6 +911,11 @@ interface UserVirtualDebitCard_virtualDebitCard_billingInfo {
|
|
|
887
911
|
email: string;
|
|
888
912
|
address: UserVirtualDebitCard_virtualDebitCard_billingInfo_address | null;
|
|
889
913
|
}
|
|
914
|
+
interface UserVirtualDebitCard_virtualDebitCard_paymentAddresses {
|
|
915
|
+
__typename: "PaymentAddress";
|
|
916
|
+
network: string;
|
|
917
|
+
address: string;
|
|
918
|
+
}
|
|
890
919
|
interface UserVirtualDebitCard_virtualDebitCard {
|
|
891
920
|
__typename: "VirtualCard";
|
|
892
921
|
id: string;
|
|
@@ -901,6 +930,7 @@ interface UserVirtualDebitCard_virtualDebitCard {
|
|
|
901
930
|
renderSecret: string | null;
|
|
902
931
|
virtualCardType: VirtualCardType;
|
|
903
932
|
billingInfo: UserVirtualDebitCard_virtualDebitCard_billingInfo | null;
|
|
933
|
+
paymentAddresses: UserVirtualDebitCard_virtualDebitCard_paymentAddresses[];
|
|
904
934
|
}
|
|
905
935
|
interface UserVirtualDebitCard {
|
|
906
936
|
virtualDebitCard: UserVirtualDebitCard_virtualDebitCard | null;
|
|
@@ -922,6 +952,11 @@ interface VirtualDebitCardFragment_billingInfo {
|
|
|
922
952
|
email: string;
|
|
923
953
|
address: VirtualDebitCardFragment_billingInfo_address | null;
|
|
924
954
|
}
|
|
955
|
+
interface VirtualDebitCardFragment_paymentAddresses {
|
|
956
|
+
__typename: "PaymentAddress";
|
|
957
|
+
network: string;
|
|
958
|
+
address: string;
|
|
959
|
+
}
|
|
925
960
|
interface VirtualDebitCardFragment {
|
|
926
961
|
__typename: "VirtualCard";
|
|
927
962
|
id: string;
|
|
@@ -936,6 +971,7 @@ interface VirtualDebitCardFragment {
|
|
|
936
971
|
renderSecret: string | null;
|
|
937
972
|
virtualCardType: VirtualCardType;
|
|
938
973
|
billingInfo: VirtualDebitCardFragment_billingInfo | null;
|
|
974
|
+
paymentAddresses: VirtualDebitCardFragment_paymentAddresses[];
|
|
939
975
|
}
|
|
940
976
|
|
|
941
977
|
interface WalletTokenBalances_tokenBalances {
|
|
@@ -1068,6 +1104,11 @@ interface RenameBankAccount_renamePayableAccount_BankAccount_institution {
|
|
|
1068
1104
|
country: string;
|
|
1069
1105
|
currency: string;
|
|
1070
1106
|
}
|
|
1107
|
+
interface RenameBankAccount_renamePayableAccount_BankAccount_paymentAddresses {
|
|
1108
|
+
__typename: "PaymentAddress";
|
|
1109
|
+
network: string;
|
|
1110
|
+
address: string;
|
|
1111
|
+
}
|
|
1071
1112
|
interface RenameBankAccount_renamePayableAccount_BankAccount {
|
|
1072
1113
|
__typename: "BankAccount";
|
|
1073
1114
|
id: string;
|
|
@@ -1086,6 +1127,7 @@ interface RenameBankAccount_renamePayableAccount_BankAccount {
|
|
|
1086
1127
|
bankAccountDetails: RenameBankAccount_renamePayableAccount_BankAccount_bankAccountDetails;
|
|
1087
1128
|
deliveryMethods: PaymentDeliveryMethod[];
|
|
1088
1129
|
institution: RenameBankAccount_renamePayableAccount_BankAccount_institution | null;
|
|
1130
|
+
paymentAddresses: RenameBankAccount_renamePayableAccount_BankAccount_paymentAddresses[];
|
|
1089
1131
|
}
|
|
1090
1132
|
|
|
1091
1133
|
type Headers = Record<string, string | null | undefined>;
|
|
@@ -1195,6 +1237,11 @@ interface CreateUSBill_addUSBill_institution {
|
|
|
1195
1237
|
name: string;
|
|
1196
1238
|
logo: string | null;
|
|
1197
1239
|
}
|
|
1240
|
+
interface CreateUSBill_addUSBill_paymentAddresses {
|
|
1241
|
+
__typename: "PaymentAddress";
|
|
1242
|
+
network: string;
|
|
1243
|
+
address: string;
|
|
1244
|
+
}
|
|
1198
1245
|
interface CreateUSBill_addUSBill {
|
|
1199
1246
|
__typename: "Bill";
|
|
1200
1247
|
id: string;
|
|
@@ -1210,6 +1257,7 @@ interface CreateUSBill_addUSBill {
|
|
|
1210
1257
|
billAccountDetails: CreateUSBill_addUSBill_billAccountDetails | null;
|
|
1211
1258
|
dataSync: CreateUSBill_addUSBill_dataSync | null;
|
|
1212
1259
|
institution: CreateUSBill_addUSBill_institution | null;
|
|
1260
|
+
paymentAddresses: CreateUSBill_addUSBill_paymentAddresses[];
|
|
1213
1261
|
}
|
|
1214
1262
|
|
|
1215
1263
|
declare class BillService {
|
|
@@ -1363,6 +1411,11 @@ interface CreateUSVirtualDebitCard_createUSVirtualDebitCard_billingInfo {
|
|
|
1363
1411
|
email: string;
|
|
1364
1412
|
address: CreateUSVirtualDebitCard_createUSVirtualDebitCard_billingInfo_address | null;
|
|
1365
1413
|
}
|
|
1414
|
+
interface CreateUSVirtualDebitCard_createUSVirtualDebitCard_paymentAddresses {
|
|
1415
|
+
__typename: "PaymentAddress";
|
|
1416
|
+
network: string;
|
|
1417
|
+
address: string;
|
|
1418
|
+
}
|
|
1366
1419
|
interface CreateUSVirtualDebitCard_createUSVirtualDebitCard {
|
|
1367
1420
|
__typename: "VirtualCard";
|
|
1368
1421
|
id: string;
|
|
@@ -1377,6 +1430,7 @@ interface CreateUSVirtualDebitCard_createUSVirtualDebitCard {
|
|
|
1377
1430
|
renderSecret: string | null;
|
|
1378
1431
|
virtualCardType: VirtualCardType;
|
|
1379
1432
|
billingInfo: CreateUSVirtualDebitCard_createUSVirtualDebitCard_billingInfo | null;
|
|
1433
|
+
paymentAddresses: CreateUSVirtualDebitCard_createUSVirtualDebitCard_paymentAddresses[];
|
|
1380
1434
|
}
|
|
1381
1435
|
interface CreateUSVirtualDebitCard {
|
|
1382
1436
|
createUSVirtualDebitCard: CreateUSVirtualDebitCard_createUSVirtualDebitCard;
|
|
@@ -1463,4 +1517,4 @@ declare class SpritzApiClient {
|
|
|
1463
1517
|
setApiKey(_apiKey: string): this;
|
|
1464
1518
|
}
|
|
1465
1519
|
|
|
1466
|
-
export { AccountPayments, AccountPaymentsVariables, AccountPayments_paymentsForAccount, BankAccountFragment, BankAccountFragment_bankAccountDetails, BankAccountFragment_bankAccountDetails_CanadianBankAccountDetails, BankAccountFragment_bankAccountDetails_USBankAccountDetails, BankAccountFragment_institution, BankAccountInput, BankAccountSubType, BankAccountType, BillFragment, BillFragment_billAccountDetails, BillFragment_dataSync, BillFragment_institution, BillType, CreateDirectPaymentInput, CreateOnrampPaymentInput, CreatePaymentRequestInput, CurrentUser, CurrentUser_me, Environment, GetSpritzPayParams, GetSpritzPayParamsVariables, GetSpritzPayParams_spritzPayParams, OnrampPaymentFragment, OnrampPaymentFragment_depositInstructions, OnrampPayments, OnrampPayments_onrampPayments, OnrampPayments_onrampPayments_depositInstructions, PayableAccountFragment, PayableAccountFragment_BankAccount, PayableAccountFragment_BankAccount_bankAccountDetails, PayableAccountFragment_BankAccount_bankAccountDetails_CanadianBankAccountDetails, PayableAccountFragment_BankAccount_bankAccountDetails_USBankAccountDetails, PayableAccountFragment_BankAccount_dataSync, PayableAccountFragment_BankAccount_institution, PayableAccountFragment_Bill, PayableAccountFragment_Bill_billAccountDetails, PayableAccountFragment_Bill_dataSync, PayableAccountFragment_Bill_institution, PayableAccountFragment_VirtualCard, PayableAccountFragment_VirtualCard_billingInfo, PayableAccountFragment_VirtualCard_billingInfo_address, PayableAccountFragment_VirtualCard_dataSync, PayableAccountFragment_VirtualCard_institution, PayableAccountInstitutionFragment, PayableAccountType, Payment, PaymentFragment, PaymentNetwork, PaymentRequestFragment, PaymentRequestPayment, PaymentRequestPaymentVariables, PaymentRequestPayment_paymentForPaymentRequest, DirectPaymentStatus as PaymentRequestStatus, PaymentStatus, PaymentVariables, Payment_payment, PopularBillInstitutions, PopularBillInstitutionsVariables, PopularBillInstitutions_popularUSBillInstitutions, SearchUSBillInstitutions, SearchUSBillInstitutionsVariables, SearchUSBillInstitutions_searchUSBillInstitutions, SpritzApiClient, TokenBalanceFragment, TransactionPrice, TransactionPriceVariables, UserBankAccounts, UserBankAccounts_bankAccounts, UserBankAccounts_bankAccounts_bankAccountDetails, UserBankAccounts_bankAccounts_bankAccountDetails_CanadianBankAccountDetails, UserBankAccounts_bankAccounts_bankAccountDetails_USBankAccountDetails, UserBankAccounts_bankAccounts_institution, UserBills, UserBills_bills, UserBills_bills_billAccountDetails, UserBills_bills_dataSync, UserBills_bills_institution, UserFragment, UserPayableAccounts, UserPayableAccounts_payableAccounts, UserPayableAccounts_payableAccounts_BankAccount, UserPayableAccounts_payableAccounts_BankAccount_bankAccountDetails, UserPayableAccounts_payableAccounts_BankAccount_bankAccountDetails_CanadianBankAccountDetails, UserPayableAccounts_payableAccounts_BankAccount_bankAccountDetails_USBankAccountDetails, UserPayableAccounts_payableAccounts_BankAccount_dataSync, UserPayableAccounts_payableAccounts_BankAccount_institution, UserPayableAccounts_payableAccounts_Bill, UserPayableAccounts_payableAccounts_Bill_billAccountDetails, UserPayableAccounts_payableAccounts_Bill_dataSync, UserPayableAccounts_payableAccounts_Bill_institution, UserPayableAccounts_payableAccounts_VirtualCard, UserPayableAccounts_payableAccounts_VirtualCard_billingInfo, UserPayableAccounts_payableAccounts_VirtualCard_billingInfo_address, UserPayableAccounts_payableAccounts_VirtualCard_dataSync, UserPayableAccounts_payableAccounts_VirtualCard_institution, UserVerification, UserVerification_verification, UserVerification_verification_identity, UserVerification_verification_identity_user, UserVirtualDebitCard, UserVirtualDebitCard_virtualDebitCard, UserVirtualDebitCard_virtualDebitCard_billingInfo, UserVirtualDebitCard_virtualDebitCard_billingInfo_address, VirtualCardType, VirtualDebitCardFragment, VirtualDebitCardFragment_billingInfo, VirtualDebitCardFragment_billingInfo_address, WalletTokenBalances, WalletTokenBalancesVariables, WalletTokenBalances_tokenBalances };
|
|
1520
|
+
export { AccountPayments, AccountPaymentsVariables, AccountPayments_paymentsForAccount, BankAccountFragment, BankAccountFragment_bankAccountDetails, BankAccountFragment_bankAccountDetails_CanadianBankAccountDetails, BankAccountFragment_bankAccountDetails_USBankAccountDetails, BankAccountFragment_institution, BankAccountFragment_paymentAddresses, BankAccountInput, BankAccountSubType, BankAccountType, BillFragment, BillFragment_billAccountDetails, BillFragment_dataSync, BillFragment_institution, BillFragment_paymentAddresses, BillType, CreateDirectPaymentInput, CreateOnrampPaymentInput, CreatePaymentRequestInput, CurrentUser, CurrentUser_me, Environment, GetSpritzPayParams, GetSpritzPayParamsVariables, GetSpritzPayParams_spritzPayParams, OnrampPaymentFragment, OnrampPaymentFragment_depositInstructions, OnrampPayments, OnrampPayments_onrampPayments, OnrampPayments_onrampPayments_depositInstructions, PayableAccountFragment, PayableAccountFragment_BankAccount, PayableAccountFragment_BankAccount_bankAccountDetails, PayableAccountFragment_BankAccount_bankAccountDetails_CanadianBankAccountDetails, PayableAccountFragment_BankAccount_bankAccountDetails_USBankAccountDetails, PayableAccountFragment_BankAccount_dataSync, PayableAccountFragment_BankAccount_institution, PayableAccountFragment_Bill, PayableAccountFragment_Bill_billAccountDetails, PayableAccountFragment_Bill_dataSync, PayableAccountFragment_Bill_institution, PayableAccountFragment_VirtualCard, PayableAccountFragment_VirtualCard_billingInfo, PayableAccountFragment_VirtualCard_billingInfo_address, PayableAccountFragment_VirtualCard_dataSync, PayableAccountFragment_VirtualCard_institution, PayableAccountInstitutionFragment, PayableAccountType, Payment, PaymentFragment, PaymentNetwork, PaymentRequestFragment, PaymentRequestPayment, PaymentRequestPaymentVariables, PaymentRequestPayment_paymentForPaymentRequest, DirectPaymentStatus as PaymentRequestStatus, PaymentStatus, PaymentVariables, Payment_payment, PopularBillInstitutions, PopularBillInstitutionsVariables, PopularBillInstitutions_popularUSBillInstitutions, SearchUSBillInstitutions, SearchUSBillInstitutionsVariables, SearchUSBillInstitutions_searchUSBillInstitutions, SpritzApiClient, TokenBalanceFragment, TransactionPrice, TransactionPriceVariables, UserBankAccounts, UserBankAccounts_bankAccounts, UserBankAccounts_bankAccounts_bankAccountDetails, UserBankAccounts_bankAccounts_bankAccountDetails_CanadianBankAccountDetails, UserBankAccounts_bankAccounts_bankAccountDetails_USBankAccountDetails, UserBankAccounts_bankAccounts_institution, UserBankAccounts_bankAccounts_paymentAddresses, UserBills, UserBills_bills, UserBills_bills_billAccountDetails, UserBills_bills_dataSync, UserBills_bills_institution, UserBills_bills_paymentAddresses, UserFragment, UserPayableAccounts, UserPayableAccounts_payableAccounts, UserPayableAccounts_payableAccounts_BankAccount, UserPayableAccounts_payableAccounts_BankAccount_bankAccountDetails, UserPayableAccounts_payableAccounts_BankAccount_bankAccountDetails_CanadianBankAccountDetails, UserPayableAccounts_payableAccounts_BankAccount_bankAccountDetails_USBankAccountDetails, UserPayableAccounts_payableAccounts_BankAccount_dataSync, UserPayableAccounts_payableAccounts_BankAccount_institution, UserPayableAccounts_payableAccounts_Bill, UserPayableAccounts_payableAccounts_Bill_billAccountDetails, UserPayableAccounts_payableAccounts_Bill_dataSync, UserPayableAccounts_payableAccounts_Bill_institution, UserPayableAccounts_payableAccounts_VirtualCard, UserPayableAccounts_payableAccounts_VirtualCard_billingInfo, UserPayableAccounts_payableAccounts_VirtualCard_billingInfo_address, UserPayableAccounts_payableAccounts_VirtualCard_dataSync, UserPayableAccounts_payableAccounts_VirtualCard_institution, UserVerification, UserVerification_verification, UserVerification_verification_identity, UserVerification_verification_identity_user, UserVirtualDebitCard, UserVirtualDebitCard_virtualDebitCard, UserVirtualDebitCard_virtualDebitCard_billingInfo, UserVirtualDebitCard_virtualDebitCard_billingInfo_address, UserVirtualDebitCard_virtualDebitCard_paymentAddresses, VirtualCardType, VirtualDebitCardFragment, VirtualDebitCardFragment_billingInfo, VirtualDebitCardFragment_billingInfo_address, VirtualDebitCardFragment_paymentAddresses, WalletTokenBalances, WalletTokenBalancesVariables, WalletTokenBalances_tokenBalances };
|
|
@@ -120,7 +120,7 @@ mutation DeletePayableAccount($accountId: String!) {
|
|
|
120
120
|
...PayableAccountFragment
|
|
121
121
|
}
|
|
122
122
|
}
|
|
123
|
-
`,name:"GraphQL request",locationOffset:{line:1,column:1}};var ji={};function Fo(e){return e.filter(function(n){if(n.kind!=="FragmentDefinition")return!0;var t=n.name.value;return ji[t]?!1:(ji[t]=!0,!0)})}de.definitions=de.definitions.concat(Fo(be.definitions));function En(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){En(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){En(i,n)}),e.definitions&&e.definitions.forEach(function(i){En(i,n)})}var gt={};(function(){de.definitions.forEach(function(n){if(n.name){var t=new Set;En(n,t),gt[n.name.value]=t}})})();function Gi(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Do(e,n){var t={kind:e.kind,definitions:[Gi(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=gt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=gt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Gi(e,o);s&&t.definitions.push(s)}),t}Do(de,"DeletePayableAccount");var Ye={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"BankAccountFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"BankAccount"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"type"},arguments:[],directives:[]},{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"BankAccount"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountNumber"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountSubType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"holder"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"email"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"ownedByUser"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountDetails"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"USBankAccountDetails"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"routingNumber"},arguments:[],directives:[]}]}}]}},{kind:"Field",name:{kind:"Name",value:"deliveryMethods"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"institution"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"logo"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:
|
|
123
|
+
`,name:"GraphQL request",locationOffset:{line:1,column:1}};var ji={};function Fo(e){return e.filter(function(n){if(n.kind!=="FragmentDefinition")return!0;var t=n.name.value;return ji[t]?!1:(ji[t]=!0,!0)})}de.definitions=de.definitions.concat(Fo(be.definitions));function En(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){En(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){En(i,n)}),e.definitions&&e.definitions.forEach(function(i){En(i,n)})}var gt={};(function(){de.definitions.forEach(function(n){if(n.name){var t=new Set;En(n,t),gt[n.name.value]=t}})})();function Gi(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Do(e,n){var t={kind:e.kind,definitions:[Gi(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=gt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=gt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Gi(e,o);s&&t.definitions.push(s)}),t}Do(de,"DeletePayableAccount");var Ye={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"BankAccountFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"BankAccount"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"type"},arguments:[],directives:[]},{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"BankAccount"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountNumber"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountSubType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"holder"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"email"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"ownedByUser"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountDetails"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"USBankAccountDetails"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"routingNumber"},arguments:[],directives:[]}]}}]}},{kind:"Field",name:{kind:"Name",value:"deliveryMethods"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"institution"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"logo"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"paymentAddresses"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"network"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"address"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:580}};Ye.loc.source={body:`fragment BankAccountFragment on BankAccount {
|
|
124
124
|
id
|
|
125
125
|
name
|
|
126
126
|
userId
|
|
@@ -149,6 +149,10 @@ mutation DeletePayableAccount($accountId: String!) {
|
|
|
149
149
|
country
|
|
150
150
|
currency
|
|
151
151
|
}
|
|
152
|
+
paymentAddresses {
|
|
153
|
+
network
|
|
154
|
+
address
|
|
155
|
+
}
|
|
152
156
|
}
|
|
153
157
|
`,name:"GraphQL request",locationOffset:{line:1,column:1}};function Tn(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){Tn(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){Tn(i,n)}),e.definitions&&e.definitions.forEach(function(i){Tn(i,n)})}var St={};(function(){Ye.definitions.forEach(function(n){if(n.name){var t=new Set;Tn(n,t),St[n.name.value]=t}})})();function Qi(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Ao(e,n){var t={kind:e.kind,definitions:[Qi(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=St[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=St[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Qi(e,o);s&&t.definitions.push(s)}),t}Ao(Ye,"BankAccountFragment");var Ee={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"RenameBankAccount"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"accountId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},directives:[]},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"name"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},directives:[]}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"renamePayableAccount"},arguments:[{kind:"Argument",name:{kind:"Name",value:"accountId"},value:{kind:"Variable",name:{kind:"Name",value:"accountId"}}},{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"Variable",name:{kind:"Name",value:"name"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"BankAccountFragment"},directives:[]}]}}]}}],loc:{start:0,end:218}};Ee.loc.source={body:`#import "../queries/bankAccountFragment.graphql"
|
|
154
158
|
|
|
@@ -164,7 +168,7 @@ query UserBankAccounts {
|
|
|
164
168
|
...BankAccountFragment
|
|
165
169
|
}
|
|
166
170
|
}
|
|
167
|
-
`,name:"GraphQL request",locationOffset:{line:1,column:1}};var Ji={};function _o(e){return e.filter(function(n){if(n.kind!=="FragmentDefinition")return!0;var t=n.name.value;return Ji[t]?!1:(Ji[t]=!0,!0)})}Te.definitions=Te.definitions.concat(_o(Ye.definitions));function In(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){In(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){In(i,n)}),e.definitions&&e.definitions.forEach(function(i){In(i,n)})}var Nt={};(function(){Te.definitions.forEach(function(n){if(n.name){var t=new Set;In(n,t),Nt[n.name.value]=t}})})();function Ki(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Lo(e,n){var t={kind:e.kind,definitions:[Ki(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=Nt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=Nt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Ki(e,o);s&&t.definitions.push(s)}),t}Lo(Te,"UserBankAccounts");function Po(e){throw new Error(e)}var Bo=(e=>(e.CHECKBOOK="CHECKBOOK",e.METHOD_FI="METHOD_FI",e.UNBLOCK="UNBLOCK",e))(Bo||{}),Vo=(e=>(e.Active="Active",e.Error="Error",e.Syncing="Syncing",e.Unavailable="Unavailable",e))(Vo||{}),Yi=(e=>(e.Business="Business",e.Checking="Checking",e.Savings="Savings",e))(Yi||{}),Fn=(e=>(e.CABankAccount="CABankAccount",e.IbanAccount="IbanAccount",e.UKBankAccount="UKBankAccount",e.USBankAccount="USBankAccount",e))(Fn||{}),Xi=(e=>(e.AutoLoan="AutoLoan",e.CreditCard="CreditCard",e.Loan="Loan",e.MobilePhone="MobilePhone",e.Mortgage="Mortgage",e.StudentLoan="StudentLoan",e.Unknown="Unknown",e.Utility="Utility",e))(Xi||{}),Wi=(e=>(e.COMPLETED="COMPLETED",e.CONFIRMED="CONFIRMED",e.CREATED="CREATED",e.FAILED="FAILED",e.PENDING="PENDING",e.REFUNDED="REFUNDED",e.TRANSACTION_FAILED="TRANSACTION_FAILED",e.TRANSACTION_PENDING="TRANSACTION_PENDING",e))(Wi||{}),Uo=(e=>(e.ACTIVE="ACTIVE",e.DISABLED="DISABLED",e.FAILED="FAILED",e.INITIALIZED="INITIALIZED",e.LOADING="LOADING",e.RETRY="RETRY",e.UNAVAILABLE="UNAVAILABLE",e.UNINITIALIZED="UNINITIALIZED",e))(Uo||{}),qo=(e=>(e.AWAITING_FUNDS="AWAITING_FUNDS",e.CANCELLED="CANCELLED",e.COMPLETED="COMPLETED",e.PENDING="PENDING",e))(qo||{}),Co=(e=>(e.Provider="Provider",e.User="User",e))(Co||{}),Zi=(e=>(e.BankAccount="BankAccount",e.Bill="Bill",e.VirtualCard="VirtualCard",e))(Zi||{}),$o=(e=>(e.INSTANT="INSTANT",e.STANDARD="STANDARD",e))($o||{}),ea=(e=>(e.CANCELLED="CANCELLED",e.COMPLETED="COMPLETED",e.FAILED="FAILED",e.INITIALIZED="INITIALIZED",e.PENDING="PENDING",e.REFUNDED="REFUNDED",e.REVERSAL_IN_PROGRESS="REVERSAL_IN_PROGRESS",e.REVERSED="REVERSED",e.SCHEDULED="SCHEDULED",e.SENT="SENT",e))(ea||{}),Et=(e=>(e.USVirtualDebitCard="USVirtualDebitCard",e))(Et||{});const xo=me.z.object({transitNumber:me.z.string().length(5,{message:"Transit number must be exactly 5 characters long"}).regex(/^[0-9]{5}$/,"Transit number should contain only digits."),institutionNumber:me.z.string().length(3,{message:"Institution number must be exactly 3 characters long"}).regex(/^[0-9]{3}$/,"Institution number should contain only digits.")}),Mo=me.z.object({routingNumber:me.z.string().length(9,{message:"Routing number must be exactly 9 characters long"}).regex(/^[0-9]{9}$/,"Routing number should contain only digits.")}),jo={[Fn.CABankAccount]:xo,[Fn.USBankAccount]:Mo};class Go{client;constructor(n){this.client=n}async list(){return(await this.client.query({query:Te}))?.bankAccounts??[]}async rename(n,t){return(await this.client.query({query:Ee,variables:{accountId:n,name:t}}))?.renamePayableAccount??null}async delete(n){return(await this.client.query({query:de,variables:{accountId:n}}))?.deletePayableAccount??null}async create(n,t){const i=jo[n]??Po("Invalid bank account type");try{const a=i.parse(t);return(await this.client.query({query:Ne,variables:{createAccountInput:{accountNumber:t.accountNumber,name:t.name,type:n,subType:t.subType,details:a,email:t.email??null,ownedByUser:t.ownedByUser??null,holder:t.holder??null}}}))?.createBankAccount??null}catch(a){throw a instanceof me.z.ZodError?new Error(a?.issues?.[0]?.message??"Input validation failure"):a}}}var Xe={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"BillFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"Bill"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"originator"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"payable"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"verifying"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billAccountDetails"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"balance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"amountDue"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"openedAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastPaymentAmount"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastPaymentDate"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"nextPaymentDueDate"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"nextPaymentMinimumAmount"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastStatementBalance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"remainingStatementBalance"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"dataSync"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"lastSync"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"syncStatus"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"institution"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"logo"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:
|
|
171
|
+
`,name:"GraphQL request",locationOffset:{line:1,column:1}};var Ji={};function _o(e){return e.filter(function(n){if(n.kind!=="FragmentDefinition")return!0;var t=n.name.value;return Ji[t]?!1:(Ji[t]=!0,!0)})}Te.definitions=Te.definitions.concat(_o(Ye.definitions));function In(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){In(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){In(i,n)}),e.definitions&&e.definitions.forEach(function(i){In(i,n)})}var Nt={};(function(){Te.definitions.forEach(function(n){if(n.name){var t=new Set;In(n,t),Nt[n.name.value]=t}})})();function Ki(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Lo(e,n){var t={kind:e.kind,definitions:[Ki(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=Nt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=Nt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Ki(e,o);s&&t.definitions.push(s)}),t}Lo(Te,"UserBankAccounts");function Po(e){throw new Error(e)}var Bo=(e=>(e.CHECKBOOK="CHECKBOOK",e.METHOD_FI="METHOD_FI",e.UNBLOCK="UNBLOCK",e))(Bo||{}),Vo=(e=>(e.Active="Active",e.Error="Error",e.Syncing="Syncing",e.Unavailable="Unavailable",e))(Vo||{}),Yi=(e=>(e.Business="Business",e.Checking="Checking",e.Savings="Savings",e))(Yi||{}),Fn=(e=>(e.CABankAccount="CABankAccount",e.IbanAccount="IbanAccount",e.UKBankAccount="UKBankAccount",e.USBankAccount="USBankAccount",e))(Fn||{}),Xi=(e=>(e.AutoLoan="AutoLoan",e.CreditCard="CreditCard",e.Loan="Loan",e.MobilePhone="MobilePhone",e.Mortgage="Mortgage",e.StudentLoan="StudentLoan",e.Unknown="Unknown",e.Utility="Utility",e))(Xi||{}),Wi=(e=>(e.COMPLETED="COMPLETED",e.CONFIRMED="CONFIRMED",e.CREATED="CREATED",e.FAILED="FAILED",e.PENDING="PENDING",e.REFUNDED="REFUNDED",e.TRANSACTION_FAILED="TRANSACTION_FAILED",e.TRANSACTION_PENDING="TRANSACTION_PENDING",e))(Wi||{}),Uo=(e=>(e.ACTIVE="ACTIVE",e.DISABLED="DISABLED",e.FAILED="FAILED",e.INITIALIZED="INITIALIZED",e.LOADING="LOADING",e.RETRY="RETRY",e.UNAVAILABLE="UNAVAILABLE",e.UNINITIALIZED="UNINITIALIZED",e))(Uo||{}),qo=(e=>(e.AWAITING_FUNDS="AWAITING_FUNDS",e.CANCELLED="CANCELLED",e.COMPLETED="COMPLETED",e.PENDING="PENDING",e))(qo||{}),Co=(e=>(e.Provider="Provider",e.User="User",e))(Co||{}),Zi=(e=>(e.BankAccount="BankAccount",e.Bill="Bill",e.VirtualCard="VirtualCard",e))(Zi||{}),$o=(e=>(e.INSTANT="INSTANT",e.STANDARD="STANDARD",e))($o||{}),ea=(e=>(e.CANCELLED="CANCELLED",e.COMPLETED="COMPLETED",e.FAILED="FAILED",e.INITIALIZED="INITIALIZED",e.PENDING="PENDING",e.REFUNDED="REFUNDED",e.REVERSAL_IN_PROGRESS="REVERSAL_IN_PROGRESS",e.REVERSED="REVERSED",e.SCHEDULED="SCHEDULED",e.SENT="SENT",e))(ea||{}),Et=(e=>(e.USVirtualDebitCard="USVirtualDebitCard",e))(Et||{});const xo=me.z.object({transitNumber:me.z.string().length(5,{message:"Transit number must be exactly 5 characters long"}).regex(/^[0-9]{5}$/,"Transit number should contain only digits."),institutionNumber:me.z.string().length(3,{message:"Institution number must be exactly 3 characters long"}).regex(/^[0-9]{3}$/,"Institution number should contain only digits.")}),Mo=me.z.object({routingNumber:me.z.string().length(9,{message:"Routing number must be exactly 9 characters long"}).regex(/^[0-9]{9}$/,"Routing number should contain only digits.")}),jo={[Fn.CABankAccount]:xo,[Fn.USBankAccount]:Mo};class Go{client;constructor(n){this.client=n}async list(){return(await this.client.query({query:Te}))?.bankAccounts??[]}async rename(n,t){return(await this.client.query({query:Ee,variables:{accountId:n,name:t}}))?.renamePayableAccount??null}async delete(n){return(await this.client.query({query:de,variables:{accountId:n}}))?.deletePayableAccount??null}async create(n,t){const i=jo[n]??Po("Invalid bank account type");try{const a=i.parse(t);return(await this.client.query({query:Ne,variables:{createAccountInput:{accountNumber:t.accountNumber,name:t.name,type:n,subType:t.subType,details:a,email:t.email??null,ownedByUser:t.ownedByUser??null,holder:t.holder??null}}}))?.createBankAccount??null}catch(a){throw a instanceof me.z.ZodError?new Error(a?.issues?.[0]?.message??"Input validation failure"):a}}}var Xe={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"BillFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"Bill"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"originator"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"payable"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"verifying"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billAccountDetails"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"balance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"amountDue"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"openedAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastPaymentAmount"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastPaymentDate"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"nextPaymentDueDate"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"nextPaymentMinimumAmount"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastStatementBalance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"remainingStatementBalance"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"dataSync"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"lastSync"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"syncStatus"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"institution"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"logo"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"paymentAddresses"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"network"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"address"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:588}};Xe.loc.source={body:`fragment BillFragment on Bill {
|
|
168
172
|
id
|
|
169
173
|
name
|
|
170
174
|
userId
|
|
@@ -195,6 +199,10 @@ query UserBankAccounts {
|
|
|
195
199
|
name
|
|
196
200
|
logo
|
|
197
201
|
}
|
|
202
|
+
paymentAddresses {
|
|
203
|
+
network
|
|
204
|
+
address
|
|
205
|
+
}
|
|
198
206
|
}
|
|
199
207
|
`,name:"GraphQL request",locationOffset:{line:1,column:1}};function Dn(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){Dn(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){Dn(i,n)}),e.definitions&&e.definitions.forEach(function(i){Dn(i,n)})}var Tt={};(function(){Xe.definitions.forEach(function(n){if(n.name){var t=new Set;Dn(n,t),Tt[n.name.value]=t}})})();function na(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Qo(e,n){var t={kind:e.kind,definitions:[na(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=Tt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=Tt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=na(e,o);s&&t.definitions.push(s)}),t}Qo(Xe,"BillFragment");var we={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateUSBill"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"institutionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},directives:[]},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"accountNumber"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},directives:[]},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"type"}},type:{kind:"NamedType",name:{kind:"Name",value:"BillType"}},directives:[]}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"addUSBill"},arguments:[{kind:"Argument",name:{kind:"Name",value:"institutionId"},value:{kind:"Variable",name:{kind:"Name",value:"institutionId"}}},{kind:"Argument",name:{kind:"Name",value:"accountNumber"},value:{kind:"Variable",name:{kind:"Name",value:"accountNumber"}}},{kind:"Argument",name:{kind:"Name",value:"type"},value:{kind:"Variable",name:{kind:"Name",value:"type"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"BillFragment"},directives:[]}]}}]}}],loc:{start:0,end:257}};we.loc.source={body:`#import "../queries/billFragment.graphql"
|
|
200
208
|
|
|
@@ -388,7 +396,7 @@ query CurrentUser {
|
|
|
388
396
|
}
|
|
389
397
|
}
|
|
390
398
|
}
|
|
391
|
-
`,name:"GraphQL request",locationOffset:{line:1,column:1}};function Xn(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){Xn(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){Xn(i,n)}),e.definitions&&e.definitions.forEach(function(i){Xn(i,n)})}var Qt={};(function(){Yn.definitions.forEach(function(n){if(n.name){var t=new Set;Xn(n,t),Qt[n.name.value]=t}})})();function Pa(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function qs(e,n){var t={kind:e.kind,definitions:[Pa(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=Qt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=Qt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Pa(e,o);s&&t.definitions.push(s)}),t}qs(Yn,"UserVerification");class Cs{client;constructor(n){this.client=n}async createUser(n){return this.client.request({method:"post",path:"/users/integration",body:n})}async create(n){return this.createUser(n)}async requestApiKey(n){return this.client.request({method:"post",path:"/users/request-key",body:{email:n}})}async authorizeApiKeyWithOTP(n){return this.client.request({method:"post",path:"/users/validate-key",body:n})}async getCurrentUser(){return(await this.client.query({query:Ve}))?.me??null}async getUserVerification(){return(await this.client.query({query:Yn}))?.verification??null}}var en={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"VirtualDebitCardFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"VirtualCard"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"type"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"mask"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"balance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"renderSecret"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"virtualCardType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billingInfo"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"holder"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"phone"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"email"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"address"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"street"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"street2"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"city"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"subdivision"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"postalCode"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"countryCode"},arguments:[],directives:[]}]}}]}}]}}],loc:{start:0,end:
|
|
399
|
+
`,name:"GraphQL request",locationOffset:{line:1,column:1}};function Xn(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){Xn(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){Xn(i,n)}),e.definitions&&e.definitions.forEach(function(i){Xn(i,n)})}var Qt={};(function(){Yn.definitions.forEach(function(n){if(n.name){var t=new Set;Xn(n,t),Qt[n.name.value]=t}})})();function Pa(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function qs(e,n){var t={kind:e.kind,definitions:[Pa(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=Qt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=Qt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Pa(e,o);s&&t.definitions.push(s)}),t}qs(Yn,"UserVerification");class Cs{client;constructor(n){this.client=n}async createUser(n){return this.client.request({method:"post",path:"/users/integration",body:n})}async create(n){return this.createUser(n)}async requestApiKey(n){return this.client.request({method:"post",path:"/users/request-key",body:{email:n}})}async authorizeApiKeyWithOTP(n){return this.client.request({method:"post",path:"/users/validate-key",body:n})}async getCurrentUser(){return(await this.client.query({query:Ve}))?.me??null}async getUserVerification(){return(await this.client.query({query:Yn}))?.verification??null}}var en={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"VirtualDebitCardFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"VirtualCard"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"type"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"mask"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"balance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"renderSecret"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"virtualCardType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billingInfo"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"holder"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"phone"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"email"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"address"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"street"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"street2"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"city"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"subdivision"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"postalCode"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"countryCode"},arguments:[],directives:[]}]}}]}},{kind:"Field",name:{kind:"Name",value:"paymentAddresses"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"network"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"address"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:469}};en.loc.source={body:`fragment VirtualDebitCardFragment on VirtualCard {
|
|
392
400
|
id
|
|
393
401
|
name
|
|
394
402
|
userId
|
|
@@ -413,6 +421,10 @@ query CurrentUser {
|
|
|
413
421
|
countryCode
|
|
414
422
|
}
|
|
415
423
|
}
|
|
424
|
+
paymentAddresses {
|
|
425
|
+
network
|
|
426
|
+
address
|
|
427
|
+
}
|
|
416
428
|
}
|
|
417
429
|
`,name:"GraphQL request",locationOffset:{line:1,column:1}};function Wn(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){Wn(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){Wn(i,n)}),e.definitions&&e.definitions.forEach(function(i){Wn(i,n)})}var zt={};(function(){en.definitions.forEach(function(n){if(n.name){var t=new Set;Wn(n,t),zt[n.name.value]=t}})})();function Ba(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function $s(e,n){var t={kind:e.kind,definitions:[Ba(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=zt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=zt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Ba(e,o);s&&t.definitions.push(s)}),t}$s(en,"VirtualDebitCardFragment");var Ue={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateUSVirtualDebitCard"},variableDefinitions:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"createUSVirtualDebitCard"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"VirtualDebitCardFragment"},directives:[]}]}}]}}],loc:{start:0,end:166}};Ue.loc.source={body:`#import "../queries/virtualDebitCardFragment.graphql"
|
|
418
430
|
|
|
@@ -120,7 +120,7 @@ mutation DeletePayableAccount($accountId: String!) {
|
|
|
120
120
|
...PayableAccountFragment
|
|
121
121
|
}
|
|
122
122
|
}
|
|
123
|
-
`,name:"GraphQL request",locationOffset:{line:1,column:1}};var ji={};function Fo(e){return e.filter(function(n){if(n.kind!=="FragmentDefinition")return!0;var t=n.name.value;return ji[t]?!1:(ji[t]=!0,!0)})}de.definitions=de.definitions.concat(Fo(be.definitions));function En(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){En(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){En(i,n)}),e.definitions&&e.definitions.forEach(function(i){En(i,n)})}var gt={};(function(){de.definitions.forEach(function(n){if(n.name){var t=new Set;En(n,t),gt[n.name.value]=t}})})();function Gi(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Do(e,n){var t={kind:e.kind,definitions:[Gi(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=gt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=gt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Gi(e,o);s&&t.definitions.push(s)}),t}Do(de,"DeletePayableAccount");var Ye={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"BankAccountFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"BankAccount"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"type"},arguments:[],directives:[]},{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"BankAccount"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountNumber"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountSubType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"holder"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"email"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"ownedByUser"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountDetails"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"USBankAccountDetails"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"routingNumber"},arguments:[],directives:[]}]}}]}},{kind:"Field",name:{kind:"Name",value:"deliveryMethods"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"institution"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"logo"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:
|
|
123
|
+
`,name:"GraphQL request",locationOffset:{line:1,column:1}};var ji={};function Fo(e){return e.filter(function(n){if(n.kind!=="FragmentDefinition")return!0;var t=n.name.value;return ji[t]?!1:(ji[t]=!0,!0)})}de.definitions=de.definitions.concat(Fo(be.definitions));function En(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){En(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){En(i,n)}),e.definitions&&e.definitions.forEach(function(i){En(i,n)})}var gt={};(function(){de.definitions.forEach(function(n){if(n.name){var t=new Set;En(n,t),gt[n.name.value]=t}})})();function Gi(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Do(e,n){var t={kind:e.kind,definitions:[Gi(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=gt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=gt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Gi(e,o);s&&t.definitions.push(s)}),t}Do(de,"DeletePayableAccount");var Ye={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"BankAccountFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"BankAccount"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"type"},arguments:[],directives:[]},{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"BankAccount"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountNumber"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountSubType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"holder"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"email"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"ownedByUser"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"bankAccountDetails"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"USBankAccountDetails"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"routingNumber"},arguments:[],directives:[]}]}}]}},{kind:"Field",name:{kind:"Name",value:"deliveryMethods"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"institution"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"logo"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"paymentAddresses"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"network"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"address"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:580}};Ye.loc.source={body:`fragment BankAccountFragment on BankAccount {
|
|
124
124
|
id
|
|
125
125
|
name
|
|
126
126
|
userId
|
|
@@ -149,6 +149,10 @@ mutation DeletePayableAccount($accountId: String!) {
|
|
|
149
149
|
country
|
|
150
150
|
currency
|
|
151
151
|
}
|
|
152
|
+
paymentAddresses {
|
|
153
|
+
network
|
|
154
|
+
address
|
|
155
|
+
}
|
|
152
156
|
}
|
|
153
157
|
`,name:"GraphQL request",locationOffset:{line:1,column:1}};function Tn(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){Tn(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){Tn(i,n)}),e.definitions&&e.definitions.forEach(function(i){Tn(i,n)})}var St={};(function(){Ye.definitions.forEach(function(n){if(n.name){var t=new Set;Tn(n,t),St[n.name.value]=t}})})();function Qi(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Ao(e,n){var t={kind:e.kind,definitions:[Qi(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=St[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=St[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Qi(e,o);s&&t.definitions.push(s)}),t}Ao(Ye,"BankAccountFragment");var Ee={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"RenameBankAccount"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"accountId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},directives:[]},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"name"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},directives:[]}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"renamePayableAccount"},arguments:[{kind:"Argument",name:{kind:"Name",value:"accountId"},value:{kind:"Variable",name:{kind:"Name",value:"accountId"}}},{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"Variable",name:{kind:"Name",value:"name"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"BankAccountFragment"},directives:[]}]}}]}}],loc:{start:0,end:218}};Ee.loc.source={body:`#import "../queries/bankAccountFragment.graphql"
|
|
154
158
|
|
|
@@ -164,7 +168,7 @@ query UserBankAccounts {
|
|
|
164
168
|
...BankAccountFragment
|
|
165
169
|
}
|
|
166
170
|
}
|
|
167
|
-
`,name:"GraphQL request",locationOffset:{line:1,column:1}};var Ji={};function _o(e){return e.filter(function(n){if(n.kind!=="FragmentDefinition")return!0;var t=n.name.value;return Ji[t]?!1:(Ji[t]=!0,!0)})}Te.definitions=Te.definitions.concat(_o(Ye.definitions));function In(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){In(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){In(i,n)}),e.definitions&&e.definitions.forEach(function(i){In(i,n)})}var Nt={};(function(){Te.definitions.forEach(function(n){if(n.name){var t=new Set;In(n,t),Nt[n.name.value]=t}})})();function Ki(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Lo(e,n){var t={kind:e.kind,definitions:[Ki(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=Nt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=Nt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Ki(e,o);s&&t.definitions.push(s)}),t}Lo(Te,"UserBankAccounts");function Po(e){throw new Error(e)}var Bo=(e=>(e.CHECKBOOK="CHECKBOOK",e.METHOD_FI="METHOD_FI",e.UNBLOCK="UNBLOCK",e))(Bo||{}),Vo=(e=>(e.Active="Active",e.Error="Error",e.Syncing="Syncing",e.Unavailable="Unavailable",e))(Vo||{}),Yi=(e=>(e.Business="Business",e.Checking="Checking",e.Savings="Savings",e))(Yi||{}),Fn=(e=>(e.CABankAccount="CABankAccount",e.IbanAccount="IbanAccount",e.UKBankAccount="UKBankAccount",e.USBankAccount="USBankAccount",e))(Fn||{}),Xi=(e=>(e.AutoLoan="AutoLoan",e.CreditCard="CreditCard",e.Loan="Loan",e.MobilePhone="MobilePhone",e.Mortgage="Mortgage",e.StudentLoan="StudentLoan",e.Unknown="Unknown",e.Utility="Utility",e))(Xi||{}),Wi=(e=>(e.COMPLETED="COMPLETED",e.CONFIRMED="CONFIRMED",e.CREATED="CREATED",e.FAILED="FAILED",e.PENDING="PENDING",e.REFUNDED="REFUNDED",e.TRANSACTION_FAILED="TRANSACTION_FAILED",e.TRANSACTION_PENDING="TRANSACTION_PENDING",e))(Wi||{}),Uo=(e=>(e.ACTIVE="ACTIVE",e.DISABLED="DISABLED",e.FAILED="FAILED",e.INITIALIZED="INITIALIZED",e.LOADING="LOADING",e.RETRY="RETRY",e.UNAVAILABLE="UNAVAILABLE",e.UNINITIALIZED="UNINITIALIZED",e))(Uo||{}),qo=(e=>(e.AWAITING_FUNDS="AWAITING_FUNDS",e.CANCELLED="CANCELLED",e.COMPLETED="COMPLETED",e.PENDING="PENDING",e))(qo||{}),Co=(e=>(e.Provider="Provider",e.User="User",e))(Co||{}),Zi=(e=>(e.BankAccount="BankAccount",e.Bill="Bill",e.VirtualCard="VirtualCard",e))(Zi||{}),$o=(e=>(e.INSTANT="INSTANT",e.STANDARD="STANDARD",e))($o||{}),ea=(e=>(e.CANCELLED="CANCELLED",e.COMPLETED="COMPLETED",e.FAILED="FAILED",e.INITIALIZED="INITIALIZED",e.PENDING="PENDING",e.REFUNDED="REFUNDED",e.REVERSAL_IN_PROGRESS="REVERSAL_IN_PROGRESS",e.REVERSED="REVERSED",e.SCHEDULED="SCHEDULED",e.SENT="SENT",e))(ea||{}),Et=(e=>(e.USVirtualDebitCard="USVirtualDebitCard",e))(Et||{});const xo=me.object({transitNumber:me.string().length(5,{message:"Transit number must be exactly 5 characters long"}).regex(/^[0-9]{5}$/,"Transit number should contain only digits."),institutionNumber:me.string().length(3,{message:"Institution number must be exactly 3 characters long"}).regex(/^[0-9]{3}$/,"Institution number should contain only digits.")}),Mo=me.object({routingNumber:me.string().length(9,{message:"Routing number must be exactly 9 characters long"}).regex(/^[0-9]{9}$/,"Routing number should contain only digits.")}),jo={[Fn.CABankAccount]:xo,[Fn.USBankAccount]:Mo};class Go{client;constructor(n){this.client=n}async list(){return(await this.client.query({query:Te}))?.bankAccounts??[]}async rename(n,t){return(await this.client.query({query:Ee,variables:{accountId:n,name:t}}))?.renamePayableAccount??null}async delete(n){return(await this.client.query({query:de,variables:{accountId:n}}))?.deletePayableAccount??null}async create(n,t){const i=jo[n]??Po("Invalid bank account type");try{const a=i.parse(t);return(await this.client.query({query:Ne,variables:{createAccountInput:{accountNumber:t.accountNumber,name:t.name,type:n,subType:t.subType,details:a,email:t.email??null,ownedByUser:t.ownedByUser??null,holder:t.holder??null}}}))?.createBankAccount??null}catch(a){throw a instanceof me.ZodError?new Error(a?.issues?.[0]?.message??"Input validation failure"):a}}}var Xe={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"BillFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"Bill"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"originator"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"payable"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"verifying"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billAccountDetails"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"balance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"amountDue"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"openedAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastPaymentAmount"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastPaymentDate"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"nextPaymentDueDate"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"nextPaymentMinimumAmount"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastStatementBalance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"remainingStatementBalance"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"dataSync"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"lastSync"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"syncStatus"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"institution"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"logo"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:
|
|
171
|
+
`,name:"GraphQL request",locationOffset:{line:1,column:1}};var Ji={};function _o(e){return e.filter(function(n){if(n.kind!=="FragmentDefinition")return!0;var t=n.name.value;return Ji[t]?!1:(Ji[t]=!0,!0)})}Te.definitions=Te.definitions.concat(_o(Ye.definitions));function In(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){In(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){In(i,n)}),e.definitions&&e.definitions.forEach(function(i){In(i,n)})}var Nt={};(function(){Te.definitions.forEach(function(n){if(n.name){var t=new Set;In(n,t),Nt[n.name.value]=t}})})();function Ki(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Lo(e,n){var t={kind:e.kind,definitions:[Ki(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=Nt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=Nt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Ki(e,o);s&&t.definitions.push(s)}),t}Lo(Te,"UserBankAccounts");function Po(e){throw new Error(e)}var Bo=(e=>(e.CHECKBOOK="CHECKBOOK",e.METHOD_FI="METHOD_FI",e.UNBLOCK="UNBLOCK",e))(Bo||{}),Vo=(e=>(e.Active="Active",e.Error="Error",e.Syncing="Syncing",e.Unavailable="Unavailable",e))(Vo||{}),Yi=(e=>(e.Business="Business",e.Checking="Checking",e.Savings="Savings",e))(Yi||{}),Fn=(e=>(e.CABankAccount="CABankAccount",e.IbanAccount="IbanAccount",e.UKBankAccount="UKBankAccount",e.USBankAccount="USBankAccount",e))(Fn||{}),Xi=(e=>(e.AutoLoan="AutoLoan",e.CreditCard="CreditCard",e.Loan="Loan",e.MobilePhone="MobilePhone",e.Mortgage="Mortgage",e.StudentLoan="StudentLoan",e.Unknown="Unknown",e.Utility="Utility",e))(Xi||{}),Wi=(e=>(e.COMPLETED="COMPLETED",e.CONFIRMED="CONFIRMED",e.CREATED="CREATED",e.FAILED="FAILED",e.PENDING="PENDING",e.REFUNDED="REFUNDED",e.TRANSACTION_FAILED="TRANSACTION_FAILED",e.TRANSACTION_PENDING="TRANSACTION_PENDING",e))(Wi||{}),Uo=(e=>(e.ACTIVE="ACTIVE",e.DISABLED="DISABLED",e.FAILED="FAILED",e.INITIALIZED="INITIALIZED",e.LOADING="LOADING",e.RETRY="RETRY",e.UNAVAILABLE="UNAVAILABLE",e.UNINITIALIZED="UNINITIALIZED",e))(Uo||{}),qo=(e=>(e.AWAITING_FUNDS="AWAITING_FUNDS",e.CANCELLED="CANCELLED",e.COMPLETED="COMPLETED",e.PENDING="PENDING",e))(qo||{}),Co=(e=>(e.Provider="Provider",e.User="User",e))(Co||{}),Zi=(e=>(e.BankAccount="BankAccount",e.Bill="Bill",e.VirtualCard="VirtualCard",e))(Zi||{}),$o=(e=>(e.INSTANT="INSTANT",e.STANDARD="STANDARD",e))($o||{}),ea=(e=>(e.CANCELLED="CANCELLED",e.COMPLETED="COMPLETED",e.FAILED="FAILED",e.INITIALIZED="INITIALIZED",e.PENDING="PENDING",e.REFUNDED="REFUNDED",e.REVERSAL_IN_PROGRESS="REVERSAL_IN_PROGRESS",e.REVERSED="REVERSED",e.SCHEDULED="SCHEDULED",e.SENT="SENT",e))(ea||{}),Et=(e=>(e.USVirtualDebitCard="USVirtualDebitCard",e))(Et||{});const xo=me.object({transitNumber:me.string().length(5,{message:"Transit number must be exactly 5 characters long"}).regex(/^[0-9]{5}$/,"Transit number should contain only digits."),institutionNumber:me.string().length(3,{message:"Institution number must be exactly 3 characters long"}).regex(/^[0-9]{3}$/,"Institution number should contain only digits.")}),Mo=me.object({routingNumber:me.string().length(9,{message:"Routing number must be exactly 9 characters long"}).regex(/^[0-9]{9}$/,"Routing number should contain only digits.")}),jo={[Fn.CABankAccount]:xo,[Fn.USBankAccount]:Mo};class Go{client;constructor(n){this.client=n}async list(){return(await this.client.query({query:Te}))?.bankAccounts??[]}async rename(n,t){return(await this.client.query({query:Ee,variables:{accountId:n,name:t}}))?.renamePayableAccount??null}async delete(n){return(await this.client.query({query:de,variables:{accountId:n}}))?.deletePayableAccount??null}async create(n,t){const i=jo[n]??Po("Invalid bank account type");try{const a=i.parse(t);return(await this.client.query({query:Ne,variables:{createAccountInput:{accountNumber:t.accountNumber,name:t.name,type:n,subType:t.subType,details:a,email:t.email??null,ownedByUser:t.ownedByUser??null,holder:t.holder??null}}}))?.createBankAccount??null}catch(a){throw a instanceof me.ZodError?new Error(a?.issues?.[0]?.message??"Input validation failure"):a}}}var Xe={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"BillFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"Bill"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"originator"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"payable"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"verifying"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billAccountDetails"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"balance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"amountDue"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"openedAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastPaymentAmount"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastPaymentDate"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"nextPaymentDueDate"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"nextPaymentMinimumAmount"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"lastStatementBalance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"remainingStatementBalance"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"dataSync"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"lastSync"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"syncStatus"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"institution"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"logo"},arguments:[],directives:[]}]}},{kind:"Field",name:{kind:"Name",value:"paymentAddresses"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"network"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"address"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:588}};Xe.loc.source={body:`fragment BillFragment on Bill {
|
|
168
172
|
id
|
|
169
173
|
name
|
|
170
174
|
userId
|
|
@@ -195,6 +199,10 @@ query UserBankAccounts {
|
|
|
195
199
|
name
|
|
196
200
|
logo
|
|
197
201
|
}
|
|
202
|
+
paymentAddresses {
|
|
203
|
+
network
|
|
204
|
+
address
|
|
205
|
+
}
|
|
198
206
|
}
|
|
199
207
|
`,name:"GraphQL request",locationOffset:{line:1,column:1}};function Dn(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){Dn(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){Dn(i,n)}),e.definitions&&e.definitions.forEach(function(i){Dn(i,n)})}var Tt={};(function(){Xe.definitions.forEach(function(n){if(n.name){var t=new Set;Dn(n,t),Tt[n.name.value]=t}})})();function na(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function Qo(e,n){var t={kind:e.kind,definitions:[na(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=Tt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=Tt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=na(e,o);s&&t.definitions.push(s)}),t}Qo(Xe,"BillFragment");var we={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateUSBill"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"institutionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},directives:[]},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"accountNumber"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},directives:[]},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"type"}},type:{kind:"NamedType",name:{kind:"Name",value:"BillType"}},directives:[]}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"addUSBill"},arguments:[{kind:"Argument",name:{kind:"Name",value:"institutionId"},value:{kind:"Variable",name:{kind:"Name",value:"institutionId"}}},{kind:"Argument",name:{kind:"Name",value:"accountNumber"},value:{kind:"Variable",name:{kind:"Name",value:"accountNumber"}}},{kind:"Argument",name:{kind:"Name",value:"type"},value:{kind:"Variable",name:{kind:"Name",value:"type"}}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"BillFragment"},directives:[]}]}}]}}],loc:{start:0,end:257}};we.loc.source={body:`#import "../queries/billFragment.graphql"
|
|
200
208
|
|
|
@@ -388,7 +396,7 @@ query CurrentUser {
|
|
|
388
396
|
}
|
|
389
397
|
}
|
|
390
398
|
}
|
|
391
|
-
`,name:"GraphQL request",locationOffset:{line:1,column:1}};function Xn(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){Xn(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){Xn(i,n)}),e.definitions&&e.definitions.forEach(function(i){Xn(i,n)})}var Qt={};(function(){Yn.definitions.forEach(function(n){if(n.name){var t=new Set;Xn(n,t),Qt[n.name.value]=t}})})();function Pa(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function qs(e,n){var t={kind:e.kind,definitions:[Pa(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=Qt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=Qt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Pa(e,o);s&&t.definitions.push(s)}),t}qs(Yn,"UserVerification");class Cs{client;constructor(n){this.client=n}async createUser(n){return this.client.request({method:"post",path:"/users/integration",body:n})}async create(n){return this.createUser(n)}async requestApiKey(n){return this.client.request({method:"post",path:"/users/request-key",body:{email:n}})}async authorizeApiKeyWithOTP(n){return this.client.request({method:"post",path:"/users/validate-key",body:n})}async getCurrentUser(){return(await this.client.query({query:Ve}))?.me??null}async getUserVerification(){return(await this.client.query({query:Yn}))?.verification??null}}var en={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"VirtualDebitCardFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"VirtualCard"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"type"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"mask"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"balance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"renderSecret"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"virtualCardType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billingInfo"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"holder"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"phone"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"email"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"address"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"street"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"street2"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"city"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"subdivision"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"postalCode"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"countryCode"},arguments:[],directives:[]}]}}]}}]}}],loc:{start:0,end:
|
|
399
|
+
`,name:"GraphQL request",locationOffset:{line:1,column:1}};function Xn(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){Xn(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){Xn(i,n)}),e.definitions&&e.definitions.forEach(function(i){Xn(i,n)})}var Qt={};(function(){Yn.definitions.forEach(function(n){if(n.name){var t=new Set;Xn(n,t),Qt[n.name.value]=t}})})();function Pa(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function qs(e,n){var t={kind:e.kind,definitions:[Pa(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=Qt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=Qt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Pa(e,o);s&&t.definitions.push(s)}),t}qs(Yn,"UserVerification");class Cs{client;constructor(n){this.client=n}async createUser(n){return this.client.request({method:"post",path:"/users/integration",body:n})}async create(n){return this.createUser(n)}async requestApiKey(n){return this.client.request({method:"post",path:"/users/request-key",body:{email:n}})}async authorizeApiKeyWithOTP(n){return this.client.request({method:"post",path:"/users/validate-key",body:n})}async getCurrentUser(){return(await this.client.query({query:Ve}))?.me??null}async getUserVerification(){return(await this.client.query({query:Yn}))?.verification??null}}var en={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"VirtualDebitCardFragment"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"VirtualCard"}},directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"userId"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"country"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"currency"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"createdAt"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"type"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"mask"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"balance"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"renderSecret"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"virtualCardType"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"billingInfo"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"holder"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"phone"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"email"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"address"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"street"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"street2"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"city"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"subdivision"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"postalCode"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"countryCode"},arguments:[],directives:[]}]}}]}},{kind:"Field",name:{kind:"Name",value:"paymentAddresses"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"network"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"address"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:469}};en.loc.source={body:`fragment VirtualDebitCardFragment on VirtualCard {
|
|
392
400
|
id
|
|
393
401
|
name
|
|
394
402
|
userId
|
|
@@ -413,6 +421,10 @@ query CurrentUser {
|
|
|
413
421
|
countryCode
|
|
414
422
|
}
|
|
415
423
|
}
|
|
424
|
+
paymentAddresses {
|
|
425
|
+
network
|
|
426
|
+
address
|
|
427
|
+
}
|
|
416
428
|
}
|
|
417
429
|
`,name:"GraphQL request",locationOffset:{line:1,column:1}};function Wn(e,n){if(e.kind==="FragmentSpread")n.add(e.name.value);else if(e.kind==="VariableDefinition"){var t=e.type;t.kind==="NamedType"&&n.add(t.name.value)}e.selectionSet&&e.selectionSet.selections.forEach(function(i){Wn(i,n)}),e.variableDefinitions&&e.variableDefinitions.forEach(function(i){Wn(i,n)}),e.definitions&&e.definitions.forEach(function(i){Wn(i,n)})}var zt={};(function(){en.definitions.forEach(function(n){if(n.name){var t=new Set;Wn(n,t),zt[n.name.value]=t}})})();function Ba(e,n){for(var t=0;t<e.definitions.length;t++){var i=e.definitions[t];if(i.name&&i.name.value==n)return i}}function $s(e,n){var t={kind:e.kind,definitions:[Ba(e,n)]};e.hasOwnProperty("loc")&&(t.loc=e.loc);var i=zt[n]||new Set,a=new Set,r=new Set;for(i.forEach(function(o){r.add(o)});r.size>0;){var u=r;r=new Set,u.forEach(function(o){if(!a.has(o)){a.add(o);var s=zt[o]||new Set;s.forEach(function(c){r.add(c)})}})}return a.forEach(function(o){var s=Ba(e,o);s&&t.definitions.push(s)}),t}$s(en,"VirtualDebitCardFragment");var Ue={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateUSVirtualDebitCard"},variableDefinitions:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"createUSVirtualDebitCard"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"VirtualDebitCardFragment"},directives:[]}]}}]}}],loc:{start:0,end:166}};Ue.loc.source={body:`#import "../queries/virtualDebitCardFragment.graphql"
|
|
418
430
|
|
package/package.json
CHANGED