Comments (12)
Awesome. Let's nail down the interface first then we can start coding it up.
from exchangesharp.
from exchangesharp.
Which web socket API are your highest priority?
from exchangesharp.
@jjxtra We can split the work, I was playing recently with gdax, https://github.com/wklm/gdx-ws.
I could start with proposing an interface for all websokcet-based apis, and implement it for a few.
Nice thing them is that they're usually open, so we don't need to deal with authentication, rate limits etc
If this is fine, I would get back to you with a PR in ~ 2 weeks.
from exchangesharp.
Has anything come of this yet?
I've added this myself today before seeing your message. I haven't spent any time really at all considering what the best interface should be, but it looks something like this:
`ExchangePoloniexAPI polo = new ExchangePoloniexAPI();
polo.StartOrderBook();
Console.WriteLine("POLO:");
Console.WriteLine(polo.bid["LTC-BTC"] + " " + polo.ask["LTC-BTC"]);
Console.WriteLine(polo.bid["ETH-BTC"] + " " + polo.ask["ETH-BTC"]);
ExchangeGdaxAPI gdax = new ExchangeGdaxAPI();
gdax.StartOrderBook();
Console.WriteLine("\nGDAX:");
Console.WriteLine(gdax.bid["LTC-BTC"] + " " + gdax.ask["LTC-BTC"]);
Console.WriteLine(gdax.bid["ETH-BTC"] + " " + gdax.ask["ETH-BTC"]);`
Which results in this:
POLO:
0.01879998 0.0188
0.04901001 0.0490103
GDAX:
0.01894 0.01895
0.04914 0.04915
It starts a new thread when you call StartOrderBook(), which manages the bid/ask prices so that they are always up-to-date using the websocket API.
from exchangesharp.
Web socket is planned and will probably be an interface property on the IExchangeAPI interface, like an IExchangeWebSocketAPI that will handle the connections. @wklm is looking into proposing an interface.
from exchangesharp.
I would be interested in contributing a Binance Websocket API since that's the exchange I'm currently using. Has there been any movement from @wklm ?
from exchangesharp.
from exchangesharp.
hey @jjxtra,
sorry for the late response. I was trying out multiple things and decided to write it in F# using MailboxProcessors, an actor model "framework" included in the F# standard library. I can understand that you might want to keep the project C#-only, but since it should be fully interoperable with rest of the codebase, maybe it's worth to consider such an integration? Otherwise I would continue it as a separate project like this guys did:
https://github.com/timmolter/XChange
https://github.com/bitrich-info/xchange-stream
All the best in the new year!
Wojtek
from exchangesharp.
Let's continue it as a separate project for now.
from exchangesharp.
Just FYI all, web sockets are being implemented. Right now tickers are being added for those exchanges that support it, along with completed orders (Bitfinex). More will be added over time.
from exchangesharp.
Would be happy to help beta test GDAX websockets.
Thanks
from exchangesharp.
Related Issues (20)
- OrderBook Websocket: wrong break condition ? HOT 3
- GetAmountsAsync crashes program HOT 2
- URL to long on candle socket HOT 2
- CryptoUtility.ToDateTimeInvariant throws exception when Korea Standard Time is passed.
- Binance's methods that have a symbol parameter throw an error.
- LBank Invalid signature "error_code": 10007
- how to set a stop loss in binance HOT 1
- Kraken Get ticker failing HOT 3
- Binance OnGetTickersAsync throws InvalidDataException HOT 2
- GetTickersAsync failes for Binance HOT 15
- bittrex websocket stuck on connect
- Fail to create order: Param validation for 'symbol' failed on the 'symbol' tag HOT 1
- Need help Poloniex signature generation HOT 4
- Crashes when getting lots of data from Binance HOT 3
- Cannot place marketorder for bitfinex HOT 1
- BitFinex: TickerSocket throws exceptions
- Coinbase API changes: HOT 11
- Shorting HOT 1
- Binance GetTickersAsync Slow response on every few calls HOT 6
- Coinbase is not authenticating, at least in sandbox
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from exchangesharp.