pub struct TradeTxParams {
pub mint: Pubkey,
pub base_token_program: Pubkey,
pub user: Pubkey,
pub creator: Pubkey,
pub fee_recipient: Pubkey,
pub buyback_fee_recipient: Pubkey,
pub is_buy: bool,
pub venue: TradeVenue,
pub is_cashback_coin: bool,
pub base_amount: u64,
pub sol_amount_threshold: u64,
}Expand description
Inputs to PumpSdk::trade_tx_instructions. Quote mint is hard-wired to
wSOL: sol_amount_threshold is the SOL ceiling on buy and the SOL floor
on sell. Caller pre-computes amounts via the existing *_quote_* helpers.
Fields§
§mint: Pubkey§base_token_program: Pubkey§user: Pubkey§creator: Pubkey§fee_recipient: Pubkey§buyback_fee_recipient: Pubkey§is_buy: bool§venue: TradeVenue§is_cashback_coin: boolOnly consumed by the AMM venue; ignored for BondingCurve.
base_amount: u64§sol_amount_threshold: u64Trait Implementations§
Source§impl Clone for TradeTxParams
impl Clone for TradeTxParams
Source§fn clone(&self) -> TradeTxParams
fn clone(&self) -> TradeTxParams
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TradeTxParams
impl Debug for TradeTxParams
impl Copy for TradeTxParams
Auto Trait Implementations§
impl Freeze for TradeTxParams
impl RefUnwindSafe for TradeTxParams
impl Send for TradeTxParams
impl Sync for TradeTxParams
impl Unpin for TradeTxParams
impl UnsafeUnpin for TradeTxParams
impl UnwindSafe for TradeTxParams
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more