ccxt 4.0.83 → 4.0.85
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/dist/ccxt.browser.js +79 -47
- package/dist/ccxt.browser.min.js +2 -2
- package/dist/cjs/ccxt.js +1 -1
- package/dist/cjs/src/latoken.js +67 -45
- package/dist/cjs/src/pro/binance.js +11 -1
- package/js/ccxt.d.ts +1 -1
- package/js/ccxt.js +1 -1
- package/js/src/base/types.d.ts +1 -1
- package/js/src/latoken.js +67 -45
- package/js/src/pro/binance.js +11 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -215,13 +215,13 @@ console.log(version, Object.keys(exchanges));
|
|
|
215
215
|
|
|
216
216
|
All-in-one browser bundle (dependencies included), served from a CDN of your choice:
|
|
217
217
|
|
|
218
|
-
* jsDelivr: https://cdn.jsdelivr.net/npm/ccxt@4.0.
|
|
219
|
-
* unpkg: https://unpkg.com/ccxt@4.0.
|
|
218
|
+
* jsDelivr: https://cdn.jsdelivr.net/npm/ccxt@4.0.85/dist/ccxt.browser.js
|
|
219
|
+
* unpkg: https://unpkg.com/ccxt@4.0.85/dist/ccxt.browser.js
|
|
220
220
|
|
|
221
221
|
CDNs are not updated in real-time and may have delays. Defaulting to the most recent version without specifying the version number is not recommended. Please, keep in mind that we are not responsible for the correct operation of those CDN servers.
|
|
222
222
|
|
|
223
223
|
```HTML
|
|
224
|
-
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/ccxt@4.0.
|
|
224
|
+
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/ccxt@4.0.85/dist/ccxt.browser.js"></script>
|
|
225
225
|
```
|
|
226
226
|
|
|
227
227
|
Creates a global `ccxt` object:
|
package/dist/ccxt.browser.js
CHANGED
|
@@ -155037,41 +155037,47 @@ class latoken extends _abstract_latoken_js__WEBPACK_IMPORTED_MODULE_0__/* ["defa
|
|
|
155037
155037
|
}
|
|
155038
155038
|
parseTicker(ticker, market = undefined) {
|
|
155039
155039
|
//
|
|
155040
|
-
//
|
|
155041
|
-
//
|
|
155042
|
-
//
|
|
155043
|
-
//
|
|
155044
|
-
//
|
|
155045
|
-
//
|
|
155046
|
-
//
|
|
155047
|
-
//
|
|
155048
|
-
//
|
|
155049
|
-
//
|
|
155040
|
+
// {
|
|
155041
|
+
// symbol: '92151d82-df98-4d88-9a4d-284fa9eca49f/0c3a106d-bde3-4c13-a26e-3fd2394529e5',
|
|
155042
|
+
// baseCurrency: '92151d82-df98-4d88-9a4d-284fa9eca49f',
|
|
155043
|
+
// quoteCurrency: '0c3a106d-bde3-4c13-a26e-3fd2394529e5',
|
|
155044
|
+
// volume24h: '165723597.189022176000000000',
|
|
155045
|
+
// volume7d: '934505768.625109571000000000',
|
|
155046
|
+
// change24h: '0.0200',
|
|
155047
|
+
// change7d: '-6.4200',
|
|
155048
|
+
// amount24h: '6438.457663100000000000',
|
|
155049
|
+
// amount7d: '35657.785013800000000000',
|
|
155050
|
+
// lastPrice: '25779.16',
|
|
155051
|
+
// lastQuantity: '0.248403300000000000',
|
|
155052
|
+
// bestBid: '25778.74',
|
|
155053
|
+
// bestBidQuantity: '0.6520232',
|
|
155054
|
+
// bestAsk: '25779.17',
|
|
155055
|
+
// bestAskQuantity: '0.4956043',
|
|
155056
|
+
// updateTimestamp: '1693965231406'
|
|
155057
|
+
// }
|
|
155050
155058
|
//
|
|
155051
155059
|
const marketId = this.safeString(ticker, 'symbol');
|
|
155052
|
-
const symbol = this.safeSymbol(marketId, market);
|
|
155053
155060
|
const last = this.safeString(ticker, 'lastPrice');
|
|
155054
|
-
const
|
|
155055
|
-
const timestamp = this.nonce();
|
|
155061
|
+
const timestamp = this.safeInteger(ticker, 'updateTimestamp');
|
|
155056
155062
|
return this.safeTicker({
|
|
155057
|
-
'symbol':
|
|
155063
|
+
'symbol': this.safeSymbol(marketId, market),
|
|
155058
155064
|
'timestamp': timestamp,
|
|
155059
155065
|
'datetime': this.iso8601(timestamp),
|
|
155060
|
-
'low':
|
|
155061
|
-
'high':
|
|
155062
|
-
'bid':
|
|
155063
|
-
'bidVolume':
|
|
155064
|
-
'ask':
|
|
155065
|
-
'askVolume':
|
|
155066
|
+
'low': undefined,
|
|
155067
|
+
'high': undefined,
|
|
155068
|
+
'bid': this.safeString(ticker, 'bestBid'),
|
|
155069
|
+
'bidVolume': this.safeString(ticker, 'bestBidQuantity'),
|
|
155070
|
+
'ask': this.safeString(ticker, 'bestAsk'),
|
|
155071
|
+
'askVolume': this.safeString(ticker, 'bestAskQuantity'),
|
|
155066
155072
|
'vwap': undefined,
|
|
155067
155073
|
'open': undefined,
|
|
155068
155074
|
'close': last,
|
|
155069
155075
|
'last': last,
|
|
155070
155076
|
'previousClose': undefined,
|
|
155071
|
-
'change':
|
|
155072
|
-
'percentage':
|
|
155077
|
+
'change': undefined,
|
|
155078
|
+
'percentage': this.safeString(ticker, 'change24h'),
|
|
155073
155079
|
'average': undefined,
|
|
155074
|
-
'baseVolume':
|
|
155080
|
+
'baseVolume': this.safeString(ticker, 'amount24h'),
|
|
155075
155081
|
'quoteVolume': this.safeString(ticker, 'volume24h'),
|
|
155076
155082
|
'info': ticker,
|
|
155077
155083
|
}, market);
|
|
@@ -155093,16 +155099,24 @@ class latoken extends _abstract_latoken_js__WEBPACK_IMPORTED_MODULE_0__/* ["defa
|
|
|
155093
155099
|
};
|
|
155094
155100
|
const response = await this.publicGetTickerBaseQuote(this.extend(request, params));
|
|
155095
155101
|
//
|
|
155096
|
-
//
|
|
155097
|
-
//
|
|
155098
|
-
//
|
|
155099
|
-
//
|
|
155100
|
-
//
|
|
155101
|
-
//
|
|
155102
|
-
//
|
|
155103
|
-
//
|
|
155104
|
-
//
|
|
155105
|
-
//
|
|
155102
|
+
// {
|
|
155103
|
+
// symbol: '92151d82-df98-4d88-9a4d-284fa9eca49f/0c3a106d-bde3-4c13-a26e-3fd2394529e5',
|
|
155104
|
+
// baseCurrency: '92151d82-df98-4d88-9a4d-284fa9eca49f',
|
|
155105
|
+
// quoteCurrency: '0c3a106d-bde3-4c13-a26e-3fd2394529e5',
|
|
155106
|
+
// volume24h: '165723597.189022176000000000',
|
|
155107
|
+
// volume7d: '934505768.625109571000000000',
|
|
155108
|
+
// change24h: '0.0200',
|
|
155109
|
+
// change7d: '-6.4200',
|
|
155110
|
+
// amount24h: '6438.457663100000000000',
|
|
155111
|
+
// amount7d: '35657.785013800000000000',
|
|
155112
|
+
// lastPrice: '25779.16',
|
|
155113
|
+
// lastQuantity: '0.248403300000000000',
|
|
155114
|
+
// bestBid: '25778.74',
|
|
155115
|
+
// bestBidQuantity: '0.6520232',
|
|
155116
|
+
// bestAsk: '25779.17',
|
|
155117
|
+
// bestAskQuantity: '0.4956043',
|
|
155118
|
+
// updateTimestamp: '1693965231406'
|
|
155119
|
+
// }
|
|
155106
155120
|
//
|
|
155107
155121
|
return this.parseTicker(response, market);
|
|
155108
155122
|
}
|
|
@@ -155118,18 +155132,26 @@ class latoken extends _abstract_latoken_js__WEBPACK_IMPORTED_MODULE_0__/* ["defa
|
|
|
155118
155132
|
await this.loadMarkets();
|
|
155119
155133
|
const response = await this.publicGetTicker(params);
|
|
155120
155134
|
//
|
|
155121
|
-
//
|
|
155122
|
-
//
|
|
155123
|
-
//
|
|
155124
|
-
//
|
|
155125
|
-
//
|
|
155126
|
-
//
|
|
155127
|
-
//
|
|
155128
|
-
//
|
|
155129
|
-
//
|
|
155130
|
-
//
|
|
155131
|
-
//
|
|
155132
|
-
//
|
|
155135
|
+
// [
|
|
155136
|
+
// {
|
|
155137
|
+
// symbol: '92151d82-df98-4d88-9a4d-284fa9eca49f/0c3a106d-bde3-4c13-a26e-3fd2394529e5',
|
|
155138
|
+
// baseCurrency: '92151d82-df98-4d88-9a4d-284fa9eca49f',
|
|
155139
|
+
// quoteCurrency: '0c3a106d-bde3-4c13-a26e-3fd2394529e5',
|
|
155140
|
+
// volume24h: '165723597.189022176000000000',
|
|
155141
|
+
// volume7d: '934505768.625109571000000000',
|
|
155142
|
+
// change24h: '0.0200',
|
|
155143
|
+
// change7d: '-6.4200',
|
|
155144
|
+
// amount24h: '6438.457663100000000000',
|
|
155145
|
+
// amount7d: '35657.785013800000000000',
|
|
155146
|
+
// lastPrice: '25779.16',
|
|
155147
|
+
// lastQuantity: '0.248403300000000000',
|
|
155148
|
+
// bestBid: '25778.74',
|
|
155149
|
+
// bestBidQuantity: '0.6520232',
|
|
155150
|
+
// bestAsk: '25779.17',
|
|
155151
|
+
// bestAskQuantity: '0.4956043',
|
|
155152
|
+
// updateTimestamp: '1693965231406'
|
|
155153
|
+
// }
|
|
155154
|
+
// ]
|
|
155133
155155
|
//
|
|
155134
155156
|
return this.parseTickers(response, symbols);
|
|
155135
155157
|
}
|
|
@@ -195796,7 +195818,17 @@ class binance extends _binance_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */
|
|
|
195796
195818
|
client.resolve(result, messageHash);
|
|
195797
195819
|
if (event === 'bookTicker') {
|
|
195798
195820
|
// watch bookTickers
|
|
195799
|
-
client.resolve(
|
|
195821
|
+
client.resolve(result, '!' + 'bookTicker@arr');
|
|
195822
|
+
const messageHashes = this.findMessageHashes(client, 'tickers::');
|
|
195823
|
+
for (let i = 0; i < messageHashes.length; i++) {
|
|
195824
|
+
const messageHash = messageHashes[i];
|
|
195825
|
+
const parts = messageHash.split('::');
|
|
195826
|
+
const symbolsString = parts[1];
|
|
195827
|
+
const symbols = symbolsString.split(',');
|
|
195828
|
+
if (this.inArray(symbol, symbols)) {
|
|
195829
|
+
client.resolve(result, messageHash);
|
|
195830
|
+
}
|
|
195831
|
+
}
|
|
195800
195832
|
}
|
|
195801
195833
|
}
|
|
195802
195834
|
handleTickers(client, message) {
|
|
@@ -273642,7 +273674,7 @@ SOFTWARE.
|
|
|
273642
273674
|
|
|
273643
273675
|
//-----------------------------------------------------------------------------
|
|
273644
273676
|
// this is updated by vss.js when building
|
|
273645
|
-
const version = '4.0.
|
|
273677
|
+
const version = '4.0.85';
|
|
273646
273678
|
_src_base_Exchange_js__WEBPACK_IMPORTED_MODULE_0__/* .Exchange.ccxtVersion */ .e.ccxtVersion = version;
|
|
273647
273679
|
//-----------------------------------------------------------------------------
|
|
273648
273680
|
|