Deribit API V2 Client for Rust Language
This is experimental and currently under heavy development. Use at your own risk.
This library uses Rust nightly features extensively like async/await and futures api. You need a nightly Rust to make it run.
The current plan is to only implement the websocket communication, which includes call api through websocket
and websocket subscription. I will first implement these APIs used for my own trading purpose, however, if you want some APIs
to be prioritly implemented please open an issue or just throw me a PR (this is more welcome :P).
Implementation Status
- Authentication
- [x] /public/auth
- [ ] /private/logout
- Session Management
- [x] /public/setheartbeat
- [ ] /public/disableheartbeat
- [ ] /private/enablecancelondisconnect
- [ ] /private/disablecancelondisconnect
- Supporting
- [x] /public/get_time
- [x] /public/hello
- [x] /public/test
- Subscription Management
- [x] /public/subscribe
- [ ] /public/unsubscribe
- [x] /private/subscribe
- [ ] /private/unsubscribe
- Account Management
- [ ] /public/getannouncements
- [ ] /private/changesubaccountname
- [ ] /private/createsubaccount
- [ ] /private/disabletfaforsubaccount
- [x] /private/getaccountsummary
- [ ] /private/getemaillanguage
- [ ] /private/getnewannouncements
- [ ] /private/getposition
- [x] /private/getpositions
- [ ] /private/getsubaccounts
- [ ] /private/setannouncementasread
- [ ] /private/setemailforsubaccount
- [ ] /private/setemaillanguage
- [ ] /private/setpasswordforsubaccount
- [ ] /private/togglenotificationsfromsubaccount
- [ ] /private/togglesubaccountlogin
Trading
- [x] /private/buy
- [x] /private/sell
- [ ] /private/edit
- [ ] /private/cancel
- [x] /private/cancel_all
- [x] /private/cancelallby_currency
- [x] /private/cancelallby_instrument
- [ ] /private/close_position
- [ ] /private/get_margins
- [ ] /private/getopenordersbycurrency
- [ ] /private/getopenordersbyinstrument
- [ ] /private/getorderhistorybycurrency
- [ ] /private/getorderhistorybyinstrument
- [ ] /private/getordermarginbyids
- [x] /private/getorderstate
- [ ] /private/getusertradesbycurrency
- [ ] /private/getusertradesbycurrencyandtime
- [ ] /private/getusertradesbyinstrument
- [ ] /private/getusertradesbyinstrumentandtime
- [ ] /private/getusertradesbyorder
- [ ] /private/getsettlementhistorybyinstrument
- [ ] /private/getsettlementhistorybycurrency
Market Data
- Wallet
- Subscriptions
- [ ] announcements
- [ ] book.{instrumentname}.{group}.{depth}.{interval}
- [x] book.{instrumentname}.{interval}
- [ ] deribitpriceindex.{indexname}
- [ ] deribitpriceranking.{indexname}
- [ ] estimatedexpirationprice.{indexname}
- [ ] markprice.options.{indexname}
- [ ] perpetual.{instrumentname}.{interval}
- [ ] quote.{instrumentname}
- [x] ticker.{instrumentname}.{interval}
- [ ] trades.{instrumentname}.{interval}
- [x] user.orders.{instrumentname}.{interval}
- [x] user.orders.{kind}.{currency}.{interval}
- [x] user.portfolio.{currency}
- [x] user.trades.{instrumentname}.{interval}
- [x] user.trades.{kind}.{currency}.{interval}]
Donate

16PeVqncfWoQ94M4pxnitkYnnW8agQBBZB