-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: CEX-like JSON API #1895
Comments
@sangaman maybe we should look into reviving the gRPC <-> REST proxy? https://github.com/ExchangeUnion/xud/blob/master/sample-xud.conf#L86 I haven't tested this in a long time, but it used to work. |
Not a small feat, but would definitely increase the reach for existing trading bots, like Hummingbot. I also know that quite some bots are written against ccxt. I am wondering if anybody ever tried to make hummbingbot work with ccxt after this. https://github.com/ccxt/ccxt We discussed ccxt compatibility way back. Here the list of unified ccxt calls. |
Thanks @jgarzik for getting the ball rolling on this one. |
We just discussed to revive our existing webproxy in POC style for you to evaluate if that behaves how you would expect it to behave (streaming calls are not interesting for you as far as I understand it nor does hummingbot seem to use streaming calls!?). Once you have a look at that and check on the vectors that you mentioned, we can decide if it's sufficient or if we want a native JSON API. We can discuss the API structure and call list in a second step. If a webproxy doesn't make sense, please step in @jgarzik |
|
Looks like the webproxy solution that we have right is working with the exception of streaming calls. There are some bugs to iron out, but this should give you a good overview what the proxy will look like if we choose to go this route. It can be enabled in the
The documentation will then be available at: http://localhost:8080/api-docs/ Example call for balance
|
What's your take on the current state of the webproxy? @jgarzik |
@kilrau Will check it out. Primary task is a side-by-side comparison of this vs Binance/Bittrex/coinbase, which is largely a documentation effort (vs testing/coding). |
Summary
Add an HTTP/JSON trading API alongside the existing gRPC API.
With the exception of authentication, the API should mirror [one of: Bittrex/Coinbase/Binance] trading API, for maximum compatibility with existing trading systems and bots.
Motivation
Bring more trading and liquidity to OpenDEX, via 98%-100% compatibility with an existing, popular trading API. The popular Hummingbot trading/MM bot already knows these APIs, and can even be connected to a Hummingbot liquidity mining program, bringing more liquidity to OpenDEX.
Recommended configuration
A TCP port is exposed, to which external trading systems may connect. Docker & xud configuration will need settings related to this.
Recommended APIs
(Summarized from bittrex, coinbase and binance APIs)
Read-only market APIs
Private / User Trading
Private / User Wallet
Implementation notes
In theory, a proxy can do this. However, a proxy solution is more complex than a built-in API, across a number of vectors.
The text was updated successfully, but these errors were encountered: