diff --git a/Cargo.toml b/Cargo.toml index f2238bc..772920a 100755 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "solana-streamer-sdk" -version = "0.1.7" +version = "0.1.8" edition = "2021" authors = ["William ", "sgxiang ", "wei <1415121722@qq.com>"] repository = "https://github.com/0xfnzero/solana-streamer" diff --git a/README.md b/README.md index ea165a4..1e6516a 100755 --- a/README.md +++ b/README.md @@ -33,14 +33,14 @@ Add the dependency to your `Cargo.toml`: ```toml # Add to your Cargo.toml -solana-streamer-sdk = { path = "./solana-streamer", version = "0.1.7" } +solana-streamer-sdk = { path = "./solana-streamer", version = "0.1.8" } ``` ### Use crates.io ```toml # Add to your Cargo.toml -solana-streamer-sdk = "0.1.7" +solana-streamer-sdk = "0.1.8" ``` ## Usage Examples diff --git a/README_CN.md b/README_CN.md index 6d9f91e..5ad5eda 100644 --- a/README_CN.md +++ b/README_CN.md @@ -33,14 +33,14 @@ git clone https://github.com/0xfnzero/solana-streamer ```toml # 添加到您的 Cargo.toml -solana-streamer-sdk = { path = "./solana-streamer", version = "0.1.7" } +solana-streamer-sdk = { path = "./solana-streamer", version = "0.1.8" } ``` ### 使用 crates.io ```toml # 添加到您的 Cargo.toml -solana-streamer-sdk = "0.1.7" +solana-streamer-sdk = "0.1.8" ``` ## 使用示例 diff --git a/src/streaming/event_parser/protocols/pumpfun/events.rs b/src/streaming/event_parser/protocols/pumpfun/events.rs index 99c04ac..ebbaabf 100755 --- a/src/streaming/event_parser/protocols/pumpfun/events.rs +++ b/src/streaming/event_parser/protocols/pumpfun/events.rs @@ -2,8 +2,8 @@ use borsh::BorshDeserialize; use serde::{Deserialize, Serialize}; use solana_sdk::pubkey::Pubkey; -use crate::streaming::event_parser::common::EventMetadata; use crate::impl_unified_event; +use crate::streaming::event_parser::common::EventMetadata; #[derive(Clone, Debug, Default, PartialEq, Eq, Serialize, Deserialize, BorshDeserialize)] pub struct PumpFunCreateTokenEvent { @@ -55,7 +55,7 @@ pub struct PumpFunTradeEvent { pub real_sol_reserves: u64, pub real_token_reserves: u64, pub fee_recipient: Pubkey, - pub fee_basis_points: u64, + pub fee_basis_points: u64, pub fee: u64, pub creator: Pubkey, pub creator_fee_basis_points: u64, @@ -78,6 +78,10 @@ pub struct PumpFunTradeEvent { pub is_bot: bool, #[borsh(skip)] pub is_dev_create_token_trade: bool, // 是否是dev创建token的交易 + #[borsh(skip)] + pub global_volume_accumulator: Pubkey, + #[borsh(skip)] + pub user_volume_accumulator: Pubkey, } impl_unified_event!( diff --git a/src/streaming/event_parser/protocols/pumpfun/parser.rs b/src/streaming/event_parser/protocols/pumpfun/parser.rs index 80c0be6..53a72c9 100755 --- a/src/streaming/event_parser/protocols/pumpfun/parser.rs +++ b/src/streaming/event_parser/protocols/pumpfun/parser.rs @@ -174,7 +174,9 @@ impl PumpFunEventParser { associated_bonding_curve: accounts[4], associated_user: accounts[5], user: accounts[6], - creator_vault: accounts[8], + creator_vault: accounts[9], + global_volume_accumulator: accounts[12], + user_volume_accumulator: accounts[13], max_sol_cost, amount, is_buy: true, @@ -209,7 +211,7 @@ impl PumpFunEventParser { associated_bonding_curve: accounts[4], associated_user: accounts[5], user: accounts[6], - creator_vault: accounts[8], + creator_vault: accounts[9], min_sol_output, amount, is_buy: false,