diff --git a/CryptoExchange.Net.UnitTests/CryptoExchange.Net.UnitTests.csproj b/CryptoExchange.Net.UnitTests/CryptoExchange.Net.UnitTests.csproj index b0e7bd2..3072a08 100644 --- a/CryptoExchange.Net.UnitTests/CryptoExchange.Net.UnitTests.csproj +++ b/CryptoExchange.Net.UnitTests/CryptoExchange.Net.UnitTests.csproj @@ -6,10 +6,10 @@ - + - - + + diff --git a/CryptoExchange.Net/CryptoExchange.Net.csproj b/CryptoExchange.Net/CryptoExchange.Net.csproj index df2faf3..007a4c7 100644 --- a/CryptoExchange.Net/CryptoExchange.Net.csproj +++ b/CryptoExchange.Net/CryptoExchange.Net.csproj @@ -51,11 +51,11 @@ - - + + - - + + \ No newline at end of file diff --git a/Examples/BlazorClient/BlazorClient.csproj b/Examples/BlazorClient/BlazorClient.csproj index 7444201..69c43da 100644 --- a/Examples/BlazorClient/BlazorClient.csproj +++ b/Examples/BlazorClient/BlazorClient.csproj @@ -5,27 +5,28 @@ - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + - - + + + diff --git a/Examples/BlazorClient/Pages/Index.razor b/Examples/BlazorClient/Pages/Index.razor index 0a8dab9..0233664 100644 --- a/Examples/BlazorClient/Pages/Index.razor +++ b/Examples/BlazorClient/Pages/Index.razor @@ -17,6 +17,7 @@ @inject IKucoinRestClient kucoinClient @inject IMexcRestClient mexcClient @inject IOKXRestClient okxClient +@inject IToobitRestClient toobitClient @inject IWhiteBitRestClient whitebitClient @inject IXTRestClient xtClient @@ -48,9 +49,10 @@ var krakenTask = krakenClient.SpotApi.ExchangeData.GetTickerAsync("XBTUSD"); var kucoinTask = kucoinClient.SpotApi.ExchangeData.GetTickerAsync("BTC-USDT"); var mexcTask = mexcClient.SpotApi.ExchangeData.GetTickerAsync("BTCUSDT"); - var okxTask = okxClient.UnifiedApi.ExchangeData.GetTickerAsync("BTCUSDT"); + var okxTask = okxClient.UnifiedApi.ExchangeData.GetTickerAsync("BTC-USDT"); + var toobitTask = toobitClient.SpotApi.ExchangeData.GetTickersAsync("BTCUSDT"); var whitebitTask = whitebitClient.V4Api.ExchangeData.GetTickersAsync(); - var xtTask = xtClient.SpotApi.ExchangeData.GetTickersAsync("eth_btc"); + var xtTask = xtClient.SpotApi.ExchangeData.GetTickersAsync("btc_usdt"); await Task.WhenAll(binanceTask, bingXTask, bitfinexTask, bitgetTask, bitmartTask, bybitTask, coinexTask, deepCoinTask, gateioTask, htxTask, krakenTask, kucoinTask, mexcTask, okxTask); @@ -116,6 +118,9 @@ if (okxTask.Result.Success) _prices.Add("OKX", okxTask.Result.Data.LastPrice ?? 0); + if (toobitTask.Result.Success) + _prices.Add("Toobit", toobitTask.Result.Data.Single().LastPrice ?? 0); + if (whitebitTask.Result.Success){ // WhiteBit API doesn't offer an endpoint to filter for a specific ticker, so we have to filter client side var tickers = whitebitTask.Result.Data; diff --git a/Examples/BlazorClient/Pages/LiveData.razor b/Examples/BlazorClient/Pages/LiveData.razor index 9b2b161..a983589 100644 --- a/Examples/BlazorClient/Pages/LiveData.razor +++ b/Examples/BlazorClient/Pages/LiveData.razor @@ -17,6 +17,7 @@ @inject IKucoinSocketClient kucoinSocketClient @inject IMexcSocketClient mexcSocketClient @inject IOKXSocketClient okxSocketClient +@inject IToobitSocketClient toobitSocketClient @inject IWhiteBitSocketClient whitebitSocketClient @inject IXTSocketClient xtSocketClient @using System.Collections.Concurrent @@ -60,6 +61,8 @@ kucoinSocketClient.SpotApi.SubscribeToTickerUpdatesAsync("ETH-BTC", data => UpdateData("Kucoin", data.Data.LastPrice ?? 0)), mexcSocketClient.SpotApi.SubscribeToMiniTickerUpdatesAsync("ETHBTC", data => UpdateData("Mexc", data.Data.LastPrice)), okxSocketClient.UnifiedApi.ExchangeData.SubscribeToTickerUpdatesAsync("ETH-BTC", data => UpdateData("OKX", data.Data.LastPrice ?? 0)), + // Toobit doesn't support the ETH/BTC pair + //toobitSocketClient.SpotApi.SubscribeToTickerUpdatesAsync("ETHBTC", data => UpdateData("Toobit", data.Data.LastPrice ?? 0)), whitebitSocketClient.V4Api.SubscribeToTickerUpdatesAsync("ETH_BTC", data => UpdateData("WhiteBit", data.Data.Ticker.LastPrice)), }; diff --git a/Examples/BlazorClient/Pages/OrderBooks.razor b/Examples/BlazorClient/Pages/OrderBooks.razor index e553563..7d371ef 100644 --- a/Examples/BlazorClient/Pages/OrderBooks.razor +++ b/Examples/BlazorClient/Pages/OrderBooks.razor @@ -22,6 +22,7 @@ @using Kucoin.Net.Interfaces @using Mexc.Net.Interfaces @using OKX.Net.Interfaces; +@using Toobit.Net.Interfaces; @using WhiteBit.Net.Interfaces @using XT.Net.Interfaces @inject IBinanceOrderBookFactory binanceFactory @@ -42,6 +43,7 @@ @inject IKucoinOrderBookFactory kucoinFactory @inject IMexcOrderBookFactory mexcFactory @inject IOKXOrderBookFactory okxFactory +@inject IToobitOrderBookFactory toobitFactory @inject IWhiteBitOrderBookFactory whitebitFactory @inject IXTOrderBookFactory xtFactory @implements IDisposable @@ -97,6 +99,8 @@ { "Kucoin", kucoinFactory.CreateSpot("ETH-BTC") }, { "Mexc", mexcFactory.CreateSpot("ETHBTC") }, { "OKX", okxFactory.Create("ETH-BTC") }, + // Toobit does not support the ETH/BTC pair + //{ "Toobit", toobitFactory.Create("ETH/BTC") }, { "WhiteBit", whitebitFactory.CreateV4("ETH_BTC") }, { "XT", xtFactory.CreateSpot("eth_btc") }, }; diff --git a/Examples/BlazorClient/Pages/Trackers.razor b/Examples/BlazorClient/Pages/Trackers.razor index 8372aa9..7416cec 100644 --- a/Examples/BlazorClient/Pages/Trackers.razor +++ b/Examples/BlazorClient/Pages/Trackers.razor @@ -23,6 +23,7 @@ @using Kucoin.Net.Interfaces @using Mexc.Net.Interfaces @using OKX.Net.Interfaces; +@using Toobit.Net.Interfaces; @using WhiteBit.Net.Interfaces @using XT.Net.Interfaces @inject IBinanceTrackerFactory binanceFactory @@ -43,6 +44,7 @@ @inject IKucoinTrackerFactory kucoinFactory @inject IMexcTrackerFactory mexcFactory @inject IOKXTrackerFactory okxFactory +@inject IToobitTrackerFactory toobitFactory @inject IWhiteBitTrackerFactory whitebitFactory @inject IXTTrackerFactory xtFactory @implements IDisposable @@ -90,6 +92,7 @@ { kucoinFactory.CreateTradeTracker(usdtSymbol, period: TimeSpan.FromMinutes(5)) }, { mexcFactory.CreateTradeTracker(usdtSymbol, period: TimeSpan.FromMinutes(5)) }, { okxFactory.CreateTradeTracker(usdtSymbol, period: TimeSpan.FromMinutes(5)) }, + { toobitFactory.CreateTradeTracker(usdtSymbol, period: TimeSpan.FromMinutes(5)) }, { whitebitFactory.CreateTradeTracker(usdtSymbol, period: TimeSpan.FromMinutes(5)) }, { xtFactory.CreateTradeTracker(usdtSymbol, period: TimeSpan.FromMinutes(5)) }, }; diff --git a/Examples/BlazorClient/Startup.cs b/Examples/BlazorClient/Startup.cs index 9b60670..1e0cb5c 100644 --- a/Examples/BlazorClient/Startup.cs +++ b/Examples/BlazorClient/Startup.cs @@ -50,6 +50,7 @@ namespace BlazorClient services.AddKucoin(); services.AddMexc(); services.AddOKX(); + services.AddToobit(); services.AddWhiteBit(); services.AddXT(); } diff --git a/Examples/BlazorClient/_Imports.razor b/Examples/BlazorClient/_Imports.razor index d55b7e4..ce97d67 100644 --- a/Examples/BlazorClient/_Imports.razor +++ b/Examples/BlazorClient/_Imports.razor @@ -26,6 +26,7 @@ @using Kucoin.Net.Interfaces.Clients; @using Mexc.Net.Interfaces.Clients; @using OKX.Net.Interfaces.Clients; +@using Toobit.Net.Interfaces.Clients; @using WhiteBit.Net.Interfaces.Clients @using XT.Net.Interfaces.Clients @using CryptoExchange.Net.Interfaces; \ No newline at end of file diff --git a/Examples/ConsoleClient/ConsoleClient.csproj b/Examples/ConsoleClient/ConsoleClient.csproj index ffb096d..5f7c65d 100644 --- a/Examples/ConsoleClient/ConsoleClient.csproj +++ b/Examples/ConsoleClient/ConsoleClient.csproj @@ -6,20 +6,20 @@ - - - - - - - - - - - - - - + + + + + + + + + + + + + + diff --git a/Examples/SharedClients/SharedClients.csproj b/Examples/SharedClients/SharedClients.csproj index 675510c..bf1b035 100644 --- a/Examples/SharedClients/SharedClients.csproj +++ b/Examples/SharedClients/SharedClients.csproj @@ -8,9 +8,9 @@ - - - + + + diff --git a/README.md b/README.md index b68953e..8d34a10 100644 --- a/README.md +++ b/README.md @@ -31,6 +31,7 @@ Full list of all libraries part of the CryptoExchange.Net ecosystem. Consider us |![Kucoin](https://raw.githubusercontent.com/JKorf/Kucoin.Net/refs/heads/master/Kucoin.Net/Icon/icon.png)|Kucoin|CEX|[JKorf/Kucoin.Net](https://github.com/JKorf/Kucoin.Net)|[![Nuget version](https://img.shields.io/nuget/v/Kucoin.net.svg?style=flat-square)](https://www.nuget.org/packages/Kucoin.Net)|[Link](https://www.kucoin.com/r/rf/QBS4FPED)|-| |![Mexc](https://raw.githubusercontent.com/JKorf/Mexc.Net/refs/heads/main/Mexc.Net/Icon/icon.png)|Mexc|CEX|[JKorf/Mexc.Net](https://github.com/JKorf/Mexc.Net)|[![Nuget version](https://img.shields.io/nuget/v/JK.Mexc.net.svg?style=flat-square)](https://www.nuget.org/packages/JK.Mexc.Net)|-|-| |![OKX](https://raw.githubusercontent.com/JKorf/OKX.Net/refs/heads/main/OKX.Net/Icon/icon.png)|OKX|CEX|[JKorf/OKX.Net](https://github.com/JKorf/OKX.Net)|[![Nuget version](https://img.shields.io/nuget/v/JK.OKX.net.svg?style=flat-square)](https://www.nuget.org/packages/JK.OKX.Net)|[Link](https://www.okx.com/join/14592495)|20%| +|![Toobit](https://raw.githubusercontent.com/JKorf/Toobit.Net/refs/heads/main/Toobit.Net/Icon/icon.png)|Toobit|CEX|[JKorf/Toobit.Net](https://github.com/JKorf/Toobit.Net)|[![Nuget version](https://img.shields.io/nuget/v/Toobit.net.svg?style=flat-square)](https://www.nuget.org/packages/Toobit.Net)|[Link](https://www.toobit.com/en-US/register?invite_code=zsV19h)|-| |![WhiteBit](https://raw.githubusercontent.com/JKorf/WhiteBit.Net/refs/heads/main/WhiteBit.Net/Icon/icon.png)|WhiteBit|CEX|[JKorf/WhiteBit.Net](https://github.com/JKorf/WhiteBit.Net)|[![Nuget version](https://img.shields.io/nuget/v/WhiteBit.net.svg?style=flat-square)](https://www.nuget.org/packages/WhiteBit.Net)|[Link](https://whitebit.com/referral/a8e59b59-186c-4662-824c-3095248e0edf)|-| |![XT](https://raw.githubusercontent.com/JKorf/XT.Net/refs/heads/main/XT.Net/Icon/icon.png)|XT|CEX|[JKorf/XT.Net](https://github.com/JKorf/XT.Net)|[![Nuget version](https://img.shields.io/nuget/v/XT.net.svg?style=flat-square)](https://www.nuget.org/packages/XT.Net)|[Link](https://www.xt.com/ru/accounts/register?ref=CZG39C)|25%|