@scallop-io/sui-scallop-sdk 1.4.19 → 1.4.20

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.
@@ -1,5 +1,5 @@
1
1
  import type { GetDynamicFieldObjectParams, GetDynamicFieldsParams, GetOwnedObjectsParams, SuiObjectData, SuiObjectDataOptions } from '@mysten/sui/client';
2
- import type { SuiObjectArg } from '@scallop-io/sui-kit';
2
+ import type { SuiObjectArg, SuiTxArg } from '@scallop-io/sui-kit';
3
3
  export declare const queryKeys: {
4
4
  api: {
5
5
  getAddresses: (addressesId?: string) => (string | {
@@ -39,7 +39,7 @@ export declare const queryKeys: {
39
39
  parentId: string | undefined;
40
40
  name: string;
41
41
  })[];
42
- getTotalVeScaTreasuryAmount: (refreshArgs?: any[], vescaAmountArgs?: (string | SuiObjectData)[]) => (string | {
42
+ getTotalVeScaTreasuryAmount: (refreshArgs?: any[], vescaAmountArgs?: (string | SuiObjectData | SuiTxArg)[]) => (string | {
43
43
  refreshArgs: string;
44
44
  vescaAmountArgs: string;
45
45
  })[];
package/dist/index.js CHANGED
@@ -2451,7 +2451,7 @@ var ScallopAddress = class {
2451
2451
  };
2452
2452
 
2453
2453
  // src/models/scallopClient.ts
2454
- var import_utils25 = require("@mysten/sui/utils");
2454
+ var import_utils24 = require("@mysten/sui/utils");
2455
2455
 
2456
2456
  // src/models/scallopUtils.ts
2457
2457
  var import_utils10 = require("@mysten/sui/utils");
@@ -4732,7 +4732,8 @@ var getObligationAccount = async (query, obligation, ownerAddress, indexer = fal
4732
4732
  };
4733
4733
  var getTotalValueLocked = async (query, indexer = false) => {
4734
4734
  const market = await query.getMarketPools(void 0, { indexer });
4735
- let supplyValue = (0, import_bignumber5.default)(0);
4735
+ let supplyLendingValue = (0, import_bignumber5.default)(0);
4736
+ let supplyCollateralValue = (0, import_bignumber5.default)(0);
4736
4737
  let borrowValue = (0, import_bignumber5.default)(0);
4737
4738
  if (indexer) {
4738
4739
  const tvlIndexer = await query.indexer.getTotalValueLocked();
@@ -4742,12 +4743,16 @@ var getTotalValueLocked = async (query, indexer = false) => {
4742
4743
  borrowValue: tvlIndexer.borrowValue,
4743
4744
  borrowValueChangeRatio: tvlIndexer.borrowValueChangeRatio,
4744
4745
  totalValue: tvlIndexer.totalValue,
4745
- totalValueChangeRatio: tvlIndexer.totalValueChangeRatio
4746
+ totalValueChangeRatio: tvlIndexer.totalValueChangeRatio,
4747
+ supplyLendingValue: tvlIndexer.supplyLendingValue,
4748
+ supplyLendingValueChangeRatio: tvlIndexer.supplyLendingValueChangeRatio,
4749
+ supplyCollateralValue: tvlIndexer.supplyCollateralValue,
4750
+ supplyCollateralValueChangeRatio: tvlIndexer.supplyCollateralValueChangeRatio
4746
4751
  };
4747
4752
  return tvl2;
4748
4753
  }
4749
4754
  for (const pool of Object.values(market.pools)) {
4750
- supplyValue = supplyValue.plus(
4755
+ supplyLendingValue = supplyLendingValue.plus(
4751
4756
  (0, import_bignumber5.default)(pool.supplyCoin).multipliedBy(pool.coinPrice)
4752
4757
  );
4753
4758
  borrowValue = borrowValue.plus(
@@ -4755,14 +4760,16 @@ var getTotalValueLocked = async (query, indexer = false) => {
4755
4760
  );
4756
4761
  }
4757
4762
  for (const collateral of Object.values(market.collaterals)) {
4758
- supplyValue = supplyValue.plus(
4763
+ supplyCollateralValue = supplyCollateralValue.plus(
4759
4764
  (0, import_bignumber5.default)(collateral.depositCoin).multipliedBy(collateral.coinPrice)
4760
4765
  );
4761
4766
  }
4762
4767
  const tvl = {
4763
- supplyValue: supplyValue.toNumber(),
4768
+ supplyValue: supplyLendingValue.plus(supplyCollateralValue).toNumber(),
4769
+ supplyLendingValue: supplyLendingValue.toNumber(),
4770
+ supplyCollateralValue: supplyCollateralValue.toNumber(),
4764
4771
  borrowValue: borrowValue.toNumber(),
4765
- totalValue: supplyValue.minus(borrowValue).toNumber()
4772
+ totalValue: supplyLendingValue.plus(supplyCollateralValue).minus(borrowValue).toNumber()
4766
4773
  };
4767
4774
  return tvl;
4768
4775
  };
@@ -5594,10 +5601,26 @@ var getTotalVeScaTreasuryAmount = async (utils, veScaTreasury) => {
5594
5601
  const veScaPkgId = utils.address.get("vesca.id");
5595
5602
  const veScaConfig = utils.address.get("vesca.config");
5596
5603
  veScaTreasury = veScaTreasury ?? utils.address.get("vesca.treasury");
5604
+ const txb = new import_sui_kit4.SuiTxBlock();
5597
5605
  const refreshQueryTarget = `${veScaPkgId}::treasury::refresh`;
5598
- const refreshArgs = [veScaConfig, veScaTreasury, import_sui_kit4.SUI_CLOCK_OBJECT_ID];
5606
+ const refreshArgs = [
5607
+ veScaConfig,
5608
+ veScaTreasury,
5609
+ txb.sharedObjectRef({
5610
+ objectId: import_sui_kit4.SUI_CLOCK_OBJECT_ID,
5611
+ mutable: false,
5612
+ initialSharedVersion: "1"
5613
+ })
5614
+ ];
5599
5615
  const veScaAmountQueryTarget = `${veScaPkgId}::treasury::total_ve_sca_amount`;
5600
- const veScaAmountArgs = [veScaTreasury, import_sui_kit4.SUI_CLOCK_OBJECT_ID];
5616
+ const veScaAmountArgs = [
5617
+ veScaTreasury,
5618
+ txb.sharedObjectRef({
5619
+ objectId: import_sui_kit4.SUI_CLOCK_OBJECT_ID,
5620
+ mutable: false,
5621
+ initialSharedVersion: "1"
5622
+ })
5623
+ ];
5601
5624
  const resolvedRefreshArgs = await Promise.all(
5602
5625
  refreshArgs.map(async (arg) => {
5603
5626
  if (typeof arg === "string") {
@@ -5614,7 +5637,6 @@ var getTotalVeScaTreasuryAmount = async (utils, veScaTreasury) => {
5614
5637
  return arg;
5615
5638
  })
5616
5639
  );
5617
- const txb = new import_sui_kit4.SuiTxBlock();
5618
5640
  txb.moveCall(refreshQueryTarget, resolvedRefreshArgs);
5619
5641
  txb.moveCall(veScaAmountQueryTarget, resolvedVeScaAmountArgs);
5620
5642
  const txBytes = await txb.txBlock.build({
@@ -6251,7 +6273,7 @@ var ScallopUtils = class {
6251
6273
  };
6252
6274
 
6253
6275
  // src/models/scallopBuilder.ts
6254
- var import_utils24 = require("@mysten/sui/utils");
6276
+ var import_utils23 = require("@mysten/sui/utils");
6255
6277
 
6256
6278
  // src/builders/coreBuilder.ts
6257
6279
  var import_transactions = require("@mysten/sui/transactions");
@@ -6375,27 +6397,67 @@ var priceUpdateRequest = (txBlock, packageId, xOracleId, coinType) => {
6375
6397
  var confirmPriceUpdateRequest = (txBlock, packageId, xOracleId, request, coinType) => {
6376
6398
  const target = `${packageId}::x_oracle::confirm_price_update_request`;
6377
6399
  const typeArgs = [coinType];
6378
- txBlock.moveCall(target, [xOracleId, request, import_utils12.SUI_CLOCK_OBJECT_ID], typeArgs);
6400
+ txBlock.moveCall(
6401
+ target,
6402
+ [
6403
+ xOracleId,
6404
+ request,
6405
+ txBlock.sharedObjectRef({
6406
+ objectId: import_utils12.SUI_CLOCK_OBJECT_ID,
6407
+ mutable: false,
6408
+ initialSharedVersion: "1"
6409
+ })
6410
+ ],
6411
+ typeArgs
6412
+ );
6379
6413
  return txBlock;
6380
6414
  };
6381
6415
  var updateSupraPrice = (txBlock, packageId, request, holderId, registryId, coinType) => {
6382
6416
  txBlock.moveCall(
6383
6417
  `${packageId}::rule::set_price`,
6384
- [request, holderId, registryId, import_utils12.SUI_CLOCK_OBJECT_ID],
6418
+ [
6419
+ request,
6420
+ holderId,
6421
+ registryId,
6422
+ txBlock.sharedObjectRef({
6423
+ objectId: import_utils12.SUI_CLOCK_OBJECT_ID,
6424
+ mutable: false,
6425
+ initialSharedVersion: "1"
6426
+ })
6427
+ ],
6385
6428
  [coinType]
6386
6429
  );
6387
6430
  };
6388
6431
  var updateSwitchboardPrice = (txBlock, packageId, request, aggregatorId, registryId, coinType) => {
6389
6432
  txBlock.moveCall(
6390
6433
  `${packageId}::rule::set_price`,
6391
- [request, aggregatorId, registryId, import_utils12.SUI_CLOCK_OBJECT_ID],
6434
+ [
6435
+ request,
6436
+ aggregatorId,
6437
+ registryId,
6438
+ txBlock.sharedObjectRef({
6439
+ objectId: import_utils12.SUI_CLOCK_OBJECT_ID,
6440
+ mutable: false,
6441
+ initialSharedVersion: "1"
6442
+ })
6443
+ ],
6392
6444
  [coinType]
6393
6445
  );
6394
6446
  };
6395
6447
  var updatePythPrice = (txBlock, packageId, request, stateId, feedObjectId, registryId, coinType) => {
6396
6448
  txBlock.moveCall(
6397
6449
  `${packageId}::rule::set_price`,
6398
- [request, stateId, feedObjectId, registryId, import_utils12.SUI_CLOCK_OBJECT_ID],
6450
+ [
6451
+ request,
6452
+ stateId,
6453
+ feedObjectId,
6454
+ registryId,
6455
+ txBlock.sharedObjectRef({
6456
+ objectId: import_utils12.SUI_CLOCK_OBJECT_ID,
6457
+ mutable: false,
6458
+ initialSharedVersion: "1"
6459
+ })
6460
+ ],
6399
6461
  [coinType]
6400
6462
  );
6401
6463
  };
@@ -6475,7 +6537,11 @@ var generateCoreNormalMethod = ({
6475
6537
  coreIds.coinDecimalsRegistry,
6476
6538
  txBlock.pure.u64(amount),
6477
6539
  coreIds.xOracle,
6478
- import_utils13.SUI_CLOCK_OBJECT_ID
6540
+ txBlock.sharedObjectRef({
6541
+ objectId: import_utils13.SUI_CLOCK_OBJECT_ID,
6542
+ mutable: false,
6543
+ initialSharedVersion: "1"
6544
+ })
6479
6545
  ],
6480
6546
  [coinType]
6481
6547
  );
@@ -6485,7 +6551,16 @@ var generateCoreNormalMethod = ({
6485
6551
  return builder.moveCall(
6486
6552
  txBlock,
6487
6553
  `${coreIds.protocolPkg}::mint::mint`,
6488
- [coreIds.version, coreIds.market, coin, import_utils13.SUI_CLOCK_OBJECT_ID],
6554
+ [
6555
+ coreIds.version,
6556
+ coreIds.market,
6557
+ coin,
6558
+ txBlock.sharedObjectRef({
6559
+ objectId: import_utils13.SUI_CLOCK_OBJECT_ID,
6560
+ mutable: false,
6561
+ initialSharedVersion: "1"
6562
+ })
6563
+ ],
6489
6564
  [coinType]
6490
6565
  );
6491
6566
  },
@@ -6494,7 +6569,16 @@ var generateCoreNormalMethod = ({
6494
6569
  return builder.moveCall(
6495
6570
  txBlock,
6496
6571
  `${coreIds.protocolPkg}::mint::mint_entry`,
6497
- [coreIds.version, coreIds.market, coin, import_utils13.SUI_CLOCK_OBJECT_ID],
6572
+ [
6573
+ coreIds.version,
6574
+ coreIds.market,
6575
+ coin,
6576
+ txBlock.sharedObjectRef({
6577
+ objectId: import_utils13.SUI_CLOCK_OBJECT_ID,
6578
+ mutable: false,
6579
+ initialSharedVersion: "1"
6580
+ })
6581
+ ],
6498
6582
  [coinType]
6499
6583
  );
6500
6584
  },
@@ -6503,7 +6587,16 @@ var generateCoreNormalMethod = ({
6503
6587
  return builder.moveCall(
6504
6588
  txBlock,
6505
6589
  `${coreIds.protocolPkg}::redeem::redeem`,
6506
- [coreIds.version, coreIds.market, marketCoin, import_utils13.SUI_CLOCK_OBJECT_ID],
6590
+ [
6591
+ coreIds.version,
6592
+ coreIds.market,
6593
+ marketCoin,
6594
+ txBlock.sharedObjectRef({
6595
+ objectId: import_utils13.SUI_CLOCK_OBJECT_ID,
6596
+ mutable: false,
6597
+ initialSharedVersion: "1"
6598
+ })
6599
+ ],
6507
6600
  [coinType]
6508
6601
  );
6509
6602
  },
@@ -6512,7 +6605,16 @@ var generateCoreNormalMethod = ({
6512
6605
  return builder.moveCall(
6513
6606
  txBlock,
6514
6607
  `${coreIds.protocolPkg}::redeem::redeem_entry`,
6515
- [coreIds.version, coreIds.market, marketCoin, import_utils13.SUI_CLOCK_OBJECT_ID],
6608
+ [
6609
+ coreIds.version,
6610
+ coreIds.market,
6611
+ marketCoin,
6612
+ txBlock.sharedObjectRef({
6613
+ objectId: import_utils13.SUI_CLOCK_OBJECT_ID,
6614
+ mutable: false,
6615
+ initialSharedVersion: "1"
6616
+ })
6617
+ ],
6516
6618
  [coinType]
6517
6619
  );
6518
6620
  },
@@ -6529,7 +6631,11 @@ var generateCoreNormalMethod = ({
6529
6631
  coreIds.coinDecimalsRegistry,
6530
6632
  amount,
6531
6633
  coreIds.xOracle,
6532
- import_utils13.SUI_CLOCK_OBJECT_ID
6634
+ txBlock.sharedObjectRef({
6635
+ objectId: import_utils13.SUI_CLOCK_OBJECT_ID,
6636
+ mutable: false,
6637
+ initialSharedVersion: "1"
6638
+ })
6533
6639
  ],
6534
6640
  [coinType]
6535
6641
  );
@@ -6548,7 +6654,11 @@ var generateCoreNormalMethod = ({
6548
6654
  borrowReferral,
6549
6655
  typeof amount === "number" ? txBlock.pure.u64(amount) : amount,
6550
6656
  coreIds.xOracle,
6551
- import_utils13.SUI_CLOCK_OBJECT_ID
6657
+ txBlock.sharedObjectRef({
6658
+ objectId: import_utils13.SUI_CLOCK_OBJECT_ID,
6659
+ mutable: false,
6660
+ initialSharedVersion: "1"
6661
+ })
6552
6662
  ],
6553
6663
  [coinType, referralWitnessType]
6554
6664
  );
@@ -6566,7 +6676,11 @@ var generateCoreNormalMethod = ({
6566
6676
  coreIds.coinDecimalsRegistry,
6567
6677
  txBlock.pure.u64(amount),
6568
6678
  coreIds.xOracle,
6569
- import_utils13.SUI_CLOCK_OBJECT_ID
6679
+ txBlock.sharedObjectRef({
6680
+ objectId: import_utils13.SUI_CLOCK_OBJECT_ID,
6681
+ mutable: false,
6682
+ initialSharedVersion: "1"
6683
+ })
6570
6684
  ],
6571
6685
  [coinType]
6572
6686
  );
@@ -6581,7 +6695,11 @@ var generateCoreNormalMethod = ({
6581
6695
  obligation,
6582
6696
  coreIds.market,
6583
6697
  coin,
6584
- import_utils13.SUI_CLOCK_OBJECT_ID
6698
+ txBlock.sharedObjectRef({
6699
+ objectId: import_utils13.SUI_CLOCK_OBJECT_ID,
6700
+ mutable: false,
6701
+ initialSharedVersion: "1"
6702
+ })
6585
6703
  ],
6586
6704
  [coinType]
6587
6705
  );
@@ -6746,7 +6864,7 @@ var generateCoreQuickMethod = ({
6746
6864
  ) ?? [];
6747
6865
  const updateCoinNames = [...obligationCoinNames, poolCoinName];
6748
6866
  await updateOracles(builder, txBlock, updateCoinNames);
6749
- return await txBlock.borrowWithReferral(
6867
+ return txBlock.borrowWithReferral(
6750
6868
  obligationInfo.obligationId,
6751
6869
  obligationInfo.obligationKey,
6752
6870
  borrowReferral,
@@ -6874,7 +6992,14 @@ var generateSpoolNormalMethod = ({
6874
6992
  return builder.moveCall(
6875
6993
  txBlock,
6876
6994
  `${spoolIds.spoolPkg}::user::new_spool_account`,
6877
- [stakePoolId, import_utils15.SUI_CLOCK_OBJECT_ID],
6995
+ [
6996
+ stakePoolId,
6997
+ txBlock.sharedObjectRef({
6998
+ objectId: import_utils15.SUI_CLOCK_OBJECT_ID,
6999
+ mutable: false,
7000
+ initialSharedVersion: "1"
7001
+ })
7002
+ ],
6878
7003
  [marketCoinType]
6879
7004
  );
6880
7005
  },
@@ -6886,7 +7011,16 @@ var generateSpoolNormalMethod = ({
6886
7011
  builder.moveCall(
6887
7012
  txBlock,
6888
7013
  `${spoolIds.spoolPkg}::user::stake`,
6889
- [stakePoolId, stakeAccount, coin, import_utils15.SUI_CLOCK_OBJECT_ID],
7014
+ [
7015
+ stakePoolId,
7016
+ stakeAccount,
7017
+ coin,
7018
+ txBlock.sharedObjectRef({
7019
+ objectId: import_utils15.SUI_CLOCK_OBJECT_ID,
7020
+ mutable: false,
7021
+ initialSharedVersion: "1"
7022
+ })
7023
+ ],
6890
7024
  [marketCoinType]
6891
7025
  );
6892
7026
  },
@@ -6898,7 +7032,16 @@ var generateSpoolNormalMethod = ({
6898
7032
  return builder.moveCall(
6899
7033
  txBlock,
6900
7034
  `${spoolIds.spoolPkg}::user::unstake`,
6901
- [stakePoolId, stakeAccount, amount, import_utils15.SUI_CLOCK_OBJECT_ID],
7035
+ [
7036
+ stakePoolId,
7037
+ stakeAccount,
7038
+ amount,
7039
+ txBlock.sharedObjectRef({
7040
+ objectId: import_utils15.SUI_CLOCK_OBJECT_ID,
7041
+ mutable: false,
7042
+ initialSharedVersion: "1"
7043
+ })
7044
+ ],
6902
7045
  [marketCoinType]
6903
7046
  );
6904
7047
  },
@@ -6915,7 +7058,16 @@ var generateSpoolNormalMethod = ({
6915
7058
  return builder.moveCall(
6916
7059
  txBlock,
6917
7060
  `${spoolIds.spoolPkg}::user::redeem_rewards`,
6918
- [stakePoolId, rewardPoolId, stakeAccount, import_utils15.SUI_CLOCK_OBJECT_ID],
7061
+ [
7062
+ stakePoolId,
7063
+ rewardPoolId,
7064
+ stakeAccount,
7065
+ txBlock.sharedObjectRef({
7066
+ objectId: import_utils15.SUI_CLOCK_OBJECT_ID,
7067
+ mutable: false,
7068
+ initialSharedVersion: "1"
7069
+ })
7070
+ ],
6919
7071
  [marketCoinType, rewardCoinType]
6920
7072
  );
6921
7073
  }
@@ -7050,7 +7202,6 @@ var newSpoolTxBlock = (builder, initTxBlock) => {
7050
7202
 
7051
7203
  // src/builders/borrowIncentiveBuilder.ts
7052
7204
  var import_transactions3 = require("@mysten/sui/transactions");
7053
- var import_utils17 = require("@mysten/sui/utils");
7054
7205
  var import_sui_kit7 = require("@scallop-io/sui-kit");
7055
7206
  var requireObligationInfo2 = async (...params) => {
7056
7207
  const [builder, txBlock, obligationId, obligationKey] = params;
@@ -7103,7 +7254,11 @@ var generateBorrowIncentiveNormalMethod = ({ builder, txBlock }) => {
7103
7254
  obligationKey,
7104
7255
  obligationId,
7105
7256
  borrowIncentiveIds.obligationAccessStore,
7106
- import_utils17.SUI_CLOCK_OBJECT_ID
7257
+ txBlock.sharedObjectRef({
7258
+ objectId: import_sui_kit7.SUI_CLOCK_OBJECT_ID,
7259
+ mutable: false,
7260
+ initialSharedVersion: "1"
7261
+ })
7107
7262
  ]
7108
7263
  );
7109
7264
  },
@@ -7122,7 +7277,11 @@ var generateBorrowIncentiveNormalMethod = ({ builder, txBlock }) => {
7122
7277
  veScaIds.treasury,
7123
7278
  veScaIds.table,
7124
7279
  veScaKey,
7125
- import_utils17.SUI_CLOCK_OBJECT_ID
7280
+ txBlock.sharedObjectRef({
7281
+ objectId: import_sui_kit7.SUI_CLOCK_OBJECT_ID,
7282
+ mutable: false,
7283
+ initialSharedVersion: "1"
7284
+ })
7126
7285
  ],
7127
7286
  []
7128
7287
  );
@@ -7137,7 +7296,11 @@ var generateBorrowIncentiveNormalMethod = ({ builder, txBlock }) => {
7137
7296
  borrowIncentiveIds.incentiveAccounts,
7138
7297
  obligationKey,
7139
7298
  obligationId,
7140
- import_utils17.SUI_CLOCK_OBJECT_ID
7299
+ txBlock.sharedObjectRef({
7300
+ objectId: import_sui_kit7.SUI_CLOCK_OBJECT_ID,
7301
+ mutable: false,
7302
+ initialSharedVersion: "1"
7303
+ })
7141
7304
  ]
7142
7305
  );
7143
7306
  },
@@ -7152,7 +7315,11 @@ var generateBorrowIncentiveNormalMethod = ({ builder, txBlock }) => {
7152
7315
  borrowIncentiveIds.incentiveAccounts,
7153
7316
  obligationKey,
7154
7317
  obligationId,
7155
- import_utils17.SUI_CLOCK_OBJECT_ID
7318
+ txBlock.sharedObjectRef({
7319
+ objectId: import_sui_kit7.SUI_CLOCK_OBJECT_ID,
7320
+ mutable: false,
7321
+ initialSharedVersion: "1"
7322
+ })
7156
7323
  ],
7157
7324
  [rewardType]
7158
7325
  );
@@ -7167,7 +7334,11 @@ var generateBorrowIncentiveNormalMethod = ({ builder, txBlock }) => {
7167
7334
  borrowIncentiveIds.incentiveAccounts,
7168
7335
  obligation,
7169
7336
  veScaKey,
7170
- import_utils17.SUI_CLOCK_OBJECT_ID
7337
+ txBlock.sharedObjectRef({
7338
+ objectId: import_sui_kit7.SUI_CLOCK_OBJECT_ID,
7339
+ mutable: false,
7340
+ initialSharedVersion: "1"
7341
+ })
7171
7342
  ]
7172
7343
  );
7173
7344
  }
@@ -7318,7 +7489,11 @@ var generateNormalVeScaMethod = ({
7318
7489
  veScaIds.treasury,
7319
7490
  scaCoin,
7320
7491
  unlockAtInSecondTimestamp,
7321
- import_sui_kit8.SUI_CLOCK_OBJECT_ID
7492
+ txBlock.sharedObjectRef({
7493
+ objectId: import_sui_kit8.SUI_CLOCK_OBJECT_ID,
7494
+ mutable: false,
7495
+ initialSharedVersion: "1"
7496
+ })
7322
7497
  ],
7323
7498
  []
7324
7499
  );
@@ -7333,7 +7508,11 @@ var generateNormalVeScaMethod = ({
7333
7508
  veScaIds.table,
7334
7509
  veScaIds.treasury,
7335
7510
  newUnlockAtInSecondTimestamp,
7336
- import_sui_kit8.SUI_CLOCK_OBJECT_ID
7511
+ txBlock.sharedObjectRef({
7512
+ objectId: import_sui_kit8.SUI_CLOCK_OBJECT_ID,
7513
+ mutable: false,
7514
+ initialSharedVersion: "1"
7515
+ })
7337
7516
  ],
7338
7517
  []
7339
7518
  );
@@ -7348,7 +7527,11 @@ var generateNormalVeScaMethod = ({
7348
7527
  veScaIds.table,
7349
7528
  veScaIds.treasury,
7350
7529
  scaCoin,
7351
- import_sui_kit8.SUI_CLOCK_OBJECT_ID
7530
+ txBlock.sharedObjectRef({
7531
+ objectId: import_sui_kit8.SUI_CLOCK_OBJECT_ID,
7532
+ mutable: false,
7533
+ initialSharedVersion: "1"
7534
+ })
7352
7535
  ],
7353
7536
  []
7354
7537
  );
@@ -7364,7 +7547,11 @@ var generateNormalVeScaMethod = ({
7364
7547
  veScaIds.treasury,
7365
7548
  scaCoin,
7366
7549
  newUnlockAtInSecondTimestamp,
7367
- import_sui_kit8.SUI_CLOCK_OBJECT_ID
7550
+ txBlock.sharedObjectRef({
7551
+ objectId: import_sui_kit8.SUI_CLOCK_OBJECT_ID,
7552
+ mutable: false,
7553
+ initialSharedVersion: "1"
7554
+ })
7368
7555
  ],
7369
7556
  []
7370
7557
  );
@@ -7378,7 +7565,11 @@ var generateNormalVeScaMethod = ({
7378
7565
  veScaKey,
7379
7566
  veScaIds.table,
7380
7567
  veScaIds.treasury,
7381
- import_sui_kit8.SUI_CLOCK_OBJECT_ID
7568
+ txBlock.sharedObjectRef({
7569
+ objectId: import_sui_kit8.SUI_CLOCK_OBJECT_ID,
7570
+ mutable: false,
7571
+ initialSharedVersion: "1"
7572
+ })
7382
7573
  ],
7383
7574
  []
7384
7575
  );
@@ -7587,7 +7778,11 @@ var generateReferralNormalMethod = ({
7587
7778
  referralIds.referralBindings,
7588
7779
  txBlock.pure.id(veScaKeyId),
7589
7780
  veScaTable,
7590
- import_sui_kit9.SUI_CLOCK_OBJECT_ID
7781
+ txBlock.sharedObjectRef({
7782
+ objectId: import_sui_kit9.SUI_CLOCK_OBJECT_ID,
7783
+ mutable: false,
7784
+ initialSharedVersion: "1"
7785
+ })
7591
7786
  ],
7592
7787
  []
7593
7788
  );
@@ -7603,7 +7798,11 @@ var generateReferralNormalMethod = ({
7603
7798
  referralIds.referralBindings,
7604
7799
  referralIds.authorizedWitnessList,
7605
7800
  referralIds.referralTiers,
7606
- import_sui_kit9.SUI_CLOCK_OBJECT_ID
7801
+ txBlock.sharedObjectRef({
7802
+ objectId: import_sui_kit9.SUI_CLOCK_OBJECT_ID,
7803
+ mutable: false,
7804
+ initialSharedVersion: "1"
7805
+ })
7607
7806
  ],
7608
7807
  [coinType]
7609
7808
  );
@@ -7617,7 +7816,11 @@ var generateReferralNormalMethod = ({
7617
7816
  referralIds.version,
7618
7817
  ticket,
7619
7818
  referralIds.referralRevenuePool,
7620
- import_sui_kit9.SUI_CLOCK_OBJECT_ID
7819
+ txBlock.sharedObjectRef({
7820
+ objectId: import_sui_kit9.SUI_CLOCK_OBJECT_ID,
7821
+ mutable: false,
7822
+ initialSharedVersion: "1"
7823
+ })
7621
7824
  ],
7622
7825
  [coinType]
7623
7826
  );
@@ -7631,7 +7834,11 @@ var generateReferralNormalMethod = ({
7631
7834
  referralIds.version,
7632
7835
  referralIds.referralRevenuePool,
7633
7836
  veScaKey,
7634
- import_sui_kit9.SUI_CLOCK_OBJECT_ID
7837
+ txBlock.sharedObjectRef({
7838
+ objectId: import_sui_kit9.SUI_CLOCK_OBJECT_ID,
7839
+ mutable: false,
7840
+ initialSharedVersion: "1"
7841
+ })
7635
7842
  ],
7636
7843
  [coinType]
7637
7844
  );
@@ -8075,12 +8282,12 @@ var ScallopIndexer = class {
8075
8282
  };
8076
8283
 
8077
8284
  // src/models/scallopQuery.ts
8078
- var import_utils23 = require("@mysten/sui/utils");
8285
+ var import_utils22 = require("@mysten/sui/utils");
8079
8286
  var ScallopQuery = class {
8080
8287
  constructor(params = {}, instance) {
8081
8288
  this.params = params;
8082
8289
  this.suiKit = instance?.suiKit ?? instance?.utils?.suiKit ?? newSuiKit(params);
8083
- this.walletAddress = (0, import_utils23.normalizeSuiAddress)(
8290
+ this.walletAddress = (0, import_utils22.normalizeSuiAddress)(
8084
8291
  params.walletAddress ?? this.suiKit.currentAddress()
8085
8292
  );
8086
8293
  if (instance?.utils) {
@@ -8680,7 +8887,7 @@ var ScallopBuilder = class {
8680
8887
  constructor(params = {}, instance) {
8681
8888
  this.suiKit = instance?.suiKit ?? newSuiKit(params);
8682
8889
  this.params = params;
8683
- this.walletAddress = (0, import_utils24.normalizeSuiAddress)(
8890
+ this.walletAddress = (0, import_utils23.normalizeSuiAddress)(
8684
8891
  params?.walletAddress ?? this.suiKit.currentAddress()
8685
8892
  );
8686
8893
  if (instance?.query) {
@@ -8827,7 +9034,7 @@ var ScallopClient = class {
8827
9034
  constructor(params = {}, instance) {
8828
9035
  this.params = params;
8829
9036
  this.suiKit = instance?.suiKit ?? instance?.builder?.suiKit ?? newSuiKit(params);
8830
- this.walletAddress = (0, import_utils25.normalizeSuiAddress)(
9037
+ this.walletAddress = (0, import_utils24.normalizeSuiAddress)(
8831
9038
  params?.walletAddress ?? this.suiKit.currentAddress()
8832
9039
  );
8833
9040
  if (instance?.builder) {