All Projects → inv2004 → coinbase-pro-rs

inv2004 / coinbase-pro-rs

Licence: Apache-2.0 license
Coinbase pro client for Rust

Programming Languages

rust
11053 projects

Projects that are alternatives of or similar to coinbase-pro-rs

Crypto Trading Bot
Cryptocurrency trading bot in javascript for Bitfinex, Bitmex, Binance, FTX, Bybit ... (public edition)
Stars: ✭ 1,089 (+757.48%)
Mutual labels:  trading, coinbase, exchange
Krypto Trading Bot
Self-hosted crypto trading bot (automated high frequency market making) written in C++
Stars: ✭ 2,589 (+1938.58%)
Mutual labels:  trading, coinbase, exchange
Coinbasepro Python
The unofficial Python client for the Coinbase Pro API
Stars: ✭ 1,386 (+991.34%)
Mutual labels:  trading, coinbase, exchange
Cryptofeed
Cryptocurrency Exchange Websocket Data Feed Handler
Stars: ✭ 643 (+406.3%)
Mutual labels:  trading, coinbase, exchange
Coinbase Pro Node
Coinbase Pro API written in TypeScript and covered by tests.
Stars: ✭ 116 (-8.66%)
Mutual labels:  trading, coinbase, exchange
Socktrader
🚀 Websocket based trading bot for 💰cryptocurrencies 📈
Stars: ✭ 152 (+19.69%)
Mutual labels:  trading, exchange
Coinbase Exchange Order Book
Real-time Coinbase Exchange (GDAX) order book + basic market maker bot
Stars: ✭ 177 (+39.37%)
Mutual labels:  trading, coinbase
Orderbook
Matching Engine for Limit Order Book in Golang
Stars: ✭ 181 (+42.52%)
Mutual labels:  trading, exchange
Ccxt Rest
Open Source Unified REST API of 100+ Crypto Exchange Sites (18k+ docker pulls) - https://ccxt-rest.io/
Stars: ✭ 210 (+65.35%)
Mutual labels:  trading, exchange
Cassandre Trading Bot
Cassandre makes it easy to create your Java crypto trading bot. Our Spring boot starter takes care of exchange connections, accounts, orders, trades, and positions.
Stars: ✭ 120 (-5.51%)
Mutual labels:  trading, coinbase
Opendax
Open-Source Cloud-Native Digital Asset & Cryptocurrency Exchange Platform
Stars: ✭ 183 (+44.09%)
Mutual labels:  trading, exchange
Cryptotrader
A cryptocurrency trader for all famous exchanges
Stars: ✭ 228 (+79.53%)
Mutual labels:  trading, exchange
Roq Api
API for algorithmic and high-frequency trading
Stars: ✭ 132 (+3.94%)
Mutual labels:  trading, exchange
Coinnect
Coinnect is a Rust library aiming to provide a complete access to main crypto currencies exchanges via REST API.
Stars: ✭ 130 (+2.36%)
Mutual labels:  trading, exchange
Tardis Node
Convenient access to tick-level real-time and historical cryptocurrency market data via Node.js
Stars: ✭ 126 (-0.79%)
Mutual labels:  trading, exchange
Uniswap Python
🦄 The unofficial Python client for the Uniswap exchange.
Stars: ✭ 191 (+50.39%)
Mutual labels:  trading, exchange
adamant-tradebot
Free market-making software for cryptocurrency projects and exchanges. Makes trade volume, maintains spread and liquidity/depth, set price range, and builds live-like dynamic order book.
Stars: ✭ 113 (-11.02%)
Mutual labels:  trading, exchange
Blankly
🚀 💸 Easily build, backtest and deploy your algo in just a few lines of code. Trade stocks, cryptos, and forex across exchanges w/ one package.
Stars: ✭ 1,456 (+1046.46%)
Mutual labels:  trading, coinbase
coincube
A Python/Vue.js crypto portfolio management and trade automation program with support for 10 exchanges.
Stars: ✭ 85 (-33.07%)
Mutual labels:  trading, exchange
hurtrade
An Open Source Forex Trading Platform
Stars: ✭ 22 (-82.68%)
Mutual labels:  trading, exchange

Build Status Crates.io Docs.rs

Coinbase pro client for Rust

Supports SYNC/ASYNC/Websocket-feed data support

Features

  • private and public API
  • sync and async support
  • websocket-feed support

Examples

Cargo.toml:

[dependencies]
coinbase-pro-rs = "0.7.1"

Async

use hyper::rt::Future;
use coinbase_pro_rs::{Public, ASync, SANDBOX_URL};

fn main() {
    let client: Public<ASync> = Public::new_with_keep_alive(SANDBOX_URL, false);
    // if keep_alive is not disables - tokio::run will hold the connection without exiting the example
    let f = client.get_time()
        .map_err(|_| ())
        .and_then(|time| {
            println!("Coinbase.time: {}", time.iso);
            Ok(())
        });

    tokio::run(f); // waiting for tokio
}

Sync

use coinbase_pro_rs::{Public, Sync, SANDBOX_URL};

fn main() {
   let client: Public<Sync> = Public::new(SANDBOX_URL);
   let time = client.get_time().unwrap();
   println!("Coinbase.time: {}", time.iso);
}

Websocket

use futures::{Future, Stream};
use coinbase_pro_rs::{WSFeed, WS_SANDBOX_URL};
use coinbase_pro_rs::structs::wsfeed::*;

fn main() {
    let stream = WSFeed::connect(WS_SANDBOX_URL,
        &["BTC-USD"], &[ChannelType::Heartbeat])
        .await
        .unwrap();

    let f = stream
        .take(10)
        .for_each(|msg| {
        match msg {
            Message::Heartbeat {sequence, last_trade_id, time, ..} => println!("{}: seq:{} id{}",
                                                                               time, sequence, last_trade_id),
            Message::Error {message} => println!("Error: {}", message),
            Message::InternalError(_) => panic!("internal_error"),
            other => println!("{:?}", other)
        }
        Ok(())
    });

    tokio::run(f.map_err(|_| panic!("stream fail")));
}

Api supported:

  • SYNC
  • ASYNC
  • Websocket-Feed

API

  • Requests
  • Pagination
  • Types
  • Private
    • Authentication
    • Accounts
    • Orders
    • Fills
    • Deposits
      • List
    • Withdrawals
      • List
    • Payment Methods
    • Coinbase Accounts
    • Fees
    • Reports
    • User Account
  • Market Data
    • Products
    • Currencies
    • Time
  • Websocket Feed
    • heartbeat
    • ticker
    • level2
    • user
    • matches
    • full

FIX API

by request

OrderBook

https://github.com/inv2004/orderbook-rs

Tests

cargo test

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].