IPC removed, replaced by WS
This commit is contained in:
1 parent
ba4217fb24
commit
656c193511
503 files changed
+28128
-34498
No files matched your search
+12
-5
@@ -3,7 +3,7 @@
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
const Exchange = require ('./base/Exchange');
|
||||
const { ExchangeError, ArgumentsRequired, NullResponse, InvalidOrder, NotSupported, InsufficientFunds, InvalidNonce, OrderNotFound, RateLimitExceeded } = require ('./base/errors');
|
||||
const { ExchangeError, ArgumentsRequired, AuthenticationError, NullResponse, InvalidOrder, NotSupported, InsufficientFunds, InvalidNonce, OrderNotFound, RateLimitExceeded } = require ('./base/errors');
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
@@ -15,7 +15,7 @@ module.exports = class cex extends Exchange {
|
||||
'countries': [ 'GB', 'EU', 'CY', 'RU' ],
|
||||
'rateLimit': 1500,
|
||||
'has': {
|
||||
'CORS': true,
|
||||
'CORS': false,
|
||||
'fetchCurrencies': true,
|
||||
'fetchTickers': true,
|
||||
'fetchOHLCV': true,
|
||||
@@ -126,6 +126,8 @@ module.exports = class cex extends Exchange {
|
||||
'Invalid Order': InvalidOrder,
|
||||
'Order not found': OrderNotFound,
|
||||
'Rate limit exceeded': RateLimitExceeded,
|
||||
'Invalid API key': AuthenticationError,
|
||||
'There was an error while placing your order': InvalidOrder,
|
||||
},
|
||||
},
|
||||
'options': {
|
||||
@@ -352,6 +354,7 @@ module.exports = class cex extends Exchange {
|
||||
'max': undefined,
|
||||
},
|
||||
},
|
||||
'active': undefined,
|
||||
});
|
||||
}
|
||||
return result;
|
||||
@@ -803,11 +806,14 @@ module.exports = class cex extends Exchange {
|
||||
'currency': market['quote'],
|
||||
},
|
||||
'info': item,
|
||||
'type': undefined,
|
||||
'takerOrMaker': undefined,
|
||||
});
|
||||
}
|
||||
}
|
||||
return {
|
||||
'id': orderId,
|
||||
'clientOrderId': undefined,
|
||||
'datetime': this.iso8601 (timestamp),
|
||||
'timestamp': timestamp,
|
||||
'lastTradeTimestamp': undefined,
|
||||
@@ -823,6 +829,7 @@ module.exports = class cex extends Exchange {
|
||||
'trades': trades,
|
||||
'fee': fee,
|
||||
'info': order,
|
||||
'average': undefined,
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1152,12 +1159,12 @@ module.exports = class cex extends Exchange {
|
||||
if (Array.isArray (response)) {
|
||||
return response; // public endpoints may return []-arrays
|
||||
}
|
||||
if (body === 'true') {
|
||||
return;
|
||||
}
|
||||
if (response === undefined) {
|
||||
throw new NullResponse (this.id + ' returned ' + this.json (response));
|
||||
}
|
||||
if (response === true || response === 'true') {
|
||||
return;
|
||||
}
|
||||
if ('e' in response) {
|
||||
if ('ok' in response) {
|
||||
if (response['ok'] === 'ok') {
|
||||
|
||||
Reference in new issue
Block a user