@t2000/sdk 0.18.10 → 0.18.11

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.
@@ -116,6 +116,7 @@ interface PositionEntry {
116
116
  asset: string;
117
117
  type: 'save' | 'borrow';
118
118
  amount: number;
119
+ amountUsd?: number;
119
120
  apy: number;
120
121
  }
121
122
  interface PositionsResult {
@@ -466,11 +467,13 @@ interface AdapterPositions {
466
467
  supplies: Array<{
467
468
  asset: string;
468
469
  amount: number;
470
+ amountUsd?: number;
469
471
  apy: number;
470
472
  }>;
471
473
  borrows: Array<{
472
474
  asset: string;
473
475
  amount: number;
476
+ amountUsd?: number;
474
477
  apy: number;
475
478
  }>;
476
479
  }
@@ -690,27 +693,18 @@ declare class CetusAdapter implements SwapAdapter {
690
693
  }
691
694
 
692
695
  declare const descriptor$1: ProtocolDescriptor;
693
- /**
694
- * Suilend adapter — contract-first, no SDK dependency.
695
- * Interacts directly with Suilend Move contracts via RPC + PTB moveCall.
696
- */
697
696
  declare class SuilendAdapter implements LendingAdapter {
698
697
  readonly id = "suilend";
699
698
  readonly name = "Suilend";
700
- readonly version = "2.0.0";
699
+ readonly version = "3.0.0";
701
700
  readonly capabilities: readonly AdapterCapability[];
702
701
  readonly supportedAssets: readonly string[];
703
702
  readonly supportsSameAssetBorrow = false;
704
703
  private client;
705
- private publishedAt;
706
- private reserveCache;
704
+ private sdkClient;
707
705
  init(client: SuiJsonRpcClient): Promise<void>;
708
706
  initSync(client: SuiJsonRpcClient): void;
709
- private resolvePackage;
710
- private loadReserves;
711
- private findReserve;
712
- private fetchObligationCaps;
713
- private fetchObligation;
707
+ private getSdkClient;
714
708
  private resolveSymbol;
715
709
  getRates(asset: string): Promise<LendingRates>;
716
710
  getPositions(address: string): Promise<AdapterPositions>;
@@ -725,13 +719,6 @@ declare class SuilendAdapter implements LendingAdapter {
725
719
  coin: TransactionObjectArgument;
726
720
  effectiveAmount: number;
727
721
  }>;
728
- /**
729
- * 3-step cToken redemption matching the official Suilend SDK flow:
730
- * 1. redeem_ctokens_and_withdraw_liquidity_request — creates a LiquidityRequest
731
- * 2. unstake_sui_from_staker — (SUI only) unstakes from validators to replenish available_liquidity
732
- * 3. fulfill_liquidity_request — splits underlying tokens from the reserve
733
- */
734
- private redeemCtokens;
735
722
  addSaveToTx(tx: Transaction, address: string, coin: TransactionObjectArgument, asset: string, options?: {
736
723
  collectFee?: boolean;
737
724
  }): Promise<void>;
@@ -751,7 +738,6 @@ declare class SuilendAdapter implements LendingAdapter {
751
738
  currentHF: number;
752
739
  }>;
753
740
  private fetchAllCoins;
754
- private isClaimableReward;
755
741
  getPendingRewards(address: string): Promise<PendingReward[]>;
756
742
  addClaimRewardsToTx(tx: Transaction, address: string): Promise<PendingReward[]>;
757
743
  }
@@ -116,6 +116,7 @@ interface PositionEntry {
116
116
  asset: string;
117
117
  type: 'save' | 'borrow';
118
118
  amount: number;
119
+ amountUsd?: number;
119
120
  apy: number;
120
121
  }
121
122
  interface PositionsResult {
@@ -466,11 +467,13 @@ interface AdapterPositions {
466
467
  supplies: Array<{
467
468
  asset: string;
468
469
  amount: number;
470
+ amountUsd?: number;
469
471
  apy: number;
470
472
  }>;
471
473
  borrows: Array<{
472
474
  asset: string;
473
475
  amount: number;
476
+ amountUsd?: number;
474
477
  apy: number;
475
478
  }>;
476
479
  }
@@ -690,27 +693,18 @@ declare class CetusAdapter implements SwapAdapter {
690
693
  }
691
694
 
692
695
  declare const descriptor$1: ProtocolDescriptor;
693
- /**
694
- * Suilend adapter — contract-first, no SDK dependency.
695
- * Interacts directly with Suilend Move contracts via RPC + PTB moveCall.
696
- */
697
696
  declare class SuilendAdapter implements LendingAdapter {
698
697
  readonly id = "suilend";
699
698
  readonly name = "Suilend";
700
- readonly version = "2.0.0";
699
+ readonly version = "3.0.0";
701
700
  readonly capabilities: readonly AdapterCapability[];
702
701
  readonly supportedAssets: readonly string[];
703
702
  readonly supportsSameAssetBorrow = false;
704
703
  private client;
705
- private publishedAt;
706
- private reserveCache;
704
+ private sdkClient;
707
705
  init(client: SuiJsonRpcClient): Promise<void>;
708
706
  initSync(client: SuiJsonRpcClient): void;
709
- private resolvePackage;
710
- private loadReserves;
711
- private findReserve;
712
- private fetchObligationCaps;
713
- private fetchObligation;
707
+ private getSdkClient;
714
708
  private resolveSymbol;
715
709
  getRates(asset: string): Promise<LendingRates>;
716
710
  getPositions(address: string): Promise<AdapterPositions>;
@@ -725,13 +719,6 @@ declare class SuilendAdapter implements LendingAdapter {
725
719
  coin: TransactionObjectArgument;
726
720
  effectiveAmount: number;
727
721
  }>;
728
- /**
729
- * 3-step cToken redemption matching the official Suilend SDK flow:
730
- * 1. redeem_ctokens_and_withdraw_liquidity_request — creates a LiquidityRequest
731
- * 2. unstake_sui_from_staker — (SUI only) unstakes from validators to replenish available_liquidity
732
- * 3. fulfill_liquidity_request — splits underlying tokens from the reserve
733
- */
734
- private redeemCtokens;
735
722
  addSaveToTx(tx: Transaction, address: string, coin: TransactionObjectArgument, asset: string, options?: {
736
723
  collectFee?: boolean;
737
724
  }): Promise<void>;
@@ -751,7 +738,6 @@ declare class SuilendAdapter implements LendingAdapter {
751
738
  currentHF: number;
752
739
  }>;
753
740
  private fetchAllCoins;
754
- private isClaimableReward;
755
741
  getPendingRewards(address: string): Promise<PendingReward[]>;
756
742
  addClaimRewardsToTx(tx: Transaction, address: string): Promise<PendingReward[]>;
757
743
  }