feat: upgrade to v1.1.0 and add universal token swap functionality

- Version bump: upgrade from 1.0.2 to 1.1.0
- Add TradeSwapParams struct for universal token-to-token swapping
- Update bonk_copy_trading example to use new swap method instead of buy/sell
- Expand trading parameters documentation with TradeSwapParams details
- Fix SOL_TOKEN_ACCOUNT constant definition
- Add USD1 token support (Bonk protocol only)
- Enhance account management and optimization options for token swaps
This commit is contained in:
ysq
2025-09-22 01:09:41 +08:00
parent 4780e71c11
commit 334e685104
8 changed files with 276 additions and 22 deletions
+1 -1
View File
@@ -24,7 +24,7 @@ pub const TOKEN_PROGRAM_2022_META: solana_sdk::instruction::AccountMeta =
is_writable: false,
};
pub const SOL_TOKEN_ACCOUNT: Pubkey = pubkey!("So11111111111111111111111111111111111111112");
pub const SOL_TOKEN_ACCOUNT: Pubkey = pubkey!("So11111111111111111111111111111111111111111");
pub const WSOL_TOKEN_ACCOUNT: Pubkey = pubkey!("So11111111111111111111111111111111111111112");
pub const WSOL_TOKEN_ACCOUNT_META: solana_sdk::instruction::AccountMeta =