@kamino-finance/kliquidity-sdk
Version:
Typescript SDK for interacting with the Kamino Liquidity (kliquidity) protocol
76 lines • 4.32 kB
TypeScript
import { Address, GetAccountInfoApi, GetMultipleAccountsApi, Rpc } from "@solana/kit";
export interface PresetParameterFields {
/** Bin step. Represent the price increment / decrement. */
binStep: number;
/** Used for base fee calculation. base_fee_rate = base_factor * bin_step */
baseFactor: number;
/** Filter period determine high frequency trading time window. */
filterPeriod: number;
/** Decay period determine when the volatile fee start decay / decrease. */
decayPeriod: number;
/** Reduction factor controls the volatile fee rate decrement rate. */
reductionFactor: number;
/** Used to scale the variable fee component depending on the dynamic of the market */
variableFeeControl: number;
/** Maximum number of bin crossed can be accumulated. Used to cap volatile fee rate. */
maxVolatilityAccumulator: number;
/** Min bin id supported by the pool based on the configured bin step. */
minBinId: number;
/** Max bin id supported by the pool based on the configured bin step. */
maxBinId: number;
/** Portion of swap fees retained by the protocol by controlling protocol_share parameter. protocol_swap_fee = protocol_share * total_swap_fee */
protocolShare: number;
}
export interface PresetParameterJSON {
/** Bin step. Represent the price increment / decrement. */
binStep: number;
/** Used for base fee calculation. base_fee_rate = base_factor * bin_step */
baseFactor: number;
/** Filter period determine high frequency trading time window. */
filterPeriod: number;
/** Decay period determine when the volatile fee start decay / decrease. */
decayPeriod: number;
/** Reduction factor controls the volatile fee rate decrement rate. */
reductionFactor: number;
/** Used to scale the variable fee component depending on the dynamic of the market */
variableFeeControl: number;
/** Maximum number of bin crossed can be accumulated. Used to cap volatile fee rate. */
maxVolatilityAccumulator: number;
/** Min bin id supported by the pool based on the configured bin step. */
minBinId: number;
/** Max bin id supported by the pool based on the configured bin step. */
maxBinId: number;
/** Portion of swap fees retained by the protocol by controlling protocol_share parameter. protocol_swap_fee = protocol_share * total_swap_fee */
protocolShare: number;
}
export declare class PresetParameter {
/** Bin step. Represent the price increment / decrement. */
readonly binStep: number;
/** Used for base fee calculation. base_fee_rate = base_factor * bin_step */
readonly baseFactor: number;
/** Filter period determine high frequency trading time window. */
readonly filterPeriod: number;
/** Decay period determine when the volatile fee start decay / decrease. */
readonly decayPeriod: number;
/** Reduction factor controls the volatile fee rate decrement rate. */
readonly reductionFactor: number;
/** Used to scale the variable fee component depending on the dynamic of the market */
readonly variableFeeControl: number;
/** Maximum number of bin crossed can be accumulated. Used to cap volatile fee rate. */
readonly maxVolatilityAccumulator: number;
/** Min bin id supported by the pool based on the configured bin step. */
readonly minBinId: number;
/** Max bin id supported by the pool based on the configured bin step. */
readonly maxBinId: number;
/** Portion of swap fees retained by the protocol by controlling protocol_share parameter. protocol_swap_fee = protocol_share * total_swap_fee */
readonly protocolShare: number;
static readonly discriminator: Buffer<ArrayBuffer>;
static readonly layout: import("buffer-layout").Layout<PresetParameter>;
constructor(fields: PresetParameterFields);
static fetch(rpc: Rpc<GetAccountInfoApi>, address: Address, programId?: Address): Promise<PresetParameter | null>;
static fetchMultiple(rpc: Rpc<GetMultipleAccountsApi>, addresses: Address[], programId?: Address): Promise<Array<PresetParameter | null>>;
static decode(data: Buffer): PresetParameter;
toJSON(): PresetParameterJSON;
static fromJSON(obj: PresetParameterJSON): PresetParameter;
}
//# sourceMappingURL=PresetParameter.d.ts.map