Commit Graph

35 Commits

Author SHA1 Message Date
tiagosiebler
1c14595fd6 feat: expose request options in REST constructor. Fix readme links. 2020-10-08 22:05:22 +01:00
tiagosiebler
af6a6e647b fix: ws handle possible timeout 2020-10-05 21:15:10 +01:00
tiagosiebler
0717a122c1 feat: use global request options for global settings pass-thru (timeout, proxy, any other custom settings as desired) 2020-10-05 10:26:36 +01:00
tiagosiebler
3df54c341c fix request case 2020-10-05 10:12:22 +01:00
tiagosiebler
1b556afeb3 fix: linting 2020-10-04 20:37:42 +01:00
tiagosiebler
3a2125e77b feat: deprecate request and implement axios. bump ws. cleaning. expose request options for proxy support. resolves #12. resolves #4. 2020-10-04 19:37:26 +01:00
tiagosiebler
b201d364bf feat: start work on axios integration, deprecating request. 2020-10-04 14:22:59 +01:00
John BEPPU
c22a27779a Add new REST endpoints
https://bybit-exchange.github.io/docs/inverse/#2020-08-19
getOpenInterest
getLatestBigDeal
getLongShortRatio

https://bybit-exchange.github.io/docs/inverse/#2020-07-07
getAssetExchangeRecords
2020-09-14 20:54:15 -07:00
John BEPPU
ce301bd4c9 Implement replaceConditionalOrder
This lets unexecuted stop orders be edited.
https://bybit-exchange.github.io/docs/inverse/#t-replacecond
2020-08-12 12:21:48 -07:00
John BEPPU
995a6405ef Fix typo: Conditioanl
s/Conditioanl/Conditional/; #6
2020-08-12 10:59:34 -07:00
tiagosiebler
f7029cf795 method name 2020-08-12 00:32:14 +01:00
tiagosiebler
e28a41bf07 v1.1.7: add get public liquidations endpoint 2020-08-12 00:27:52 +01:00
tiagosiebler
ccbba6dd38 approach to fixing #12 2020-06-17 12:05:31 +01:00
tiagosiebler
e70d811654 fix prefixes 2020-06-17 10:56:18 +01:00
tiagosiebler
165faac7f4 find endpoint typo 2020-06-17 10:54:55 +01:00
tiagosiebler
2f130931ff spacing & fix prefixed endpoints 2020-06-17 10:54:37 +01:00
Tiago
336170faa5 Add missing getKline API. Fixes #8. (#9)
Co-authored-by: tiagosiebler <ts@github.com>
2020-04-20 14:10:02 +02:00
Tiago
3f5624dd06 Add support for recv_window parameter and custom options for REST client (#7)
* remove unused/unexisting method. Add missing semi-colon. Add support for recvWindow parameter, optional, with default value. Add support for custom sync time interval.

* add new params to rest client constructor

* add recv and sync as options object, optional, with updated docs

* cleaning

* whitespace

* allow override via params

* param consistency

Co-authored-by: tiagosiebler <ts@github.com>
2020-04-09 15:28:18 +02:00
Stefan Aebischer
e519c368e5 Add new endpoint getWalletBalance
See: https://github.com/bybit-exchange/bybit-official-api-docs/blob/master/en/CHANGELOG.md#2020-02-10
2020-02-12 10:45:53 -05:00
Stefan Aebischer
90ae9984a4 Add reconnect and reconnected events to ws 2020-02-01 20:24:54 -05:00
Stefan Aebischer
7ae88dec0e Allow symbol as parameter for getTradeRecords 2020-01-20 22:34:18 -05:00
Stefan Aebischer
1b73064aa9 Adds required parameter symbol to cancelActiveOrder 2020-01-20 22:20:55 -05:00
Stefan Aebischer
470415056e Fix getPosition
* Re adds the v1 endpoint as `getPositions`
* Fixes params for v2 endpoint `getPosition`

Resolves: #5
2020-01-20 22:19:25 -05:00
Stefan Aebischer
ac8ed45ef5 Change getOrderTradeRecords to getTradeRecords 2020-01-17 21:45:05 -05:00
Stefan Aebischer
d8c7a551a4 Add missing endpoints, switch to v2
Adds missing endpoints:

* queryActiveOrder
* cancelAllConditionalOrders
* queryConditionalOrder
* setTradingStop
* getWalletFundRecords
* getWithdrawRecords
* setRiskLimit
* getRiskLimitList
* getPublicTradingRecords
* getApiAnnouncements

Switches Endpoints to v2:

* getPosition
2020-01-17 21:36:41 -05:00
Tiago
d6c18b1e57 Expand API support, including some V2 endpoints (#4)
Switch to V2 versions of some APIs:

* place order
* cancel order

Add missing APIs:

* cancel all orders
* replace order
* get symbols

Add support for custom order ID for cancel active order.
2020-01-17 21:01:03 -05:00
Stefan Aebischer
995cd6ed73 Avoid conccurent _syncTime calls 2020-01-15 14:40:10 -05:00
Stefan Aebischer
e5fd04afc1 Fix time synchronization with server
- avoid that client time being ahead of server time
2020-01-15 14:38:23 -05:00
Stefan Aebischer
6da5126190 Add silly logging 2019-10-27 16:46:20 +02:00
Stefan Aebischer
59aee838a3 Removing console.log 2019-09-16 16:00:40 +02:00
Stefan Aebischer
4660dc98b8 Reconnect if connection fails 2019-09-16 15:06:18 +02:00
Stefan Aebischer
26a1354ec5 Resubscribe to subscriptions after reconnecting 2019-09-16 15:04:02 +02:00
Stefan Aebischer
5caa65fedf Allow to unsubscribe from ws topic 2019-09-16 14:37:19 +02:00
Stefan Aebischer
b6d2803a49 Time synchronization with server
- wrapper for /v2/public/time rest endpoint
- synchronize time before trying to authenticate a request in order
  to avoid invalid authentication because prevented replay attacks.

Resolves #1
2019-09-16 14:25:55 +02:00
Stefan Aebischer
ed28d14171 Initial commit 2019-09-14 16:02:11 +02:00