@aurigami/sdk 1.12.0-beta1 → 1.12.0-beta3

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
@@ -111,7 +111,7 @@ var networkAddresses = {
111
111
  PLY_TOKEN_LOCK: /*#__PURE__*/MAINNET_ADDRESSES.plyTokenLock.toLowerCase(),
112
112
  REFERRAL: /*#__PURE__*/MAINNET_ADDRESSES.referralDirectory.toLowerCase(),
113
113
  AURI_INTERNAL_LENS: /*#__PURE__*/MAINNET_ADDRESSES.auriInternalLens.toLowerCase(),
114
- PLYGAME: /*#__PURE__*/'0x60bf668CA101060BD83BD644531a38719586B89f'.toLowerCase()
114
+ PLYGAME: /*#__PURE__*/MAINNET_ADDRESSES.plyGame.toLowerCase()
115
115
  },
116
116
  tokens: {
117
117
  AURORA: /*#__PURE__*/'0x8bec47865ade3b172a928df8f990bc7f2a3b9f79'.toLowerCase(),
@@ -1208,6 +1208,30 @@ var isSameAddress = function isSameAddress(address1, address2) {
1208
1208
  var getCurrentTimestamp = function getCurrentTimestamp() {
1209
1209
  return Math.trunc(Date.now() / 1000);
1210
1210
  };
1211
+ function sleep(_x) {
1212
+ return _sleep.apply(this, arguments);
1213
+ }
1214
+
1215
+ function _sleep() {
1216
+ _sleep = _asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee(duration) {
1217
+ return runtime_1.wrap(function _callee$(_context) {
1218
+ while (1) {
1219
+ switch (_context.prev = _context.next) {
1220
+ case 0:
1221
+ return _context.abrupt("return", new Promise(function (resolve) {
1222
+ setTimeout(resolve, duration);
1223
+ }));
1224
+
1225
+ case 1:
1226
+ case "end":
1227
+ return _context.stop();
1228
+ }
1229
+ }
1230
+ }, _callee);
1231
+ }));
1232
+ return _sleep.apply(this, arguments);
1233
+ }
1234
+
1211
1235
  function validateAndParseAddress(address) {
1212
1236
  try {
1213
1237
  return utils.getAddress(address);
@@ -1249,35 +1273,35 @@ function calcLMRewardApr(rewardsValue, totalStakeValue, frequencyPerYear) {
1249
1273
 
1250
1274
  return rewardsValue.multipliedBy(frequencyPerYear).dividedBy(totalStakeValue);
1251
1275
  }
1252
- function getBlockTimestamp(_x, _x2) {
1276
+ function getBlockTimestamp(_x2, _x3) {
1253
1277
  return _getBlockTimestamp.apply(this, arguments);
1254
1278
  }
1255
1279
 
1256
1280
  function _getBlockTimestamp() {
1257
- _getBlockTimestamp = _asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee(provider, blockNumber) {
1281
+ _getBlockTimestamp = _asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee2(provider, blockNumber) {
1258
1282
  var block;
1259
- return runtime_1.wrap(function _callee$(_context) {
1283
+ return runtime_1.wrap(function _callee2$(_context2) {
1260
1284
  while (1) {
1261
- switch (_context.prev = _context.next) {
1285
+ switch (_context2.prev = _context2.next) {
1262
1286
  case 0:
1263
- _context.next = 2;
1287
+ _context2.next = 2;
1264
1288
  return provider.getBlock(blockNumber);
1265
1289
 
1266
1290
  case 2:
1267
- block = _context.sent;
1268
- return _context.abrupt("return", block.timestamp);
1291
+ block = _context2.sent;
1292
+ return _context2.abrupt("return", block.timestamp);
1269
1293
 
1270
1294
  case 4:
1271
1295
  case "end":
1272
- return _context.stop();
1296
+ return _context2.stop();
1273
1297
  }
1274
1298
  }
1275
- }, _callee);
1299
+ }, _callee2);
1276
1300
  }));
1277
1301
  return _getBlockTimestamp.apply(this, arguments);
1278
1302
  }
1279
1303
 
1280
- function getBlocksTimestampViaRPC(_x3, _x4) {
1304
+ function getBlocksTimestampViaRPC(_x4, _x5) {
1281
1305
  return _getBlocksTimestampViaRPC.apply(this, arguments);
1282
1306
  }
1283
1307
  /**
@@ -1287,11 +1311,11 @@ function getBlocksTimestampViaRPC(_x3, _x4) {
1287
1311
  */
1288
1312
 
1289
1313
  function _getBlocksTimestampViaRPC() {
1290
- _getBlocksTimestampViaRPC = _asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee3(provider, blocksNumber) {
1314
+ _getBlocksTimestampViaRPC = _asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee4(provider, blocksNumber) {
1291
1315
  var CHUNK_SIZE, results, i, slice, promises;
1292
- return runtime_1.wrap(function _callee3$(_context3) {
1316
+ return runtime_1.wrap(function _callee4$(_context4) {
1293
1317
  while (1) {
1294
- switch (_context3.prev = _context3.next) {
1318
+ switch (_context4.prev = _context4.next) {
1295
1319
  case 0:
1296
1320
  // Promise all 200 blocks at a time, using too many blocks at once will cause the RPC call timeout.
1297
1321
  CHUNK_SIZE = 200;
@@ -1300,58 +1324,58 @@ function _getBlocksTimestampViaRPC() {
1300
1324
 
1301
1325
  case 3:
1302
1326
  if (!(i < blocksNumber.length)) {
1303
- _context3.next = 14;
1327
+ _context4.next = 14;
1304
1328
  break;
1305
1329
  }
1306
1330
 
1307
1331
  slice = blocksNumber.slice(i, i + CHUNK_SIZE);
1308
1332
  promises = slice.map( /*#__PURE__*/function () {
1309
- var _ref = _asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee2(blockNumber) {
1310
- return runtime_1.wrap(function _callee2$(_context2) {
1333
+ var _ref = _asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee3(blockNumber) {
1334
+ return runtime_1.wrap(function _callee3$(_context3) {
1311
1335
  while (1) {
1312
- switch (_context2.prev = _context2.next) {
1336
+ switch (_context3.prev = _context3.next) {
1313
1337
  case 0:
1314
- return _context2.abrupt("return", getBlockTimestamp(provider, blockNumber));
1338
+ return _context3.abrupt("return", getBlockTimestamp(provider, blockNumber));
1315
1339
 
1316
1340
  case 1:
1317
1341
  case "end":
1318
- return _context2.stop();
1342
+ return _context3.stop();
1319
1343
  }
1320
1344
  }
1321
- }, _callee2);
1345
+ }, _callee3);
1322
1346
  }));
1323
1347
 
1324
- return function (_x9) {
1348
+ return function (_x10) {
1325
1349
  return _ref.apply(this, arguments);
1326
1350
  };
1327
1351
  }());
1328
- _context3.t0 = results;
1329
- _context3.next = 9;
1352
+ _context4.t0 = results;
1353
+ _context4.next = 9;
1330
1354
  return Promise.all(promises);
1331
1355
 
1332
1356
  case 9:
1333
- _context3.t1 = _context3.sent;
1334
- results = _context3.t0.concat.call(_context3.t0, _context3.t1);
1357
+ _context4.t1 = _context4.sent;
1358
+ results = _context4.t0.concat.call(_context4.t0, _context4.t1);
1335
1359
 
1336
1360
  case 11:
1337
1361
  i += CHUNK_SIZE;
1338
- _context3.next = 3;
1362
+ _context4.next = 3;
1339
1363
  break;
1340
1364
 
1341
1365
  case 14:
1342
- return _context3.abrupt("return", results);
1366
+ return _context4.abrupt("return", results);
1343
1367
 
1344
1368
  case 15:
1345
1369
  case "end":
1346
- return _context3.stop();
1370
+ return _context4.stop();
1347
1371
  }
1348
1372
  }
1349
- }, _callee3);
1373
+ }, _callee4);
1350
1374
  }));
1351
1375
  return _getBlocksTimestampViaRPC.apply(this, arguments);
1352
1376
  }
1353
1377
 
1354
- function getBlocksTimestamp(_x5, _x6) {
1378
+ function getBlocksTimestamp(_x6, _x7) {
1355
1379
  return _getBlocksTimestamp.apply(this, arguments);
1356
1380
  }
1357
1381
  /**
@@ -1364,18 +1388,18 @@ function getBlocksTimestamp(_x5, _x6) {
1364
1388
  */
1365
1389
 
1366
1390
  function _getBlocksTimestamp() {
1367
- _getBlocksTimestamp = _asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee4(provider, blockNumbers) {
1391
+ _getBlocksTimestamp = _asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee5(provider, blockNumbers) {
1368
1392
  var CHUNK_SIZE, promises, lines, i, query, results, missingBlocks, missingBlocksTimestamps;
1369
- return runtime_1.wrap(function _callee4$(_context4) {
1393
+ return runtime_1.wrap(function _callee5$(_context5) {
1370
1394
  while (1) {
1371
- switch (_context4.prev = _context4.next) {
1395
+ switch (_context5.prev = _context5.next) {
1372
1396
  case 0:
1373
1397
  if (!(blockNumbers.length == 0)) {
1374
- _context4.next = 2;
1398
+ _context5.next = 2;
1375
1399
  break;
1376
1400
  }
1377
1401
 
1378
- return _context4.abrupt("return", []);
1402
+ return _context5.abrupt("return", []);
1379
1403
 
1380
1404
  case 2:
1381
1405
  CHUNK_SIZE = 100; // graphql query limit
@@ -1391,11 +1415,11 @@ function _getBlocksTimestamp() {
1391
1415
  } // merge all the json objects
1392
1416
 
1393
1417
 
1394
- _context4.next = 8;
1418
+ _context5.next = 8;
1395
1419
  return Promise.all(promises);
1396
1420
 
1397
1421
  case 8:
1398
- results = _context4.sent.reduce(function (acc, cur) {
1422
+ results = _context5.sent.reduce(function (acc, cur) {
1399
1423
  return _extends({}, acc, cur);
1400
1424
  });
1401
1425
  missingBlocks = blockNumbers.filter(function (blockNumber) {
@@ -1406,71 +1430,71 @@ function _getBlocksTimestamp() {
1406
1430
  devLog("These blocks are missing from Aurora GraphQL endpoint: " + missingBlocks.join(', '));
1407
1431
  }
1408
1432
 
1409
- _context4.next = 13;
1433
+ _context5.next = 13;
1410
1434
  return getBlocksTimestampViaRPC(provider, missingBlocks);
1411
1435
 
1412
1436
  case 13:
1413
- missingBlocksTimestamps = _context4.sent;
1437
+ missingBlocksTimestamps = _context5.sent;
1414
1438
  missingBlocksTimestamps.forEach(function (timestamp, index) {
1415
1439
  results["b" + missingBlocks[index]] = {
1416
1440
  timestamp: new Date(timestamp * 1000).toISOString()
1417
1441
  };
1418
1442
  });
1419
- return _context4.abrupt("return", blockNumbers.map(function (blockNumber) {
1443
+ return _context5.abrupt("return", blockNumbers.map(function (blockNumber) {
1420
1444
  return Math.trunc(new Date(results["b" + blockNumber].timestamp).getTime() / 1000);
1421
1445
  }));
1422
1446
 
1423
1447
  case 16:
1424
1448
  case "end":
1425
- return _context4.stop();
1449
+ return _context5.stop();
1426
1450
  }
1427
1451
  }
1428
- }, _callee4);
1452
+ }, _callee5);
1429
1453
  }));
1430
1454
  return _getBlocksTimestamp.apply(this, arguments);
1431
1455
  }
1432
1456
 
1433
- function getBlockBeforeTimestamp(_x7, _x8) {
1457
+ function getBlockBeforeTimestamp(_x8, _x9) {
1434
1458
  return _getBlockBeforeTimestamp.apply(this, arguments);
1435
1459
  }
1436
1460
 
1437
1461
  function _getBlockBeforeTimestamp() {
1438
- _getBlockBeforeTimestamp = _asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee5(provider, timestamp) {
1462
+ _getBlockBeforeTimestamp = _asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee6(provider, timestamp) {
1439
1463
  var result;
1440
- return runtime_1.wrap(function _callee5$(_context5) {
1464
+ return runtime_1.wrap(function _callee6$(_context6) {
1441
1465
  while (1) {
1442
- switch (_context5.prev = _context5.next) {
1466
+ switch (_context6.prev = _context6.next) {
1443
1467
  case 0:
1444
- _context5.next = 2;
1468
+ _context6.next = 2;
1445
1469
  return getQuery('block', 'getblocknobytime', {
1446
1470
  timestamp: timestamp,
1447
1471
  closest: 'before'
1448
1472
  });
1449
1473
 
1450
1474
  case 2:
1451
- result = _context5.sent;
1452
- _context5.t0 = parseInt(result);
1475
+ result = _context6.sent;
1476
+ _context6.t0 = parseInt(result);
1453
1477
 
1454
- if (_context5.t0) {
1455
- _context5.next = 8;
1478
+ if (_context6.t0) {
1479
+ _context6.next = 8;
1456
1480
  break;
1457
1481
  }
1458
1482
 
1459
- _context5.next = 7;
1483
+ _context6.next = 7;
1460
1484
  return provider.getBlockNumber();
1461
1485
 
1462
1486
  case 7:
1463
- _context5.t0 = _context5.sent;
1487
+ _context6.t0 = _context6.sent;
1464
1488
 
1465
1489
  case 8:
1466
- return _context5.abrupt("return", _context5.t0);
1490
+ return _context6.abrupt("return", _context6.t0);
1467
1491
 
1468
1492
  case 9:
1469
1493
  case "end":
1470
- return _context5.stop();
1494
+ return _context6.stop();
1471
1495
  }
1472
1496
  }
1473
- }, _callee5);
1497
+ }, _callee6);
1474
1498
  }));
1475
1499
  return _getBlockBeforeTimestamp.apply(this, arguments);
1476
1500
  }
@@ -1486,6 +1510,20 @@ function devLog(message) {
1486
1510
  (_console = console).log.apply(_console, ['[DEV LOG]', message].concat(optionalParams));
1487
1511
  }
1488
1512
  }
1513
+ /**
1514
+ * Sorts (in place) an array of Events by blocknumber.
1515
+ * This method mutates the array and returns a reference to the same array.
1516
+ **/
1517
+
1518
+ function sortEvents(events) {
1519
+ return events.sort(function (a, b) {
1520
+ if (a.blockNumber == b.blockNumber) {
1521
+ return a.logIndex - b.logIndex;
1522
+ }
1523
+
1524
+ return a.blockNumber - b.blockNumber;
1525
+ });
1526
+ }
1489
1527
 
1490
1528
  var BlockchainEntityRead = function BlockchainEntityRead(networkConnection) {
1491
1529
  this._networkConnection = networkConnection;
@@ -1750,21 +1788,23 @@ var dummyUserMarketDetails = {
1750
1788
  };
1751
1789
  var referralRewardDummy1 = {
1752
1790
  campaign: 'testa',
1753
- startTime: 1652882400,
1754
- endTime: 1653573599,
1791
+ startTime: /*#__PURE__*/Math.trunc( /*#__PURE__*/new Date(2022, 8, 1).getTime() / 1000),
1792
+ endTime: /*#__PURE__*/Math.trunc( /*#__PURE__*/new Date(2022, 9, 30).getTime() / 1000),
1755
1793
  isReferrer: false,
1756
1794
  rewardTokenAmount: dummyTokenAmount,
1757
1795
  transactionHash: null,
1758
- userAddr: '0x...123'
1796
+ userAddr: '0x...123',
1797
+ refereeAddress: '0x123..123'
1759
1798
  };
1760
1799
  var referralRewardDummy2 = {
1761
1800
  campaign: 'testb',
1762
- startTime: 1652882400,
1763
- endTime: 1653573599,
1801
+ startTime: /*#__PURE__*/Math.trunc( /*#__PURE__*/new Date(2022, 8, 1).getTime() / 1000),
1802
+ endTime: /*#__PURE__*/Math.trunc( /*#__PURE__*/new Date(2022, 8, 31).getTime() / 1000),
1764
1803
  isReferrer: true,
1765
1804
  rewardTokenAmount: dummyTokenAmount2,
1766
1805
  transactionHash: '0x4da9657663b46ef18d150b897b28c7b717f16421978b52e3a06d91b54ca3548b',
1767
- userAddr: '0x...456'
1806
+ userAddr: '0x...456',
1807
+ refereeAddress: '0x123..123'
1768
1808
  };
1769
1809
 
1770
1810
  var AURIGAMI_API_END_POINT = 'https://api.aurigami.finance/app/';
@@ -2584,6 +2624,7 @@ var helpers = {
2584
2624
  decimalFactor: decimalFactor,
2585
2625
  isSameAddress: isSameAddress,
2586
2626
  getCurrentTimestamp: getCurrentTimestamp,
2627
+ sleep: sleep,
2587
2628
  validateAndParseAddress: validateAndParseAddress,
2588
2629
  getDecimal: getDecimal,
2589
2630
  getSymbol: getSymbol,
@@ -2594,6 +2635,7 @@ var helpers = {
2594
2635
  getBlocksTimestamp: getBlocksTimestamp,
2595
2636
  getBlockBeforeTimestamp: getBlockBeforeTimestamp,
2596
2637
  devLog: devLog,
2638
+ sortEvents: sortEvents,
2597
2639
  fetchPriceFromCoingeckoAPI: fetchPriceFromCoingeckoAPI,
2598
2640
  fetchPriceFromCoingecko: fetchPriceFromCoingecko,
2599
2641
  fetchLPPositions: fetchLPPositions,
@@ -4648,11 +4690,14 @@ var PlyGameRead = /*#__PURE__*/function (_BlockchainEntityRead) {
4648
4690
 
4649
4691
  _proto.parseBetMakeEvent = function parseBetMakeEvent(event) {
4650
4692
  var outcome = ['bigWin', 'win', 'lose', 'noImpact'][event.args.outcome];
4651
- var amount = event.args.amount;
4652
- var unlock = amount.mul([10, 1, 0, 0][event.args.outcome]);
4693
+ var betAmount = event.args.amount; // 0%, 0%, 100%, 2%
4694
+ // big win, win, lose, no impact
4695
+
4696
+ var lostAmount = betAmount.mul([0, 0, 100, 2][event.args.outcome]).div(100);
4697
+ var unlock = betAmount.mul([10, 1, 0, 0][event.args.outcome]);
4653
4698
  return {
4654
4699
  player: event.args.player,
4655
- amount: new TokenAmount(this.plyToken, amount.toString()),
4700
+ lostAmount: new TokenAmount(this.plyToken, lostAmount.toString()),
4656
4701
  unlockedPulpAmount: new TokenAmount(this.pulpToken, unlock.toString()),
4657
4702
  outcome: outcome,
4658
4703
  transactionHash: event.transactionHash,
@@ -4732,11 +4777,13 @@ var PlyGameRead = /*#__PURE__*/function (_BlockchainEntityRead) {
4732
4777
 
4733
4778
  case 8:
4734
4779
  events = _context2.sent;
4780
+ // Sort descending by block number
4781
+ sortEvents(events).reverse();
4735
4782
  return _context2.abrupt("return", this.attachTimestamp(events.map(function (event) {
4736
4783
  return _this2.parseBetMakeEvent(event);
4737
4784
  })));
4738
4785
 
4739
- case 10:
4786
+ case 11:
4740
4787
  case "end":
4741
4788
  return _context2.stop();
4742
4789
  }
@@ -4786,49 +4833,26 @@ var PlyGameRead = /*#__PURE__*/function (_BlockchainEntityRead) {
4786
4833
  return currentJackpotAmount;
4787
4834
  }();
4788
4835
 
4789
- _proto.nextJackpotRevealTime = /*#__PURE__*/function () {
4790
- var _nextJackpotRevealTime = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee4() {
4791
- return runtime_1.wrap(function _callee4$(_context4) {
4792
- while (1) {
4793
- switch (_context4.prev = _context4.next) {
4794
- case 0:
4795
- return _context4.abrupt("return", 0);
4796
-
4797
- case 1:
4798
- case "end":
4799
- return _context4.stop();
4800
- }
4801
- }
4802
- }, _callee4);
4803
- }));
4804
-
4805
- function nextJackpotRevealTime() {
4806
- return _nextJackpotRevealTime.apply(this, arguments);
4807
- }
4808
-
4809
- return nextJackpotRevealTime;
4810
- }();
4811
-
4812
4836
  _proto.earlyUnlockedPulpAmount = /*#__PURE__*/function () {
4813
- var _earlyUnlockedPulpAmount = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee5(user) {
4837
+ var _earlyUnlockedPulpAmount = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee4(user) {
4814
4838
  var earlyUnlockedPulpAmount;
4815
- return runtime_1.wrap(function _callee5$(_context5) {
4839
+ return runtime_1.wrap(function _callee4$(_context4) {
4816
4840
  while (1) {
4817
- switch (_context5.prev = _context5.next) {
4841
+ switch (_context4.prev = _context4.next) {
4818
4842
  case 0:
4819
- _context5.next = 2;
4843
+ _context4.next = 2;
4820
4844
  return this.env.plygame.totalPlyUnlockedEarly(user);
4821
4845
 
4822
4846
  case 2:
4823
- earlyUnlockedPulpAmount = _context5.sent;
4824
- return _context5.abrupt("return", new TokenAmount(this.pulpToken, earlyUnlockedPulpAmount.toString()));
4847
+ earlyUnlockedPulpAmount = _context4.sent;
4848
+ return _context4.abrupt("return", new TokenAmount(this.pulpToken, earlyUnlockedPulpAmount.toString()));
4825
4849
 
4826
4850
  case 4:
4827
4851
  case "end":
4828
- return _context5.stop();
4852
+ return _context4.stop();
4829
4853
  }
4830
4854
  }
4831
- }, _callee5, this);
4855
+ }, _callee4, this);
4832
4856
  }));
4833
4857
 
4834
4858
  function earlyUnlockedPulpAmount(_x3) {
@@ -4839,19 +4863,51 @@ var PlyGameRead = /*#__PURE__*/function (_BlockchainEntityRead) {
4839
4863
  }();
4840
4864
 
4841
4865
  _proto.getPlyGameResultsInTransaction = /*#__PURE__*/function () {
4842
- var _getPlyGameResultsInTransaction = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee6(txHash) {
4866
+ var _getPlyGameResultsInTransaction = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee5(txHash) {
4843
4867
  var _this3 = this;
4844
4868
 
4845
- var tx, filter, betMadeEvents;
4846
- return runtime_1.wrap(function _callee6$(_context6) {
4869
+ var tx, i, filter, betMadeEvents;
4870
+ return runtime_1.wrap(function _callee5$(_context5) {
4847
4871
  while (1) {
4848
- switch (_context6.prev = _context6.next) {
4872
+ switch (_context5.prev = _context5.next) {
4849
4873
  case 0:
4850
- _context6.next = 2;
4874
+ _context5.next = 2;
4851
4875
  return this._networkConnection.provider.getTransactionReceipt(txHash);
4852
4876
 
4853
4877
  case 2:
4854
- tx = _context6.sent;
4878
+ tx = _context5.sent;
4879
+ i = 0;
4880
+
4881
+ case 4:
4882
+ if (!(i < 100 && !tx)) {
4883
+ _context5.next = 13;
4884
+ break;
4885
+ }
4886
+
4887
+ _context5.next = 7;
4888
+ return sleep(1000);
4889
+
4890
+ case 7:
4891
+ _context5.next = 9;
4892
+ return this._networkConnection.provider.getTransactionReceipt(txHash);
4893
+
4894
+ case 9:
4895
+ tx = _context5.sent;
4896
+
4897
+ case 10:
4898
+ i++;
4899
+ _context5.next = 4;
4900
+ break;
4901
+
4902
+ case 13:
4903
+ if (tx) {
4904
+ _context5.next = 15;
4905
+ break;
4906
+ }
4907
+
4908
+ throw new Error("Transaction " + txHash + " takes too long to be mined");
4909
+
4910
+ case 15:
4855
4911
  filter = this.env.plygame.filters.BetMade();
4856
4912
  betMadeEvents = tx.logs.filter(function (log) {
4857
4913
  return isSameAddress(log.topics[0], filter.topics[0]);
@@ -4861,16 +4917,16 @@ var PlyGameRead = /*#__PURE__*/function (_BlockchainEntityRead) {
4861
4917
  transactionHash: txHash
4862
4918
  });
4863
4919
  });
4864
- return _context6.abrupt("return", this.attachTimestamp(betMadeEvents.map(function (e) {
4920
+ return _context5.abrupt("return", this.attachTimestamp(betMadeEvents.map(function (e) {
4865
4921
  return _this3.parseBetMakeEvent(e);
4866
4922
  })));
4867
4923
 
4868
- case 6:
4924
+ case 18:
4869
4925
  case "end":
4870
- return _context6.stop();
4926
+ return _context5.stop();
4871
4927
  }
4872
4928
  }
4873
- }, _callee6, this);
4929
+ }, _callee5, this);
4874
4930
  }));
4875
4931
 
4876
4932
  function getPlyGameResultsInTransaction(_x4) {
@@ -4887,20 +4943,20 @@ var PlyGameRead = /*#__PURE__*/function (_BlockchainEntityRead) {
4887
4943
  _proto.leaderboard =
4888
4944
  /*#__PURE__*/
4889
4945
  function () {
4890
- var _leaderboard = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee7() {
4946
+ var _leaderboard = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee6() {
4891
4947
  var _this4 = this;
4892
4948
 
4893
4949
  var result;
4894
- return runtime_1.wrap(function _callee7$(_context7) {
4950
+ return runtime_1.wrap(function _callee6$(_context6) {
4895
4951
  while (1) {
4896
- switch (_context7.prev = _context7.next) {
4952
+ switch (_context6.prev = _context6.next) {
4897
4953
  case 0:
4898
- _context7.next = 2;
4954
+ _context6.next = 2;
4899
4955
  return getPaginatedApi('/plygame/leaderboard');
4900
4956
 
4901
4957
  case 2:
4902
- result = _context7.sent;
4903
- return _context7.abrupt("return", result.items.map(function (item, i) {
4958
+ result = _context6.sent;
4959
+ return _context6.abrupt("return", result.items.map(function (item, i) {
4904
4960
  return {
4905
4961
  player: item.user,
4906
4962
  unlockedPulpAmount: new TokenAmount(_this4.pulpToken, item.unlockedAmount),
@@ -4910,10 +4966,10 @@ var PlyGameRead = /*#__PURE__*/function (_BlockchainEntityRead) {
4910
4966
 
4911
4967
  case 4:
4912
4968
  case "end":
4913
- return _context7.stop();
4969
+ return _context6.stop();
4914
4970
  }
4915
4971
  }
4916
- }, _callee7);
4972
+ }, _callee6);
4917
4973
  }));
4918
4974
 
4919
4975
  function leaderboard() {
@@ -4934,57 +4990,28 @@ var PlyGameReadWrite = /*#__PURE__*/function (_PlyGameRead) {
4934
4990
 
4935
4991
  var _proto2 = PlyGameReadWrite.prototype;
4936
4992
 
4937
- /**
4938
- * makes "times" independent bets, but consecutively, of the same amount
4939
- */
4940
- _proto2.makeBetMultiple =
4941
- /*#__PURE__*/
4942
- function () {
4943
- var _makeBetMultiple = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee8(amount, times) {
4944
- return runtime_1.wrap(function _callee8$(_context8) {
4945
- while (1) {
4946
- switch (_context8.prev = _context8.next) {
4947
- case 0:
4948
- return _context8.abrupt("return", this.env.plygame.connect(this._networkConnection.signer).makeBetMultiple(amount.rawAmount(), times));
4949
-
4950
- case 1:
4951
- case "end":
4952
- return _context8.stop();
4953
- }
4954
- }
4955
- }, _callee8, this);
4956
- }));
4957
-
4958
- function makeBetMultiple(_x5, _x6) {
4959
- return _makeBetMultiple.apply(this, arguments);
4960
- }
4961
-
4962
- return makeBetMultiple;
4963
- }()
4964
4993
  /**
4965
4994
  * Make a single bet
4966
4995
  */
4967
- ;
4968
-
4969
4996
  _proto2.makeBetOnce =
4970
4997
  /*#__PURE__*/
4971
4998
  function () {
4972
- var _makeBetOnce = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee9(amount) {
4973
- return runtime_1.wrap(function _callee9$(_context9) {
4999
+ var _makeBetOnce = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee7(amount) {
5000
+ return runtime_1.wrap(function _callee7$(_context7) {
4974
5001
  while (1) {
4975
- switch (_context9.prev = _context9.next) {
5002
+ switch (_context7.prev = _context7.next) {
4976
5003
  case 0:
4977
- return _context9.abrupt("return", this.env.plygame.connect(this._networkConnection.signer).makeBetOnce(amount.rawAmount()));
5004
+ return _context7.abrupt("return", this.env.plygame.connect(this._networkConnection.signer).makeBetOnce(amount.rawAmount()));
4978
5005
 
4979
5006
  case 1:
4980
5007
  case "end":
4981
- return _context9.stop();
5008
+ return _context7.stop();
4982
5009
  }
4983
5010
  }
4984
- }, _callee9, this);
5011
+ }, _callee7, this);
4985
5012
  }));
4986
5013
 
4987
- function makeBetOnce(_x7) {
5014
+ function makeBetOnce(_x5) {
4988
5015
  return _makeBetOnce.apply(this, arguments);
4989
5016
  }
4990
5017
 
@@ -4992,22 +5019,22 @@ var PlyGameReadWrite = /*#__PURE__*/function (_PlyGameRead) {
4992
5019
  }();
4993
5020
 
4994
5021
  _proto2.approve = /*#__PURE__*/function () {
4995
- var _approve = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee10(amount) {
4996
- return runtime_1.wrap(function _callee10$(_context10) {
5022
+ var _approve = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee8(amount) {
5023
+ return runtime_1.wrap(function _callee8$(_context8) {
4997
5024
  while (1) {
4998
- switch (_context10.prev = _context10.next) {
5025
+ switch (_context8.prev = _context8.next) {
4999
5026
  case 0:
5000
- return _context10.abrupt("return", this.env.ply.connect(this._networkConnection.signer).approve(this.env.plygame.address, amount.rawAmount()));
5027
+ return _context8.abrupt("return", this.env.ply.connect(this._networkConnection.signer).approve(this.env.plygame.address, amount.rawAmount()));
5001
5028
 
5002
5029
  case 1:
5003
5030
  case "end":
5004
- return _context10.stop();
5031
+ return _context8.stop();
5005
5032
  }
5006
5033
  }
5007
- }, _callee10, this);
5034
+ }, _callee8, this);
5008
5035
  }));
5009
5036
 
5010
- function approve(_x8) {
5037
+ function approve(_x6) {
5011
5038
  return _approve.apply(this, arguments);
5012
5039
  }
5013
5040
 
@@ -5251,12 +5278,14 @@ var ReferralRead = /*#__PURE__*/function (_BlockchainEntityRead) {
5251
5278
  rewardTokenAmount: TokenAmount.fromAddressAndAmount(item.token, item.amount),
5252
5279
  startTime: REFERRAL_CAMPAIGNS[item.campaign].start,
5253
5280
  endTime: REFERRAL_CAMPAIGNS[item.campaign].end,
5254
- transactionHash: (_item$transactionHash = item.transactionHash) != null ? _item$transactionHash : null
5281
+ transactionHash: (_item$transactionHash = item.transactionHash) != null ? _item$transactionHash : null,
5282
+ refereeAddress: null
5255
5283
  };
5256
5284
  });
5285
+ items = [referralRewardDummy1, referralRewardDummy2].concat(items);
5257
5286
  return _context5.abrupt("return", items);
5258
5287
 
5259
- case 5:
5288
+ case 6:
5260
5289
  case "end":
5261
5290
  return _context5.stop();
5262
5291
  }
@@ -5299,7 +5328,8 @@ var ReferralRead = /*#__PURE__*/function (_BlockchainEntityRead) {
5299
5328
  rewardTokenAmount: TokenAmount.fromAddressAndAmount(item.token, item.amount),
5300
5329
  startTime: REFERRAL_CAMPAIGNS[item.campaign].start,
5301
5330
  endTime: REFERRAL_CAMPAIGNS[item.campaign].end,
5302
- transactionHash: null
5331
+ transactionHash: null,
5332
+ refereeAddress: null
5303
5333
  };
5304
5334
  });
5305
5335
  items.sort(function (a, b) {
@@ -5320,23 +5350,29 @@ var ReferralRead = /*#__PURE__*/function (_BlockchainEntityRead) {
5320
5350
  }
5321
5351
 
5322
5352
  return leaderboard;
5323
- }();
5353
+ }()
5354
+ /**
5355
+ * current number of slots under a referral code being used that exceed minimum deposit amount
5356
+ */
5357
+ ;
5324
5358
 
5325
- _proto.isWhitelistedAddress = /*#__PURE__*/function () {
5326
- var _isWhitelistedAddress = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee7(address) {
5359
+ _proto.slotsInUse =
5360
+ /*#__PURE__*/
5361
+ function () {
5362
+ var _slotsInUse = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee7(referralCode) {
5327
5363
  var result;
5328
5364
  return runtime_1.wrap(function _callee7$(_context7) {
5329
5365
  while (1) {
5330
5366
  switch (_context7.prev = _context7.next) {
5331
5367
  case 0:
5332
5368
  _context7.next = 2;
5333
- return getApi('/referral/whitelisted', {
5334
- address: address
5369
+ return getApi('/referral/slotsInUse', {
5370
+ referralCode: referralCode
5335
5371
  });
5336
5372
 
5337
5373
  case 2:
5338
5374
  result = _context7.sent;
5339
- return _context7.abrupt("return", result.isWhitelisted);
5375
+ return _context7.abrupt("return", result);
5340
5376
 
5341
5377
  case 4:
5342
5378
  case "end":
@@ -5346,7 +5382,95 @@ var ReferralRead = /*#__PURE__*/function (_BlockchainEntityRead) {
5346
5382
  }, _callee7);
5347
5383
  }));
5348
5384
 
5349
- function isWhitelistedAddress(_x7) {
5385
+ function slotsInUse(_x7) {
5386
+ return _slotsInUse.apply(this, arguments);
5387
+ }
5388
+
5389
+ return slotsInUse;
5390
+ }();
5391
+
5392
+ _proto.totalReferralSlots = function totalReferralSlots() {
5393
+ return 500;
5394
+ }
5395
+ /**
5396
+ * a way to determine qualification status of a user. null if not referred yet,
5397
+ * qualified if referred + min deposit, notQualified if referred + min deposit
5398
+ * not reached or withdrew too early
5399
+ */
5400
+ ;
5401
+
5402
+ _proto.userReferralStatus =
5403
+ /*#__PURE__*/
5404
+ function () {
5405
+ var _userReferralStatus = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee8(userAddr) {
5406
+ var result;
5407
+ return runtime_1.wrap(function _callee8$(_context8) {
5408
+ while (1) {
5409
+ switch (_context8.prev = _context8.next) {
5410
+ case 0:
5411
+ _context8.next = 2;
5412
+ return getApi('/referral/referralStatus', {
5413
+ address: userAddr
5414
+ });
5415
+
5416
+ case 2:
5417
+ result = _context8.sent;
5418
+ _context8.t0 = result;
5419
+ _context8.next = _context8.t0 === -1 ? 6 : _context8.t0 === 0 ? 7 : _context8.t0 === 1 ? 8 : 9;
5420
+ break;
5421
+
5422
+ case 6:
5423
+ return _context8.abrupt("return", 'notReferred');
5424
+
5425
+ case 7:
5426
+ return _context8.abrupt("return", 'notQualified');
5427
+
5428
+ case 8:
5429
+ return _context8.abrupt("return", 'Qualified');
5430
+
5431
+ case 9:
5432
+ return _context8.abrupt("return", 'Withdrawn');
5433
+
5434
+ case 10:
5435
+ case "end":
5436
+ return _context8.stop();
5437
+ }
5438
+ }
5439
+ }, _callee8);
5440
+ }));
5441
+
5442
+ function userReferralStatus(_x8) {
5443
+ return _userReferralStatus.apply(this, arguments);
5444
+ }
5445
+
5446
+ return userReferralStatus;
5447
+ }();
5448
+
5449
+ _proto.isWhitelistedAddress = /*#__PURE__*/function () {
5450
+ var _isWhitelistedAddress = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee9(address) {
5451
+ var result;
5452
+ return runtime_1.wrap(function _callee9$(_context9) {
5453
+ while (1) {
5454
+ switch (_context9.prev = _context9.next) {
5455
+ case 0:
5456
+ _context9.next = 2;
5457
+ return getApi('/referral/whitelisted', {
5458
+ address: address
5459
+ });
5460
+
5461
+ case 2:
5462
+ result = _context9.sent;
5463
+ return _context9.abrupt("return", result.isWhitelisted);
5464
+
5465
+ case 4:
5466
+ case "end":
5467
+ return _context9.stop();
5468
+ }
5469
+ }
5470
+ }, _callee9);
5471
+ }));
5472
+
5473
+ function isWhitelistedAddress(_x9) {
5350
5474
  return _isWhitelistedAddress.apply(this, arguments);
5351
5475
  }
5352
5476
 
@@ -5354,28 +5478,28 @@ var ReferralRead = /*#__PURE__*/function (_BlockchainEntityRead) {
5354
5478
  }();
5355
5479
 
5356
5480
  _proto.isOnAuroraPlus = /*#__PURE__*/function () {
5357
- var _isOnAuroraPlus = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee8(address) {
5481
+ var _isOnAuroraPlus = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee10(address) {
5358
5482
  var resp;
5359
- return runtime_1.wrap(function _callee8$(_context8) {
5483
+ return runtime_1.wrap(function _callee10$(_context10) {
5360
5484
  while (1) {
5361
- switch (_context8.prev = _context8.next) {
5485
+ switch (_context10.prev = _context10.next) {
5362
5486
  case 0:
5363
- _context8.next = 2;
5487
+ _context10.next = 2;
5364
5488
  return axios.get(AURORA_PLUS_API_PREFIX + address);
5365
5489
 
5366
5490
  case 2:
5367
- resp = _context8.sent;
5368
- return _context8.abrupt("return", resp.data.status == 'active');
5491
+ resp = _context10.sent;
5492
+ return _context10.abrupt("return", resp.data.status == 'active');
5369
5493
 
5370
5494
  case 4:
5371
5495
  case "end":
5372
- return _context8.stop();
5496
+ return _context10.stop();
5373
5497
  }
5374
5498
  }
5375
- }, _callee8);
5499
+ }, _callee10);
5376
5500
  }));
5377
5501
 
5378
- function isOnAuroraPlus(_x8) {
5502
+ function isOnAuroraPlus(_x10) {
5379
5503
  return _isOnAuroraPlus.apply(this, arguments);
5380
5504
  }
5381
5505
 
@@ -5401,21 +5525,21 @@ var ReferralReadWrite = /*#__PURE__*/function (_ReferralRead) {
5401
5525
  _proto2.registerNewReferralCode =
5402
5526
  /*#__PURE__*/
5403
5527
  function () {
5404
- var _registerNewReferralCode = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee9() {
5528
+ var _registerNewReferralCode = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee11() {
5405
5529
  var referralCode;
5406
- return runtime_1.wrap(function _callee9$(_context9) {
5530
+ return runtime_1.wrap(function _callee11$(_context11) {
5407
5531
  while (1) {
5408
- switch (_context9.prev = _context9.next) {
5532
+ switch (_context11.prev = _context11.next) {
5409
5533
  case 0:
5410
5534
  referralCode = ethers.utils.formatBytes32String(this.generateReferralCode());
5411
- return _context9.abrupt("return", this.env.referralDirectory.connect(this._networkConnection.signer).registerNewUserReferralCode(referralCode));
5535
+ return _context11.abrupt("return", this.env.referralDirectory.connect(this._networkConnection.signer).registerNewUserReferralCode(referralCode));
5412
5536
 
5413
5537
  case 2:
5414
5538
  case "end":
5415
- return _context9.stop();
5539
+ return _context11.stop();
5416
5540
  }
5417
5541
  }
5418
- }, _callee9, this);
5542
+ }, _callee11, this);
5419
5543
  }));
5420
5544
 
5421
5545
  function registerNewReferralCode() {
@@ -5432,24 +5556,24 @@ var ReferralReadWrite = /*#__PURE__*/function (_ReferralRead) {
5432
5556
  _proto2.useReferralCode =
5433
5557
  /*#__PURE__*/
5434
5558
  function () {
5435
- var _useReferralCode = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee10(code) {
5559
+ var _useReferralCode = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee12(code) {
5436
5560
  var referralCode;
5437
- return runtime_1.wrap(function _callee10$(_context10) {
5561
+ return runtime_1.wrap(function _callee12$(_context12) {
5438
5562
  while (1) {
5439
- switch (_context10.prev = _context10.next) {
5563
+ switch (_context12.prev = _context12.next) {
5440
5564
  case 0:
5441
5565
  referralCode = ethers.utils.formatBytes32String(code);
5442
- return _context10.abrupt("return", this.env.referralDirectory.connect(this._networkConnection.signer).registerReferralCodeUsed(referralCode));
5566
+ return _context12.abrupt("return", this.env.referralDirectory.connect(this._networkConnection.signer).registerReferralCodeUsed(referralCode));
5443
5567
 
5444
5568
  case 2:
5445
5569
  case "end":
5446
- return _context10.stop();
5570
+ return _context12.stop();
5447
5571
  }
5448
5572
  }
5449
- }, _callee10, this);
5573
+ }, _callee12, this);
5450
5574
  }));
5451
5575
 
5452
- function useReferralCode(_x9) {
5576
+ function useReferralCode(_x11) {
5453
5577
  return _useReferralCode.apply(this, arguments);
5454
5578
  }
5455
5579
 
@@ -5463,23 +5587,23 @@ var ReferralReadWrite = /*#__PURE__*/function (_ReferralRead) {
5463
5587
  _proto2.claimReferralRewards =
5464
5588
  /*#__PURE__*/
5465
5589
  function () {
5466
- var _claimReferralRewards = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee11() {
5590
+ var _claimReferralRewards = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee13() {
5467
5591
  var unclaimedRewards, campaigns, tokens;
5468
- return runtime_1.wrap(function _callee11$(_context11) {
5592
+ return runtime_1.wrap(function _callee13$(_context13) {
5469
5593
  while (1) {
5470
- switch (_context11.prev = _context11.next) {
5594
+ switch (_context13.prev = _context13.next) {
5471
5595
  case 0:
5472
- _context11.t0 = this;
5473
- _context11.next = 3;
5596
+ _context13.t0 = this;
5597
+ _context13.next = 3;
5474
5598
  return this._networkConnection.signer.getAddress();
5475
5599
 
5476
5600
  case 3:
5477
- _context11.t1 = _context11.sent;
5478
- _context11.next = 6;
5479
- return _context11.t0.referralRewards.call(_context11.t0, _context11.t1);
5601
+ _context13.t1 = _context13.sent;
5602
+ _context13.next = 6;
5603
+ return _context13.t0.referralRewards.call(_context13.t0, _context13.t1);
5480
5604
 
5481
5605
  case 6:
5482
- unclaimedRewards = _context11.sent.filter(function (reward) {
5606
+ unclaimedRewards = _context13.sent.filter(function (reward) {
5483
5607
  return reward.transactionHash == null;
5484
5608
  });
5485
5609
  campaigns = unclaimedRewards.map(function (reward) {
@@ -5488,14 +5612,14 @@ var ReferralReadWrite = /*#__PURE__*/function (_ReferralRead) {
5488
5612
  tokens = unclaimedRewards.map(function (reward) {
5489
5613
  return reward.rewardTokenAmount.token.address;
5490
5614
  });
5491
- return _context11.abrupt("return", new AirdropReadWrite(this._networkConnection).redeemMultiple(campaigns, tokens));
5615
+ return _context13.abrupt("return", new AirdropReadWrite(this._networkConnection).redeemMultiple(campaigns, tokens));
5492
5616
 
5493
5617
  case 10:
5494
5618
  case "end":
5495
- return _context11.stop();
5619
+ return _context13.stop();
5496
5620
  }
5497
5621
  }
5498
- }, _callee11, this);
5622
+ }, _callee13, this);
5499
5623
  }));
5500
5624
 
5501
5625
  function claimReferralRewards() {
@@ -5903,5 +6027,5 @@ BigNumber.config({
5903
6027
  DECIMAL_PLACES: 50
5904
6028
  });
5905
6029
 
5906
- export { AIRDROP_END_TIMESTAMP, AIRDROP_KEEP_THRESHOLD, AIRDROP_START_TIMESTAMP, ALL_STAKING_POOLS, AURORA_CHAINID, AURORA_PLUS_API_PREFIX, Airdrop, AirdropRead, AirdropReadWrite, AuriEnv, BORROW_LIMIT_BUFFER, BORROW_NEAR_REWARDS_PER_WEEK, BlockchainEntity, BlockchainEntityRead, BlockchainEntityReadWrite, ComptrollerRewardType, DECIMAL_PRECISION, DEPOSIT_NEAR_REWARDS_PER_WEEK, DEPOSIT_ONLY_TOKENS, ETHAddress, HARDCODE_PRICE_TOKENS, INF, MarketAction, MiscRead, MoneyMarket, MoneyMarketRead, MoneyMarketReadWrite, ONE_DAY, ONE_WEEK, ONE_YEAR, PLYToken, PLYWNEARToken, PLYWNEAR_POOL_ID, PLYWNEAR_REWARD_TOKENS, PRICE_WHITELISTED, Papermill, PapermillRead, PapermillReadWrite, PlyGame, PlyGameRead, PlyGameReadWrite, REFERRAL_CAMPAIGNS, REWARD_CLAIM_START, Referral, ReferralRead, ReferralReadWrite, SDK, SdkRead, SdkReadWrite, Staking, StakingRead, StakingReadWrite, Token, TokenAmount, TransferEventQuery, index as abis, assert, calcLMRewardApr, calcValuation, decimalFactor, decimalRecords, devLog, dummyAddress, dummyMarketAddress, dummyPly, dummyPlyAurora, dummyToken, dummyTokenAmount, dummyTokenAmount2, dummyTokenAmount3, dummyUserMarketDetails, dummyZeroTokenAmount, fetchLPPositions, fetchLPPrice, fetchPLYPrice, fetchPULPPrice, fetchPrice, fetchPriceFromCoingecko, fetchPriceFromCoingeckoAPI, fetchPriceFromOracle, fetchStNEARPrice, fetchToken0PriceByLP, fetchUnderlyingTokensPrices, fetchValuation, formatObject, getApi, getBlockBeforeTimestamp, getBlockTimestamp, getBlocksTimestamp, getBlocksTimestampViaRPC, getCurrentTimestamp, getDecimal, getPaginatedApi, getQuery, getSymbol, getUnderlying, isSameAddress, networkAddresses, queryGraphQL, referralRewardDummy1, referralRewardDummy2, symbolRecords, validateAndParseAddress, valuateToken };
6030
+ export { AIRDROP_END_TIMESTAMP, AIRDROP_KEEP_THRESHOLD, AIRDROP_START_TIMESTAMP, ALL_STAKING_POOLS, AURORA_CHAINID, AURORA_PLUS_API_PREFIX, Airdrop, AirdropRead, AirdropReadWrite, AuriEnv, BORROW_LIMIT_BUFFER, BORROW_NEAR_REWARDS_PER_WEEK, BlockchainEntity, BlockchainEntityRead, BlockchainEntityReadWrite, ComptrollerRewardType, DECIMAL_PRECISION, DEPOSIT_NEAR_REWARDS_PER_WEEK, DEPOSIT_ONLY_TOKENS, ETHAddress, HARDCODE_PRICE_TOKENS, INF, MarketAction, MiscRead, MoneyMarket, MoneyMarketRead, MoneyMarketReadWrite, ONE_DAY, ONE_WEEK, ONE_YEAR, PLYToken, PLYWNEARToken, PLYWNEAR_POOL_ID, PLYWNEAR_REWARD_TOKENS, PRICE_WHITELISTED, Papermill, PapermillRead, PapermillReadWrite, PlyGame, PlyGameRead, PlyGameReadWrite, REFERRAL_CAMPAIGNS, REWARD_CLAIM_START, Referral, ReferralRead, ReferralReadWrite, SDK, SdkRead, SdkReadWrite, Staking, StakingRead, StakingReadWrite, Token, TokenAmount, TransferEventQuery, index as abis, assert, calcLMRewardApr, calcValuation, decimalFactor, decimalRecords, devLog, dummyAddress, dummyMarketAddress, dummyPly, dummyPlyAurora, dummyToken, dummyTokenAmount, dummyTokenAmount2, dummyTokenAmount3, dummyUserMarketDetails, dummyZeroTokenAmount, fetchLPPositions, fetchLPPrice, fetchPLYPrice, fetchPULPPrice, fetchPrice, fetchPriceFromCoingecko, fetchPriceFromCoingeckoAPI, fetchPriceFromOracle, fetchStNEARPrice, fetchToken0PriceByLP, fetchUnderlyingTokensPrices, fetchValuation, formatObject, getApi, getBlockBeforeTimestamp, getBlockTimestamp, getBlocksTimestamp, getBlocksTimestampViaRPC, getCurrentTimestamp, getDecimal, getPaginatedApi, getQuery, getSymbol, getUnderlying, isSameAddress, networkAddresses, queryGraphQL, referralRewardDummy1, referralRewardDummy2, sleep, sortEvents, symbolRecords, validateAndParseAddress, valuateToken };
5907
6031
  //# sourceMappingURL=sdk.esm.js.map