@aurigami/sdk 0.1.0 → 0.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/sdk.esm.js CHANGED
@@ -1,7 +1,5 @@
1
- import { Token, CurrencyAmount, validateAndParseAddress } from '@pendle/sdk-core';
2
- import IERC20 from '@aurigami/contracts/artifacts/contracts/EIP20Interface.sol/EIP20Interface.json';
3
- import { Contract } from 'ethers';
4
- import AuToken from '@aurigami/contracts/artifacts/contracts/AuToken.sol/AuToken.json';
1
+ import BigNumber from 'bignumber.js';
2
+ import { Contract, BigNumber as BigNumber$1, utils } from 'ethers';
5
3
 
6
4
  function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
7
5
  try {
@@ -843,43 +841,47 @@ var BlockchainEntity = /*#__PURE__*/function () {
843
841
  return BlockchainEntity;
844
842
  }();
845
843
 
846
- var dummyToken = /*#__PURE__*/new Token({
847
- chainId: 43114,
848
- decimal: 6,
849
- symbol: 'USDC',
850
- address: '0xb97ef9ef8734c71904d8002f8b6bc66dd9c48a6e'
851
- });
852
- var dummyPly = /*#__PURE__*/new Token({
853
- chainId: 43114,
854
- decimal: 18,
855
- symbol: 'QI',
856
- address: '0x8729438eb15e2c8b576fcc6aecda6a148776c0f5'
857
- });
858
- var dummyPlyAurora = /*#__PURE__*/new Token({
859
- chainId: 43114,
860
- decimal: 18,
861
- symbol: 'QIWAVAX',
862
- address: '0xE530dC2095Ef5653205CF5ea79F8979a7028065c'
863
- });
864
- var dummyTokenAmount = /*#__PURE__*/new CurrencyAmount({
865
- currency: dummyToken,
866
- amount: '123.456',
867
- isRaw: false
868
- });
869
- var dummyZeroTokenAmount = /*#__PURE__*/new CurrencyAmount({
870
- currency: dummyToken,
871
- amount: '0'
872
- });
873
- var dummyTokenAmount2 = /*#__PURE__*/new CurrencyAmount({
874
- currency: dummyToken,
875
- amount: '456.123',
876
- isRaw: false
877
- });
878
- var dummyTokenAmount3 = /*#__PURE__*/new CurrencyAmount({
879
- currency: dummyToken,
880
- amount: '1000.123',
881
- isRaw: false
882
- });
844
+ var Token = function Token(address, decimals, expiry) {
845
+ this.address = address.toLowerCase();
846
+ this.decimals = decimals;
847
+ this.expiry = expiry;
848
+ };
849
+
850
+ var TokenAmount = /*#__PURE__*/function () {
851
+ function TokenAmount(token, amount, isRaw) {
852
+ if (isRaw === void 0) {
853
+ isRaw = true;
854
+ }
855
+
856
+ if (isRaw) {
857
+ this.rawAmnt = amount;
858
+ } else {
859
+ this.rawAmnt = new BigNumber(amount).times(decimalFactor(token.decimals)).toFixed(0);
860
+ }
861
+
862
+ this.token = token;
863
+ }
864
+
865
+ var _proto = TokenAmount.prototype;
866
+
867
+ _proto.formattedAmount = function formattedAmount() {
868
+ return new BigNumber(this.rawAmnt).div(decimalFactor(this.token.decimals)).toString();
869
+ };
870
+
871
+ _proto.rawAmount = function rawAmount() {
872
+ return this.rawAmnt;
873
+ };
874
+
875
+ return TokenAmount;
876
+ }();
877
+
878
+ var dummyToken = /*#__PURE__*/new Token('0xb97ef9ef8734c71904d8002f8b6bc66dd9c48a6e', 6);
879
+ var dummyPly = /*#__PURE__*/new Token('0x8729438eb15e2c8b576fcc6aecda6a148776c0f5', 18);
880
+ var dummyPlyAurora = /*#__PURE__*/new Token('0xE530dC2095Ef5653205CF5ea79F8979a7028065c', 18);
881
+ var dummyTokenAmount = /*#__PURE__*/new TokenAmount(dummyToken, '123.456', false);
882
+ var dummyZeroTokenAmount = /*#__PURE__*/new TokenAmount(dummyToken, '0');
883
+ var dummyTokenAmount2 = /*#__PURE__*/new TokenAmount(dummyToken, '456.123', false);
884
+ var dummyTokenAmount3 = /*#__PURE__*/new TokenAmount(dummyToken, '1000.123', false);
883
885
  var dummyMarketAddress = '0xbeb5d47a3f720ec0a390d04b4d41ed7d9688bc7f';
884
886
  var dummyUserMarketDetails = {
885
887
  market: dummyMarketAddress,
@@ -891,17 +893,1304 @@ var dummyUserMarketDetails = {
891
893
 
892
894
  var ethers = /*#__PURE__*/require('ethers');
893
895
 
894
- var DOLLAR = /*#__PURE__*/new Token({
895
- chainId: 43114,
896
- decimal: 2,
897
- symbol: 'USDC',
898
- address: '0x0000000000000000000000000000000000000001'
899
- });
896
+ var DOLLAR = /*#__PURE__*/new Token('0x0000000000000000000000000000000000000001', 2);
900
897
  var AVAX_DEFAULT_PROVIDER_URL = 'https://api.avax.network/ext/bc/C/rpc';
901
898
  var AVAX_DEFAULT_PROVIDER = /*#__PURE__*/new ethers.providers.JsonRpcProvider(AVAX_DEFAULT_PROVIDER_URL);
902
899
  var dummyPrivateKey = '1111111111111111111111111111111111111111111111111111111111111111';
903
900
  var AVAX_DEFAULT_SIGNER = /*#__PURE__*/new ethers.Wallet(dummyPrivateKey);
904
901
 
902
+ var abi = [
903
+ {
904
+ inputs: [
905
+ {
906
+ internalType: "string",
907
+ name: "_name",
908
+ type: "string"
909
+ },
910
+ {
911
+ internalType: "string",
912
+ name: "_symbol",
913
+ type: "string"
914
+ },
915
+ {
916
+ internalType: "uint8",
917
+ name: "_decimals",
918
+ type: "uint8"
919
+ },
920
+ {
921
+ internalType: "address",
922
+ name: "_underlying",
923
+ type: "address"
924
+ },
925
+ {
926
+ internalType: "address",
927
+ name: "_vault",
928
+ type: "address"
929
+ }
930
+ ],
931
+ stateMutability: "nonpayable",
932
+ type: "constructor"
933
+ },
934
+ {
935
+ anonymous: false,
936
+ inputs: [
937
+ {
938
+ indexed: true,
939
+ internalType: "address",
940
+ name: "owner",
941
+ type: "address"
942
+ },
943
+ {
944
+ indexed: true,
945
+ internalType: "address",
946
+ name: "spender",
947
+ type: "address"
948
+ },
949
+ {
950
+ indexed: false,
951
+ internalType: "uint256",
952
+ name: "value",
953
+ type: "uint256"
954
+ }
955
+ ],
956
+ name: "Approval",
957
+ type: "event"
958
+ },
959
+ {
960
+ anonymous: false,
961
+ inputs: [
962
+ {
963
+ indexed: true,
964
+ internalType: "address",
965
+ name: "auth",
966
+ type: "address"
967
+ },
968
+ {
969
+ indexed: false,
970
+ internalType: "uint256",
971
+ name: "timestamp",
972
+ type: "uint256"
973
+ }
974
+ ],
975
+ name: "LogAddAuth",
976
+ type: "event"
977
+ },
978
+ {
979
+ anonymous: false,
980
+ inputs: [
981
+ {
982
+ indexed: true,
983
+ internalType: "address",
984
+ name: "oldOwner",
985
+ type: "address"
986
+ },
987
+ {
988
+ indexed: true,
989
+ internalType: "address",
990
+ name: "newOwner",
991
+ type: "address"
992
+ },
993
+ {
994
+ indexed: true,
995
+ internalType: "uint256",
996
+ name: "effectiveHeight",
997
+ type: "uint256"
998
+ }
999
+ ],
1000
+ name: "LogChangeMPCOwner",
1001
+ type: "event"
1002
+ },
1003
+ {
1004
+ anonymous: false,
1005
+ inputs: [
1006
+ {
1007
+ indexed: true,
1008
+ internalType: "address",
1009
+ name: "oldVault",
1010
+ type: "address"
1011
+ },
1012
+ {
1013
+ indexed: true,
1014
+ internalType: "address",
1015
+ name: "newVault",
1016
+ type: "address"
1017
+ },
1018
+ {
1019
+ indexed: true,
1020
+ internalType: "uint256",
1021
+ name: "effectiveTime",
1022
+ type: "uint256"
1023
+ }
1024
+ ],
1025
+ name: "LogChangeVault",
1026
+ type: "event"
1027
+ },
1028
+ {
1029
+ anonymous: false,
1030
+ inputs: [
1031
+ {
1032
+ indexed: true,
1033
+ internalType: "bytes32",
1034
+ name: "txhash",
1035
+ type: "bytes32"
1036
+ },
1037
+ {
1038
+ indexed: true,
1039
+ internalType: "address",
1040
+ name: "account",
1041
+ type: "address"
1042
+ },
1043
+ {
1044
+ indexed: false,
1045
+ internalType: "uint256",
1046
+ name: "amount",
1047
+ type: "uint256"
1048
+ }
1049
+ ],
1050
+ name: "LogSwapin",
1051
+ type: "event"
1052
+ },
1053
+ {
1054
+ anonymous: false,
1055
+ inputs: [
1056
+ {
1057
+ indexed: true,
1058
+ internalType: "address",
1059
+ name: "account",
1060
+ type: "address"
1061
+ },
1062
+ {
1063
+ indexed: true,
1064
+ internalType: "address",
1065
+ name: "bindaddr",
1066
+ type: "address"
1067
+ },
1068
+ {
1069
+ indexed: false,
1070
+ internalType: "uint256",
1071
+ name: "amount",
1072
+ type: "uint256"
1073
+ }
1074
+ ],
1075
+ name: "LogSwapout",
1076
+ type: "event"
1077
+ },
1078
+ {
1079
+ anonymous: false,
1080
+ inputs: [
1081
+ {
1082
+ indexed: true,
1083
+ internalType: "address",
1084
+ name: "from",
1085
+ type: "address"
1086
+ },
1087
+ {
1088
+ indexed: true,
1089
+ internalType: "address",
1090
+ name: "to",
1091
+ type: "address"
1092
+ },
1093
+ {
1094
+ indexed: false,
1095
+ internalType: "uint256",
1096
+ name: "value",
1097
+ type: "uint256"
1098
+ }
1099
+ ],
1100
+ name: "Transfer",
1101
+ type: "event"
1102
+ },
1103
+ {
1104
+ inputs: [
1105
+ ],
1106
+ name: "DOMAIN_SEPARATOR",
1107
+ outputs: [
1108
+ {
1109
+ internalType: "bytes32",
1110
+ name: "",
1111
+ type: "bytes32"
1112
+ }
1113
+ ],
1114
+ stateMutability: "view",
1115
+ type: "function"
1116
+ },
1117
+ {
1118
+ inputs: [
1119
+ ],
1120
+ name: "PERMIT_TYPEHASH",
1121
+ outputs: [
1122
+ {
1123
+ internalType: "bytes32",
1124
+ name: "",
1125
+ type: "bytes32"
1126
+ }
1127
+ ],
1128
+ stateMutability: "view",
1129
+ type: "function"
1130
+ },
1131
+ {
1132
+ inputs: [
1133
+ {
1134
+ internalType: "bytes32",
1135
+ name: "txhash",
1136
+ type: "bytes32"
1137
+ },
1138
+ {
1139
+ internalType: "address",
1140
+ name: "account",
1141
+ type: "address"
1142
+ },
1143
+ {
1144
+ internalType: "uint256",
1145
+ name: "amount",
1146
+ type: "uint256"
1147
+ }
1148
+ ],
1149
+ name: "Swapin",
1150
+ outputs: [
1151
+ {
1152
+ internalType: "bool",
1153
+ name: "",
1154
+ type: "bool"
1155
+ }
1156
+ ],
1157
+ stateMutability: "nonpayable",
1158
+ type: "function"
1159
+ },
1160
+ {
1161
+ inputs: [
1162
+ {
1163
+ internalType: "uint256",
1164
+ name: "amount",
1165
+ type: "uint256"
1166
+ },
1167
+ {
1168
+ internalType: "address",
1169
+ name: "bindaddr",
1170
+ type: "address"
1171
+ }
1172
+ ],
1173
+ name: "Swapout",
1174
+ outputs: [
1175
+ {
1176
+ internalType: "bool",
1177
+ name: "",
1178
+ type: "bool"
1179
+ }
1180
+ ],
1181
+ stateMutability: "nonpayable",
1182
+ type: "function"
1183
+ },
1184
+ {
1185
+ inputs: [
1186
+ ],
1187
+ name: "TRANSFER_TYPEHASH",
1188
+ outputs: [
1189
+ {
1190
+ internalType: "bytes32",
1191
+ name: "",
1192
+ type: "bytes32"
1193
+ }
1194
+ ],
1195
+ stateMutability: "view",
1196
+ type: "function"
1197
+ },
1198
+ {
1199
+ inputs: [
1200
+ {
1201
+ internalType: "address",
1202
+ name: "",
1203
+ type: "address"
1204
+ },
1205
+ {
1206
+ internalType: "address",
1207
+ name: "",
1208
+ type: "address"
1209
+ }
1210
+ ],
1211
+ name: "allowance",
1212
+ outputs: [
1213
+ {
1214
+ internalType: "uint256",
1215
+ name: "",
1216
+ type: "uint256"
1217
+ }
1218
+ ],
1219
+ stateMutability: "view",
1220
+ type: "function"
1221
+ },
1222
+ {
1223
+ inputs: [
1224
+ ],
1225
+ name: "applyMinter",
1226
+ outputs: [
1227
+ ],
1228
+ stateMutability: "nonpayable",
1229
+ type: "function"
1230
+ },
1231
+ {
1232
+ inputs: [
1233
+ ],
1234
+ name: "applyVault",
1235
+ outputs: [
1236
+ ],
1237
+ stateMutability: "nonpayable",
1238
+ type: "function"
1239
+ },
1240
+ {
1241
+ inputs: [
1242
+ {
1243
+ internalType: "address",
1244
+ name: "spender",
1245
+ type: "address"
1246
+ },
1247
+ {
1248
+ internalType: "uint256",
1249
+ name: "value",
1250
+ type: "uint256"
1251
+ }
1252
+ ],
1253
+ name: "approve",
1254
+ outputs: [
1255
+ {
1256
+ internalType: "bool",
1257
+ name: "",
1258
+ type: "bool"
1259
+ }
1260
+ ],
1261
+ stateMutability: "nonpayable",
1262
+ type: "function"
1263
+ },
1264
+ {
1265
+ inputs: [
1266
+ {
1267
+ internalType: "address",
1268
+ name: "spender",
1269
+ type: "address"
1270
+ },
1271
+ {
1272
+ internalType: "uint256",
1273
+ name: "value",
1274
+ type: "uint256"
1275
+ },
1276
+ {
1277
+ internalType: "bytes",
1278
+ name: "data",
1279
+ type: "bytes"
1280
+ }
1281
+ ],
1282
+ name: "approveAndCall",
1283
+ outputs: [
1284
+ {
1285
+ internalType: "bool",
1286
+ name: "",
1287
+ type: "bool"
1288
+ }
1289
+ ],
1290
+ stateMutability: "nonpayable",
1291
+ type: "function"
1292
+ },
1293
+ {
1294
+ inputs: [
1295
+ {
1296
+ internalType: "address",
1297
+ name: "",
1298
+ type: "address"
1299
+ }
1300
+ ],
1301
+ name: "balanceOf",
1302
+ outputs: [
1303
+ {
1304
+ internalType: "uint256",
1305
+ name: "",
1306
+ type: "uint256"
1307
+ }
1308
+ ],
1309
+ stateMutability: "view",
1310
+ type: "function"
1311
+ },
1312
+ {
1313
+ inputs: [
1314
+ {
1315
+ internalType: "address",
1316
+ name: "from",
1317
+ type: "address"
1318
+ },
1319
+ {
1320
+ internalType: "uint256",
1321
+ name: "amount",
1322
+ type: "uint256"
1323
+ }
1324
+ ],
1325
+ name: "burn",
1326
+ outputs: [
1327
+ {
1328
+ internalType: "bool",
1329
+ name: "",
1330
+ type: "bool"
1331
+ }
1332
+ ],
1333
+ stateMutability: "nonpayable",
1334
+ type: "function"
1335
+ },
1336
+ {
1337
+ inputs: [
1338
+ {
1339
+ internalType: "address",
1340
+ name: "newVault",
1341
+ type: "address"
1342
+ }
1343
+ ],
1344
+ name: "changeMPCOwner",
1345
+ outputs: [
1346
+ {
1347
+ internalType: "bool",
1348
+ name: "",
1349
+ type: "bool"
1350
+ }
1351
+ ],
1352
+ stateMutability: "nonpayable",
1353
+ type: "function"
1354
+ },
1355
+ {
1356
+ inputs: [
1357
+ {
1358
+ internalType: "address",
1359
+ name: "newVault",
1360
+ type: "address"
1361
+ }
1362
+ ],
1363
+ name: "changeVault",
1364
+ outputs: [
1365
+ {
1366
+ internalType: "bool",
1367
+ name: "",
1368
+ type: "bool"
1369
+ }
1370
+ ],
1371
+ stateMutability: "nonpayable",
1372
+ type: "function"
1373
+ },
1374
+ {
1375
+ inputs: [
1376
+ ],
1377
+ name: "decimals",
1378
+ outputs: [
1379
+ {
1380
+ internalType: "uint8",
1381
+ name: "",
1382
+ type: "uint8"
1383
+ }
1384
+ ],
1385
+ stateMutability: "view",
1386
+ type: "function"
1387
+ },
1388
+ {
1389
+ inputs: [
1390
+ ],
1391
+ name: "delay",
1392
+ outputs: [
1393
+ {
1394
+ internalType: "uint256",
1395
+ name: "",
1396
+ type: "uint256"
1397
+ }
1398
+ ],
1399
+ stateMutability: "view",
1400
+ type: "function"
1401
+ },
1402
+ {
1403
+ inputs: [
1404
+ ],
1405
+ name: "delayDelay",
1406
+ outputs: [
1407
+ {
1408
+ internalType: "uint256",
1409
+ name: "",
1410
+ type: "uint256"
1411
+ }
1412
+ ],
1413
+ stateMutability: "view",
1414
+ type: "function"
1415
+ },
1416
+ {
1417
+ inputs: [
1418
+ ],
1419
+ name: "delayMinter",
1420
+ outputs: [
1421
+ {
1422
+ internalType: "uint256",
1423
+ name: "",
1424
+ type: "uint256"
1425
+ }
1426
+ ],
1427
+ stateMutability: "view",
1428
+ type: "function"
1429
+ },
1430
+ {
1431
+ inputs: [
1432
+ ],
1433
+ name: "delayVault",
1434
+ outputs: [
1435
+ {
1436
+ internalType: "uint256",
1437
+ name: "",
1438
+ type: "uint256"
1439
+ }
1440
+ ],
1441
+ stateMutability: "view",
1442
+ type: "function"
1443
+ },
1444
+ {
1445
+ inputs: [
1446
+ {
1447
+ internalType: "uint256",
1448
+ name: "amount",
1449
+ type: "uint256"
1450
+ },
1451
+ {
1452
+ internalType: "address",
1453
+ name: "to",
1454
+ type: "address"
1455
+ }
1456
+ ],
1457
+ name: "deposit",
1458
+ outputs: [
1459
+ {
1460
+ internalType: "uint256",
1461
+ name: "",
1462
+ type: "uint256"
1463
+ }
1464
+ ],
1465
+ stateMutability: "nonpayable",
1466
+ type: "function"
1467
+ },
1468
+ {
1469
+ inputs: [
1470
+ {
1471
+ internalType: "uint256",
1472
+ name: "amount",
1473
+ type: "uint256"
1474
+ }
1475
+ ],
1476
+ name: "deposit",
1477
+ outputs: [
1478
+ {
1479
+ internalType: "uint256",
1480
+ name: "",
1481
+ type: "uint256"
1482
+ }
1483
+ ],
1484
+ stateMutability: "nonpayable",
1485
+ type: "function"
1486
+ },
1487
+ {
1488
+ inputs: [
1489
+ ],
1490
+ name: "deposit",
1491
+ outputs: [
1492
+ {
1493
+ internalType: "uint256",
1494
+ name: "",
1495
+ type: "uint256"
1496
+ }
1497
+ ],
1498
+ stateMutability: "nonpayable",
1499
+ type: "function"
1500
+ },
1501
+ {
1502
+ inputs: [
1503
+ {
1504
+ internalType: "uint256",
1505
+ name: "amount",
1506
+ type: "uint256"
1507
+ },
1508
+ {
1509
+ internalType: "address",
1510
+ name: "to",
1511
+ type: "address"
1512
+ }
1513
+ ],
1514
+ name: "depositVault",
1515
+ outputs: [
1516
+ {
1517
+ internalType: "uint256",
1518
+ name: "",
1519
+ type: "uint256"
1520
+ }
1521
+ ],
1522
+ stateMutability: "nonpayable",
1523
+ type: "function"
1524
+ },
1525
+ {
1526
+ inputs: [
1527
+ {
1528
+ internalType: "address",
1529
+ name: "target",
1530
+ type: "address"
1531
+ },
1532
+ {
1533
+ internalType: "uint256",
1534
+ name: "value",
1535
+ type: "uint256"
1536
+ },
1537
+ {
1538
+ internalType: "uint256",
1539
+ name: "deadline",
1540
+ type: "uint256"
1541
+ },
1542
+ {
1543
+ internalType: "uint8",
1544
+ name: "v",
1545
+ type: "uint8"
1546
+ },
1547
+ {
1548
+ internalType: "bytes32",
1549
+ name: "r",
1550
+ type: "bytes32"
1551
+ },
1552
+ {
1553
+ internalType: "bytes32",
1554
+ name: "s",
1555
+ type: "bytes32"
1556
+ },
1557
+ {
1558
+ internalType: "address",
1559
+ name: "to",
1560
+ type: "address"
1561
+ }
1562
+ ],
1563
+ name: "depositWithPermit",
1564
+ outputs: [
1565
+ {
1566
+ internalType: "uint256",
1567
+ name: "",
1568
+ type: "uint256"
1569
+ }
1570
+ ],
1571
+ stateMutability: "nonpayable",
1572
+ type: "function"
1573
+ },
1574
+ {
1575
+ inputs: [
1576
+ {
1577
+ internalType: "address",
1578
+ name: "target",
1579
+ type: "address"
1580
+ },
1581
+ {
1582
+ internalType: "uint256",
1583
+ name: "value",
1584
+ type: "uint256"
1585
+ },
1586
+ {
1587
+ internalType: "uint256",
1588
+ name: "deadline",
1589
+ type: "uint256"
1590
+ },
1591
+ {
1592
+ internalType: "uint8",
1593
+ name: "v",
1594
+ type: "uint8"
1595
+ },
1596
+ {
1597
+ internalType: "bytes32",
1598
+ name: "r",
1599
+ type: "bytes32"
1600
+ },
1601
+ {
1602
+ internalType: "bytes32",
1603
+ name: "s",
1604
+ type: "bytes32"
1605
+ },
1606
+ {
1607
+ internalType: "address",
1608
+ name: "to",
1609
+ type: "address"
1610
+ }
1611
+ ],
1612
+ name: "depositWithTransferPermit",
1613
+ outputs: [
1614
+ {
1615
+ internalType: "uint256",
1616
+ name: "",
1617
+ type: "uint256"
1618
+ }
1619
+ ],
1620
+ stateMutability: "nonpayable",
1621
+ type: "function"
1622
+ },
1623
+ {
1624
+ inputs: [
1625
+ ],
1626
+ name: "getAllMinters",
1627
+ outputs: [
1628
+ {
1629
+ internalType: "address[]",
1630
+ name: "",
1631
+ type: "address[]"
1632
+ }
1633
+ ],
1634
+ stateMutability: "view",
1635
+ type: "function"
1636
+ },
1637
+ {
1638
+ inputs: [
1639
+ {
1640
+ internalType: "address",
1641
+ name: "_vault",
1642
+ type: "address"
1643
+ }
1644
+ ],
1645
+ name: "initVault",
1646
+ outputs: [
1647
+ ],
1648
+ stateMutability: "nonpayable",
1649
+ type: "function"
1650
+ },
1651
+ {
1652
+ inputs: [
1653
+ {
1654
+ internalType: "address",
1655
+ name: "",
1656
+ type: "address"
1657
+ }
1658
+ ],
1659
+ name: "isMinter",
1660
+ outputs: [
1661
+ {
1662
+ internalType: "bool",
1663
+ name: "",
1664
+ type: "bool"
1665
+ }
1666
+ ],
1667
+ stateMutability: "view",
1668
+ type: "function"
1669
+ },
1670
+ {
1671
+ inputs: [
1672
+ {
1673
+ internalType: "address",
1674
+ name: "to",
1675
+ type: "address"
1676
+ },
1677
+ {
1678
+ internalType: "uint256",
1679
+ name: "amount",
1680
+ type: "uint256"
1681
+ }
1682
+ ],
1683
+ name: "mint",
1684
+ outputs: [
1685
+ {
1686
+ internalType: "bool",
1687
+ name: "",
1688
+ type: "bool"
1689
+ }
1690
+ ],
1691
+ stateMutability: "nonpayable",
1692
+ type: "function"
1693
+ },
1694
+ {
1695
+ inputs: [
1696
+ {
1697
+ internalType: "uint256",
1698
+ name: "",
1699
+ type: "uint256"
1700
+ }
1701
+ ],
1702
+ name: "minters",
1703
+ outputs: [
1704
+ {
1705
+ internalType: "address",
1706
+ name: "",
1707
+ type: "address"
1708
+ }
1709
+ ],
1710
+ stateMutability: "view",
1711
+ type: "function"
1712
+ },
1713
+ {
1714
+ inputs: [
1715
+ ],
1716
+ name: "mpc",
1717
+ outputs: [
1718
+ {
1719
+ internalType: "address",
1720
+ name: "",
1721
+ type: "address"
1722
+ }
1723
+ ],
1724
+ stateMutability: "view",
1725
+ type: "function"
1726
+ },
1727
+ {
1728
+ inputs: [
1729
+ ],
1730
+ name: "name",
1731
+ outputs: [
1732
+ {
1733
+ internalType: "string",
1734
+ name: "",
1735
+ type: "string"
1736
+ }
1737
+ ],
1738
+ stateMutability: "view",
1739
+ type: "function"
1740
+ },
1741
+ {
1742
+ inputs: [
1743
+ {
1744
+ internalType: "address",
1745
+ name: "",
1746
+ type: "address"
1747
+ }
1748
+ ],
1749
+ name: "nonces",
1750
+ outputs: [
1751
+ {
1752
+ internalType: "uint256",
1753
+ name: "",
1754
+ type: "uint256"
1755
+ }
1756
+ ],
1757
+ stateMutability: "view",
1758
+ type: "function"
1759
+ },
1760
+ {
1761
+ inputs: [
1762
+ ],
1763
+ name: "owner",
1764
+ outputs: [
1765
+ {
1766
+ internalType: "address",
1767
+ name: "",
1768
+ type: "address"
1769
+ }
1770
+ ],
1771
+ stateMutability: "view",
1772
+ type: "function"
1773
+ },
1774
+ {
1775
+ inputs: [
1776
+ ],
1777
+ name: "pendingDelay",
1778
+ outputs: [
1779
+ {
1780
+ internalType: "uint256",
1781
+ name: "",
1782
+ type: "uint256"
1783
+ }
1784
+ ],
1785
+ stateMutability: "view",
1786
+ type: "function"
1787
+ },
1788
+ {
1789
+ inputs: [
1790
+ ],
1791
+ name: "pendingMinter",
1792
+ outputs: [
1793
+ {
1794
+ internalType: "address",
1795
+ name: "",
1796
+ type: "address"
1797
+ }
1798
+ ],
1799
+ stateMutability: "view",
1800
+ type: "function"
1801
+ },
1802
+ {
1803
+ inputs: [
1804
+ ],
1805
+ name: "pendingVault",
1806
+ outputs: [
1807
+ {
1808
+ internalType: "address",
1809
+ name: "",
1810
+ type: "address"
1811
+ }
1812
+ ],
1813
+ stateMutability: "view",
1814
+ type: "function"
1815
+ },
1816
+ {
1817
+ inputs: [
1818
+ {
1819
+ internalType: "address",
1820
+ name: "target",
1821
+ type: "address"
1822
+ },
1823
+ {
1824
+ internalType: "address",
1825
+ name: "spender",
1826
+ type: "address"
1827
+ },
1828
+ {
1829
+ internalType: "uint256",
1830
+ name: "value",
1831
+ type: "uint256"
1832
+ },
1833
+ {
1834
+ internalType: "uint256",
1835
+ name: "deadline",
1836
+ type: "uint256"
1837
+ },
1838
+ {
1839
+ internalType: "uint8",
1840
+ name: "v",
1841
+ type: "uint8"
1842
+ },
1843
+ {
1844
+ internalType: "bytes32",
1845
+ name: "r",
1846
+ type: "bytes32"
1847
+ },
1848
+ {
1849
+ internalType: "bytes32",
1850
+ name: "s",
1851
+ type: "bytes32"
1852
+ }
1853
+ ],
1854
+ name: "permit",
1855
+ outputs: [
1856
+ ],
1857
+ stateMutability: "nonpayable",
1858
+ type: "function"
1859
+ },
1860
+ {
1861
+ inputs: [
1862
+ {
1863
+ internalType: "address",
1864
+ name: "_auth",
1865
+ type: "address"
1866
+ }
1867
+ ],
1868
+ name: "revokeMinter",
1869
+ outputs: [
1870
+ ],
1871
+ stateMutability: "nonpayable",
1872
+ type: "function"
1873
+ },
1874
+ {
1875
+ inputs: [
1876
+ {
1877
+ internalType: "address",
1878
+ name: "_auth",
1879
+ type: "address"
1880
+ }
1881
+ ],
1882
+ name: "setMinter",
1883
+ outputs: [
1884
+ ],
1885
+ stateMutability: "nonpayable",
1886
+ type: "function"
1887
+ },
1888
+ {
1889
+ inputs: [
1890
+ {
1891
+ internalType: "address",
1892
+ name: "_vault",
1893
+ type: "address"
1894
+ }
1895
+ ],
1896
+ name: "setVault",
1897
+ outputs: [
1898
+ ],
1899
+ stateMutability: "nonpayable",
1900
+ type: "function"
1901
+ },
1902
+ {
1903
+ inputs: [
1904
+ {
1905
+ internalType: "bool",
1906
+ name: "enabled",
1907
+ type: "bool"
1908
+ }
1909
+ ],
1910
+ name: "setVaultOnly",
1911
+ outputs: [
1912
+ ],
1913
+ stateMutability: "nonpayable",
1914
+ type: "function"
1915
+ },
1916
+ {
1917
+ inputs: [
1918
+ ],
1919
+ name: "symbol",
1920
+ outputs: [
1921
+ {
1922
+ internalType: "string",
1923
+ name: "",
1924
+ type: "string"
1925
+ }
1926
+ ],
1927
+ stateMutability: "view",
1928
+ type: "function"
1929
+ },
1930
+ {
1931
+ inputs: [
1932
+ ],
1933
+ name: "totalSupply",
1934
+ outputs: [
1935
+ {
1936
+ internalType: "uint256",
1937
+ name: "",
1938
+ type: "uint256"
1939
+ }
1940
+ ],
1941
+ stateMutability: "view",
1942
+ type: "function"
1943
+ },
1944
+ {
1945
+ inputs: [
1946
+ {
1947
+ internalType: "address",
1948
+ name: "to",
1949
+ type: "address"
1950
+ },
1951
+ {
1952
+ internalType: "uint256",
1953
+ name: "value",
1954
+ type: "uint256"
1955
+ }
1956
+ ],
1957
+ name: "transfer",
1958
+ outputs: [
1959
+ {
1960
+ internalType: "bool",
1961
+ name: "",
1962
+ type: "bool"
1963
+ }
1964
+ ],
1965
+ stateMutability: "nonpayable",
1966
+ type: "function"
1967
+ },
1968
+ {
1969
+ inputs: [
1970
+ {
1971
+ internalType: "address",
1972
+ name: "to",
1973
+ type: "address"
1974
+ },
1975
+ {
1976
+ internalType: "uint256",
1977
+ name: "value",
1978
+ type: "uint256"
1979
+ },
1980
+ {
1981
+ internalType: "bytes",
1982
+ name: "data",
1983
+ type: "bytes"
1984
+ }
1985
+ ],
1986
+ name: "transferAndCall",
1987
+ outputs: [
1988
+ {
1989
+ internalType: "bool",
1990
+ name: "",
1991
+ type: "bool"
1992
+ }
1993
+ ],
1994
+ stateMutability: "nonpayable",
1995
+ type: "function"
1996
+ },
1997
+ {
1998
+ inputs: [
1999
+ {
2000
+ internalType: "address",
2001
+ name: "from",
2002
+ type: "address"
2003
+ },
2004
+ {
2005
+ internalType: "address",
2006
+ name: "to",
2007
+ type: "address"
2008
+ },
2009
+ {
2010
+ internalType: "uint256",
2011
+ name: "value",
2012
+ type: "uint256"
2013
+ }
2014
+ ],
2015
+ name: "transferFrom",
2016
+ outputs: [
2017
+ {
2018
+ internalType: "bool",
2019
+ name: "",
2020
+ type: "bool"
2021
+ }
2022
+ ],
2023
+ stateMutability: "nonpayable",
2024
+ type: "function"
2025
+ },
2026
+ {
2027
+ inputs: [
2028
+ {
2029
+ internalType: "address",
2030
+ name: "target",
2031
+ type: "address"
2032
+ },
2033
+ {
2034
+ internalType: "address",
2035
+ name: "to",
2036
+ type: "address"
2037
+ },
2038
+ {
2039
+ internalType: "uint256",
2040
+ name: "value",
2041
+ type: "uint256"
2042
+ },
2043
+ {
2044
+ internalType: "uint256",
2045
+ name: "deadline",
2046
+ type: "uint256"
2047
+ },
2048
+ {
2049
+ internalType: "uint8",
2050
+ name: "v",
2051
+ type: "uint8"
2052
+ },
2053
+ {
2054
+ internalType: "bytes32",
2055
+ name: "r",
2056
+ type: "bytes32"
2057
+ },
2058
+ {
2059
+ internalType: "bytes32",
2060
+ name: "s",
2061
+ type: "bytes32"
2062
+ }
2063
+ ],
2064
+ name: "transferWithPermit",
2065
+ outputs: [
2066
+ {
2067
+ internalType: "bool",
2068
+ name: "",
2069
+ type: "bool"
2070
+ }
2071
+ ],
2072
+ stateMutability: "nonpayable",
2073
+ type: "function"
2074
+ },
2075
+ {
2076
+ inputs: [
2077
+ ],
2078
+ name: "underlying",
2079
+ outputs: [
2080
+ {
2081
+ internalType: "address",
2082
+ name: "",
2083
+ type: "address"
2084
+ }
2085
+ ],
2086
+ stateMutability: "view",
2087
+ type: "function"
2088
+ },
2089
+ {
2090
+ inputs: [
2091
+ ],
2092
+ name: "vault",
2093
+ outputs: [
2094
+ {
2095
+ internalType: "address",
2096
+ name: "",
2097
+ type: "address"
2098
+ }
2099
+ ],
2100
+ stateMutability: "view",
2101
+ type: "function"
2102
+ },
2103
+ {
2104
+ inputs: [
2105
+ {
2106
+ internalType: "uint256",
2107
+ name: "amount",
2108
+ type: "uint256"
2109
+ },
2110
+ {
2111
+ internalType: "address",
2112
+ name: "to",
2113
+ type: "address"
2114
+ }
2115
+ ],
2116
+ name: "withdraw",
2117
+ outputs: [
2118
+ {
2119
+ internalType: "uint256",
2120
+ name: "",
2121
+ type: "uint256"
2122
+ }
2123
+ ],
2124
+ stateMutability: "nonpayable",
2125
+ type: "function"
2126
+ },
2127
+ {
2128
+ inputs: [
2129
+ {
2130
+ internalType: "uint256",
2131
+ name: "amount",
2132
+ type: "uint256"
2133
+ }
2134
+ ],
2135
+ name: "withdraw",
2136
+ outputs: [
2137
+ {
2138
+ internalType: "uint256",
2139
+ name: "",
2140
+ type: "uint256"
2141
+ }
2142
+ ],
2143
+ stateMutability: "nonpayable",
2144
+ type: "function"
2145
+ },
2146
+ {
2147
+ inputs: [
2148
+ ],
2149
+ name: "withdraw",
2150
+ outputs: [
2151
+ {
2152
+ internalType: "uint256",
2153
+ name: "",
2154
+ type: "uint256"
2155
+ }
2156
+ ],
2157
+ stateMutability: "nonpayable",
2158
+ type: "function"
2159
+ },
2160
+ {
2161
+ inputs: [
2162
+ {
2163
+ internalType: "address",
2164
+ name: "from",
2165
+ type: "address"
2166
+ },
2167
+ {
2168
+ internalType: "uint256",
2169
+ name: "amount",
2170
+ type: "uint256"
2171
+ },
2172
+ {
2173
+ internalType: "address",
2174
+ name: "to",
2175
+ type: "address"
2176
+ }
2177
+ ],
2178
+ name: "withdrawVault",
2179
+ outputs: [
2180
+ {
2181
+ internalType: "uint256",
2182
+ name: "",
2183
+ type: "uint256"
2184
+ }
2185
+ ],
2186
+ stateMutability: "nonpayable",
2187
+ type: "function"
2188
+ }
2189
+ ];
2190
+ var IERC20 = {
2191
+ abi: abi
2192
+ };
2193
+
905
2194
  var ethers$1 = /*#__PURE__*/require('ethers');
906
2195
 
907
2196
  var SdkRead = /*#__PURE__*/function (_BlockchainEntityRead) {
@@ -949,16 +2238,8 @@ var SdkRead = /*#__PURE__*/function (_BlockchainEntityRead) {
949
2238
  return _context2.abrupt("return", {
950
2239
  markets: [dummyUserMarketDetails],
951
2240
  borrowLimit: dummyTokenAmount3,
952
- accruedPly: new CurrencyAmount({
953
- currency: dummyPly,
954
- amount: '100.12',
955
- isRaw: false
956
- }),
957
- lockedPly: new CurrencyAmount({
958
- currency: dummyPly,
959
- amount: '200.12',
960
- isRaw: false
961
- }),
2241
+ accruedPly: new TokenAmount(dummyPly, '100.12', false),
2242
+ lockedPly: new TokenAmount(dummyPly, '200.12', false),
962
2243
  borrowableAmount: dummyTokenAmount2
963
2244
  });
964
2245
 
@@ -984,11 +2265,7 @@ var SdkRead = /*#__PURE__*/function (_BlockchainEntityRead) {
984
2265
  switch (_context3.prev = _context3.next) {
985
2266
  case 0:
986
2267
  return _context3.abrupt("return", {
987
- totalStakedLiquidity: new CurrencyAmount({
988
- currency: dummyPlyAurora,
989
- amount: '12.1',
990
- isRaw: false
991
- }),
2268
+ totalStakedLiquidity: new TokenAmount(dummyPlyAurora, '12.1', false),
992
2269
  apy: 1.21
993
2270
  });
994
2271
 
@@ -1018,18 +2295,10 @@ var SdkRead = /*#__PURE__*/function (_BlockchainEntityRead) {
1018
2295
  break;
1019
2296
  }
1020
2297
 
1021
- return _context4.abrupt("return", new CurrencyAmount({
1022
- currency: DOLLAR,
1023
- amount: '1',
1024
- isRaw: false
1025
- }));
2298
+ return _context4.abrupt("return", new TokenAmount(DOLLAR, '1', false));
1026
2299
 
1027
2300
  case 2:
1028
- return _context4.abrupt("return", new CurrencyAmount({
1029
- currency: DOLLAR,
1030
- amount: '12.1',
1031
- isRaw: false
1032
- }));
2301
+ return _context4.abrupt("return", new TokenAmount(DOLLAR, '12.1', false));
1033
2302
 
1034
2303
  case 3:
1035
2304
  case "end":
@@ -1052,11 +2321,7 @@ var SdkRead = /*#__PURE__*/function (_BlockchainEntityRead) {
1052
2321
  while (1) {
1053
2322
  switch (_context5.prev = _context5.next) {
1054
2323
  case 0:
1055
- return _context5.abrupt("return", new CurrencyAmount({
1056
- currency: dummyPlyAurora,
1057
- amount: '103.4',
1058
- isRaw: false
1059
- }));
2324
+ return _context5.abrupt("return", new TokenAmount(dummyPlyAurora, '103.4', false));
1060
2325
 
1061
2326
  case 1:
1062
2327
  case "end":
@@ -1198,6 +2463,1585 @@ var SDK = /*#__PURE__*/function (_BlockchainEntity) {
1198
2463
  return SDK;
1199
2464
  }(BlockchainEntity);
1200
2465
 
2466
+ var abi$1 = [
2467
+ {
2468
+ inputs: [
2469
+ {
2470
+ internalType: "address",
2471
+ name: "underlying_",
2472
+ type: "address"
2473
+ },
2474
+ {
2475
+ internalType: "contract ComptrollerInterface",
2476
+ name: "comptroller_",
2477
+ type: "address"
2478
+ },
2479
+ {
2480
+ internalType: "contract InterestRateModel",
2481
+ name: "interestRateModel_",
2482
+ type: "address"
2483
+ },
2484
+ {
2485
+ internalType: "uint256",
2486
+ name: "initialExchangeRateMantissa_",
2487
+ type: "uint256"
2488
+ },
2489
+ {
2490
+ internalType: "string",
2491
+ name: "name_",
2492
+ type: "string"
2493
+ },
2494
+ {
2495
+ internalType: "string",
2496
+ name: "symbol_",
2497
+ type: "string"
2498
+ },
2499
+ {
2500
+ internalType: "uint8",
2501
+ name: "decimals_",
2502
+ type: "uint8"
2503
+ },
2504
+ {
2505
+ internalType: "address payable",
2506
+ name: "admin_",
2507
+ type: "address"
2508
+ },
2509
+ {
2510
+ internalType: "address",
2511
+ name: "implementation_",
2512
+ type: "address"
2513
+ },
2514
+ {
2515
+ internalType: "bytes",
2516
+ name: "becomeImplementationData",
2517
+ type: "bytes"
2518
+ }
2519
+ ],
2520
+ payable: false,
2521
+ stateMutability: "nonpayable",
2522
+ type: "constructor"
2523
+ },
2524
+ {
2525
+ anonymous: false,
2526
+ inputs: [
2527
+ {
2528
+ indexed: false,
2529
+ internalType: "uint256",
2530
+ name: "cashPrior",
2531
+ type: "uint256"
2532
+ },
2533
+ {
2534
+ indexed: false,
2535
+ internalType: "uint256",
2536
+ name: "interestAccumulated",
2537
+ type: "uint256"
2538
+ },
2539
+ {
2540
+ indexed: false,
2541
+ internalType: "uint256",
2542
+ name: "borrowIndex",
2543
+ type: "uint256"
2544
+ },
2545
+ {
2546
+ indexed: false,
2547
+ internalType: "uint256",
2548
+ name: "totalBorrows",
2549
+ type: "uint256"
2550
+ }
2551
+ ],
2552
+ name: "AccrueInterest",
2553
+ type: "event"
2554
+ },
2555
+ {
2556
+ anonymous: false,
2557
+ inputs: [
2558
+ {
2559
+ indexed: true,
2560
+ internalType: "address",
2561
+ name: "owner",
2562
+ type: "address"
2563
+ },
2564
+ {
2565
+ indexed: true,
2566
+ internalType: "address",
2567
+ name: "spender",
2568
+ type: "address"
2569
+ },
2570
+ {
2571
+ indexed: false,
2572
+ internalType: "uint256",
2573
+ name: "amount",
2574
+ type: "uint256"
2575
+ }
2576
+ ],
2577
+ name: "Approval",
2578
+ type: "event"
2579
+ },
2580
+ {
2581
+ anonymous: false,
2582
+ inputs: [
2583
+ {
2584
+ indexed: false,
2585
+ internalType: "address",
2586
+ name: "borrower",
2587
+ type: "address"
2588
+ },
2589
+ {
2590
+ indexed: false,
2591
+ internalType: "uint256",
2592
+ name: "borrowAmount",
2593
+ type: "uint256"
2594
+ },
2595
+ {
2596
+ indexed: false,
2597
+ internalType: "uint256",
2598
+ name: "accountBorrows",
2599
+ type: "uint256"
2600
+ },
2601
+ {
2602
+ indexed: false,
2603
+ internalType: "uint256",
2604
+ name: "totalBorrows",
2605
+ type: "uint256"
2606
+ }
2607
+ ],
2608
+ name: "Borrow",
2609
+ type: "event"
2610
+ },
2611
+ {
2612
+ anonymous: false,
2613
+ inputs: [
2614
+ {
2615
+ indexed: false,
2616
+ internalType: "uint256",
2617
+ name: "error",
2618
+ type: "uint256"
2619
+ },
2620
+ {
2621
+ indexed: false,
2622
+ internalType: "uint256",
2623
+ name: "info",
2624
+ type: "uint256"
2625
+ },
2626
+ {
2627
+ indexed: false,
2628
+ internalType: "uint256",
2629
+ name: "detail",
2630
+ type: "uint256"
2631
+ }
2632
+ ],
2633
+ name: "Failure",
2634
+ type: "event"
2635
+ },
2636
+ {
2637
+ anonymous: false,
2638
+ inputs: [
2639
+ {
2640
+ indexed: false,
2641
+ internalType: "address",
2642
+ name: "liquidator",
2643
+ type: "address"
2644
+ },
2645
+ {
2646
+ indexed: false,
2647
+ internalType: "address",
2648
+ name: "borrower",
2649
+ type: "address"
2650
+ },
2651
+ {
2652
+ indexed: false,
2653
+ internalType: "uint256",
2654
+ name: "repayAmount",
2655
+ type: "uint256"
2656
+ },
2657
+ {
2658
+ indexed: false,
2659
+ internalType: "address",
2660
+ name: "qiTokenCollateral",
2661
+ type: "address"
2662
+ },
2663
+ {
2664
+ indexed: false,
2665
+ internalType: "uint256",
2666
+ name: "seizeTokens",
2667
+ type: "uint256"
2668
+ }
2669
+ ],
2670
+ name: "LiquidateBorrow",
2671
+ type: "event"
2672
+ },
2673
+ {
2674
+ anonymous: false,
2675
+ inputs: [
2676
+ {
2677
+ indexed: false,
2678
+ internalType: "address",
2679
+ name: "minter",
2680
+ type: "address"
2681
+ },
2682
+ {
2683
+ indexed: false,
2684
+ internalType: "uint256",
2685
+ name: "mintAmount",
2686
+ type: "uint256"
2687
+ },
2688
+ {
2689
+ indexed: false,
2690
+ internalType: "uint256",
2691
+ name: "mintTokens",
2692
+ type: "uint256"
2693
+ }
2694
+ ],
2695
+ name: "Mint",
2696
+ type: "event"
2697
+ },
2698
+ {
2699
+ anonymous: false,
2700
+ inputs: [
2701
+ {
2702
+ indexed: false,
2703
+ internalType: "address",
2704
+ name: "oldAdmin",
2705
+ type: "address"
2706
+ },
2707
+ {
2708
+ indexed: false,
2709
+ internalType: "address",
2710
+ name: "newAdmin",
2711
+ type: "address"
2712
+ }
2713
+ ],
2714
+ name: "NewAdmin",
2715
+ type: "event"
2716
+ },
2717
+ {
2718
+ anonymous: false,
2719
+ inputs: [
2720
+ {
2721
+ indexed: false,
2722
+ internalType: "contract ComptrollerInterface",
2723
+ name: "oldComptroller",
2724
+ type: "address"
2725
+ },
2726
+ {
2727
+ indexed: false,
2728
+ internalType: "contract ComptrollerInterface",
2729
+ name: "newComptroller",
2730
+ type: "address"
2731
+ }
2732
+ ],
2733
+ name: "NewComptroller",
2734
+ type: "event"
2735
+ },
2736
+ {
2737
+ anonymous: false,
2738
+ inputs: [
2739
+ {
2740
+ indexed: false,
2741
+ internalType: "address",
2742
+ name: "oldImplementation",
2743
+ type: "address"
2744
+ },
2745
+ {
2746
+ indexed: false,
2747
+ internalType: "address",
2748
+ name: "newImplementation",
2749
+ type: "address"
2750
+ }
2751
+ ],
2752
+ name: "NewImplementation",
2753
+ type: "event"
2754
+ },
2755
+ {
2756
+ anonymous: false,
2757
+ inputs: [
2758
+ {
2759
+ indexed: false,
2760
+ internalType: "contract InterestRateModel",
2761
+ name: "oldInterestRateModel",
2762
+ type: "address"
2763
+ },
2764
+ {
2765
+ indexed: false,
2766
+ internalType: "contract InterestRateModel",
2767
+ name: "newInterestRateModel",
2768
+ type: "address"
2769
+ }
2770
+ ],
2771
+ name: "NewMarketInterestRateModel",
2772
+ type: "event"
2773
+ },
2774
+ {
2775
+ anonymous: false,
2776
+ inputs: [
2777
+ {
2778
+ indexed: false,
2779
+ internalType: "address",
2780
+ name: "oldPendingAdmin",
2781
+ type: "address"
2782
+ },
2783
+ {
2784
+ indexed: false,
2785
+ internalType: "address",
2786
+ name: "newPendingAdmin",
2787
+ type: "address"
2788
+ }
2789
+ ],
2790
+ name: "NewPendingAdmin",
2791
+ type: "event"
2792
+ },
2793
+ {
2794
+ anonymous: false,
2795
+ inputs: [
2796
+ {
2797
+ indexed: false,
2798
+ internalType: "uint256",
2799
+ name: "oldProtocolSeizeShareMantissa",
2800
+ type: "uint256"
2801
+ },
2802
+ {
2803
+ indexed: false,
2804
+ internalType: "uint256",
2805
+ name: "newProtocolSeizeShareMantissa",
2806
+ type: "uint256"
2807
+ }
2808
+ ],
2809
+ name: "NewProtocolSeizeShare",
2810
+ type: "event"
2811
+ },
2812
+ {
2813
+ anonymous: false,
2814
+ inputs: [
2815
+ {
2816
+ indexed: false,
2817
+ internalType: "uint256",
2818
+ name: "oldReserveFactorMantissa",
2819
+ type: "uint256"
2820
+ },
2821
+ {
2822
+ indexed: false,
2823
+ internalType: "uint256",
2824
+ name: "newReserveFactorMantissa",
2825
+ type: "uint256"
2826
+ }
2827
+ ],
2828
+ name: "NewReserveFactor",
2829
+ type: "event"
2830
+ },
2831
+ {
2832
+ anonymous: false,
2833
+ inputs: [
2834
+ {
2835
+ indexed: false,
2836
+ internalType: "address",
2837
+ name: "redeemer",
2838
+ type: "address"
2839
+ },
2840
+ {
2841
+ indexed: false,
2842
+ internalType: "uint256",
2843
+ name: "redeemAmount",
2844
+ type: "uint256"
2845
+ },
2846
+ {
2847
+ indexed: false,
2848
+ internalType: "uint256",
2849
+ name: "redeemTokens",
2850
+ type: "uint256"
2851
+ }
2852
+ ],
2853
+ name: "Redeem",
2854
+ type: "event"
2855
+ },
2856
+ {
2857
+ anonymous: false,
2858
+ inputs: [
2859
+ {
2860
+ indexed: false,
2861
+ internalType: "address",
2862
+ name: "payer",
2863
+ type: "address"
2864
+ },
2865
+ {
2866
+ indexed: false,
2867
+ internalType: "address",
2868
+ name: "borrower",
2869
+ type: "address"
2870
+ },
2871
+ {
2872
+ indexed: false,
2873
+ internalType: "uint256",
2874
+ name: "repayAmount",
2875
+ type: "uint256"
2876
+ },
2877
+ {
2878
+ indexed: false,
2879
+ internalType: "uint256",
2880
+ name: "accountBorrows",
2881
+ type: "uint256"
2882
+ },
2883
+ {
2884
+ indexed: false,
2885
+ internalType: "uint256",
2886
+ name: "totalBorrows",
2887
+ type: "uint256"
2888
+ }
2889
+ ],
2890
+ name: "RepayBorrow",
2891
+ type: "event"
2892
+ },
2893
+ {
2894
+ anonymous: false,
2895
+ inputs: [
2896
+ {
2897
+ indexed: false,
2898
+ internalType: "address",
2899
+ name: "benefactor",
2900
+ type: "address"
2901
+ },
2902
+ {
2903
+ indexed: false,
2904
+ internalType: "uint256",
2905
+ name: "addAmount",
2906
+ type: "uint256"
2907
+ },
2908
+ {
2909
+ indexed: false,
2910
+ internalType: "uint256",
2911
+ name: "newTotalReserves",
2912
+ type: "uint256"
2913
+ }
2914
+ ],
2915
+ name: "ReservesAdded",
2916
+ type: "event"
2917
+ },
2918
+ {
2919
+ anonymous: false,
2920
+ inputs: [
2921
+ {
2922
+ indexed: false,
2923
+ internalType: "address",
2924
+ name: "admin",
2925
+ type: "address"
2926
+ },
2927
+ {
2928
+ indexed: false,
2929
+ internalType: "uint256",
2930
+ name: "reduceAmount",
2931
+ type: "uint256"
2932
+ },
2933
+ {
2934
+ indexed: false,
2935
+ internalType: "uint256",
2936
+ name: "newTotalReserves",
2937
+ type: "uint256"
2938
+ }
2939
+ ],
2940
+ name: "ReservesReduced",
2941
+ type: "event"
2942
+ },
2943
+ {
2944
+ anonymous: false,
2945
+ inputs: [
2946
+ {
2947
+ indexed: true,
2948
+ internalType: "address",
2949
+ name: "from",
2950
+ type: "address"
2951
+ },
2952
+ {
2953
+ indexed: true,
2954
+ internalType: "address",
2955
+ name: "to",
2956
+ type: "address"
2957
+ },
2958
+ {
2959
+ indexed: false,
2960
+ internalType: "uint256",
2961
+ name: "amount",
2962
+ type: "uint256"
2963
+ }
2964
+ ],
2965
+ name: "Transfer",
2966
+ type: "event"
2967
+ },
2968
+ {
2969
+ payable: true,
2970
+ stateMutability: "payable",
2971
+ type: "fallback"
2972
+ },
2973
+ {
2974
+ constant: false,
2975
+ inputs: [
2976
+ ],
2977
+ name: "_acceptAdmin",
2978
+ outputs: [
2979
+ {
2980
+ internalType: "uint256",
2981
+ name: "",
2982
+ type: "uint256"
2983
+ }
2984
+ ],
2985
+ payable: false,
2986
+ stateMutability: "nonpayable",
2987
+ type: "function"
2988
+ },
2989
+ {
2990
+ constant: false,
2991
+ inputs: [
2992
+ {
2993
+ internalType: "uint256",
2994
+ name: "addAmount",
2995
+ type: "uint256"
2996
+ }
2997
+ ],
2998
+ name: "_addReserves",
2999
+ outputs: [
3000
+ {
3001
+ internalType: "uint256",
3002
+ name: "",
3003
+ type: "uint256"
3004
+ }
3005
+ ],
3006
+ payable: false,
3007
+ stateMutability: "nonpayable",
3008
+ type: "function"
3009
+ },
3010
+ {
3011
+ constant: false,
3012
+ inputs: [
3013
+ {
3014
+ internalType: "uint256",
3015
+ name: "reduceAmount",
3016
+ type: "uint256"
3017
+ }
3018
+ ],
3019
+ name: "_reduceReserves",
3020
+ outputs: [
3021
+ {
3022
+ internalType: "uint256",
3023
+ name: "",
3024
+ type: "uint256"
3025
+ }
3026
+ ],
3027
+ payable: false,
3028
+ stateMutability: "nonpayable",
3029
+ type: "function"
3030
+ },
3031
+ {
3032
+ constant: false,
3033
+ inputs: [
3034
+ {
3035
+ internalType: "contract ComptrollerInterface",
3036
+ name: "newComptroller",
3037
+ type: "address"
3038
+ }
3039
+ ],
3040
+ name: "_setComptroller",
3041
+ outputs: [
3042
+ {
3043
+ internalType: "uint256",
3044
+ name: "",
3045
+ type: "uint256"
3046
+ }
3047
+ ],
3048
+ payable: false,
3049
+ stateMutability: "nonpayable",
3050
+ type: "function"
3051
+ },
3052
+ {
3053
+ constant: false,
3054
+ inputs: [
3055
+ {
3056
+ internalType: "address",
3057
+ name: "implementation_",
3058
+ type: "address"
3059
+ },
3060
+ {
3061
+ internalType: "bool",
3062
+ name: "allowResign",
3063
+ type: "bool"
3064
+ },
3065
+ {
3066
+ internalType: "bytes",
3067
+ name: "becomeImplementationData",
3068
+ type: "bytes"
3069
+ }
3070
+ ],
3071
+ name: "_setImplementation",
3072
+ outputs: [
3073
+ ],
3074
+ payable: false,
3075
+ stateMutability: "nonpayable",
3076
+ type: "function"
3077
+ },
3078
+ {
3079
+ constant: false,
3080
+ inputs: [
3081
+ {
3082
+ internalType: "contract InterestRateModel",
3083
+ name: "newInterestRateModel",
3084
+ type: "address"
3085
+ }
3086
+ ],
3087
+ name: "_setInterestRateModel",
3088
+ outputs: [
3089
+ {
3090
+ internalType: "uint256",
3091
+ name: "",
3092
+ type: "uint256"
3093
+ }
3094
+ ],
3095
+ payable: false,
3096
+ stateMutability: "nonpayable",
3097
+ type: "function"
3098
+ },
3099
+ {
3100
+ constant: false,
3101
+ inputs: [
3102
+ {
3103
+ internalType: "address payable",
3104
+ name: "newPendingAdmin",
3105
+ type: "address"
3106
+ }
3107
+ ],
3108
+ name: "_setPendingAdmin",
3109
+ outputs: [
3110
+ {
3111
+ internalType: "uint256",
3112
+ name: "",
3113
+ type: "uint256"
3114
+ }
3115
+ ],
3116
+ payable: false,
3117
+ stateMutability: "nonpayable",
3118
+ type: "function"
3119
+ },
3120
+ {
3121
+ constant: false,
3122
+ inputs: [
3123
+ {
3124
+ internalType: "uint256",
3125
+ name: "newProtocolSeizeShareMantissa",
3126
+ type: "uint256"
3127
+ }
3128
+ ],
3129
+ name: "_setProtocolSeizeShare",
3130
+ outputs: [
3131
+ {
3132
+ internalType: "uint256",
3133
+ name: "",
3134
+ type: "uint256"
3135
+ }
3136
+ ],
3137
+ payable: false,
3138
+ stateMutability: "nonpayable",
3139
+ type: "function"
3140
+ },
3141
+ {
3142
+ constant: false,
3143
+ inputs: [
3144
+ {
3145
+ internalType: "uint256",
3146
+ name: "newReserveFactorMantissa",
3147
+ type: "uint256"
3148
+ }
3149
+ ],
3150
+ name: "_setReserveFactor",
3151
+ outputs: [
3152
+ {
3153
+ internalType: "uint256",
3154
+ name: "",
3155
+ type: "uint256"
3156
+ }
3157
+ ],
3158
+ payable: false,
3159
+ stateMutability: "nonpayable",
3160
+ type: "function"
3161
+ },
3162
+ {
3163
+ constant: true,
3164
+ inputs: [
3165
+ ],
3166
+ name: "accrualBlockTimestamp",
3167
+ outputs: [
3168
+ {
3169
+ internalType: "uint256",
3170
+ name: "",
3171
+ type: "uint256"
3172
+ }
3173
+ ],
3174
+ payable: false,
3175
+ stateMutability: "view",
3176
+ type: "function"
3177
+ },
3178
+ {
3179
+ constant: false,
3180
+ inputs: [
3181
+ ],
3182
+ name: "accrueInterest",
3183
+ outputs: [
3184
+ {
3185
+ internalType: "uint256",
3186
+ name: "",
3187
+ type: "uint256"
3188
+ }
3189
+ ],
3190
+ payable: false,
3191
+ stateMutability: "nonpayable",
3192
+ type: "function"
3193
+ },
3194
+ {
3195
+ constant: true,
3196
+ inputs: [
3197
+ ],
3198
+ name: "admin",
3199
+ outputs: [
3200
+ {
3201
+ internalType: "address payable",
3202
+ name: "",
3203
+ type: "address"
3204
+ }
3205
+ ],
3206
+ payable: false,
3207
+ stateMutability: "view",
3208
+ type: "function"
3209
+ },
3210
+ {
3211
+ constant: true,
3212
+ inputs: [
3213
+ {
3214
+ internalType: "address",
3215
+ name: "owner",
3216
+ type: "address"
3217
+ },
3218
+ {
3219
+ internalType: "address",
3220
+ name: "spender",
3221
+ type: "address"
3222
+ }
3223
+ ],
3224
+ name: "allowance",
3225
+ outputs: [
3226
+ {
3227
+ internalType: "uint256",
3228
+ name: "",
3229
+ type: "uint256"
3230
+ }
3231
+ ],
3232
+ payable: false,
3233
+ stateMutability: "view",
3234
+ type: "function"
3235
+ },
3236
+ {
3237
+ constant: false,
3238
+ inputs: [
3239
+ {
3240
+ internalType: "address",
3241
+ name: "spender",
3242
+ type: "address"
3243
+ },
3244
+ {
3245
+ internalType: "uint256",
3246
+ name: "amount",
3247
+ type: "uint256"
3248
+ }
3249
+ ],
3250
+ name: "approve",
3251
+ outputs: [
3252
+ {
3253
+ internalType: "bool",
3254
+ name: "",
3255
+ type: "bool"
3256
+ }
3257
+ ],
3258
+ payable: false,
3259
+ stateMutability: "nonpayable",
3260
+ type: "function"
3261
+ },
3262
+ {
3263
+ constant: true,
3264
+ inputs: [
3265
+ {
3266
+ internalType: "address",
3267
+ name: "owner",
3268
+ type: "address"
3269
+ }
3270
+ ],
3271
+ name: "balanceOf",
3272
+ outputs: [
3273
+ {
3274
+ internalType: "uint256",
3275
+ name: "",
3276
+ type: "uint256"
3277
+ }
3278
+ ],
3279
+ payable: false,
3280
+ stateMutability: "view",
3281
+ type: "function"
3282
+ },
3283
+ {
3284
+ constant: false,
3285
+ inputs: [
3286
+ {
3287
+ internalType: "address",
3288
+ name: "owner",
3289
+ type: "address"
3290
+ }
3291
+ ],
3292
+ name: "balanceOfUnderlying",
3293
+ outputs: [
3294
+ {
3295
+ internalType: "uint256",
3296
+ name: "",
3297
+ type: "uint256"
3298
+ }
3299
+ ],
3300
+ payable: false,
3301
+ stateMutability: "nonpayable",
3302
+ type: "function"
3303
+ },
3304
+ {
3305
+ constant: false,
3306
+ inputs: [
3307
+ {
3308
+ internalType: "uint256",
3309
+ name: "borrowAmount",
3310
+ type: "uint256"
3311
+ }
3312
+ ],
3313
+ name: "borrow",
3314
+ outputs: [
3315
+ {
3316
+ internalType: "uint256",
3317
+ name: "",
3318
+ type: "uint256"
3319
+ }
3320
+ ],
3321
+ payable: false,
3322
+ stateMutability: "nonpayable",
3323
+ type: "function"
3324
+ },
3325
+ {
3326
+ constant: false,
3327
+ inputs: [
3328
+ {
3329
+ internalType: "address",
3330
+ name: "account",
3331
+ type: "address"
3332
+ }
3333
+ ],
3334
+ name: "borrowBalanceCurrent",
3335
+ outputs: [
3336
+ {
3337
+ internalType: "uint256",
3338
+ name: "",
3339
+ type: "uint256"
3340
+ }
3341
+ ],
3342
+ payable: false,
3343
+ stateMutability: "nonpayable",
3344
+ type: "function"
3345
+ },
3346
+ {
3347
+ constant: true,
3348
+ inputs: [
3349
+ {
3350
+ internalType: "address",
3351
+ name: "account",
3352
+ type: "address"
3353
+ }
3354
+ ],
3355
+ name: "borrowBalanceStored",
3356
+ outputs: [
3357
+ {
3358
+ internalType: "uint256",
3359
+ name: "",
3360
+ type: "uint256"
3361
+ }
3362
+ ],
3363
+ payable: false,
3364
+ stateMutability: "view",
3365
+ type: "function"
3366
+ },
3367
+ {
3368
+ constant: true,
3369
+ inputs: [
3370
+ ],
3371
+ name: "borrowIndex",
3372
+ outputs: [
3373
+ {
3374
+ internalType: "uint256",
3375
+ name: "",
3376
+ type: "uint256"
3377
+ }
3378
+ ],
3379
+ payable: false,
3380
+ stateMutability: "view",
3381
+ type: "function"
3382
+ },
3383
+ {
3384
+ constant: true,
3385
+ inputs: [
3386
+ ],
3387
+ name: "borrowRatePerTimestamp",
3388
+ outputs: [
3389
+ {
3390
+ internalType: "uint256",
3391
+ name: "",
3392
+ type: "uint256"
3393
+ }
3394
+ ],
3395
+ payable: false,
3396
+ stateMutability: "view",
3397
+ type: "function"
3398
+ },
3399
+ {
3400
+ constant: true,
3401
+ inputs: [
3402
+ ],
3403
+ name: "comptroller",
3404
+ outputs: [
3405
+ {
3406
+ internalType: "contract ComptrollerInterface",
3407
+ name: "",
3408
+ type: "address"
3409
+ }
3410
+ ],
3411
+ payable: false,
3412
+ stateMutability: "view",
3413
+ type: "function"
3414
+ },
3415
+ {
3416
+ constant: true,
3417
+ inputs: [
3418
+ ],
3419
+ name: "decimals",
3420
+ outputs: [
3421
+ {
3422
+ internalType: "uint8",
3423
+ name: "",
3424
+ type: "uint8"
3425
+ }
3426
+ ],
3427
+ payable: false,
3428
+ stateMutability: "view",
3429
+ type: "function"
3430
+ },
3431
+ {
3432
+ constant: false,
3433
+ inputs: [
3434
+ {
3435
+ internalType: "bytes",
3436
+ name: "data",
3437
+ type: "bytes"
3438
+ }
3439
+ ],
3440
+ name: "delegateToImplementation",
3441
+ outputs: [
3442
+ {
3443
+ internalType: "bytes",
3444
+ name: "",
3445
+ type: "bytes"
3446
+ }
3447
+ ],
3448
+ payable: false,
3449
+ stateMutability: "nonpayable",
3450
+ type: "function"
3451
+ },
3452
+ {
3453
+ constant: true,
3454
+ inputs: [
3455
+ {
3456
+ internalType: "bytes",
3457
+ name: "data",
3458
+ type: "bytes"
3459
+ }
3460
+ ],
3461
+ name: "delegateToViewImplementation",
3462
+ outputs: [
3463
+ {
3464
+ internalType: "bytes",
3465
+ name: "",
3466
+ type: "bytes"
3467
+ }
3468
+ ],
3469
+ payable: false,
3470
+ stateMutability: "view",
3471
+ type: "function"
3472
+ },
3473
+ {
3474
+ constant: false,
3475
+ inputs: [
3476
+ ],
3477
+ name: "exchangeRateCurrent",
3478
+ outputs: [
3479
+ {
3480
+ internalType: "uint256",
3481
+ name: "",
3482
+ type: "uint256"
3483
+ }
3484
+ ],
3485
+ payable: false,
3486
+ stateMutability: "nonpayable",
3487
+ type: "function"
3488
+ },
3489
+ {
3490
+ constant: true,
3491
+ inputs: [
3492
+ ],
3493
+ name: "exchangeRateStored",
3494
+ outputs: [
3495
+ {
3496
+ internalType: "uint256",
3497
+ name: "",
3498
+ type: "uint256"
3499
+ }
3500
+ ],
3501
+ payable: false,
3502
+ stateMutability: "view",
3503
+ type: "function"
3504
+ },
3505
+ {
3506
+ constant: true,
3507
+ inputs: [
3508
+ {
3509
+ internalType: "address",
3510
+ name: "account",
3511
+ type: "address"
3512
+ }
3513
+ ],
3514
+ name: "getAccountSnapshot",
3515
+ outputs: [
3516
+ {
3517
+ internalType: "uint256",
3518
+ name: "",
3519
+ type: "uint256"
3520
+ },
3521
+ {
3522
+ internalType: "uint256",
3523
+ name: "",
3524
+ type: "uint256"
3525
+ },
3526
+ {
3527
+ internalType: "uint256",
3528
+ name: "",
3529
+ type: "uint256"
3530
+ },
3531
+ {
3532
+ internalType: "uint256",
3533
+ name: "",
3534
+ type: "uint256"
3535
+ }
3536
+ ],
3537
+ payable: false,
3538
+ stateMutability: "view",
3539
+ type: "function"
3540
+ },
3541
+ {
3542
+ constant: true,
3543
+ inputs: [
3544
+ ],
3545
+ name: "getCash",
3546
+ outputs: [
3547
+ {
3548
+ internalType: "uint256",
3549
+ name: "",
3550
+ type: "uint256"
3551
+ }
3552
+ ],
3553
+ payable: false,
3554
+ stateMutability: "view",
3555
+ type: "function"
3556
+ },
3557
+ {
3558
+ constant: true,
3559
+ inputs: [
3560
+ ],
3561
+ name: "implementation",
3562
+ outputs: [
3563
+ {
3564
+ internalType: "address",
3565
+ name: "",
3566
+ type: "address"
3567
+ }
3568
+ ],
3569
+ payable: false,
3570
+ stateMutability: "view",
3571
+ type: "function"
3572
+ },
3573
+ {
3574
+ constant: true,
3575
+ inputs: [
3576
+ ],
3577
+ name: "interestRateModel",
3578
+ outputs: [
3579
+ {
3580
+ internalType: "contract InterestRateModel",
3581
+ name: "",
3582
+ type: "address"
3583
+ }
3584
+ ],
3585
+ payable: false,
3586
+ stateMutability: "view",
3587
+ type: "function"
3588
+ },
3589
+ {
3590
+ constant: true,
3591
+ inputs: [
3592
+ ],
3593
+ name: "isQiToken",
3594
+ outputs: [
3595
+ {
3596
+ internalType: "bool",
3597
+ name: "",
3598
+ type: "bool"
3599
+ }
3600
+ ],
3601
+ payable: false,
3602
+ stateMutability: "view",
3603
+ type: "function"
3604
+ },
3605
+ {
3606
+ constant: false,
3607
+ inputs: [
3608
+ {
3609
+ internalType: "address",
3610
+ name: "borrower",
3611
+ type: "address"
3612
+ },
3613
+ {
3614
+ internalType: "uint256",
3615
+ name: "repayAmount",
3616
+ type: "uint256"
3617
+ },
3618
+ {
3619
+ internalType: "contract QiTokenInterface",
3620
+ name: "qiTokenCollateral",
3621
+ type: "address"
3622
+ }
3623
+ ],
3624
+ name: "liquidateBorrow",
3625
+ outputs: [
3626
+ {
3627
+ internalType: "uint256",
3628
+ name: "",
3629
+ type: "uint256"
3630
+ }
3631
+ ],
3632
+ payable: false,
3633
+ stateMutability: "nonpayable",
3634
+ type: "function"
3635
+ },
3636
+ {
3637
+ constant: false,
3638
+ inputs: [
3639
+ {
3640
+ internalType: "uint256",
3641
+ name: "mintAmount",
3642
+ type: "uint256"
3643
+ }
3644
+ ],
3645
+ name: "mint",
3646
+ outputs: [
3647
+ {
3648
+ internalType: "uint256",
3649
+ name: "",
3650
+ type: "uint256"
3651
+ }
3652
+ ],
3653
+ payable: false,
3654
+ stateMutability: "nonpayable",
3655
+ type: "function"
3656
+ },
3657
+ {
3658
+ constant: true,
3659
+ inputs: [
3660
+ ],
3661
+ name: "name",
3662
+ outputs: [
3663
+ {
3664
+ internalType: "string",
3665
+ name: "",
3666
+ type: "string"
3667
+ }
3668
+ ],
3669
+ payable: false,
3670
+ stateMutability: "view",
3671
+ type: "function"
3672
+ },
3673
+ {
3674
+ constant: true,
3675
+ inputs: [
3676
+ ],
3677
+ name: "pendingAdmin",
3678
+ outputs: [
3679
+ {
3680
+ internalType: "address payable",
3681
+ name: "",
3682
+ type: "address"
3683
+ }
3684
+ ],
3685
+ payable: false,
3686
+ stateMutability: "view",
3687
+ type: "function"
3688
+ },
3689
+ {
3690
+ constant: true,
3691
+ inputs: [
3692
+ ],
3693
+ name: "protocolSeizeShareMantissa",
3694
+ outputs: [
3695
+ {
3696
+ internalType: "uint256",
3697
+ name: "",
3698
+ type: "uint256"
3699
+ }
3700
+ ],
3701
+ payable: false,
3702
+ stateMutability: "view",
3703
+ type: "function"
3704
+ },
3705
+ {
3706
+ constant: false,
3707
+ inputs: [
3708
+ {
3709
+ internalType: "uint256",
3710
+ name: "redeemTokens",
3711
+ type: "uint256"
3712
+ }
3713
+ ],
3714
+ name: "redeem",
3715
+ outputs: [
3716
+ {
3717
+ internalType: "uint256",
3718
+ name: "",
3719
+ type: "uint256"
3720
+ }
3721
+ ],
3722
+ payable: false,
3723
+ stateMutability: "nonpayable",
3724
+ type: "function"
3725
+ },
3726
+ {
3727
+ constant: false,
3728
+ inputs: [
3729
+ {
3730
+ internalType: "uint256",
3731
+ name: "redeemAmount",
3732
+ type: "uint256"
3733
+ }
3734
+ ],
3735
+ name: "redeemUnderlying",
3736
+ outputs: [
3737
+ {
3738
+ internalType: "uint256",
3739
+ name: "",
3740
+ type: "uint256"
3741
+ }
3742
+ ],
3743
+ payable: false,
3744
+ stateMutability: "nonpayable",
3745
+ type: "function"
3746
+ },
3747
+ {
3748
+ constant: false,
3749
+ inputs: [
3750
+ {
3751
+ internalType: "uint256",
3752
+ name: "repayAmount",
3753
+ type: "uint256"
3754
+ }
3755
+ ],
3756
+ name: "repayBorrow",
3757
+ outputs: [
3758
+ {
3759
+ internalType: "uint256",
3760
+ name: "",
3761
+ type: "uint256"
3762
+ }
3763
+ ],
3764
+ payable: false,
3765
+ stateMutability: "nonpayable",
3766
+ type: "function"
3767
+ },
3768
+ {
3769
+ constant: false,
3770
+ inputs: [
3771
+ {
3772
+ internalType: "address",
3773
+ name: "borrower",
3774
+ type: "address"
3775
+ },
3776
+ {
3777
+ internalType: "uint256",
3778
+ name: "repayAmount",
3779
+ type: "uint256"
3780
+ }
3781
+ ],
3782
+ name: "repayBorrowBehalf",
3783
+ outputs: [
3784
+ {
3785
+ internalType: "uint256",
3786
+ name: "",
3787
+ type: "uint256"
3788
+ }
3789
+ ],
3790
+ payable: false,
3791
+ stateMutability: "nonpayable",
3792
+ type: "function"
3793
+ },
3794
+ {
3795
+ constant: true,
3796
+ inputs: [
3797
+ ],
3798
+ name: "reserveFactorMantissa",
3799
+ outputs: [
3800
+ {
3801
+ internalType: "uint256",
3802
+ name: "",
3803
+ type: "uint256"
3804
+ }
3805
+ ],
3806
+ payable: false,
3807
+ stateMutability: "view",
3808
+ type: "function"
3809
+ },
3810
+ {
3811
+ constant: false,
3812
+ inputs: [
3813
+ {
3814
+ internalType: "address",
3815
+ name: "liquidator",
3816
+ type: "address"
3817
+ },
3818
+ {
3819
+ internalType: "address",
3820
+ name: "borrower",
3821
+ type: "address"
3822
+ },
3823
+ {
3824
+ internalType: "uint256",
3825
+ name: "seizeTokens",
3826
+ type: "uint256"
3827
+ }
3828
+ ],
3829
+ name: "seize",
3830
+ outputs: [
3831
+ {
3832
+ internalType: "uint256",
3833
+ name: "",
3834
+ type: "uint256"
3835
+ }
3836
+ ],
3837
+ payable: false,
3838
+ stateMutability: "nonpayable",
3839
+ type: "function"
3840
+ },
3841
+ {
3842
+ constant: true,
3843
+ inputs: [
3844
+ ],
3845
+ name: "supplyRatePerTimestamp",
3846
+ outputs: [
3847
+ {
3848
+ internalType: "uint256",
3849
+ name: "",
3850
+ type: "uint256"
3851
+ }
3852
+ ],
3853
+ payable: false,
3854
+ stateMutability: "view",
3855
+ type: "function"
3856
+ },
3857
+ {
3858
+ constant: false,
3859
+ inputs: [
3860
+ {
3861
+ internalType: "contract EIP20NonStandardInterface",
3862
+ name: "token",
3863
+ type: "address"
3864
+ }
3865
+ ],
3866
+ name: "sweepToken",
3867
+ outputs: [
3868
+ ],
3869
+ payable: false,
3870
+ stateMutability: "nonpayable",
3871
+ type: "function"
3872
+ },
3873
+ {
3874
+ constant: true,
3875
+ inputs: [
3876
+ ],
3877
+ name: "symbol",
3878
+ outputs: [
3879
+ {
3880
+ internalType: "string",
3881
+ name: "",
3882
+ type: "string"
3883
+ }
3884
+ ],
3885
+ payable: false,
3886
+ stateMutability: "view",
3887
+ type: "function"
3888
+ },
3889
+ {
3890
+ constant: true,
3891
+ inputs: [
3892
+ ],
3893
+ name: "totalBorrows",
3894
+ outputs: [
3895
+ {
3896
+ internalType: "uint256",
3897
+ name: "",
3898
+ type: "uint256"
3899
+ }
3900
+ ],
3901
+ payable: false,
3902
+ stateMutability: "view",
3903
+ type: "function"
3904
+ },
3905
+ {
3906
+ constant: false,
3907
+ inputs: [
3908
+ ],
3909
+ name: "totalBorrowsCurrent",
3910
+ outputs: [
3911
+ {
3912
+ internalType: "uint256",
3913
+ name: "",
3914
+ type: "uint256"
3915
+ }
3916
+ ],
3917
+ payable: false,
3918
+ stateMutability: "nonpayable",
3919
+ type: "function"
3920
+ },
3921
+ {
3922
+ constant: true,
3923
+ inputs: [
3924
+ ],
3925
+ name: "totalReserves",
3926
+ outputs: [
3927
+ {
3928
+ internalType: "uint256",
3929
+ name: "",
3930
+ type: "uint256"
3931
+ }
3932
+ ],
3933
+ payable: false,
3934
+ stateMutability: "view",
3935
+ type: "function"
3936
+ },
3937
+ {
3938
+ constant: true,
3939
+ inputs: [
3940
+ ],
3941
+ name: "totalSupply",
3942
+ outputs: [
3943
+ {
3944
+ internalType: "uint256",
3945
+ name: "",
3946
+ type: "uint256"
3947
+ }
3948
+ ],
3949
+ payable: false,
3950
+ stateMutability: "view",
3951
+ type: "function"
3952
+ },
3953
+ {
3954
+ constant: false,
3955
+ inputs: [
3956
+ {
3957
+ internalType: "address",
3958
+ name: "dst",
3959
+ type: "address"
3960
+ },
3961
+ {
3962
+ internalType: "uint256",
3963
+ name: "amount",
3964
+ type: "uint256"
3965
+ }
3966
+ ],
3967
+ name: "transfer",
3968
+ outputs: [
3969
+ {
3970
+ internalType: "bool",
3971
+ name: "",
3972
+ type: "bool"
3973
+ }
3974
+ ],
3975
+ payable: false,
3976
+ stateMutability: "nonpayable",
3977
+ type: "function"
3978
+ },
3979
+ {
3980
+ constant: false,
3981
+ inputs: [
3982
+ {
3983
+ internalType: "address",
3984
+ name: "src",
3985
+ type: "address"
3986
+ },
3987
+ {
3988
+ internalType: "address",
3989
+ name: "dst",
3990
+ type: "address"
3991
+ },
3992
+ {
3993
+ internalType: "uint256",
3994
+ name: "amount",
3995
+ type: "uint256"
3996
+ }
3997
+ ],
3998
+ name: "transferFrom",
3999
+ outputs: [
4000
+ {
4001
+ internalType: "bool",
4002
+ name: "",
4003
+ type: "bool"
4004
+ }
4005
+ ],
4006
+ payable: false,
4007
+ stateMutability: "nonpayable",
4008
+ type: "function"
4009
+ },
4010
+ {
4011
+ constant: true,
4012
+ inputs: [
4013
+ ],
4014
+ name: "underlying",
4015
+ outputs: [
4016
+ {
4017
+ internalType: "address",
4018
+ name: "",
4019
+ type: "address"
4020
+ }
4021
+ ],
4022
+ payable: false,
4023
+ stateMutability: "view",
4024
+ type: "function"
4025
+ }
4026
+ ];
4027
+ var AuToken = {
4028
+ abi: abi$1
4029
+ };
4030
+
4031
+ function formatObject(object) {
4032
+ return JSON.stringify(object, null, ' ');
4033
+ }
4034
+ var decimalFactor = function decimalFactor(decimal) {
4035
+ return BigNumber$1.from(10).pow(decimal).toString();
4036
+ };
4037
+ function validateAndParseAddress(address) {
4038
+ try {
4039
+ return utils.getAddress(address);
4040
+ } catch (error) {
4041
+ throw new Error("Invalid address " + address);
4042
+ }
4043
+ }
4044
+
1201
4045
  var MoneyMarketRead = /*#__PURE__*/function (_BlockchainEntityRead) {
1202
4046
  _inheritsLoose(MoneyMarketRead, _BlockchainEntityRead);
1203
4047
 
@@ -1437,13 +4281,9 @@ var MoneyMarket = /*#__PURE__*/function (_BlockchainEntity) {
1437
4281
  return MoneyMarket;
1438
4282
  }(BlockchainEntity);
1439
4283
 
1440
- function formatObject(object) {
1441
- return JSON.stringify(object, null, ' ');
1442
- }
1443
-
1444
4284
  function sum(a, b) {
1445
4285
  return a + b;
1446
4286
  }
1447
4287
 
1448
- export { AVAX_DEFAULT_PROVIDER, AVAX_DEFAULT_PROVIDER_URL, AVAX_DEFAULT_SIGNER, BlockchainEntity, BlockchainEntityRead, BlockchainEntityReadWrite, DOLLAR, MoneyMarket, MoneyMarketRead, MoneyMarketReadWrite, SDK, SdkRead, SdkReadWrite, dummyMarketAddress, dummyPly, dummyPlyAurora, dummyToken, dummyTokenAmount, dummyTokenAmount2, dummyTokenAmount3, dummyUserMarketDetails, dummyZeroTokenAmount, formatObject, sum };
4288
+ export { AVAX_DEFAULT_PROVIDER, AVAX_DEFAULT_PROVIDER_URL, AVAX_DEFAULT_SIGNER, BlockchainEntity, BlockchainEntityRead, BlockchainEntityReadWrite, DOLLAR, MoneyMarket, MoneyMarketRead, MoneyMarketReadWrite, SDK, SdkRead, SdkReadWrite, decimalFactor, dummyMarketAddress, dummyPly, dummyPlyAurora, dummyToken, dummyTokenAmount, dummyTokenAmount2, dummyTokenAmount3, dummyUserMarketDetails, dummyZeroTokenAmount, formatObject, sum, validateAndParseAddress };
1449
4289
  //# sourceMappingURL=sdk.esm.js.map