Skip to content

danmandel/trading-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Trading Client

trading-client is a Rust library that provides a convenient wrapper for commonly used trading platform APIs under a single unified interface. Currently an experimental work in progress that only supports Alpaca.

Supported API

pub trait TradingClient {
    fn new(config: &Config) -> Self
    where
        Self: Sized;
    async fn create_order(&self, order: &Order) -> Result<(), Box<dyn std::error::Error>>; // TODO: OrderResponse
    async fn get_asset(&self, symbol: &str) -> Result<Asset, Box<dyn std::error::Error>>;
    async fn subscribe_to_data(
        &self,
        symbol: &str,
    ) -> std::result::Result<(), Box<dyn std::error::Error>>;
}

About

Rust wrapper for trading platform web APIs

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages