1
0
mirror of https://github.com/payden/libwsclient synced 2025-06-13 12:53:52 +00:00
payden_libwsclient/dex/dex_integration.rs

11 lines
435 B
Rust
Raw Permalink Normal View History

2025-05-16 06:09:24 +00:00
use async_trait::async_trait;
use solana_sdk::pubkey::Pubkey;
use std::collections::HashMap;
#[async_trait]
pub trait DexIntegration {
async fn get_prices(&self) -> HashMap<String, f64>;
async fn get_account_balances(&self, account: &Pubkey) -> HashMap<String, f64>;
async fn place_order(&self, market: &str, side: &str, size: f64, price: f64) -> Option<String>;
async fn cancel_order(&self, order_id: &str) -> bool;
}