Meteora DLMM decoder
Decode Meteora DLMM instructions, accounts and events in Rust with carbon-meteora-dlmm-decoder 2.0.0. Program ID LBUZKhRxPF3XUpBCjp4YzTKgLccjZhTSDM9YuVaPwxo.
On this page
carbon-meteora-dlmm-decoder decodes the instructions, accounts and events of the Meteora DLMM program (LBUZKhRxPF3XUpBCjp4YzTKgLccjZhTSDM9YuVaPwxo): 76 instructions, 12 account types, 30 events. It is generated with Codama from the program's IDL; see decoders for how decoders plug into a pipeline.
| Crate | carbon-meteora-dlmm-decoder 2.0.0 |
| Install | cargo add carbon-meteora-dlmm-decoder@2. |
| Program ID | LBUZKhRxPF3XUpBCjp4YzTKgLccjZhTSDM9YuVaPwxo (carbon_) |
| Category | DEX & AMM |
| Decoder | carbon_ |
| Instruction enum | instructions:: |
| Account enum | accounts:: |
| Event enum | instructions:: |
| Features | serde, postgres, graphql (none enabled by default) |
| API docs | docs.rs/carbon-meteora-dlmm-decoder/2.0.0 |
| Source | decoders/meteora-dlmm-decoder |
Other DEX and AMM decoders: BonkSwap, FluxBeam, Gavel, Heaven, Jupiter Limit Order, Jupiter Limit Order v2, Kamino Limit Order, Lifinity AMM v2, Meteora DAMM v2, Meteora Pools, OpenBook v2, Orca Whirlpools, PancakeSwap, Phoenix v1, PumpSwap, Raydium AMM v4, Raydium CLMM, Raydium CPMM, Raydium Stable Swap, Stabble Stable Swap, Stabble Weighted Swap. To decode several in one pipeline, see dEX and AMM decoders.
Guide: Index swaps across DEXs.
The serde feature derives Serialize/Deserialize on every type, postgres adds tables and processors for Postgres, and graphql adds a schema for the GraphQL server.
Usage#
This program crawls recent Meteora DLMM transactions from the public RPC and prints every decoded Swap instruction. Add the dependencies:
cargo add carbon-core@2.0.0 carbon-meteora-dlmm-decoder@2.0.0 carbon-rpc-transaction-crawler-datasource@2.0.0 carbon-log-metrics@2.0.0 env_logger tokio --features tokio/fulluse {
carbon_core::{
error::CarbonResult, instruction::InstructionProcessorInputType, pipeline::Pipeline,
processor::Processor,
},
carbon_log_metrics::LogMetrics,
carbon_meteora_dlmm_decoder::{
instructions::MeteoraDlmmInstruction, MeteoraDlmmDecoder, PROGRAM_ID,
},
carbon_rpc_transaction_crawler_datasource::{ConnectionConfig, Filters, RpcTransactionCrawler},
std::sync::Arc,
};
#[tokio::main]
async fn main() -> CarbonResult<()> {
env_logger::init();
// Fetches the program's recent transactions over JSON-RPC, newest first.
let datasource = RpcTransactionCrawler::new(
"https://api.mainnet-beta.solana.com".to_string(),
PROGRAM_ID,
ConnectionConfig::default(),
Filters::new(None, None, None),
None,
);
Pipeline::builder()
.datasource(datasource)
.metrics(Arc::new(LogMetrics::new()))
.instruction(MeteoraDlmmDecoder, InstructionLogger)
.build()?
.run()
.await
}
struct InstructionLogger;
impl Processor<InstructionProcessorInputType<'_, MeteoraDlmmInstruction>> for InstructionLogger {
async fn process(
&mut self,
input: &InstructionProcessorInputType<'_, MeteoraDlmmInstruction>,
) -> CarbonResult<()> {
let signature = input.metadata.transaction_metadata.signature;
if let MeteoraDlmmInstruction::Swap { data, accounts, .. } = input.decoded_instruction {
println!("swap {signature}: {data:?} lb_pair={}", accounts.lb_pair);
}
Ok(())
}
}RUST_LOG=info cargo runEach Swap instruction prints one line with the transaction signature and the decoded Swap data. The public endpoint rate-limits requests, so the first lines can take a while; use your own RPC URL for anything beyond a test. See stream with RPC for the crawler options.
Events published with Anchor's emit_cpi! arrive as the CpiEvent instruction. Match them with MeteoraDlmmInstruction:: (import instructions::); see Events. If CpiEvent never arrives, the program logs its events with emit! instead: decode them with decode_.
Decode accounts#
The transaction crawler emits transactions only. To decode accounts, use a datasource that emits account updates. This program subscribes to the program's accounts with programSubscribe on the public WebSocket endpoint and prints every decoded LbPair account as it changes. Add the datasource and the Solana RPC types it takes:
cargo add carbon-rpc-program-subscribe-datasource@2.0.0 solana-client@4.2.2use {
carbon_core::{
account::AccountProcessorInputType, error::CarbonResult, pipeline::Pipeline,
processor::Processor,
},
carbon_log_metrics::LogMetrics,
carbon_meteora_dlmm_decoder::{accounts::MeteoraDlmmAccount, MeteoraDlmmDecoder, PROGRAM_ID},
carbon_rpc_program_subscribe_datasource::{Filters, RpcProgramSubscribe},
solana_client::rpc_config::{RpcAccountInfoConfig, RpcProgramAccountsConfig, UiAccountEncoding},
std::sync::Arc,
};
#[tokio::main]
async fn main() -> CarbonResult<()> {
env_logger::init();
// Streams every change to an account owned by the program (programSubscribe).
let config = RpcProgramAccountsConfig {
account_config: RpcAccountInfoConfig {
encoding: Some(UiAccountEncoding::Base64),
..Default::default()
},
..Default::default()
};
let datasource = RpcProgramSubscribe::new(
"wss://api.mainnet-beta.solana.com".to_string(),
Filters::new(PROGRAM_ID, Some(config)),
);
Pipeline::builder()
.datasource(datasource)
.metrics(Arc::new(LogMetrics::new()))
.account(MeteoraDlmmDecoder, AccountLogger)
.build()?
.run()
.await
}
struct AccountLogger;
impl Processor<AccountProcessorInputType<'_, MeteoraDlmmAccount>> for AccountLogger {
async fn process(
&mut self,
input: &AccountProcessorInputType<'_, MeteoraDlmmAccount>,
) -> CarbonResult<()> {
if let MeteoraDlmmAccount::LbPair(lb_pair) = &input.decoded_account.data {
println!("lb_pair {}: {lb_pair:?}", input.metadata.pubkey);
}
Ok(())
}
}RUST_LOG=info cargo runEach update to a LbPair account prints its address and decoded fields; the program runs until you stop it. Cargo resolves solana-client to 4.2.2, the exact version the datasource pins, so both use the same RpcProgramAccountsConfig type. To load every existing account once instead of streaming changes, see load account state.
Instructions#
Variants of MeteoraDlmmInstruction. Each is MeteoraDlmmInstruction::, where data and accounts are the types listed under the variant, exported from carbon_. Discriminators are the leading bytes of the instruction data, in hex.
How an instruction decodes. The decoder returns a variant only when all of these hold; otherwise the instruction is skipped and no processor is called:
- The instruction's program ID is
LBUZKhRxPF3XUpBCjp4YzTKgLccjZhTSDM9YuVaPwxo. - The data starts with the variant's discriminator, and the rest deserializes into its data type.
- The instruction has at least as many accounts as the variant requires (the "Required accounts" count under each variant).
Accounts. They are matched by position, in the order listed. An account marked optional is None only when the instruction ends before it; Anchor programs pass the program ID as a placeholder for an omitted optional account, so check for Some(PROGRAM_ too. Accounts after the listed ones are in accounts. as AccountMetas. The decoder doesn't record whether an account signed or was writable: read that from input. and ., which follow the same order. It doesn't check signer, writable, owner or PDA constraints either; the program enforced those when the transaction executed, so a decoded instruction from a successful transaction already satisfied them.
AddLiquidity#
Discriminator b59d59438fb63448 · data AddLiquidity · accounts AddLiquidityInstructionAccounts.
| Field | Type |
|---|---|
liquidity_ | LiquidityParameter |
Required accounts: 16; extras go to remaining.
Fields of AddLiquidityInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | bin_ | Pubkey |
| 10 | bin_ | Pubkey |
| 11 | sender | Pubkey |
| 12 | token_ | Pubkey |
| 13 | token_ | Pubkey |
| 14 | event_ | Pubkey |
| 15 | program | Pubkey |
| 16… | remaining | Vec< |
AddLiquidity2#
Discriminator e4a24e1c46db7473 · data AddLiquidity2 · accounts AddLiquidity2InstructionAccounts.
| Field | Type |
|---|---|
liquidity_ | LiquidityParameter |
remaining_ | RemainingAccountsInfo |
Required accounts: 14; extras go to remaining.
Fields of AddLiquidity2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | sender | Pubkey |
| 10 | token_ | Pubkey |
| 11 | token_ | Pubkey |
| 12 | event_ | Pubkey |
| 13 | program | Pubkey |
| 14… | remaining | Vec< |
AddLiquidityByStrategy#
Discriminator 0703967f94283dc8 · data AddLiquidityByStrategy · accounts AddLiquidityByStrategyInstructionAccounts.
| Field | Type |
|---|---|
liquidity_ | LiquidityParameterByStrategy |
Required accounts: 16; extras go to remaining.
Fields of AddLiquidityByStrategyInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | bin_ | Pubkey |
| 10 | bin_ | Pubkey |
| 11 | sender | Pubkey |
| 12 | token_ | Pubkey |
| 13 | token_ | Pubkey |
| 14 | event_ | Pubkey |
| 15 | program | Pubkey |
| 16… | remaining | Vec< |
AddLiquidityByStrategy2#
Discriminator 03dd95da6f8d76d5 · data AddLiquidityByStrategy2 · accounts AddLiquidityByStrategy2InstructionAccounts.
| Field | Type |
|---|---|
liquidity_ | LiquidityParameterByStrategy |
remaining_ | RemainingAccountsInfo |
Required accounts: 14; extras go to remaining.
Fields of AddLiquidityByStrategy2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | sender | Pubkey |
| 10 | token_ | Pubkey |
| 11 | token_ | Pubkey |
| 12 | event_ | Pubkey |
| 13 | program | Pubkey |
| 14… | remaining | Vec< |
AddLiquidityByStrategyOneSide#
Discriminator 2905eeaf64e106cd · data AddLiquidityByStrategyOneSide · accounts AddLiquidityByStrategyOneSideInstructionAccounts.
| Field | Type |
|---|---|
liquidity_ | LiquidityParameterByStrategyOneSide |
Required accounts: 12; extras go to remaining.
Fields of AddLiquidityByStrategyOneSideInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_token | Pubkey |
| 4 | reserve | Pubkey |
| 5 | token_mint | Pubkey |
| 6 | bin_ | Pubkey |
| 7 | bin_ | Pubkey |
| 8 | sender | Pubkey |
| 9 | token_ | Pubkey |
| 10 | event_ | Pubkey |
| 11 | program | Pubkey |
| 12… | remaining | Vec< |
AddLiquidityByWeight#
Discriminator 1c8cee63e7a21595 · data AddLiquidityByWeight · accounts AddLiquidityByWeightInstructionAccounts.
| Field | Type |
|---|---|
liquidity_ | LiquidityParameterByWeight |
Required accounts: 16; extras go to remaining.
Fields of AddLiquidityByWeightInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | bin_ | Pubkey |
| 10 | bin_ | Pubkey |
| 11 | sender | Pubkey |
| 12 | token_ | Pubkey |
| 13 | token_ | Pubkey |
| 14 | event_ | Pubkey |
| 15 | program | Pubkey |
| 16… | remaining | Vec< |
AddLiquidityByWeight2#
Discriminator d13b3f5b6fc899e4 · data AddLiquidityByWeight2 · accounts AddLiquidityByWeight2InstructionAccounts.
| Field | Type |
|---|---|
liquidity_ | LiquidityParameterByWeight |
remaining_ | RemainingAccountsInfo |
Required accounts: 14; extras go to remaining.
Fields of AddLiquidityByWeight2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | sender | Pubkey |
| 10 | token_ | Pubkey |
| 11 | token_ | Pubkey |
| 12 | event_ | Pubkey |
| 13 | program | Pubkey |
| 14… | remaining | Vec< |
AddLiquidityOneSide#
Discriminator 5e9b6797465fdca5 · data AddLiquidityOneSide · accounts AddLiquidityOneSideInstructionAccounts.
| Field | Type |
|---|---|
liquidity_ | LiquidityOneSideParameter |
Required accounts: 12; extras go to remaining.
Fields of AddLiquidityOneSideInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_token | Pubkey |
| 4 | reserve | Pubkey |
| 5 | token_mint | Pubkey |
| 6 | bin_ | Pubkey |
| 7 | bin_ | Pubkey |
| 8 | sender | Pubkey |
| 9 | token_ | Pubkey |
| 10 | event_ | Pubkey |
| 11 | program | Pubkey |
| 12… | remaining | Vec< |
AddLiquidityOneSidePrecise#
Discriminator a1c26754ab47fa9a · data AddLiquidityOneSidePrecise · accounts AddLiquidityOneSidePreciseInstructionAccounts.
| Field | Type |
|---|---|
parameter | AddLiquiditySingleSidePreciseParameter |
Required accounts: 12; extras go to remaining.
Fields of AddLiquidityOneSidePreciseInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_token | Pubkey |
| 4 | reserve | Pubkey |
| 5 | token_mint | Pubkey |
| 6 | bin_ | Pubkey |
| 7 | bin_ | Pubkey |
| 8 | sender | Pubkey |
| 9 | token_ | Pubkey |
| 10 | event_ | Pubkey |
| 11 | program | Pubkey |
| 12… | remaining | Vec< |
AddLiquidityOneSidePrecise2#
Discriminator 2133a3c975627de7 · data AddLiquidityOneSidePrecise2 · accounts AddLiquidityOneSidePrecise2InstructionAccounts.
| Field | Type |
|---|---|
liquidity_ | AddLiquiditySingleSidePreciseParameter2 |
remaining_ | RemainingAccountsInfo |
Required accounts: 10; extras go to remaining.
Fields of AddLiquidityOneSidePrecise2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_token | Pubkey |
| 4 | reserve | Pubkey |
| 5 | token_mint | Pubkey |
| 6 | sender | Pubkey |
| 7 | token_ | Pubkey |
| 8 | event_ | Pubkey |
| 9 | program | Pubkey |
| 10… | remaining | Vec< |
CancelLimitOrder#
Discriminator 849c841f4328e861 · data CancelLimitOrder · accounts CancelLimitOrderInstructionAccounts.
| Field | Type |
|---|---|
bins | Vec<i32> |
remaining_ | RemainingAccountsInfo |
Required accounts: 15; extras go to remaining.
Fields of CancelLimitOrderInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | reserve_x | Pubkey |
| 3 | reserve_y | Pubkey |
| 4 | token_ | Pubkey |
| 5 | token_ | Pubkey |
| 6 | limit_order | Pubkey |
| 7 | owner_ | Pubkey |
| 8 | owner_ | Pubkey |
| 9 | owner | Pubkey |
| 10 | token_ | Pubkey |
| 11 | token_ | Pubkey |
| 12 | memo_ | Pubkey |
| 13 | event_ | Pubkey |
| 14 | program | Pubkey |
| 15… | remaining | Vec< |
ClaimFee#
Discriminator a9204f8988e84689 · data ClaimFee · accounts ClaimFeeInstructionAccounts.
No data fields.
Required accounts: 14; extras go to remaining.
Fields of ClaimFeeInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | position | Pubkey |
| 2 | bin_ | Pubkey |
| 3 | bin_ | Pubkey |
| 4 | sender | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | user_ | Pubkey |
| 8 | user_ | Pubkey |
| 9 | token_ | Pubkey |
| 10 | token_ | Pubkey |
| 11 | token_ | Pubkey |
| 12 | event_ | Pubkey |
| 13 | program | Pubkey |
| 14… | remaining | Vec< |
ClaimFee2#
Discriminator 70bf65ab1c907fbb · data ClaimFee2 · accounts ClaimFee2InstructionAccounts.
| Field | Type |
|---|---|
min_bin_id | i32 |
max_bin_id | i32 |
remaining_ | RemainingAccountsInfo |
Required accounts: 14; extras go to remaining.
Fields of ClaimFee2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | position | Pubkey |
| 2 | sender | Pubkey |
| 3 | reserve_x | Pubkey |
| 4 | reserve_y | Pubkey |
| 5 | user_ | Pubkey |
| 6 | user_ | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | token_ | Pubkey |
| 10 | token_ | Pubkey |
| 11 | memo_ | Pubkey |
| 12 | event_ | Pubkey |
| 13 | program | Pubkey |
| 14… | remaining | Vec< |
ClaimReward#
Discriminator 955fb5f25e5a9ea2 · data ClaimReward · accounts ClaimRewardInstructionAccounts.
| Field | Type |
|---|---|
reward_ | u64 |
Required accounts: 11; extras go to remaining.
Fields of ClaimRewardInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | position | Pubkey |
| 2 | bin_ | Pubkey |
| 3 | bin_ | Pubkey |
| 4 | sender | Pubkey |
| 5 | reward_ | Pubkey |
| 6 | reward_mint | Pubkey |
| 7 | user_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | event_ | Pubkey |
| 10 | program | Pubkey |
| 11… | remaining | Vec< |
ClaimReward2#
Discriminator be037f77b2579db7 · data ClaimReward2 · accounts ClaimReward2InstructionAccounts.
| Field | Type |
|---|---|
reward_ | u64 |
min_bin_id | i32 |
max_bin_id | i32 |
remaining_ | RemainingAccountsInfo |
Required accounts: 10; extras go to remaining.
Fields of ClaimReward2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | position | Pubkey |
| 2 | sender | Pubkey |
| 3 | reward_ | Pubkey |
| 4 | reward_mint | Pubkey |
| 5 | user_ | Pubkey |
| 6 | token_ | Pubkey |
| 7 | memo_ | Pubkey |
| 8 | event_ | Pubkey |
| 9 | program | Pubkey |
| 10… | remaining | Vec< |
CloseBinArray#
Discriminator 44ae5850b5cc13e0 · data CloseBinArray · accounts CloseBinArrayInstructionAccounts.
No data fields.
Required accounts: 4; extras go to remaining.
Fields of CloseBinArrayInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_array | Pubkey |
| 2 | rent_ | Pubkey |
| 3 | signer | Pubkey |
| 4… | remaining | Vec< |
CloseClaimFeeOperatorAccount#
Discriminator b8d5581fb3658224 · data CloseClaimFeeOperatorAccount · accounts CloseClaimFeeOperatorAccountInstructionAccounts.
No data fields.
Required accounts: 3; extras go to remaining.
Fields of CloseClaimFeeOperatorAccountInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | claim_ | Pubkey |
| 1 | rent_ | Pubkey |
| 2 | signer | Pubkey |
| 3… | remaining | Vec< |
CloseLimitOrderIfEmpty#
Discriminator 397c249b7ef95dab · data CloseLimitOrderIfEmpty · accounts CloseLimitOrderIfEmptyInstructionAccounts.
No data fields.
Required accounts: 5; extras go to remaining.
Fields of CloseLimitOrderIfEmptyInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | limit_order | Pubkey |
| 1 | owner | Pubkey |
| 2 | rent_ | Pubkey |
| 3 | event_ | Pubkey |
| 4 | program | Pubkey |
| 5… | remaining | Vec< |
CloseOperatorAccount#
Discriminator ab09d54a7817031d · data CloseOperatorAccount · accounts CloseOperatorAccountInstructionAccounts.
No data fields.
Required accounts: 3; extras go to remaining.
Fields of CloseOperatorAccountInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | operator | Pubkey |
| 1 | signer | Pubkey |
| 2 | rent_ | Pubkey |
| 3… | remaining | Vec< |
ClosePosition#
Discriminator 7b86510031446262 · data ClosePosition · accounts ClosePositionInstructionAccounts.
No data fields.
Required accounts: 8; extras go to remaining.
Fields of ClosePositionInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Pubkey |
| 3 | bin_ | Pubkey |
| 4 | sender | Pubkey |
| 5 | rent_ | Pubkey |
| 6 | event_ | Pubkey |
| 7 | program | Pubkey |
| 8… | remaining | Vec< |
ClosePosition2#
Discriminator ae5a2373ba2893e2 · data ClosePosition2 · accounts ClosePosition2InstructionAccounts.
No data fields.
Required accounts: 5; extras go to remaining.
Fields of ClosePosition2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | sender | Pubkey |
| 2 | rent_ | Pubkey |
| 3 | event_ | Pubkey |
| 4 | program | Pubkey |
| 5… | remaining | Vec< |
ClosePositionIfEmpty#
Discriminator 3b7cd4765b986e9d · data ClosePositionIfEmpty · accounts ClosePositionIfEmptyInstructionAccounts.
No data fields.
Required accounts: 5; extras go to remaining.
Fields of ClosePositionIfEmptyInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | sender | Pubkey |
| 2 | rent_ | Pubkey |
| 3 | event_ | Pubkey |
| 4 | program | Pubkey |
| 5… | remaining | Vec< |
ClosePresetParameter#
Discriminator 04949164861ab53d · data ClosePresetParameter · accounts ClosePresetParameterInstructionAccounts.
No data fields.
Required accounts: 4; extras go to remaining.
Fields of ClosePresetParameterInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | preset_ | Pubkey |
| 1 | operator | Pubkey |
| 2 | signer | Pubkey |
| 3 | rent_ | Pubkey |
| 4… | remaining | Vec< |
ClosePresetParameter2#
Discriminator 27195f6b7411731c · data ClosePresetParameter2 · accounts ClosePresetParameter2InstructionAccounts.
No data fields.
Required accounts: 4; extras go to remaining.
Fields of ClosePresetParameter2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | preset_ | Pubkey |
| 1 | operator | Pubkey |
| 2 | signer | Pubkey |
| 3 | rent_ | Pubkey |
| 4… | remaining | Vec< |
CloseTokenBadge#
Discriminator 6c92566eb3fe0a68 · data CloseTokenBadge · accounts CloseTokenBadgeInstructionAccounts.
No data fields.
Required accounts: 4; extras go to remaining.
Fields of CloseTokenBadgeInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | token_badge | Pubkey |
| 1 | rent_ | Pubkey |
| 2 | operator | Pubkey |
| 3 | signer | Pubkey |
| 4… | remaining | Vec< |
CreateOperatorAccount#
Discriminator dd40f695f099e5a3 · data CreateOperatorAccount · accounts CreateOperatorAccountInstructionAccounts.
| Field | Type |
|---|---|
permission | u128 |
Required accounts: 5; extras go to remaining.
Fields of CreateOperatorAccountInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | operator | Pubkey |
| 1 | whitelisted_ | Pubkey |
| 2 | signer | Pubkey |
| 3 | payer | Pubkey |
| 4 | system_ | Pubkey |
| 5… | remaining | Vec< |
DecreasePositionLength#
Discriminator c2db882019606925 · data DecreasePositionLength · accounts DecreasePositionLengthInstructionAccounts.
| Field | Type |
|---|---|
length_ | u16 |
side | u8 |
Required accounts: 6; extras go to remaining.
Fields of DecreasePositionLengthInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | rent_ | Pubkey |
| 1 | position | Pubkey |
| 2 | owner | Pubkey |
| 3 | system_ | Pubkey |
| 4 | event_ | Pubkey |
| 5 | program | Pubkey |
| 6… | remaining | Vec< |
ForIdlTypeGenerationDoNotCall#
Discriminator b46945505f32496c · data ForIdlTypeGenerationDoNotCall · accounts ForIdlTypeGenerationDoNotCallInstructionAccounts.
| Field | Type |
|---|---|
ix | DummyIx |
Required accounts: 1; extras go to remaining.
Fields of ForIdlTypeGenerationDoNotCallInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | dummy_ | Pubkey |
| 1… | remaining | Vec< |
FundReward#
Discriminator bc32f9a55d97263f · data FundReward · accounts FundRewardInstructionAccounts.
| Field | Type |
|---|---|
reward_ | u64 |
amount | u64 |
carry_ | bool |
remaining_ | RemainingAccountsInfo |
Required accounts: 9; extras go to remaining.
Fields of FundRewardInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | reward_ | Pubkey |
| 2 | reward_mint | Pubkey |
| 3 | funder_ | Pubkey |
| 4 | funder | Pubkey |
| 5 | bin_array | Pubkey |
| 6 | token_ | Pubkey |
| 7 | event_ | Pubkey |
| 8 | program | Pubkey |
| 9… | remaining | Vec< |
GoToABin#
Discriminator 9248aee028fd54ae · data GoToABin · accounts GoToABinInstructionAccounts.
| Field | Type |
|---|---|
bin_id | i32 |
Required accounts: 6; extras go to remaining.
Fields of GoToABinInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | from_ | Option< |
| 3 | to_ | Option< |
| 4 | event_ | Pubkey |
| 5 | program | Pubkey |
| 6… | remaining | Vec< |
IncreaseOracleLength#
Discriminator be3d7d57674f9ead · data IncreaseOracleLength · accounts IncreaseOracleLengthInstructionAccounts.
| Field | Type |
|---|---|
length_ | u64 |
Required accounts: 5; extras go to remaining.
Fields of IncreaseOracleLengthInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | oracle | Pubkey |
| 1 | funder | Pubkey |
| 2 | system_ | Pubkey |
| 3 | event_ | Pubkey |
| 4 | program | Pubkey |
| 5… | remaining | Vec< |
IncreasePositionLength#
Discriminator 505375d3420d2195 · data IncreasePositionLength · accounts IncreasePositionLengthInstructionAccounts.
| Field | Type |
|---|---|
length_ | u16 |
side | u8 |
Required accounts: 7; extras go to remaining.
Fields of IncreasePositionLengthInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | funder | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | position | Pubkey |
| 3 | owner | Pubkey |
| 4 | system_ | Pubkey |
| 5 | event_ | Pubkey |
| 6 | program | Pubkey |
| 7… | remaining | Vec< |
IncreasePositionLength2#
Discriminator ffd2cc477389e171 · data IncreasePositionLength2 · accounts IncreasePositionLength2InstructionAccounts.
| Field | Type |
|---|---|
minimum_ | i32 |
Required accounts: 7; extras go to remaining.
Fields of IncreasePositionLength2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | funder | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | position | Pubkey |
| 3 | owner | Pubkey |
| 4 | system_ | Pubkey |
| 5 | event_ | Pubkey |
| 6 | program | Pubkey |
| 7… | remaining | Vec< |
InitializeBinArray#
Discriminator 235613b94ed44bd3 · data InitializeBinArray · accounts InitializeBinArrayInstructionAccounts.
| Field | Type |
|---|---|
index | i64 |
Required accounts: 4; extras go to remaining.
Fields of InitializeBinArrayInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_array | Pubkey |
| 2 | funder | Pubkey |
| 3 | system_ | Pubkey |
| 4… | remaining | Vec< |
InitializeBinArrayBitmapExtension#
Discriminator 2f9de2b40cf02147 · data InitializeBinArrayBitmapExtension · accounts InitializeBinArrayBitmapExtensionInstructionAccounts.
No data fields.
Required accounts: 5; extras go to remaining.
Fields of InitializeBinArrayBitmapExtensionInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Pubkey |
| 2 | funder | Pubkey |
| 3 | system_ | Pubkey |
| 4 | rent | Pubkey |
| 5… | remaining | Vec< |
InitializeCustomizablePermissionlessLbPair#
Discriminator 2e2729876fb7c840 · data InitializeCustomizablePermissionlessLbPair · accounts InitializeCustomizablePermissionlessLbPairInstructionAccounts.
| Field | Type |
|---|---|
params | CustomizableParams |
Required accounts: 14; extras go to remaining.
Fields of InitializeCustomizablePermissionlessLbPairInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | token_ | Pubkey |
| 3 | token_ | Pubkey |
| 4 | reserve_x | Pubkey |
| 5 | reserve_y | Pubkey |
| 6 | oracle | Pubkey |
| 7 | user_ | Pubkey |
| 8 | funder | Pubkey |
| 9 | token_ | Pubkey |
| 10 | system_ | Pubkey |
| 11 | user_ | Pubkey |
| 12 | event_ | Pubkey |
| 13 | program | Pubkey |
| 14… | remaining | Vec< |
InitializeCustomizablePermissionlessLbPair2#
Discriminator f349817e3313f16b · data InitializeCustomizablePermissionlessLbPair2 · accounts InitializeCustomizablePermissionlessLbPair2InstructionAccounts.
| Field | Type |
|---|---|
params | CustomizableParams |
Required accounts: 17; extras go to remaining.
Fields of InitializeCustomizablePermissionlessLbPair2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | token_ | Pubkey |
| 3 | token_ | Pubkey |
| 4 | reserve_x | Pubkey |
| 5 | reserve_y | Pubkey |
| 6 | oracle | Pubkey |
| 7 | user_ | Pubkey |
| 8 | funder | Pubkey |
| 9 | token_ | Option< |
| 10 | token_ | Option< |
| 11 | token_ | Pubkey |
| 12 | token_ | Pubkey |
| 13 | system_ | Pubkey |
| 14 | user_ | Pubkey |
| 15 | event_ | Pubkey |
| 16 | program | Pubkey |
| 17… | remaining | Vec< |
InitializeLbPair#
Discriminator 2d9aedd2dd0fa65c · data InitializeLbPair · accounts InitializeLbPairInstructionAccounts.
| Field | Type |
|---|---|
active_id | i32 |
bin_step | u16 |
Required accounts: 14; extras go to remaining.
Fields of InitializeLbPairInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | token_ | Pubkey |
| 3 | token_ | Pubkey |
| 4 | reserve_x | Pubkey |
| 5 | reserve_y | Pubkey |
| 6 | oracle | Pubkey |
| 7 | preset_ | Pubkey |
| 8 | funder | Pubkey |
| 9 | token_ | Pubkey |
| 10 | system_ | Pubkey |
| 11 | rent | Pubkey |
| 12 | event_ | Pubkey |
| 13 | program | Pubkey |
| 14… | remaining | Vec< |
InitializeLbPair2#
Discriminator 493b2478ed536cc6 · data InitializeLbPair2 · accounts InitializeLbPair2InstructionAccounts.
| Field | Type |
|---|---|
params | InitializeLbPair2Params |
Required accounts: 16; extras go to remaining.
Fields of InitializeLbPair2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | token_ | Pubkey |
| 3 | token_ | Pubkey |
| 4 | reserve_x | Pubkey |
| 5 | reserve_y | Pubkey |
| 6 | oracle | Pubkey |
| 7 | preset_ | Pubkey |
| 8 | funder | Pubkey |
| 9 | token_ | Option< |
| 10 | token_ | Option< |
| 11 | token_ | Pubkey |
| 12 | token_ | Pubkey |
| 13 | system_ | Pubkey |
| 14 | event_ | Pubkey |
| 15 | program | Pubkey |
| 16… | remaining | Vec< |
InitializePermissionLbPair#
Discriminator 6c66d555fb033515 · data InitializePermissionLbPair · accounts InitializePermissionLbPairInstructionAccounts.
| Field | Type |
|---|---|
ix_data | InitPermissionPairIx |
Required accounts: 18; extras go to remaining.
Fields of InitializePermissionLbPairInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | base | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | token_ | Pubkey |
| 4 | token_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | oracle | Pubkey |
| 8 | payer | Pubkey |
| 9 | operator | Pubkey |
| 10 | signer | Pubkey |
| 11 | token_ | Option< |
| 12 | token_ | Option< |
| 13 | token_ | Pubkey |
| 14 | token_ | Pubkey |
| 15 | system_ | Pubkey |
| 16 | event_ | Pubkey |
| 17 | program | Pubkey |
| 18… | remaining | Vec< |
InitializePosition#
Discriminator dbc0ea47bebf6650 · data InitializePosition · accounts InitializePositionInstructionAccounts.
| Field | Type |
|---|---|
lower_ | i32 |
width | i32 |
Required accounts: 8; extras go to remaining.
Fields of InitializePositionInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | payer | Pubkey |
| 1 | position | Pubkey |
| 2 | lb_pair | Pubkey |
| 3 | owner | Pubkey |
| 4 | system_ | Pubkey |
| 5 | rent | Pubkey |
| 6 | event_ | Pubkey |
| 7 | program | Pubkey |
| 8… | remaining | Vec< |
InitializePosition2#
Discriminator 8f13f291d50f6873 · data InitializePosition2 · accounts InitializePosition2InstructionAccounts.
| Field | Type |
|---|---|
lower_ | i32 |
width | i32 |
Required accounts: 7; extras go to remaining.
Fields of InitializePosition2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | payer | Pubkey |
| 1 | position | Pubkey |
| 2 | lb_pair | Pubkey |
| 3 | owner | Pubkey |
| 4 | system_ | Pubkey |
| 5 | event_ | Pubkey |
| 6 | program | Pubkey |
| 7… | remaining | Vec< |
InitializePositionByOperator#
Discriminator fbbdbef475fe2394 · data InitializePositionByOperator · accounts InitializePositionByOperatorInstructionAccounts.
| Field | Type |
|---|---|
lower_ | i32 |
width | i32 |
fee_owner | Pubkey |
lock_ | u64 |
Required accounts: 11; extras go to remaining.
Fields of InitializePositionByOperatorInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | payer | Pubkey |
| 1 | base | Pubkey |
| 2 | position | Pubkey |
| 3 | lb_pair | Pubkey |
| 4 | owner | Pubkey |
| 5 | operator | Pubkey |
| 6 | operator_ | Pubkey |
| 7 | owner_ | Pubkey |
| 8 | system_ | Pubkey |
| 9 | event_ | Pubkey |
| 10 | program | Pubkey |
| 11… | remaining | Vec< |
InitializePositionPda#
Discriminator 2e527d92558de499 · data InitializePositionPda · accounts InitializePositionPdaInstructionAccounts.
| Field | Type |
|---|---|
lower_ | i32 |
width | i32 |
Required accounts: 9; extras go to remaining.
Fields of InitializePositionPdaInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | payer | Pubkey |
| 1 | base | Pubkey |
| 2 | position | Pubkey |
| 3 | lb_pair | Pubkey |
| 4 | owner | Pubkey |
| 5 | system_ | Pubkey |
| 6 | rent | Pubkey |
| 7 | event_ | Pubkey |
| 8 | program | Pubkey |
| 9… | remaining | Vec< |
InitializePresetParameter#
Discriminator 42bc47d3626d0eba · data InitializePresetParameter · accounts InitializePresetParameterInstructionAccounts.
| Field | Type |
|---|---|
ix | InitPresetParametersIx |
Required accounts: 5; extras go to remaining.
Fields of InitializePresetParameterInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | preset_ | Pubkey |
| 1 | operator | Pubkey |
| 2 | signer | Pubkey |
| 3 | payer | Pubkey |
| 4 | system_ | Pubkey |
| 5… | remaining | Vec< |
InitializeReward#
Discriminator 5f87c0c4f281e644 · data InitializeReward · accounts InitializeRewardInstructionAccounts.
| Field | Type |
|---|---|
reward_ | u64 |
reward_ | u64 |
funder | Pubkey |
Required accounts: 11; extras go to remaining.
Fields of InitializeRewardInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | reward_ | Pubkey |
| 2 | reward_mint | Pubkey |
| 3 | token_badge | Option< |
| 4 | operator | Pubkey |
| 5 | signer | Pubkey |
| 6 | payer | Pubkey |
| 7 | token_ | Pubkey |
| 8 | system_ | Pubkey |
| 9 | event_ | Pubkey |
| 10 | program | Pubkey |
| 11… | remaining | Vec< |
InitializeTokenBadge#
Discriminator fd4dcd5f1be059df · data InitializeTokenBadge · accounts InitializeTokenBadgeInstructionAccounts.
No data fields.
Required accounts: 6; extras go to remaining.
Fields of InitializeTokenBadgeInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | token_mint | Pubkey |
| 1 | token_badge | Pubkey |
| 2 | operator | Pubkey |
| 3 | signer | Pubkey |
| 4 | payer | Pubkey |
| 5 | system_ | Pubkey |
| 6… | remaining | Vec< |
PlaceLimitOrder#
Discriminator 6cb021ba92e501c5 · data PlaceLimitOrder · accounts PlaceLimitOrderInstructionAccounts.
| Field | Type |
|---|---|
params | PlaceLimitOrderParams |
remaining_ | RemainingAccountsInfo |
Required accounts: 13; extras go to remaining.
Fields of PlaceLimitOrderInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | reserve | Pubkey |
| 3 | token_mint | Pubkey |
| 4 | limit_order | Pubkey |
| 5 | payer | Pubkey |
| 6 | owner | Pubkey |
| 7 | user_token | Pubkey |
| 8 | sender | Pubkey |
| 9 | token_ | Pubkey |
| 10 | system_ | Pubkey |
| 11 | event_ | Pubkey |
| 12 | program | Pubkey |
| 13… | remaining | Vec< |
RebalanceLiquidity#
Discriminator 5c04b0c177b95309 · data RebalanceLiquidity · accounts RebalanceLiquidityInstructionAccounts.
| Field | Type |
|---|---|
params | RebalanceLiquidityParams |
remaining_ | RemainingAccountsInfo |
Required accounts: 17; extras go to remaining.
Fields of RebalanceLiquidityInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | owner | Pubkey |
| 10 | rent_payer | Pubkey |
| 11 | token_ | Pubkey |
| 12 | token_ | Pubkey |
| 13 | memo_ | Pubkey |
| 14 | system_ | Pubkey |
| 15 | event_ | Pubkey |
| 16 | program | Pubkey |
| 17… | remaining | Vec< |
RemoveAllLiquidity#
Discriminator 0a333d2370691855 · data RemoveAllLiquidity · accounts RemoveAllLiquidityInstructionAccounts.
No data fields.
Required accounts: 16; extras go to remaining.
Fields of RemoveAllLiquidityInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | bin_ | Pubkey |
| 10 | bin_ | Pubkey |
| 11 | sender | Pubkey |
| 12 | token_ | Pubkey |
| 13 | token_ | Pubkey |
| 14 | event_ | Pubkey |
| 15 | program | Pubkey |
| 16… | remaining | Vec< |
RemoveLiquidity#
Discriminator 5055d14818ceb16c · data RemoveLiquidity · accounts RemoveLiquidityInstructionAccounts.
| Field | Type |
|---|---|
bin_ | Vec< |
Required accounts: 16; extras go to remaining.
Fields of RemoveLiquidityInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | bin_ | Pubkey |
| 10 | bin_ | Pubkey |
| 11 | sender | Pubkey |
| 12 | token_ | Pubkey |
| 13 | token_ | Pubkey |
| 14 | event_ | Pubkey |
| 15 | program | Pubkey |
| 16… | remaining | Vec< |
RemoveLiquidity2#
Discriminator e6d7527ff165e392 · data RemoveLiquidity2 · accounts RemoveLiquidity2InstructionAccounts.
| Field | Type |
|---|---|
bin_ | Vec< |
remaining_ | RemainingAccountsInfo |
Required accounts: 15; extras go to remaining.
Fields of RemoveLiquidity2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | sender | Pubkey |
| 10 | token_ | Pubkey |
| 11 | token_ | Pubkey |
| 12 | memo_ | Pubkey |
| 13 | event_ | Pubkey |
| 14 | program | Pubkey |
| 15… | remaining | Vec< |
RemoveLiquidityByRange#
Discriminator 1a526698f04a691a · data RemoveLiquidityByRange · accounts RemoveLiquidityByRangeInstructionAccounts.
| Field | Type |
|---|---|
from_bin_id | i32 |
to_bin_id | i32 |
bps_ | u16 |
Required accounts: 16; extras go to remaining.
Fields of RemoveLiquidityByRangeInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | bin_ | Pubkey |
| 10 | bin_ | Pubkey |
| 11 | sender | Pubkey |
| 12 | token_ | Pubkey |
| 13 | token_ | Pubkey |
| 14 | event_ | Pubkey |
| 15 | program | Pubkey |
| 16… | remaining | Vec< |
RemoveLiquidityByRange2#
Discriminator cc02c391359191cd · data RemoveLiquidityByRange2 · accounts RemoveLiquidityByRange2InstructionAccounts.
| Field | Type |
|---|---|
from_bin_id | i32 |
to_bin_id | i32 |
bps_ | u16 |
remaining_ | RemainingAccountsInfo |
Required accounts: 15; extras go to remaining.
Fields of RemoveLiquidityByRange2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Option< |
| 3 | user_ | Pubkey |
| 4 | user_ | Pubkey |
| 5 | reserve_x | Pubkey |
| 6 | reserve_y | Pubkey |
| 7 | token_ | Pubkey |
| 8 | token_ | Pubkey |
| 9 | sender | Pubkey |
| 10 | token_ | Pubkey |
| 11 | token_ | Pubkey |
| 12 | memo_ | Pubkey |
| 13 | event_ | Pubkey |
| 14 | program | Pubkey |
| 15… | remaining | Vec< |
SetActivationPoint#
Discriminator 5bf90fa51a81fe7d · data SetActivationPoint · accounts SetActivationPointInstructionAccounts.
| Field | Type |
|---|---|
activation_ | u64 |
Required accounts: 2; extras go to remaining.
Fields of SetActivationPointInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | signer | Pubkey |
| 2… | remaining | Vec< |
SetPairStatus#
Discriminator 43f8e7899a95d9ae · data SetPairStatus · accounts SetPairStatusInstructionAccounts.
| Field | Type |
|---|---|
status | u8 |
Required accounts: 3; extras go to remaining.
Fields of SetPairStatusInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | operator | Pubkey |
| 2 | signer | Pubkey |
| 3… | remaining | Vec< |
SetPairStatusPermissionless#
Discriminator 4e3b98d346b72ed0 · data SetPairStatusPermissionless · accounts SetPairStatusPermissionlessInstructionAccounts.
| Field | Type |
|---|---|
status | u8 |
Required accounts: 2; extras go to remaining.
Fields of SetPairStatusPermissionlessInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | signer | Pubkey |
| 2… | remaining | Vec< |
SetPermissionlessOperationBits#
Discriminator 543acb8ba351beba · data SetPermissionlessOperationBits · accounts SetPermissionlessOperationBitsInstructionAccounts.
| Field | Type |
|---|---|
bits | u8 |
Required accounts: 4; extras go to remaining.
Fields of SetPermissionlessOperationBitsInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | owner | Pubkey |
| 2 | event_ | Pubkey |
| 3 | program | Pubkey |
| 4… | remaining | Vec< |
SetPreActivationDuration#
Discriminator a53dc9f4829f1664 · data SetPreActivationDuration · accounts SetPreActivationDurationInstructionAccounts.
| Field | Type |
|---|---|
pre_ | u64 |
Required accounts: 2; extras go to remaining.
Fields of SetPreActivationDurationInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | signer | Pubkey |
| 2… | remaining | Vec< |
SetPreActivationSwapAddress#
Discriminator 398b2f7bd850df0a · data SetPreActivationSwapAddress · accounts SetPreActivationSwapAddressInstructionAccounts.
| Field | Type |
|---|---|
pre_ | Pubkey |
Required accounts: 2; extras go to remaining.
Fields of SetPreActivationSwapAddressInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | signer | Pubkey |
| 2… | remaining | Vec< |
Swap#
Discriminator f8c69e91e17587c8 · data Swap · accounts SwapInstructionAccounts.
| Field | Type |
|---|---|
amount_in | u64 |
min_ | u64 |
Required accounts: 15; extras go to remaining.
Fields of SwapInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | reserve_x | Pubkey |
| 3 | reserve_y | Pubkey |
| 4 | user_ | Pubkey |
| 5 | user_ | Pubkey |
| 6 | token_ | Pubkey |
| 7 | token_ | Pubkey |
| 8 | oracle | Pubkey |
| 9 | host_fee_in | Option< |
| 10 | user | Pubkey |
| 11 | token_ | Pubkey |
| 12 | token_ | Pubkey |
| 13 | event_ | Pubkey |
| 14 | program | Pubkey |
| 15… | remaining | Vec< |
Swap2#
Discriminator 414b3f4ceb5b5b88 · data Swap2 · accounts Swap2InstructionAccounts.
| Field | Type |
|---|---|
amount_in | u64 |
min_ | u64 |
remaining_ | RemainingAccountsInfo |
Required accounts: 16; extras go to remaining.
Fields of Swap2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | reserve_x | Pubkey |
| 3 | reserve_y | Pubkey |
| 4 | user_ | Pubkey |
| 5 | user_ | Pubkey |
| 6 | token_ | Pubkey |
| 7 | token_ | Pubkey |
| 8 | oracle | Pubkey |
| 9 | host_fee_in | Option< |
| 10 | user | Pubkey |
| 11 | token_ | Pubkey |
| 12 | token_ | Pubkey |
| 13 | memo_ | Pubkey |
| 14 | event_ | Pubkey |
| 15 | program | Pubkey |
| 16… | remaining | Vec< |
SwapExactOut#
Discriminator fa49652126cf4bb8 · data SwapExactOut · accounts SwapExactOutInstructionAccounts.
| Field | Type |
|---|---|
max_ | u64 |
out_amount | u64 |
Required accounts: 15; extras go to remaining.
Fields of SwapExactOutInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | reserve_x | Pubkey |
| 3 | reserve_y | Pubkey |
| 4 | user_ | Pubkey |
| 5 | user_ | Pubkey |
| 6 | token_ | Pubkey |
| 7 | token_ | Pubkey |
| 8 | oracle | Pubkey |
| 9 | host_fee_in | Option< |
| 10 | user | Pubkey |
| 11 | token_ | Pubkey |
| 12 | token_ | Pubkey |
| 13 | event_ | Pubkey |
| 14 | program | Pubkey |
| 15… | remaining | Vec< |
SwapExactOut2#
Discriminator 2bd7f784893cf351 · data SwapExactOut2 · accounts SwapExactOut2InstructionAccounts.
| Field | Type |
|---|---|
max_ | u64 |
out_amount | u64 |
remaining_ | RemainingAccountsInfo |
Required accounts: 16; extras go to remaining.
Fields of SwapExactOut2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | reserve_x | Pubkey |
| 3 | reserve_y | Pubkey |
| 4 | user_ | Pubkey |
| 5 | user_ | Pubkey |
| 6 | token_ | Pubkey |
| 7 | token_ | Pubkey |
| 8 | oracle | Pubkey |
| 9 | host_fee_in | Option< |
| 10 | user | Pubkey |
| 11 | token_ | Pubkey |
| 12 | token_ | Pubkey |
| 13 | memo_ | Pubkey |
| 14 | event_ | Pubkey |
| 15 | program | Pubkey |
| 16… | remaining | Vec< |
SwapWithPriceImpact#
Discriminator 38ade6d0ade49ccd · data SwapWithPriceImpact · accounts SwapWithPriceImpactInstructionAccounts.
| Field | Type |
|---|---|
amount_in | u64 |
active_id | Option<i32> |
max_ | u16 |
Required accounts: 15; extras go to remaining.
Fields of SwapWithPriceImpactInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | reserve_x | Pubkey |
| 3 | reserve_y | Pubkey |
| 4 | user_ | Pubkey |
| 5 | user_ | Pubkey |
| 6 | token_ | Pubkey |
| 7 | token_ | Pubkey |
| 8 | oracle | Pubkey |
| 9 | host_fee_in | Option< |
| 10 | user | Pubkey |
| 11 | token_ | Pubkey |
| 12 | token_ | Pubkey |
| 13 | event_ | Pubkey |
| 14 | program | Pubkey |
| 15… | remaining | Vec< |
SwapWithPriceImpact2#
Discriminator 4a62c0d6b1334b33 · data SwapWithPriceImpact2 · accounts SwapWithPriceImpact2InstructionAccounts.
| Field | Type |
|---|---|
amount_in | u64 |
active_id | Option<i32> |
max_ | u16 |
remaining_ | RemainingAccountsInfo |
Required accounts: 16; extras go to remaining.
Fields of SwapWithPriceImpact2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | bin_ | Option< |
| 2 | reserve_x | Pubkey |
| 3 | reserve_y | Pubkey |
| 4 | user_ | Pubkey |
| 5 | user_ | Pubkey |
| 6 | token_ | Pubkey |
| 7 | token_ | Pubkey |
| 8 | oracle | Pubkey |
| 9 | host_fee_in | Option< |
| 10 | user | Pubkey |
| 11 | token_ | Pubkey |
| 12 | token_ | Pubkey |
| 13 | memo_ | Pubkey |
| 14 | event_ | Pubkey |
| 15 | program | Pubkey |
| 16… | remaining | Vec< |
UpdateBaseFeeParameters#
Discriminator 4ba8dfa110c3032f · data UpdateBaseFeeParameters · accounts UpdateBaseFeeParametersInstructionAccounts.
| Field | Type |
|---|---|
fee_ | BaseFeeParameter |
Required accounts: 5; extras go to remaining.
Fields of UpdateBaseFeeParametersInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | operator | Pubkey |
| 2 | signer | Pubkey |
| 3 | event_ | Pubkey |
| 4 | program | Pubkey |
| 5… | remaining | Vec< |
UpdateDynamicFeeParameters#
Discriminator 5ca12ef6ffbd1616 · data UpdateDynamicFeeParameters · accounts UpdateDynamicFeeParametersInstructionAccounts.
| Field | Type |
|---|---|
fee_ | DynamicFeeParameter |
Required accounts: 5; extras go to remaining.
Fields of UpdateDynamicFeeParametersInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | operator | Pubkey |
| 2 | signer | Pubkey |
| 3 | event_ | Pubkey |
| 4 | program | Pubkey |
| 5… | remaining | Vec< |
UpdateFeesAndReward2#
Discriminator 208eb89a6741b858 · data UpdateFeesAndReward2 · accounts UpdateFeesAndReward2InstructionAccounts.
| Field | Type |
|---|---|
min_bin_id | i32 |
max_bin_id | i32 |
Required accounts: 3; extras go to remaining.
Fields of UpdateFeesAndReward2InstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | owner | Pubkey |
| 3… | remaining | Vec< |
UpdateFeesAndRewards#
Discriminator 9ae6fa0decd14bdf · data UpdateFeesAndRewards · accounts UpdateFeesAndRewardsInstructionAccounts.
No data fields.
Required accounts: 5; extras go to remaining.
Fields of UpdateFeesAndRewardsInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | lb_pair | Pubkey |
| 2 | bin_ | Pubkey |
| 3 | bin_ | Pubkey |
| 4 | owner | Pubkey |
| 5… | remaining | Vec< |
UpdatePositionOperator#
Discriminator cab8678fb4bf74d9 · data UpdatePositionOperator · accounts UpdatePositionOperatorInstructionAccounts.
| Field | Type |
|---|---|
operator | Pubkey |
Required accounts: 4; extras go to remaining.
Fields of UpdatePositionOperatorInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | position | Pubkey |
| 1 | owner | Pubkey |
| 2 | event_ | Pubkey |
| 3 | program | Pubkey |
| 4… | remaining | Vec< |
UpdateRewardDuration#
Discriminator 8aaec4a9d5ebfe6b · data UpdateRewardDuration · accounts UpdateRewardDurationInstructionAccounts.
| Field | Type |
|---|---|
reward_ | u64 |
new_ | u64 |
Required accounts: 6; extras go to remaining.
Fields of UpdateRewardDurationInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | operator | Pubkey |
| 2 | signer | Pubkey |
| 3 | bin_array | Pubkey |
| 4 | event_ | Pubkey |
| 5 | program | Pubkey |
| 6… | remaining | Vec< |
UpdateRewardFunder#
Discriminator d31c3020d7a02317 · data UpdateRewardFunder · accounts UpdateRewardFunderInstructionAccounts.
| Field | Type |
|---|---|
reward_ | u64 |
new_funder | Pubkey |
Required accounts: 5; extras go to remaining.
Fields of UpdateRewardFunderInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | operator | Pubkey |
| 2 | signer | Pubkey |
| 3 | event_ | Pubkey |
| 4 | program | Pubkey |
| 5… | remaining | Vec< |
WithdrawIneligibleReward#
Discriminator 94ce2ac3f7316708 · data WithdrawIneligibleReward · accounts WithdrawIneligibleRewardInstructionAccounts.
| Field | Type |
|---|---|
reward_ | u64 |
remaining_ | RemainingAccountsInfo |
Required accounts: 10; extras go to remaining.
Fields of WithdrawIneligibleRewardInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | reward_ | Pubkey |
| 2 | reward_mint | Pubkey |
| 3 | funder_ | Pubkey |
| 4 | funder | Pubkey |
| 5 | bin_array | Pubkey |
| 6 | token_ | Pubkey |
| 7 | memo_ | Pubkey |
| 8 | event_ | Pubkey |
| 9 | program | Pubkey |
| 10… | remaining | Vec< |
WithdrawProtocolFee#
Discriminator 9ec99ebd215da267 · data WithdrawProtocolFee · accounts WithdrawProtocolFeeInstructionAccounts.
| Field | Type |
|---|---|
max_ | u64 |
max_ | u64 |
remaining_ | RemainingAccountsInfo |
Required accounts: 11; extras go to remaining.
Fields of WithdrawProtocolFeeInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | reserve_x | Pubkey |
| 2 | reserve_y | Pubkey |
| 3 | token_ | Pubkey |
| 4 | token_ | Pubkey |
| 5 | receiver_ | Pubkey |
| 6 | receiver_ | Pubkey |
| 7 | operator | Pubkey |
| 8 | signer | Pubkey |
| 9 | token_ | Pubkey |
| 10 | token_ | Pubkey |
| 11… | remaining | Vec< |
ZapProtocolFee#
Discriminator d59bbb2238b65bf0 · data ZapProtocolFee · accounts ZapProtocolFeeInstructionAccounts.
| Field | Type |
|---|---|
max_amount | u64 |
remaining_ | RemainingAccountsInfo |
Required accounts: 8; extras go to remaining.
Fields of ZapProtocolFeeInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | lb_pair | Pubkey |
| 1 | reserve | Pubkey |
| 2 | token_mint | Pubkey |
| 3 | receiver_ | Pubkey |
| 4 | operator | Pubkey |
| 5 | signer | Pubkey |
| 6 | token_ | Pubkey |
| 7 | sysvar_ | Pubkey |
| 8… | remaining | Vec< |
CpiEvent#
Anchor self-CPI that carries one of the program's events. data is the CpiEvent enum.
Discriminator e445a52e51cb9a1d · data CpiEvent · accounts CpiEventInstructionAccounts.
Required accounts: 2; extras go to remaining.
Fields of CpiEventInstructionAccounts, in account order:
| # | Field | Type |
|---|---|---|
| 0 | program | Pubkey |
| 1 | event_ | Pubkey |
| 2… | remaining | Vec< |
Accounts#
Variants of MeteoraDlmmAccount. Each wraps a boxed struct from carbon_. decode_ only considers accounts owned by PROGRAM_ID and returns the first variant that matches.
BinArray#
Discriminator 5c8e5cdc059446b5 · accounts::.
| Field | Type |
|---|---|
index | i64 |
version | u8 |
padding1 | [u8; 7] |
lb_pair | Pubkey |
bins | [Bin; 70] |
BinArrayBitmapExtension#
Discriminator 506f7c7137ed1205 · accounts::.
| Field | Type | Description |
|---|---|---|
lb_pair | Pubkey | |
positive_ | [[u64; 8]; 12] | Packed initialized bin array state for start_bin_index is positive |
negative_ | [[u64; 8]; 12] | Packed initialized bin array state for start_bin_index is negative |
ClaimFeeOperator#
Discriminator a630865622c8bc96 · accounts::.
| Field | Type | Description |
|---|---|---|
operator | Pubkey | operator |
padding | [u8; 128] | Reserve |
DummyZcAccount#
Discriminator 5e6bee50d030b408 · accounts::.
| Field | Type |
|---|---|
position_ | PositionBinData |
LbPair#
Discriminator 210b3162b565b10d · accounts::.
| Field | Type | Description |
|---|---|---|
parameters | StaticParameters | |
v_ | VariableParameters | |
bump_seed | [u8; 1] | |
bin_ | [u8; 2] | Bin step signer seed |
pair_type | u8 | Type of the pair |
active_id | i32 | Active bin id |
bin_step | u16 | Bin step. Represent the price increment / decrement. |
status | u8 | Status of the pair. Check PairStatus enum. |
require_ | u8 | Require base factor seed |
base_ | [u8; 2] | Base factor seed |
activation_ | u8 | Activation type |
creator_ | u8 | Allow pool creator to enable/disable pool with restricted validation. Only applicable for customizable permissionless pair type. |
token_ | Pubkey | Token X mint |
token_ | Pubkey | Token Y mint |
reserve_x | Pubkey | LB token X vault |
reserve_y | Pubkey | LB token Y vault |
protocol_ | ProtocolFee | Uncollected protocol fee |
padding1 | [u8; 32] | padding 1 |
reward_ | [RewardInfo; 2] | Farming reward information |
oracle | Pubkey | Oracle pubkey |
bin_ | [u64; 16] | Packed initialized bin array state |
last_ | i64 | Last time the pool fee parameter was updated |
padding2 | [u8; 32] | _padding_2 |
pre_ | Pubkey | Address allowed to swap when the current point is greater than or equal to the pre-activation point. The pre-activation point is calculated as activation_. |
base_key | Pubkey | Base keypair. Only required for permission pair |
activation_ | u64 | Time point to enable the pair. Only applicable for permission pair. |
pre_ | u64 | Duration before activation activation_point. Used to calculate pre-activation time point for pre_activation_swap_address |
padding3 | [u8; 8] | _padding 3 |
padding4 | u64 | _padding_4 |
creator | Pubkey | Pool creator |
token_ | u8 | token_mint_x_program_flag |
token_ | u8 | token_mint_y_program_flag |
version | u8 | version to know whether we have reset tombstone fields |
reserved | [u8; 21] | Reserved space for future use |
LimitOrder#
Discriminator 89b7d45b731d8de3 · accounts::.
| Field | Type | Description |
|---|---|---|
lb_pair | Pubkey | The LB pair of this LO |
owner | Pubkey | Owner of the LO. Client rely on this to to fetch their LOs. |
bin_count | u16 | Bin count |
padding0 | [u8; 14] | Padding |
padding1 | [u64; 4] | Reserved space for future use |
Operator#
Discriminator db1fbc91458bcc75 · accounts::.
| Field | Type |
|---|---|
signer | Pubkey |
permission | u128 |
padding | [u64; 2] |
Oracle#
Discriminator 8bc283b38cb3e5f4 · accounts::.
| Field | Type | Description |
|---|---|---|
idx | u64 | Index of latest observation |
active_size | u64 | Size of active sample. Active sample is initialized observation. |
length | u64 | Number of observations |
PositionV2#
Discriminator 75b0d4c7f5b485b6 · accounts::.
| Field | Type | Description |
|---|---|---|
lb_pair | Pubkey | The LB pair of this position |
owner | Pubkey | Owner of the position. Client rely on this to to fetch their positions. |
liquidity_ | [u128; 70] | Liquidity shares of this position in bins (lower_bin_id <-> upper_bin_id). This is the same as LP concept. |
reward_ | [UserRewardInfo; 70] | Farming reward information |
fee_infos | [FeeInfo; 70] | Swap fee to claim information |
lower_ | i32 | Lower bin ID |
upper_ | i32 | Upper bin ID |
last_ | i64 | Last updated timestamp |
total_ | u64 | Total claimed token fee X |
total_ | u64 | Total claimed token fee Y |
total_ | [u64; 2] | Total claimed rewards |
operator | Pubkey | Operator of position |
lock_ | u64 | Time point which the locked liquidity can be withdraw |
padding0 | u8 | _padding_0, previous subjected_to_bootstrap_liquidity_locking, BE CAREFUL FOR TOMBSTONE WHEN REUSE !! |
fee_owner | Pubkey | Address is able to claim fee in this position, only valid for bootstrap_liquidity_position |
version | u8 | version to know whether we have reset tombstone fields |
permissionless_ | u8 | |
reserved | [u8; 85] | Reserved space for future use |
PresetParameter#
Discriminator f23ef422b5703aaa · accounts::.
| Field | Type | Description |
|---|---|---|
bin_step | u16 | Bin step. Represent the price increment / decrement. |
base_factor | u16 | Used for base fee calculation. base_fee_rate = base_factor * bin_step * 10 * 10^base_fee_power_factor |
filter_ | u16 | Filter period determine high frequency trading time window. |
decay_ | u16 | Decay period determine when the volatile fee start decay / decrease. |
reduction_ | u16 | Reduction factor controls the volatile fee rate decrement rate. |
variable_ | u32 | Used to scale the variable fee component depending on the dynamic of the market |
max_ | u32 | Maximum number of bin crossed can be accumulated. Used to cap volatile fee rate. |
min_bin_id | i32 | Min bin id supported by the pool based on the configured bin step. |
max_bin_id | i32 | Max bin id supported by the pool based on the configured bin step. |
protocol_ | u16 | Portion of swap fees retained by the protocol by controlling protocol_share parameter. protocol_swap_fee = protocol_share * total_swap_fee |
PresetParameter2#
Discriminator abec9473a271deae · accounts::.
| Field | Type | Description |
|---|---|---|
bin_step | u16 | Bin step. Represent the price increment / decrement. |
base_factor | u16 | Used for base fee calculation. base_fee_rate = base_factor * bin_step * 10 * 10^base_fee_power_factor |
filter_ | u16 | Filter period determine high frequency trading time window. |
decay_ | u16 | Decay period determine when the volatile fee start decay / decrease. |
variable_ | u32 | Used to scale the variable fee component depending on the dynamic of the market |
max_ | u32 | Maximum number of bin crossed can be accumulated. Used to cap volatile fee rate. |
reduction_ | u16 | Reduction factor controls the volatile fee rate decrement rate. |
protocol_ | u16 | Portion of swap fees retained by the protocol by controlling protocol_share parameter. protocol_swap_fee = protocol_share * total_swap_fee |
index | u16 | index |
base_ | u8 | Base fee power factor |
concrete_ | u8 | function type, to check whether the pool should have LM farming or other functions in the future, refer ConcreteFunctionType |
collect_ | u8 | collect fee mode |
padding0 | [u8; 7] | |
padding1 | [u64; 19] | Padding 1 for future use |
TokenBadge#
Discriminator 74dbcce5f974ff96 · accounts::.
| Field | Type | Description |
|---|---|---|
token_mint | Pubkey | token mint |
padding | [u8; 128] | Reserve |
Events#
Variants of instructions::, decoded from the CpiEvent instruction. Each wraps a struct from carbon_. The discriminator is the 8-byte event discriminator that follows the e445a52e51cb9a1d CPI-event tag.
AddLiquidity#
Discriminator 1f5e7d5ae3343dba · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
from | Pubkey |
position | Pubkey |
amounts | [u64; 2] |
active_ | i32 |
CancelLimitOrderEvt#
Discriminator 83eac285090ebdd1 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
from | Pubkey |
limit_order | Pubkey |
amounts | [u64; 2] |
active_id | i32 |
bins | Vec<i32> |
ClaimFee#
Discriminator 4b7a9a308c4a7ba3 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
position | Pubkey |
owner | Pubkey |
fee_x | u64 |
fee_y | u64 |
ClaimFee2#
Discriminator e8abf2613a4d232d · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
position | Pubkey |
owner | Pubkey |
fee_x | u64 |
fee_y | u64 |
active_ | i32 |
ClaimReward#
Discriminator 947486cc16ab555f · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
position | Pubkey |
owner | Pubkey |
reward_ | u64 |
total_ | u64 |
ClaimReward2#
Discriminator 1b8ff421502b6e92 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
position | Pubkey |
owner | Pubkey |
reward_ | u64 |
total_ | u64 |
active_ | i32 |
CloseLimitOrderEvt#
Discriminator 8e87084c5c3f7653 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
owner | Pubkey |
limit_order | Pubkey |
CompositionFee#
Discriminator 80977b6a1166718e · events::.
| Field | Type |
|---|---|
from | Pubkey |
bin_id | i16 |
token_ | u64 |
token_ | u64 |
protocol_ | u64 |
protocol_ | u64 |
DecreasePositionLength#
Discriminator 3476eb55aca90f80 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
position | Pubkey |
owner | Pubkey |
length_ | u16 |
side | u8 |
DynamicFeeParameterUpdate#
Discriminator 5858b287c2925bf3 · events::.
| Field | Type | Description |
|---|---|---|
lb_pair | Pubkey | |
filter_ | u16 | Filter period determine high frequency trading time window. |
decay_ | u16 | Decay period determine when the volatile fee start decay / decrease. |
reduction_ | u16 | Reduction factor controls the volatile fee rate decrement rate. |
variable_ | u32 | Used to scale the variable fee component depending on the dynamic of the market |
max_ | u32 | Maximum number of bin crossed can be accumulated. Used to cap volatile fee rate. |
FeeParameterUpdate#
Discriminator 304cf17590d7f22c · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
protocol_ | u16 |
base_factor | u16 |
base_ | u8 |
FundReward#
Discriminator f6e43a8291aa4fcc · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
funder | Pubkey |
reward_ | u64 |
amount | u64 |
GoToABin#
Discriminator 3b8a4c448a83b043 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
from_bin_id | i32 |
to_bin_id | i32 |
IncreaseObservation#
Discriminator 63f91179a69ccfd7 · events::.
| Field | Type |
|---|---|
oracle | Pubkey |
new_ | u64 |
IncreasePositionLength#
Discriminator 9def2acc1e38df2e · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
position | Pubkey |
owner | Pubkey |
length_ | u16 |
side | u8 |
InitializeReward#
Discriminator d399583e953cb146 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
reward_mint | Pubkey |
funder | Pubkey |
reward_ | u64 |
reward_ | u64 |
LbPairCreate#
Discriminator b94afc7d1bd7bc6f · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
bin_step | u16 |
token_x | Pubkey |
token_y | Pubkey |
PlaceLimitOrderEvt#
Discriminator 2b4f1ba9f41ce13f · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
sender | Pubkey |
owner | Pubkey |
limit_order | Pubkey |
active_id | i32 |
params | PlaceLimitOrderParams |
PositionClose#
Discriminator ffc4106b1cca3580 · events::.
| Field | Type |
|---|---|
position | Pubkey |
owner | Pubkey |
PositionCreate#
Discriminator 908efc549d352579 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
position | Pubkey |
owner | Pubkey |
Rebalancing#
Discriminator 006d75b33d5bc7c8 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
position | Pubkey |
owner | Pubkey |
active_ | i32 |
x_ | u64 |
x_ | u64 |
y_ | u64 |
y_ | u64 |
x_ | u64 |
y_ | u64 |
old_min_id | i32 |
old_max_id | i32 |
new_min_id | i32 |
new_max_id | i32 |
rewards | [u64; 2] |
RemoveLiquidity#
Discriminator 74f461e8671f983a · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
from | Pubkey |
position | Pubkey |
amounts | [u64; 2] |
active_ | i32 |
SetPositionPermissionlessOperationBitsEvt#
Discriminator c3e593f51d7d30a8 · events::.
| Field | Type |
|---|---|
position | Pubkey |
owner | Pubkey |
old_bits | u8 |
new_bits | u8 |
Swap#
Discriminator 516ce3becdd00ac4 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
from | Pubkey |
start_ | i32 |
end_bin_id | i32 |
amount_in | u64 |
amount_out | u64 |
swap_for_y | bool |
fee | u64 |
protocol_ | u64 |
fee_bps | u128 |
host_fee | u64 |
Swap2Evt#
Discriminator 2e7452d7941b544d · events::.
| Field | Type | Description |
|---|---|---|
lb_pair | Pubkey | |
from | Pubkey | |
start_ | i32 | |
end_bin_id | i32 | |
swap_for_y | bool | |
fee_bps | u128 | |
amount_in | u64 | Total amount, user transfer out |
amount_left | u64 | Leftover amount |
amount_out | u64 | Total amount transfer to user, including transfer fee |
mm_fee | u64 | Market maker fee |
protocol_ | u64 | Total protocol fee |
limit_ | u64 | Total limit order fee |
host_fee | u64 | Total host fee |
fees_ | bool | check if fees on input |
fees_ | bool | check if fees is on token x |
UpdatePositionLockReleasePoint#
Discriminator 85d642e0400c07bf · events::.
| Field | Type |
|---|---|
position | Pubkey |
current_ | u64 |
new_ | u64 |
old_ | u64 |
sender | Pubkey |
UpdatePositionOperator#
Discriminator 277330ccf62f4239 · events::.
| Field | Type |
|---|---|
position | Pubkey |
old_ | Pubkey |
new_ | Pubkey |
UpdateRewardDuration#
Discriminator dff5e099311da3ac · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
reward_ | u64 |
old_ | u64 |
new_ | u64 |
UpdateRewardFunder#
Discriminator e0b2ae4afca555b4 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
reward_ | u64 |
old_funder | Pubkey |
new_funder | Pubkey |
WithdrawIneligibleReward#
Discriminator e7bd419566d79af4 · events::.
| Field | Type |
|---|---|
lb_pair | Pubkey |
reward_mint | Pubkey |
amount | u64 |
Types#
Types used by the instructions, accounts and events above, exported from carbon_.
AccountsType#
Enum types::.
| Variant | Fields |
|---|---|
TransferHookX | |
TransferHookY | |
TransferHookReward | |
TransferHookMultiReward | u8 |
TransferHookReferral |
ActivationType#
From the program's IDL:
Type of the activation
Enum types::.
| Variant |
|---|
Slot |
Timestamp |
AddLiquidity#
Struct types::. Same fields as the AddLiquidity event.
AddLiquidityParams#
Struct types::.
| Field | Type |
|---|---|
min_ | i32 |
max_ | i32 |
x0 | u64 |
y0 | u64 |
delta_x | u64 |
delta_y | u64 |
bit_flag | u8 |
favor_ | bool |
padding | [u8; 16] |
AddLiquiditySingleSidePreciseParameter#
Struct types::.
| Field | Type |
|---|---|
bins | Vec< |
decompress_ | u64 |
AddLiquiditySingleSidePreciseParameter2#
Struct types::.
| Field | Type |
|---|---|
bins | Vec< |
decompress_ | u64 |
max_amount | u64 |
BaseFeeParameter#
Struct types::.
| Field | Type | Description |
|---|---|---|
protocol_ | u16 | Portion of swap fees retained by the protocol by controlling protocol_share parameter. protocol_swap_fee = protocol_share * total_swap_fee |
base_factor | u16 | Base factor for base fee rate |
base_ | u8 | Base fee power factor |
Bin#
Struct types::Bin.
| Field | Type | Description |
|---|---|---|
amount_x | u64 | Amount of token X in the bin for market making. This already excluded protocol fees. |
amount_y | u64 | Amount of token Y in the bin for market making. This already excluded protocol fees. |
price | u128 | Bin price |
liquidity_ | u128 | Bin MM liquidity supply. |
fulfilled_ | u64 | Total fulfilled order amount x |
fulfilled_ | u64 | Total fulfilled order amount y |
limit_ | u64 | Limit order fee collected by ask side orders |
limit_ | u64 | Limit order fee collected by bid side orders |
fee_ | u128 | Swap fee amount of token X per liquidity deposited. |
fee_ | u128 | Swap fee amount of token Y per liquidity deposited. |
open_ | u64 | Pending open limit orders amount in the bin. |
total_ | u64 | Total processing order amount |
processed_ | u64 | Remaining in processing open limit orders amount in the bin. |
order_age | u32 | Age |
limit_ | u8 | limit order flag |
padding1 | [u8; 3] | padding |
BinLimitOrderAmount#
Struct types::.
| Field | Type |
|---|---|
id | i32 |
amount | u64 |
BinLiquidityDistribution#
Struct types::.
| Field | Type | Description |
|---|---|---|
bin_id | i32 | Define the bin ID wish to deposit to. |
distribution_ | u16 | DistributionX (or distributionY) is the percentages of amountX (or amountY) you want to add to each bin. |
distribution_ | u16 | DistributionX (or distributionY) is the percentages of amountX (or amountY) you want to add to each bin. |
BinLiquidityDistributionByWeight#
Struct types::.
| Field | Type | Description |
|---|---|---|
bin_id | i32 | Define the bin ID wish to deposit to. |
weight | u16 | weight of liquidity distributed for this bin id |
BinLiquidityReduction#
Struct types::.
| Field | Type |
|---|---|
bin_id | i32 |
bps_ | u16 |
CancelLimitOrderEvt#
Struct types::. Same fields as the CancelLimitOrderEvt event.
ClaimFee#
Struct types::. Same fields as the ClaimFee event.
ClaimFee2#
Struct types::. Same fields as the ClaimFee2 event.
ClaimReward#
Struct types::. Same fields as the ClaimReward event.
ClaimReward2#
Struct types::. Same fields as the ClaimReward2 event.
CloseLimitOrderEvt#
Struct types::. Same fields as the CloseLimitOrderEvt event.
CompositionFee#
Struct types::. Same fields as the CompositionFee event.
CompressedBinDepositAmount#
Struct types::.
| Field | Type |
|---|---|
bin_id | i32 |
amount | u32 |
CustomizableParams#
Struct types::.
| Field | Type | Description |
|---|---|---|
active_id | i32 | Pool price |
bin_step | u16 | Bin step |
base_factor | u16 | Base factor |
activation_ | u8 | Activation type. 0 = Slot, 1 = Time. Check ActivationType enum |
has_ | bool | Whether the pool has an alpha vault |
activation_ | Option<u64> | Decide when does the pool start trade. None = Now |
creator_ | bool | Pool creator have permission to enable/disable pool with restricted program validation. Only applicable for customizable permissionless pool. |
base_ | u8 | Base fee power factor |
concrete_ | u8 | Concrete function type |
collect_ | u8 | Collect fee mode |
padding | [u8; 60] | Padding, for future use |
DecreasePositionLength#
Struct types::. Same fields as the DecreasePositionLength event.
DummyIx#
Struct types::.
| Field | Type |
|---|---|
pair_status | PairStatus |
pair_type | PairType |
activation_ | ActivationType |
token_ | TokenProgramFlags |
resize_side | ResizeSide |
rounding | Rounding |
DynamicFeeParameter#
Struct types::.
| Field | Type | Description |
|---|---|---|
filter_ | u16 | Filter period determine high frequency trading time window. |
decay_ | u16 | Decay period determine when the volatile fee start decay / decrease. |
reduction_ | u16 | Reduction factor controls the volatile fee rate decrement rate. |
variable_ | u32 | Used to scale the variable fee component depending on the dynamic of the market |
max_ | u32 | Maximum number of bin crossed can be accumulated. Used to cap volatile fee rate. |
DynamicFeeParameterUpdate#
Struct types::. Same fields as the DynamicFeeParameterUpdate event.
FeeInfo#
Struct types::.
| Field | Type |
|---|---|
fee_ | u128 |
fee_ | u128 |
fee_ | u64 |
fee_ | u64 |
FeeParameterUpdate#
Struct types::. Same fields as the FeeParameterUpdate event.
FundReward#
Struct types::. Same fields as the FundReward event.
GoToABin#
Struct types::. Same fields as the GoToABin event.
IncreaseObservation#
Struct types::. Same fields as the IncreaseObservation event.
IncreasePositionLength#
Struct types::. Same fields as the IncreasePositionLength event.
InitializeLbPair2Params#
Struct types::.
| Field | Type | Description |
|---|---|---|
active_id | i32 | Pool price |
padding | [u8; 96] | Padding, for future use |
InitializeReward#
Struct types::. Same fields as the InitializeReward event.
InitPermissionPairIx#
Struct types::.
| Field | Type |
|---|---|
active_id | i32 |
bin_step | u16 |
base_factor | u16 |
base_ | u8 |
activation_ | u8 |
padding0 | u16 |
concrete_ | u8 |
collect_ | u8 |
InitPresetParametersIx#
Struct types::.
| Field | Type | Description |
|---|---|---|
index | u16 | |
bin_step | u16 | Bin step. Represent the price increment / decrement. |
base_factor | u16 | Used for base fee calculation. base_fee_rate = base_factor * bin_step * 10 * 10^base_fee_power_factor |
filter_ | u16 | Filter period determine high frequency trading time window. |
decay_ | u16 | Decay period determine when the volatile fee start decay / decrease. |
reduction_ | u16 | Reduction factor controls the volatile fee rate decrement rate. |
variable_ | u32 | Used to scale the variable fee component depending on the dynamic of the market |
max_ | u32 | Maximum number of bin crossed can be accumulated. Used to cap volatile fee rate. |
protocol_ | u16 | Portion of swap fees retained by the protocol by controlling protocol_share parameter. protocol_swap_fee = protocol_share * total_swap_fee |
base_ | u8 | Base fee power factor |
concrete_ | u8 | function type |
collect_ | u8 | collect fee mode |
LbPairCreate#
Struct types::. Same fields as the LbPairCreate event.
LiquidityOneSideParameter#
Struct types::.
| Field | Type | Description |
|---|---|---|
amount | u64 | Amount of X token or Y token to deposit |
active_id | i32 | Active bin that integrator observe off-chain |
max_ | i32 | max active bin slippage allowed |
bin_ | Vec< | Liquidity distribution to each bins |
LiquidityParameter#
Struct types::.
| Field | Type | Description |
|---|---|---|
amount_x | u64 | Amount of X token to deposit |
amount_y | u64 | Amount of Y token to deposit |
bin_ | Vec< | Liquidity distribution to each bins |
LiquidityParameterByStrategy#
Struct types::.
| Field | Type | Description |
|---|---|---|
amount_x | u64 | Amount of X token to deposit |
amount_y | u64 | Amount of Y token to deposit |
active_id | i32 | Active bin that integrator observe off-chain |
max_ | i32 | max active bin slippage allowed |
strategy_ | StrategyParameters | strategy parameters |
LiquidityParameterByStrategyOneSide#
Struct types::.
| Field | Type | Description |
|---|---|---|
amount | u64 | Amount of X token or Y token to deposit |
active_id | i32 | Active bin that integrator observe off-chain |
max_ | i32 | max active bin slippage allowed |
strategy_ | StrategyParameters | strategy parameters |
LiquidityParameterByWeight#
Struct types::.
| Field | Type | Description |
|---|---|---|
amount_x | u64 | Amount of X token to deposit |
amount_y | u64 | Amount of Y token to deposit |
active_id | i32 | Active bin that integrator observe off-chain |
max_ | i32 | max active bin slippage allowed |
bin_ | Vec< | Liquidity distribution to each bins |
PairStatus#
From the program's IDL:
Pair status. 0 = Enabled, 1 = Disabled. Putting 0 as enabled for backward compatibility.
Enum types::.
| Variant |
|---|
Enabled |
Disabled |
PairType#
From the program's IDL:
Type of the Pair. 0 = Permissionless, 1 = Permission, 2 =
CustomizablePermissionless. Putting 0 as permissionless for backward compatibility.
Enum types::.
| Variant |
|---|
Permissionless |
Permission |
CustomizablePermissionless |
PermissionlessV2 |
PlaceLimitOrderEvt#
Struct types::. Same fields as the PlaceLimitOrderEvt event.
PlaceLimitOrderParams#
Struct types::.
| Field | Type |
|---|---|
is_ask_side | bool |
padding | [u8; 16] |
relative_ | Option< |
bins | Vec< |
PositionBinData#
Struct types::.
| Field | Type |
|---|---|
liquidity_ | u128 |
reward_info | UserRewardInfo |
fee_info | FeeInfo |
PositionClose#
Struct types::. Same fields as the PositionClose event.
PositionCreate#
Struct types::. Same fields as the PositionCreate event.
ProtocolFee#
Struct types::.
| Field | Type |
|---|---|
amount_x | u64 |
amount_y | u64 |
RebalanceLiquidityParams#
Struct types::.
| Field | Type | Description |
|---|---|---|
active_id | i32 | active id |
max_ | u16 | max active bin slippage allowed |
should_ | bool | a flag to indicate that whether fee should be harvested |
should_ | bool | a flag to indicate that whether rewards should be harvested |
min_ | u64 | threshold for withdraw token x |
max_ | u64 | threshold for deposit token x |
min_ | u64 | threshold for withdraw token y |
max_ | u64 | threshold for deposit token y |
shrink_mode | u8 | shrink mode |
padding | [u8; 31] | padding 32 bytes for future usage |
removes | Vec< | removes |
adds | Vec< | adds |
Rebalancing#
Struct types::. Same fields as the Rebalancing event.
RelativeBin#
Struct types::.
| Field | Type | Description |
|---|---|---|
active_id | i32 | Active bin that integrator observe off-chain |
max_ | i32 | max active bin slippage allowed |
RemainingAccountsInfo#
Struct types::.
| Field | Type |
|---|---|
slices | Vec< |
RemainingAccountsSlice#
Struct types::.
| Field | Type |
|---|---|
accounts_ | AccountsType |
length | u8 |
RemoveLiquidity#
Struct types::. Same fields as the RemoveLiquidity event.
RemoveLiquidityParams#
Struct types::.
| Field | Type |
|---|---|
min_bin_id | Option<i32> |
max_bin_id | Option<i32> |
bps | u16 |
padding | [u8; 16] |
ResizeSide#
From the program's IDL:
Side of resize, 0 for lower and 1 for upper
Enum types::.
| Variant |
|---|
Lower |
Upper |
RewardInfo#
From the program's IDL:
Stores the state relevant for tracking liquidity mining rewards
Struct types::.
| Field | Type | Description |
|---|---|---|
mint | Pubkey | Reward token mint. |
vault | Pubkey | Reward vault token account. |
funder | Pubkey | Authority account that allows to fund rewards |
reward_ | u64 | LM reward duration in seconds. |
reward_ | u64 | LM reward duration end time. |
reward_rate | u128 | LM reward rate |
last_ | u64 | The last time reward states were updated. |
cumulative_ | u64 | Accumulated seconds where when farm distribute rewards, but the bin is empty. The reward will be accumulated for next reward time window. |
Rounding#
Enum types::.
| Variant |
|---|
Up |
Down |
SetPositionPermissionlessOperationBitsEvt#
Struct types::. Same fields as the SetPositionPermissionlessOperationBitsEvt event.
StaticParameters#
From the program's IDL:
Parameter that set by the protocol
Struct types::.
| Field | Type | Description |
|---|---|---|
base_factor | u16 | Used for base fee calculation. base_fee_rate = base_factor * bin_step * 10 * 10^base_fee_power_factor |
filter_ | u16 | Filter period determine high frequency trading time window. |
decay_ | u16 | Decay period determine when the volatile fee start decay / decrease. |
reduction_ | u16 | Reduction factor controls the volatile fee rate decrement rate. |
variable_ | u32 | Used to scale the variable fee component depending on the dynamic of the market |
max_ | u32 | Maximum number of bin crossed can be accumulated. Used to cap volatile fee rate. |
min_bin_id | i32 | Min bin id supported by the pool based on the configured bin step. |
max_bin_id | i32 | Max bin id supported by the pool based on the configured bin step. |
protocol_ | u16 | Portion of swap fees retained by the protocol by controlling protocol_share parameter. protocol_swap_fee = protocol_share * total_swap_fee |
base_ | u8 | Base fee power factor |
function_ | u8 | function type |
collect_ | u8 | Collect fee mode |
padding | [u8; 3] | Padding for bytemuck safe alignment |
StrategyParameters#
Struct types::.
| Field | Type | Description |
|---|---|---|
min_bin_id | i32 | min bin id |
max_bin_id | i32 | max bin id |
strategy_ | StrategyType | strategy type |
parameteres | [u8; 64] | parameters |
StrategyType#
Enum types::.
| Variant |
|---|
SpotOneSide |
CurveOneSide |
BidAskOneSide |
SpotBalanced |
CurveBalanced |
BidAskBalanced |
SpotImBalanced |
CurveImBalanced |
BidAskImBalanced |
Swap#
Struct types::Swap. Same fields as the Swap event.
Swap2Evt#
Struct types::. Same fields as the Swap2Evt event.
TokenProgramFlags#
Enum types::.
| Variant |
|---|
TokenProgram |
TokenProgram2022 |
UpdatePositionLockReleasePoint#
Struct types::. Same fields as the UpdatePositionLockReleasePoint event.
UpdatePositionOperator#
Struct types::. Same fields as the UpdatePositionOperator event.
UpdateRewardDuration#
Struct types::. Same fields as the UpdateRewardDuration event.
UpdateRewardFunder#
Struct types::. Same fields as the UpdateRewardFunder event.
UserRewardInfo#
Struct types::.
| Field | Type |
|---|---|
reward_ | [u128; 2] |
reward_ | [u64; 2] |
VariableParameters#
From the program's IDL:
Parameters that changes based on dynamic of the market
Struct types::.
| Field | Type | Description |
|---|---|---|
volatility_ | u32 | Volatility accumulator measure the number of bin crossed since reference bin ID. Normally (without filter period taken into consideration), reference bin ID is the active bin of last swap. It affects the variable fee rate |
volatility_ | u32 | Volatility reference is decayed volatility accumulator. It is always <= volatility_accumulator |
index_ | i32 | Active bin id of last swap. |
padding | [u8; 4] | Padding for bytemuck safe alignment |
last_ | i64 | Last timestamp the variable parameters was updated |
padding1 | [u8; 8] | Padding for bytemuck safe alignment |
WithdrawIneligibleReward#
Struct types::. Same fields as the WithdrawIneligibleReward event.