UNPKG

@kamino-finance/kliquidity-sdk

Version:

Typescript SDK for interacting with the Kamino Liquidity (kliquidity) protocol

35 lines 2.59 kB
import { Address, ProgramDerivedAddress, Rpc, SolanaRpcApi } from '@solana/kit'; import { Pool, RaydiumPoolsResponse } from './RaydiumPoolsResponse'; import Decimal from 'decimal.js'; import { WhirlpoolAprApy } from './WhirlpoolAprApy'; import { WhirlpoolStrategy } from '../@codegen/kliquidity/accounts'; import { GenericPoolInfo, LiquidityDistribution } from '../utils'; import { ApiV3PoolInfoConcentratedItem, ClmmRpcData, ComputeClmmPoolInfo, ReturnTypeFetchExBitmaps, ReturnTypeFetchMultipleMintInfos, ReturnTypeGetTickPrice } from '@raydium-io/raydium-sdk-v2/lib'; export declare class RaydiumService { private readonly _rpc; private readonly _raydiumProgramId; constructor(rpc: Rpc<SolanaRpcApi>, raydiumProgramId?: Address); getRaydiumProgramId(): Address; getRaydiumWhirlpools(): Promise<RaydiumPoolsResponse>; getRaydiumPoolInfo(poolPubkey: Address): Promise<ApiV3PoolInfoConcentratedItem>; getRaydiumPoolLiquidityDistribution(pool: Address, keepOrder?: boolean, lowestTick?: number, highestTick?: number): Promise<LiquidityDistribution>; getStrategyWhirlpoolPoolAprApy: (strategy: WhirlpoolStrategy, pools?: Pool[]) => Promise<WhirlpoolAprApy>; getRaydiumPositionAprApy: (poolPubkey: Address, priceLower: Decimal, priceUpper: Decimal, pools?: Pool[]) => Promise<WhirlpoolAprApy>; getGenericPoolInfo(poolPubkey: Address, pools?: Pool[]): Promise<GenericPoolInfo>; getPositionsCountByPool(pool: Address): Promise<number>; getTickPrice(tick: number, tokenADecimals: number, tokenBDecimals: number, baseIn?: boolean): ReturnTypeGetTickPrice; getRpcClmmPoolInfo(poolId: string): Promise<ClmmRpcData>; fetchComputeClmmInfo(poolInfoWithAddress: ClmmRpcDataWithAddress): Promise<ComputeClmmPoolInfo>; fetchExBitmaps(exBitmapAddress: Address[]): Promise<ReturnTypeFetchExBitmaps>; fetchComputeMultipleClmmInfo(poolList: ClmmRpcDataWithAddress[]): Promise<Record<string, ComputeClmmPoolInfo>>; fetchMultipleMintInfos(mints: Address[]): Promise<ReturnTypeFetchMultipleMintInfos>; getComputeClmmPoolInfo(clmmPoolRpcInfoWithAddress: ClmmRpcDataWithAddress): Promise<ComputeClmmPoolInfo>; getPoolInfoFromRpc(poolId: string): Promise<ApiV3PoolInfoConcentratedItem>; clmmComputeInfoToApiInfo(pool: ComputeClmmPoolInfo): ApiV3PoolInfoConcentratedItem; } export interface ClmmRpcDataWithAddress { address: Address; clmmPoolRpcInfo: ClmmRpcData; } export declare function getPdaExBitmapAccount(programId: Address, poolId: Address): Promise<ProgramDerivedAddress>; //# sourceMappingURL=RaydiumService.d.ts.map