feat(pumpswap): Add fee configuration support v0.5.6

This commit is contained in:
ysq
2025-09-03 21:06:14 +08:00
parent db3b50fc28
commit 02af3e98e2
6 changed files with 30 additions and 8 deletions
+10 -1
View File
@@ -16,7 +16,7 @@ use crate::{
},
pumpswap::common::{
coin_creator_vault_ata, coin_creator_vault_authority, fee_recipient_ata,
get_global_volume_accumulator_pda, get_user_volume_accumulator_pda,
get_fee_config_pda, get_global_volume_accumulator_pda, get_user_volume_accumulator_pda,
},
},
utils::calc::pumpswap::{buy_quote_input_internal, sell_base_input_internal},
@@ -272,6 +272,10 @@ impl PumpSwapInstructionBuilder {
false,
));
}
accounts
.push(solana_sdk::instruction::AccountMeta::new(get_fee_config_pda().unwrap(), false));
accounts
.push(solana_sdk::instruction::AccountMeta::new_readonly(accounts::FEE_PROGRAM, false));
// Create instruction data
let mut data = vec![];
@@ -461,6 +465,11 @@ impl PumpSwapInstructionBuilder {
));
}
accounts
.push(solana_sdk::instruction::AccountMeta::new(get_fee_config_pda().unwrap(), false));
accounts
.push(solana_sdk::instruction::AccountMeta::new_readonly(accounts::FEE_PROGRAM, false));
// Create instruction data
let mut data = vec![];
if quote_mint_is_wsol {