ccxt 4.1.55 → 4.1.57

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.
Files changed (328) hide show
  1. package/.git-templates/hooks/pre-push +2 -2
  2. package/CONTRIBUTING.md +1 -1
  3. package/README.md +6 -6
  4. package/build.sh +30 -8
  5. package/dist/ccxt.browser.js +5592 -4907
  6. package/dist/ccxt.browser.min.js +13 -13
  7. package/dist/cjs/ccxt.js +1 -1
  8. package/dist/cjs/src/ace.js +17 -13
  9. package/dist/cjs/src/alpaca.js +6 -6
  10. package/dist/cjs/src/ascendex.js +35 -29
  11. package/dist/cjs/src/base/Exchange.js +39 -26
  12. package/dist/cjs/src/base/Precise.js +1 -3
  13. package/dist/cjs/src/bigone.js +24 -20
  14. package/dist/cjs/src/binance.js +97 -76
  15. package/dist/cjs/src/bingx.js +63 -44
  16. package/dist/cjs/src/bit2c.js +18 -15
  17. package/dist/cjs/src/bitbank.js +17 -15
  18. package/dist/cjs/src/bitbns.js +28 -18
  19. package/dist/cjs/src/bitfinex.js +23 -21
  20. package/dist/cjs/src/bitfinex2.js +32 -28
  21. package/dist/cjs/src/bitflyer.js +28 -20
  22. package/dist/cjs/src/bitforex.js +25 -18
  23. package/dist/cjs/src/bitget.js +184 -147
  24. package/dist/cjs/src/bithumb.js +23 -16
  25. package/dist/cjs/src/bitmart.js +129 -94
  26. package/dist/cjs/src/bitmex.js +104 -64
  27. package/dist/cjs/src/bitopro.js +38 -26
  28. package/dist/cjs/src/bitpanda.js +24 -23
  29. package/dist/cjs/src/bitrue.js +33 -24
  30. package/dist/cjs/src/bitso.js +24 -23
  31. package/dist/cjs/src/bitstamp.js +24 -23
  32. package/dist/cjs/src/bittrex.js +30 -29
  33. package/dist/cjs/src/bitvavo.js +38 -30
  34. package/dist/cjs/src/bl3p.js +11 -10
  35. package/dist/cjs/src/blockchaincom.js +20 -20
  36. package/dist/cjs/src/btcalpha.js +18 -17
  37. package/dist/cjs/src/btcbox.js +13 -12
  38. package/dist/cjs/src/btcmarkets.js +20 -19
  39. package/dist/cjs/src/btcturk.js +14 -13
  40. package/dist/cjs/src/bybit.js +84 -54
  41. package/dist/cjs/src/cex.js +16 -14
  42. package/dist/cjs/src/coinbase.js +29 -27
  43. package/dist/cjs/src/coinbasepro.js +27 -25
  44. package/dist/cjs/src/coincheck.js +15 -14
  45. package/dist/cjs/src/coinex.js +101 -78
  46. package/dist/cjs/src/coinlist.js +28 -27
  47. package/dist/cjs/src/coinmate.js +20 -17
  48. package/dist/cjs/src/coinone.js +21 -16
  49. package/dist/cjs/src/coinsph.js +37 -28
  50. package/dist/cjs/src/coinspot.js +12 -11
  51. package/dist/cjs/src/cryptocom.js +40 -202
  52. package/dist/cjs/src/currencycom.js +32 -25
  53. package/dist/cjs/src/delta.js +34 -28
  54. package/dist/cjs/src/deribit.js +39 -36
  55. package/dist/cjs/src/digifinex.js +64 -44
  56. package/dist/cjs/src/exmo.js +29 -27
  57. package/dist/cjs/src/gate.js +67 -53
  58. package/dist/cjs/src/gemini.js +23 -20
  59. package/dist/cjs/src/hitbtc.js +65 -56
  60. package/dist/cjs/src/hollaex.js +30 -27
  61. package/dist/cjs/src/htx.js +135 -143
  62. package/dist/cjs/src/huobijp.js +22 -20
  63. package/dist/cjs/src/idex.js +22 -21
  64. package/dist/cjs/src/independentreserve.js +15 -14
  65. package/dist/cjs/src/indodax.js +30 -26
  66. package/dist/cjs/src/kraken.js +29 -27
  67. package/dist/cjs/src/krakenfutures.js +29 -22
  68. package/dist/cjs/src/kucoin.js +48 -43
  69. package/dist/cjs/src/kucoinfutures.js +33 -28
  70. package/dist/cjs/src/kuna.js +25 -24
  71. package/dist/cjs/src/latoken.js +24 -22
  72. package/dist/cjs/src/lbank.js +45 -30
  73. package/dist/cjs/src/luno.js +22 -19
  74. package/dist/cjs/src/lykke.js +19 -17
  75. package/dist/cjs/src/mercado.js +30 -19
  76. package/dist/cjs/src/mexc.js +60 -49
  77. package/dist/cjs/src/ndax.js +23 -22
  78. package/dist/cjs/src/novadax.js +23 -22
  79. package/dist/cjs/src/oceanex.js +22 -19
  80. package/dist/cjs/src/okcoin.js +29 -23
  81. package/dist/cjs/src/okx.js +92 -84
  82. package/dist/cjs/src/p2b.js +80 -83
  83. package/dist/cjs/src/paymium.js +10 -10
  84. package/dist/cjs/src/phemex.js +63 -40
  85. package/dist/cjs/src/poloniex.js +22 -22
  86. package/dist/cjs/src/poloniexfutures.js +23 -19
  87. package/dist/cjs/src/pro/alpaca.js +5 -5
  88. package/dist/cjs/src/pro/ascendex.js +4 -4
  89. package/dist/cjs/src/pro/binance.js +16 -16
  90. package/dist/cjs/src/pro/bingx.js +1 -1
  91. package/dist/cjs/src/pro/bitfinex.js +4 -4
  92. package/dist/cjs/src/pro/bitfinex2.js +6 -6
  93. package/dist/cjs/src/pro/bitget.js +7 -7
  94. package/dist/cjs/src/pro/bitmart.js +7 -5
  95. package/dist/cjs/src/pro/bitmex.js +6 -6
  96. package/dist/cjs/src/pro/bitopro.js +4 -4
  97. package/dist/cjs/src/pro/bitpanda.js +6 -6
  98. package/dist/cjs/src/pro/bitrue.js +2 -2
  99. package/dist/cjs/src/pro/bitstamp.js +6 -4
  100. package/dist/cjs/src/pro/bittrex.js +6 -6
  101. package/dist/cjs/src/pro/bitvavo.js +11 -7
  102. package/dist/cjs/src/pro/blockchaincom.js +8 -8
  103. package/dist/cjs/src/pro/bybit.js +7 -7
  104. package/dist/cjs/src/pro/cex.js +13 -9
  105. package/dist/cjs/src/pro/coinbase.js +5 -5
  106. package/dist/cjs/src/pro/coinbasepro.js +11 -10
  107. package/dist/cjs/src/pro/coinex.js +7 -9
  108. package/dist/cjs/src/pro/cryptocom.js +9 -9
  109. package/dist/cjs/src/pro/currencycom.js +4 -4
  110. package/dist/cjs/src/pro/deribit.js +6 -6
  111. package/dist/cjs/src/pro/exmo.js +12 -14
  112. package/dist/cjs/src/pro/gate.js +7 -7
  113. package/dist/cjs/src/pro/gemini.js +3 -3
  114. package/dist/cjs/src/pro/hitbtc.js +263 -4
  115. package/dist/cjs/src/pro/hollaex.js +5 -5
  116. package/dist/cjs/src/pro/htx.js +6 -6
  117. package/dist/cjs/src/pro/huobijp.js +3 -3
  118. package/dist/cjs/src/pro/idex.js +4 -4
  119. package/dist/cjs/src/pro/independentreserve.js +2 -2
  120. package/dist/cjs/src/pro/kraken.js +10 -10
  121. package/dist/cjs/src/pro/krakenfutures.js +41 -17
  122. package/dist/cjs/src/pro/kucoin.js +7 -7
  123. package/dist/cjs/src/pro/kucoinfutures.js +8 -6
  124. package/dist/cjs/src/pro/luno.js +2 -2
  125. package/dist/cjs/src/pro/mexc.js +6 -6
  126. package/dist/cjs/src/pro/ndax.js +3 -3
  127. package/dist/cjs/src/pro/okcoin.js +5 -5
  128. package/dist/cjs/src/pro/okx.js +12 -12
  129. package/dist/cjs/src/pro/phemex.js +6 -6
  130. package/dist/cjs/src/pro/poloniex.js +7 -7
  131. package/dist/cjs/src/pro/poloniexfutures.js +5 -5
  132. package/dist/cjs/src/pro/probit.js +6 -6
  133. package/dist/cjs/src/pro/upbit.js +3 -3
  134. package/dist/cjs/src/pro/wazirx.js +8 -8
  135. package/dist/cjs/src/pro/whitebit.js +12 -8
  136. package/dist/cjs/src/pro/woo.js +1 -1
  137. package/dist/cjs/src/probit.js +28 -23
  138. package/dist/cjs/src/tidex.js +16 -15
  139. package/dist/cjs/src/timex.js +19 -18
  140. package/dist/cjs/src/tokocrypto.js +27 -22
  141. package/dist/cjs/src/upbit.js +19 -19
  142. package/dist/cjs/src/wavesexchange.js +22 -19
  143. package/dist/cjs/src/wazirx.js +24 -17
  144. package/dist/cjs/src/whitebit.js +33 -27
  145. package/dist/cjs/src/woo.js +44 -34
  146. package/dist/cjs/src/yobit.js +25 -20
  147. package/dist/cjs/src/zaif.js +9 -9
  148. package/dist/cjs/src/zonda.js +18 -17
  149. package/js/ccxt.d.ts +1 -1
  150. package/js/ccxt.js +1 -1
  151. package/js/src/abstract/bitbank.d.ts +1 -0
  152. package/js/src/abstract/bybit.d.ts +1 -0
  153. package/js/src/abstract/cryptocom.d.ts +0 -20
  154. package/js/src/abstract/htx.d.ts +3 -0
  155. package/js/src/abstract/huobi.d.ts +3 -0
  156. package/js/src/abstract/huobipro.d.ts +3 -0
  157. package/js/src/abstract/okex.d.ts +3 -1
  158. package/js/src/abstract/okex5.d.ts +3 -1
  159. package/js/src/abstract/okx.d.ts +3 -1
  160. package/js/src/ace.js +18 -14
  161. package/js/src/alpaca.js +6 -6
  162. package/js/src/ascendex.js +35 -29
  163. package/js/src/base/Exchange.d.ts +37 -34
  164. package/js/src/base/Exchange.js +39 -26
  165. package/js/src/base/Precise.d.ts +4 -4
  166. package/js/src/base/Precise.js +1 -3
  167. package/js/src/base/functions/type.d.ts +25 -25
  168. package/js/src/base/types.d.ts +21 -14
  169. package/js/src/bigone.js +25 -21
  170. package/js/src/binance.d.ts +2 -2
  171. package/js/src/binance.js +97 -76
  172. package/js/src/bingx.js +63 -44
  173. package/js/src/bit2c.js +19 -16
  174. package/js/src/bitbank.js +17 -15
  175. package/js/src/bitbns.js +28 -18
  176. package/js/src/bitfinex.js +23 -21
  177. package/js/src/bitfinex2.js +32 -28
  178. package/js/src/bitflyer.js +28 -20
  179. package/js/src/bitforex.js +26 -19
  180. package/js/src/bitget.d.ts +25 -3
  181. package/js/src/bitget.js +184 -147
  182. package/js/src/bithumb.js +23 -16
  183. package/js/src/bitmart.d.ts +1 -1
  184. package/js/src/bitmart.js +129 -94
  185. package/js/src/bitmex.d.ts +2 -2
  186. package/js/src/bitmex.js +104 -64
  187. package/js/src/bitopro.js +38 -26
  188. package/js/src/bitpanda.js +24 -23
  189. package/js/src/bitrue.js +33 -24
  190. package/js/src/bitso.js +24 -23
  191. package/js/src/bitstamp.d.ts +2 -2
  192. package/js/src/bitstamp.js +24 -23
  193. package/js/src/bittrex.js +30 -29
  194. package/js/src/bitvavo.js +38 -30
  195. package/js/src/bl3p.js +11 -10
  196. package/js/src/blockchaincom.js +20 -20
  197. package/js/src/btcalpha.js +18 -17
  198. package/js/src/btcbox.js +13 -12
  199. package/js/src/btcmarkets.js +20 -19
  200. package/js/src/btcturk.js +14 -13
  201. package/js/src/bybit.d.ts +1 -1
  202. package/js/src/bybit.js +84 -54
  203. package/js/src/cex.js +16 -14
  204. package/js/src/coinbase.js +29 -27
  205. package/js/src/coinbasepro.js +27 -25
  206. package/js/src/coincheck.js +15 -14
  207. package/js/src/coinex.d.ts +1 -1
  208. package/js/src/coinex.js +101 -78
  209. package/js/src/coinlist.js +28 -27
  210. package/js/src/coinmate.js +21 -18
  211. package/js/src/coinone.js +21 -16
  212. package/js/src/coinsph.js +37 -28
  213. package/js/src/coinspot.js +12 -11
  214. package/js/src/cryptocom.d.ts +0 -23
  215. package/js/src/cryptocom.js +40 -202
  216. package/js/src/currencycom.js +32 -25
  217. package/js/src/delta.js +35 -29
  218. package/js/src/deribit.js +39 -36
  219. package/js/src/digifinex.d.ts +2 -2
  220. package/js/src/digifinex.js +65 -45
  221. package/js/src/exmo.js +29 -27
  222. package/js/src/gate.d.ts +1 -1
  223. package/js/src/gate.js +67 -53
  224. package/js/src/gemini.js +23 -20
  225. package/js/src/hitbtc.d.ts +1 -0
  226. package/js/src/hitbtc.js +65 -56
  227. package/js/src/hollaex.js +30 -27
  228. package/js/src/htx.d.ts +11 -3
  229. package/js/src/htx.js +135 -143
  230. package/js/src/huobijp.js +23 -21
  231. package/js/src/idex.js +22 -21
  232. package/js/src/independentreserve.js +15 -14
  233. package/js/src/indodax.js +30 -26
  234. package/js/src/kraken.js +29 -27
  235. package/js/src/krakenfutures.js +29 -22
  236. package/js/src/kucoin.d.ts +1 -1
  237. package/js/src/kucoin.js +48 -43
  238. package/js/src/kucoinfutures.js +33 -28
  239. package/js/src/kuna.js +25 -24
  240. package/js/src/latoken.js +25 -23
  241. package/js/src/lbank.js +46 -31
  242. package/js/src/luno.js +22 -19
  243. package/js/src/lykke.js +19 -17
  244. package/js/src/mercado.js +30 -19
  245. package/js/src/mexc.d.ts +1 -1
  246. package/js/src/mexc.js +60 -49
  247. package/js/src/ndax.js +23 -22
  248. package/js/src/novadax.js +23 -22
  249. package/js/src/oceanex.js +22 -19
  250. package/js/src/okcoin.js +29 -23
  251. package/js/src/okx.d.ts +2 -2
  252. package/js/src/okx.js +92 -84
  253. package/js/src/p2b.d.ts +8 -7
  254. package/js/src/p2b.js +80 -82
  255. package/js/src/paymium.js +10 -10
  256. package/js/src/phemex.js +63 -40
  257. package/js/src/poloniex.js +22 -22
  258. package/js/src/poloniexfutures.js +23 -19
  259. package/js/src/pro/alpaca.js +5 -5
  260. package/js/src/pro/ascendex.js +4 -4
  261. package/js/src/pro/binance.js +16 -16
  262. package/js/src/pro/bingx.js +1 -1
  263. package/js/src/pro/bitfinex.js +4 -4
  264. package/js/src/pro/bitfinex2.d.ts +1 -1
  265. package/js/src/pro/bitfinex2.js +6 -6
  266. package/js/src/pro/bitget.js +7 -7
  267. package/js/src/pro/bitmart.js +7 -5
  268. package/js/src/pro/bitmex.js +6 -6
  269. package/js/src/pro/bitopro.js +4 -4
  270. package/js/src/pro/bitpanda.js +6 -6
  271. package/js/src/pro/bitrue.js +2 -2
  272. package/js/src/pro/bitstamp.js +7 -5
  273. package/js/src/pro/bittrex.js +6 -6
  274. package/js/src/pro/bitvavo.js +12 -8
  275. package/js/src/pro/blockchaincom.js +8 -8
  276. package/js/src/pro/bybit.js +7 -7
  277. package/js/src/pro/cex.js +14 -10
  278. package/js/src/pro/coinbase.js +5 -5
  279. package/js/src/pro/coinbasepro.js +12 -11
  280. package/js/src/pro/coinex.js +7 -9
  281. package/js/src/pro/cryptocom.js +9 -9
  282. package/js/src/pro/currencycom.js +4 -4
  283. package/js/src/pro/deribit.js +6 -6
  284. package/js/src/pro/exmo.js +12 -14
  285. package/js/src/pro/gate.js +7 -7
  286. package/js/src/pro/gemini.js +3 -3
  287. package/js/src/pro/hitbtc.d.ts +8 -1
  288. package/js/src/pro/hitbtc.js +264 -5
  289. package/js/src/pro/hollaex.js +5 -5
  290. package/js/src/pro/htx.js +6 -6
  291. package/js/src/pro/huobijp.js +3 -3
  292. package/js/src/pro/idex.js +4 -4
  293. package/js/src/pro/independentreserve.js +2 -2
  294. package/js/src/pro/kraken.js +10 -10
  295. package/js/src/pro/krakenfutures.d.ts +1 -0
  296. package/js/src/pro/krakenfutures.js +42 -18
  297. package/js/src/pro/kucoin.js +7 -7
  298. package/js/src/pro/kucoinfutures.js +8 -6
  299. package/js/src/pro/luno.js +2 -2
  300. package/js/src/pro/mexc.js +6 -6
  301. package/js/src/pro/ndax.js +3 -3
  302. package/js/src/pro/okcoin.js +5 -5
  303. package/js/src/pro/okx.js +12 -12
  304. package/js/src/pro/phemex.js +6 -6
  305. package/js/src/pro/poloniex.js +7 -7
  306. package/js/src/pro/poloniexfutures.js +5 -5
  307. package/js/src/pro/probit.js +6 -6
  308. package/js/src/pro/upbit.js +3 -3
  309. package/js/src/pro/wazirx.js +8 -8
  310. package/js/src/pro/whitebit.js +13 -9
  311. package/js/src/pro/woo.js +1 -1
  312. package/js/src/probit.js +29 -24
  313. package/js/src/tidex.js +16 -15
  314. package/js/src/timex.js +19 -18
  315. package/js/src/tokocrypto.js +28 -23
  316. package/js/src/upbit.js +19 -19
  317. package/js/src/wavesexchange.js +23 -20
  318. package/js/src/wazirx.js +25 -18
  319. package/js/src/whitebit.js +33 -27
  320. package/js/src/woo.js +45 -35
  321. package/js/src/yobit.js +25 -20
  322. package/js/src/zaif.js +9 -9
  323. package/js/src/zonda.js +18 -17
  324. package/package.json +2 -2
  325. package/js/src/bitstamp1.d.ts +0 -28
  326. package/js/src/bitstamp1.js +0 -430
  327. package/js/src/lbank2.d.ts +0 -90
  328. package/js/src/lbank2.js +0 -2779
package/js/src/ace.js CHANGED
@@ -6,7 +6,7 @@
6
6
 
7
7
  // ---------------------------------------------------------------------------
8
8
  import Exchange from './abstract/ace.js';
9
- import { BadRequest, AuthenticationError, InsufficientFunds, InvalidOrder } from './base/errors.js';
9
+ import { BadRequest, AuthenticationError, InsufficientFunds, InvalidOrder, ArgumentsRequired } from './base/errors.js';
10
10
  import { Precise } from './base/Precise.js';
11
11
  import { TICK_SIZE } from './base/functions/number.js';
12
12
  import { sha256 } from './static_dependencies/noble-hashes/sha256.js';
@@ -37,11 +37,11 @@ export default class ace extends Exchange {
37
37
  'createOrder': true,
38
38
  'editOrder': false,
39
39
  'fetchBalance': true,
40
- 'fetchBorrowRate': false,
41
40
  'fetchBorrowRateHistories': false,
42
41
  'fetchBorrowRateHistory': false,
43
- 'fetchBorrowRates': false,
44
42
  'fetchClosedOrders': false,
43
+ 'fetchCrossBorrowRate': false,
44
+ 'fetchCrossBorrowRates': false,
45
45
  'fetchCurrencies': false,
46
46
  'fetchDepositAddress': false,
47
47
  'fetchDeposits': false,
@@ -50,6 +50,8 @@ export default class ace extends Exchange {
50
50
  'fetchFundingRateHistory': false,
51
51
  'fetchFundingRates': false,
52
52
  'fetchIndexOHLCV': false,
53
+ 'fetchIsolatedBorrowRate': false,
54
+ 'fetchIsolatedBorrowRates': false,
53
55
  'fetchMarginMode': false,
54
56
  'fetchMarkets': true,
55
57
  'fetchMarkOHLCV': false,
@@ -289,7 +291,7 @@ export default class ace extends Exchange {
289
291
  * @see https://github.com/ace-exchange/ace-official-api-docs/blob/master/api_v2.md#oapi-api---trade-data
290
292
  * @param {string} symbol unified symbol of the market to fetch the ticker for
291
293
  * @param {object} [params] extra parameters specific to the ace api endpoint
292
- * @returns {object} a [ticker structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#ticker-structure}
294
+ * @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
293
295
  */
294
296
  await this.loadMarkets();
295
297
  const market = this.market(symbol);
@@ -315,7 +317,7 @@ export default class ace extends Exchange {
315
317
  * @see https://github.com/ace-exchange/ace-official-api-docs/blob/master/api_v2.md#oapi-api---trade-data
316
318
  * @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
317
319
  * @param {object} [params] extra parameters specific to the ace api endpoint
318
- * @returns {object} a dictionary of [ticker structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#ticker-structure}
320
+ * @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
319
321
  */
320
322
  await this.loadMarkets();
321
323
  const response = await this.publicGetOapiV2ListTradePrice();
@@ -348,7 +350,7 @@ export default class ace extends Exchange {
348
350
  * @param {string} symbol unified symbol of the market to fetch the order book for
349
351
  * @param {int} [limit] the maximum amount of order book entries to return
350
352
  * @param {object} [params] extra parameters specific to the ace api endpoint
351
- * @returns {object} A dictionary of [order book structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-book-structure} indexed by market symbols
353
+ * @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
352
354
  */
353
355
  await this.loadMarkets();
354
356
  const market = this.market(symbol);
@@ -594,7 +596,7 @@ export default class ace extends Exchange {
594
596
  * @param {float} amount how much of currency you want to trade in units of base currency
595
597
  * @param {float} [price] the price at which the order is to be fullfilled, in units of the quote currency, ignored in market orders
596
598
  * @param {object} [params] extra parameters specific to the ace api endpoint
597
- * @returns {object} an [order structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
599
+ * @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
598
600
  */
599
601
  await this.loadMarkets();
600
602
  const market = this.market(symbol);
@@ -631,7 +633,7 @@ export default class ace extends Exchange {
631
633
  * @param {string} id order id
632
634
  * @param {string} symbol unified symbol of the market the order was made in
633
635
  * @param {object} [params] extra parameters specific to the ace api endpoint
634
- * @returns {object} An [order structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
636
+ * @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
635
637
  */
636
638
  await this.loadMarkets();
637
639
  const request = {
@@ -656,7 +658,7 @@ export default class ace extends Exchange {
656
658
  * @see https://github.com/ace-exchange/ace-official-api-docs/blob/master/api_v2.md#open-api---order-status
657
659
  * @param {string} symbol unified symbol of the market the order was made in
658
660
  * @param {object} [params] extra parameters specific to the ace api endpoint
659
- * @returns {object} An [order structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
661
+ * @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
660
662
  */
661
663
  await this.loadMarkets();
662
664
  const request = {
@@ -698,9 +700,11 @@ export default class ace extends Exchange {
698
700
  * @param {int} [since] the earliest time in ms to fetch orders for
699
701
  * @param {int} [limit] the maximum number of orde structures to retrieve
700
702
  * @param {object} [params] extra parameters specific to the ace api endpoint
701
- * @returns {Order[]} a list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
703
+ * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
702
704
  */
703
- this.checkRequiredSymbol('fetchOpenOrders', symbol);
705
+ if (symbol === undefined) {
706
+ throw new ArgumentsRequired(this.id + ' fetchOpenOrders() requires a symbol argument');
707
+ }
704
708
  await this.loadMarkets();
705
709
  const market = this.market(symbol);
706
710
  const request = {
@@ -834,7 +838,7 @@ export default class ace extends Exchange {
834
838
  * @param {int} [since] the earliest time in ms to fetch trades for
835
839
  * @param {int} [limit] the maximum number of trades to retrieve
836
840
  * @param {object} [params] extra parameters specific to the ace api endpoint
837
- * @returns {object[]} a list of [trade structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#trade-structure}
841
+ * @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure}
838
842
  */
839
843
  await this.loadMarkets();
840
844
  const market = this.safeMarket(symbol);
@@ -889,7 +893,7 @@ export default class ace extends Exchange {
889
893
  * @param {int} [since] timestamp in ms of the earliest trade to fetch
890
894
  * @param {int} [limit] the maximum amount of trades to fetch
891
895
  * @param {object} [params] extra parameters specific to the ace api endpoint
892
- * @returns {Trade[]} a list of [trade structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#public-trades}
896
+ * @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
893
897
  */
894
898
  await this.loadMarkets();
895
899
  const market = this.safeMarket(symbol);
@@ -974,7 +978,7 @@ export default class ace extends Exchange {
974
978
  * @description query for balance and get the amount of funds available for trading or funds locked in orders
975
979
  * @see https://github.com/ace-exchange/ace-official-api-docs/blob/master/api_v2.md#open-api---account-balance
976
980
  * @param {object} [params] extra parameters specific to the ace api endpoint
977
- * @returns {object} a [balance structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#balance-structure}
981
+ * @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
978
982
  */
979
983
  await this.loadMarkets();
980
984
  const response = await this.privatePostV2CoinCustomerAccount(params);
package/js/src/alpaca.js CHANGED
@@ -322,7 +322,7 @@ export default class alpaca extends Exchange {
322
322
  * @param {int} [since] timestamp in ms of the earliest trade to fetch
323
323
  * @param {int} [limit] the maximum amount of trades to fetch
324
324
  * @param {object} [params] extra parameters specific to the alpaca api endpoint
325
- * @returns {Trade[]} a list of [trade structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#public-trades}
325
+ * @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
326
326
  */
327
327
  await this.loadMarkets();
328
328
  const market = this.market(symbol);
@@ -366,7 +366,7 @@ export default class alpaca extends Exchange {
366
366
  * @param {string} symbol unified symbol of the market to fetch the order book for
367
367
  * @param {int} [limit] the maximum amount of order book entries to return
368
368
  * @param {object} [params] extra parameters specific to the alpaca api endpoint
369
- * @returns {object} A dictionary of [order book structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-book-structure} indexed by market symbols
369
+ * @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
370
370
  */
371
371
  await this.loadMarkets();
372
372
  const market = this.market(symbol);
@@ -512,7 +512,7 @@ export default class alpaca extends Exchange {
512
512
  * @param {float} [price] the price at which the order is to be fullfilled, in units of the quote currency, ignored in market orders
513
513
  * @param {object} [params] extra parameters specific to the alpaca api endpoint
514
514
  * @param {float} [params.triggerPrice] The price at which a trigger order is triggered at
515
- * @returns {object} an [order structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
515
+ * @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
516
516
  */
517
517
  await this.loadMarkets();
518
518
  const market = this.market(symbol);
@@ -596,7 +596,7 @@ export default class alpaca extends Exchange {
596
596
  * @param {string} id order id
597
597
  * @param {string} symbol unified symbol of the market the order was made in
598
598
  * @param {object} [params] extra parameters specific to the alpaca api endpoint
599
- * @returns {object} An [order structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
599
+ * @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
600
600
  */
601
601
  const request = {
602
602
  'order_id': id,
@@ -617,7 +617,7 @@ export default class alpaca extends Exchange {
617
617
  * @description fetches information on an order made by the user
618
618
  * @param {string} symbol unified symbol of the market the order was made in
619
619
  * @param {object} [params] extra parameters specific to the alpaca api endpoint
620
- * @returns {object} An [order structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
620
+ * @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
621
621
  */
622
622
  await this.loadMarkets();
623
623
  const request = {
@@ -637,7 +637,7 @@ export default class alpaca extends Exchange {
637
637
  * @param {int} [since] the earliest time in ms to fetch open orders for
638
638
  * @param {int} [limit] the maximum number of open orders structures to retrieve
639
639
  * @param {object} [params] extra parameters specific to the alpaca api endpoint
640
- * @returns {Order[]} a list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
640
+ * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
641
641
  */
642
642
  await this.loadMarkets();
643
643
  let market = undefined;
@@ -706,7 +706,7 @@ export default class ascendex extends Exchange {
706
706
  * @name ascendex#fetchAccounts
707
707
  * @description fetch all the accounts associated with a profile
708
708
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
709
- * @returns {object} a dictionary of [account structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#account-structure} indexed by the account type
709
+ * @returns {object} a dictionary of [account structures]{@link https://docs.ccxt.com/#/?id=account-structure} indexed by the account type
710
710
  */
711
711
  let accountGroup = this.safeString(this.options, 'account-group');
712
712
  let response = undefined;
@@ -804,7 +804,7 @@ export default class ascendex extends Exchange {
804
804
  * @name ascendex#fetchBalance
805
805
  * @description query for balance and get the amount of funds available for trading or funds locked in orders
806
806
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
807
- * @returns {object} a [balance structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#balance-structure}
807
+ * @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
808
808
  */
809
809
  await this.loadMarkets();
810
810
  await this.loadAccounts();
@@ -893,7 +893,7 @@ export default class ascendex extends Exchange {
893
893
  * @param {string} symbol unified symbol of the market to fetch the order book for
894
894
  * @param {int} [limit] the maximum amount of order book entries to return
895
895
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
896
- * @returns {object} A dictionary of [order book structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-book-structure} indexed by market symbols
896
+ * @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
897
897
  */
898
898
  await this.loadMarkets();
899
899
  const market = this.market(symbol);
@@ -984,7 +984,7 @@ export default class ascendex extends Exchange {
984
984
  * @description fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
985
985
  * @param {string} symbol unified symbol of the market to fetch the ticker for
986
986
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
987
- * @returns {object} a [ticker structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#ticker-structure}
987
+ * @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
988
988
  */
989
989
  await this.loadMarkets();
990
990
  const market = this.market(symbol);
@@ -1020,7 +1020,7 @@ export default class ascendex extends Exchange {
1020
1020
  * @see https://ascendex.github.io/ascendex-futures-pro-api-v2/#ticker
1021
1021
  * @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
1022
1022
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
1023
- * @returns {object} a dictionary of [ticker structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#ticker-structure}
1023
+ * @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
1024
1024
  */
1025
1025
  await this.loadMarkets();
1026
1026
  const request = {};
@@ -1194,7 +1194,7 @@ export default class ascendex extends Exchange {
1194
1194
  * @param {int} [since] timestamp in ms of the earliest trade to fetch
1195
1195
  * @param {int} [limit] the maximum amount of trades to fetch
1196
1196
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
1197
- * @returns {Trade[]} a list of [trade structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#public-trades}
1197
+ * @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
1198
1198
  */
1199
1199
  await this.loadMarkets();
1200
1200
  const market = this.market(symbol);
@@ -1421,7 +1421,7 @@ export default class ascendex extends Exchange {
1421
1421
  * @name ascendex#fetchTradingFees
1422
1422
  * @description fetch the trading fees for multiple markets
1423
1423
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
1424
- * @returns {object} a dictionary of [fee structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#fee-structure} indexed by market symbols
1424
+ * @returns {object} a dictionary of [fee structures]{@link https://docs.ccxt.com/#/?id=fee-structure} indexed by market symbols
1425
1425
  */
1426
1426
  await this.loadMarkets();
1427
1427
  await this.loadAccounts();
@@ -1572,7 +1572,7 @@ export default class ascendex extends Exchange {
1572
1572
  * @param {float} [params.takeProfit.triggerPrice] *swap only* take profit trigger price
1573
1573
  * @param {object} [params.stopLoss] *stopLoss object in params* containing the triggerPrice that the attached stop loss order will be triggered (perpetual swap markets only)
1574
1574
  * @param {float} [params.stopLoss.triggerPrice] *swap only* stop loss trigger price
1575
- * @returns [An order structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
1575
+ * @returns [An order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
1576
1576
  */
1577
1577
  await this.loadMarkets();
1578
1578
  await this.loadAccounts();
@@ -1664,7 +1664,7 @@ export default class ascendex extends Exchange {
1664
1664
  * @param {string} [params.timeInForce] "GTC", "IOC", "FOK", or "PO"
1665
1665
  * @param {bool} [params.postOnly] true or false
1666
1666
  * @param {float} [params.stopPrice] the price at which a trigger order is triggered at
1667
- * @returns {object} an [order structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
1667
+ * @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
1668
1668
  */
1669
1669
  await this.loadMarkets();
1670
1670
  await this.loadAccounts();
@@ -1758,7 +1758,7 @@ export default class ascendex extends Exchange {
1758
1758
  * @description fetches information on an order made by the user
1759
1759
  * @param {string} symbol unified symbol of the market the order was made in
1760
1760
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
1761
- * @returns {object} An [order structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
1761
+ * @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
1762
1762
  */
1763
1763
  await this.loadMarkets();
1764
1764
  await this.loadAccounts();
@@ -1871,7 +1871,7 @@ export default class ascendex extends Exchange {
1871
1871
  * @param {int} [since] the earliest time in ms to fetch open orders for
1872
1872
  * @param {int} [limit] the maximum number of open orders structures to retrieve
1873
1873
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
1874
- * @returns {Order[]} a list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
1874
+ * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
1875
1875
  */
1876
1876
  await this.loadMarkets();
1877
1877
  await this.loadAccounts();
@@ -1995,7 +1995,7 @@ export default class ascendex extends Exchange {
1995
1995
  * @param {int} [limit] the maximum number of orde structures to retrieve
1996
1996
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
1997
1997
  * @param {int} [params.until] the latest time in ms to fetch orders for
1998
- * @returns {Order[]} a list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
1998
+ * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
1999
1999
  */
2000
2000
  await this.loadMarkets();
2001
2001
  await this.loadAccounts();
@@ -2154,9 +2154,11 @@ export default class ascendex extends Exchange {
2154
2154
  * @param {string} id order id
2155
2155
  * @param {string} symbol unified symbol of the market the order was made in
2156
2156
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2157
- * @returns {object} An [order structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
2157
+ * @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
2158
2158
  */
2159
- this.checkRequiredSymbol('cancelOrder', symbol);
2159
+ if (symbol === undefined) {
2160
+ throw new ArgumentsRequired(this.id + ' cancelOrder() requires a symbol argument');
2161
+ }
2160
2162
  await this.loadMarkets();
2161
2163
  await this.loadAccounts();
2162
2164
  const market = this.market(symbol);
@@ -2270,7 +2272,7 @@ export default class ascendex extends Exchange {
2270
2272
  * @description cancel all open orders
2271
2273
  * @param {string} symbol unified market symbol, only orders in the market of this symbol are cancelled when symbol is not undefined
2272
2274
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2273
- * @returns {object[]} a list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
2275
+ * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
2274
2276
  */
2275
2277
  await this.loadMarkets();
2276
2278
  await this.loadAccounts();
@@ -2396,7 +2398,7 @@ export default class ascendex extends Exchange {
2396
2398
  * @description fetch the deposit address for a currency associated with this account
2397
2399
  * @param {string} code unified currency code
2398
2400
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2399
- * @returns {object} an [address structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#address-structure}
2401
+ * @returns {object} an [address structure]{@link https://docs.ccxt.com/#/?id=address-structure}
2400
2402
  */
2401
2403
  await this.loadMarkets();
2402
2404
  const currency = this.currency(code);
@@ -2470,7 +2472,7 @@ export default class ascendex extends Exchange {
2470
2472
  * @param {int} [since] the earliest time in ms to fetch deposits for
2471
2473
  * @param {int} [limit] the maximum number of deposits structures to retrieve
2472
2474
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2473
- * @returns {object[]} a list of [transaction structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#transaction-structure}
2475
+ * @returns {object[]} a list of [transaction structures]{@link https://docs.ccxt.com/#/?id=transaction-structure}
2474
2476
  */
2475
2477
  const request = {
2476
2478
  'txType': 'deposit',
@@ -2486,7 +2488,7 @@ export default class ascendex extends Exchange {
2486
2488
  * @param {int} [since] the earliest time in ms to fetch withdrawals for
2487
2489
  * @param {int} [limit] the maximum number of withdrawals structures to retrieve
2488
2490
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2489
- * @returns {object[]} a list of [transaction structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#transaction-structure}
2491
+ * @returns {object[]} a list of [transaction structures]{@link https://docs.ccxt.com/#/?id=transaction-structure}
2490
2492
  */
2491
2493
  const request = {
2492
2494
  'txType': 'withdrawal',
@@ -2502,7 +2504,7 @@ export default class ascendex extends Exchange {
2502
2504
  * @param {int} [since] timestamp in ms of the earliest deposit/withdrawal, default is undefined
2503
2505
  * @param {int} [limit] max number of deposit/withdrawals to return, default is undefined
2504
2506
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2505
- * @returns {object} a list of [transaction structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#transaction-structure}
2507
+ * @returns {object} a list of [transaction structure]{@link https://docs.ccxt.com/#/?id=transaction-structure}
2506
2508
  */
2507
2509
  await this.loadMarkets();
2508
2510
  const request = {
@@ -2625,7 +2627,7 @@ export default class ascendex extends Exchange {
2625
2627
  * @description fetch all open positions
2626
2628
  * @param {string[]|undefined} symbols list of unified market symbols
2627
2629
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2628
- * @returns {object[]} a list of [position structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#position-structure}
2630
+ * @returns {object[]} a list of [position structure]{@link https://docs.ccxt.com/#/?id=position-structure}
2629
2631
  */
2630
2632
  await this.loadMarkets();
2631
2633
  await this.loadAccounts();
@@ -2791,7 +2793,7 @@ export default class ascendex extends Exchange {
2791
2793
  * @description fetch the funding rate for multiple markets
2792
2794
  * @param {string[]|undefined} symbols list of unified market symbols
2793
2795
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2794
- * @returns {object} a dictionary of [funding rates structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#funding-rates-structure}, indexe by market symbols
2796
+ * @returns {object} a dictionary of [funding rates structures]{@link https://docs.ccxt.com/#/?id=funding-rates-structure}, indexe by market symbols
2795
2797
  */
2796
2798
  await this.loadMarkets();
2797
2799
  symbols = this.marketSymbols(symbols);
@@ -2873,7 +2875,7 @@ export default class ascendex extends Exchange {
2873
2875
  * @param {string} symbol unified market symbol
2874
2876
  * @param {float} amount the amount of margin to remove
2875
2877
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2876
- * @returns {object} a [margin structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#reduce-margin-structure}
2878
+ * @returns {object} a [margin structure]{@link https://docs.ccxt.com/#/?id=reduce-margin-structure}
2877
2879
  */
2878
2880
  return await this.modifyMarginHelper(symbol, -amount, 'reduce', params);
2879
2881
  }
@@ -2885,7 +2887,7 @@ export default class ascendex extends Exchange {
2885
2887
  * @param {string} symbol unified market symbol
2886
2888
  * @param {float} amount amount of margin to add
2887
2889
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2888
- * @returns {object} a [margin structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#add-margin-structure}
2890
+ * @returns {object} a [margin structure]{@link https://docs.ccxt.com/#/?id=add-margin-structure}
2889
2891
  */
2890
2892
  return await this.modifyMarginHelper(symbol, amount, 'add', params);
2891
2893
  }
@@ -2900,7 +2902,9 @@ export default class ascendex extends Exchange {
2900
2902
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2901
2903
  * @returns {object} response from the exchange
2902
2904
  */
2903
- this.checkRequiredSymbol('setLeverage', symbol);
2905
+ if (symbol === undefined) {
2906
+ throw new ArgumentsRequired(this.id + ' setLeverage() requires a symbol argument');
2907
+ }
2904
2908
  if ((leverage < 1) || (leverage > 100)) {
2905
2909
  throw new BadRequest(this.id + ' leverage should be between 1 and 100');
2906
2910
  }
@@ -2930,7 +2934,9 @@ export default class ascendex extends Exchange {
2930
2934
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2931
2935
  * @returns {object} response from the exchange
2932
2936
  */
2933
- this.checkRequiredSymbol('setMarginMode', symbol);
2937
+ if (symbol === undefined) {
2938
+ throw new ArgumentsRequired(this.id + ' setMarginMode() requires a symbol argument');
2939
+ }
2934
2940
  marginMode = marginMode.toLowerCase();
2935
2941
  if (marginMode === 'cross') {
2936
2942
  marginMode = 'crossed';
@@ -2960,7 +2966,7 @@ export default class ascendex extends Exchange {
2960
2966
  * @description retrieve information on the maximum leverage, and maintenance margin for trades of varying trade sizes
2961
2967
  * @param {string[]|undefined} symbols list of unified market symbols
2962
2968
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
2963
- * @returns {object} a dictionary of [leverage tiers structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#leverage-tiers-structure}, indexed by market symbols
2969
+ * @returns {object} a dictionary of [leverage tiers structures]{@link https://docs.ccxt.com/#/?id=leverage-tiers-structure}, indexed by market symbols
2964
2970
  */
2965
2971
  await this.loadMarkets();
2966
2972
  const response = await this.v2PublicGetFuturesContract(params);
@@ -3101,7 +3107,7 @@ export default class ascendex extends Exchange {
3101
3107
  * @see https://ascendex.github.io/ascendex-pro-api/#list-all-assets
3102
3108
  * @param {string[]|undefined} codes list of unified currency codes
3103
3109
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
3104
- * @returns {object} a list of [fee structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#fee-structure}
3110
+ * @returns {object} a list of [fee structures]{@link https://docs.ccxt.com/#/?id=fee-structure}
3105
3111
  */
3106
3112
  await this.loadMarkets();
3107
3113
  const response = await this.v2PublicGetAssets(params);
@@ -3118,7 +3124,7 @@ export default class ascendex extends Exchange {
3118
3124
  * @param {string} fromAccount account to transfer from
3119
3125
  * @param {string} toAccount account to transfer to
3120
3126
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
3121
- * @returns {object} a [transfer structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#transfer-structure}
3127
+ * @returns {object} a [transfer structure]{@link https://docs.ccxt.com/#/?id=transfer-structure}
3122
3128
  */
3123
3129
  await this.loadMarkets();
3124
3130
  await this.loadAccounts();
@@ -3190,7 +3196,7 @@ export default class ascendex extends Exchange {
3190
3196
  * @param {int} [limit] the maximum number of funding history structures to retrieve
3191
3197
  * @param {object} [params] extra parameters specific to the ascendex api endpoint
3192
3198
  * @param {boolean} [params.paginate] default false, when true will automatically paginate by calling this endpoint multiple times. See in the docs all the [available parameters](https://github.com/ccxt/ccxt/wiki/Manual#pagination-params)
3193
- * @returns {object} a [funding history structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#funding-history-structure}
3199
+ * @returns {object} a [funding history structure]{@link https://docs.ccxt.com/#/?id=funding-history-structure}
3194
3200
  */
3195
3201
  await this.loadMarkets();
3196
3202
  await this.loadAccounts();
@@ -4,7 +4,7 @@ ExchangeError, AuthenticationError, DDoSProtection, RequestTimeout, ExchangeNotA
4
4
  import WsClient from './ws/WsClient.js';
5
5
  import { Future } from './ws/Future.js';
6
6
  import { OrderBook as WsOrderBook, IndexedOrderBook, CountedOrderBook } from './ws/OrderBook.js';
7
- import { Market, Trade, Ticker, OHLCV, OHLCVC, Order, OrderBook, Balance, Balances, Dictionary, DepositAddressResponse, Currency, MinMax, IndexType, Int, OrderType, OrderSide, Position, FundingRateHistory, OpenInterest, Liquidation, OrderRequest, FundingHistory, MarginMode, Tickers, Greeks, Str, Num, MarketInterface, CurrencyInterface } from './types.js';
7
+ import { Market, Trade, Ticker, OHLCV, OHLCVC, Order, OrderBook, Balance, Balances, Dictionary, DepositAddressResponse, Currency, MinMax, IndexType, Int, OrderType, OrderSide, Position, FundingRateHistory, OpenInterest, Liquidation, OrderRequest, FundingHistory, MarginMode, Tickers, Greeks, Str, Num, MarketInterface, CurrencyInterface, Account } from './types.js';
8
8
  export { Market, Trade, Fee, Ticker, OHLCV, OHLCVC, Order, OrderBook, Balance, Balances, Dictionary, Transaction, DepositAddressResponse, Currency, MinMax, IndexType, Int, OrderType, OrderSide, Position, FundingRateHistory, Liquidation, FundingHistory, Greeks } from './types.js';
9
9
  /**
10
10
  * @class Exchange
@@ -175,12 +175,12 @@ export default class Exchange {
175
175
  capitalize: (s: string) => string;
176
176
  now: () => number;
177
177
  decimalToPrecision: (x: any, roundingMode: any, numPrecisionDigits: any, countingMode?: number, paddingMode?: number) => any;
178
- safeValue: (o: any, k: string | number, $default?: any) => any;
179
- safeValue2: (o: any, k1: string | number, k2: string | number, $default?: any) => any;
180
- safeString: (o: any, k: string | number, $default?: string) => string;
181
- safeString2: (o: any, k1: string | number, k2: string | number, $default?: string) => string;
182
- safeFloat: (o: any, k: string | number, $default?: number) => number;
183
- safeFloat2: (o: any, k1: string | number, k2: string | number, $default?: number) => number;
178
+ safeValue: (o: any, k: IndexType, $default?: any) => any;
179
+ safeValue2: (o: any, k1: IndexType, k2: IndexType, $default?: any) => any;
180
+ safeString: (o: any, k: IndexType, $default?: string) => string;
181
+ safeString2: (o: any, k1: IndexType, k2: IndexType, $default?: string) => string;
182
+ safeFloat: (o: any, k: IndexType, $default?: number) => number;
183
+ safeFloat2: (o: any, k1: IndexType, k2: IndexType, $default?: number) => number;
184
184
  seconds: () => number;
185
185
  milliseconds: () => number;
186
186
  binaryToBase16: (data: Uint8Array) => string;
@@ -189,7 +189,7 @@ export default class Exchange {
189
189
  iso8601: (timestamp: any) => string;
190
190
  omit: (x: any, ...args: any[]) => any;
191
191
  isJsonEncodedObject: (object: any) => boolean;
192
- safeInteger: (o: any, k: string | number, $default?: number) => number;
192
+ safeInteger: (o: any, k: IndexType, $default?: number) => number;
193
193
  sum: (...xs: any[]) => any;
194
194
  omitZero: typeof functions.omitZero;
195
195
  implodeParams: (string: any, params: any) => any;
@@ -215,12 +215,12 @@ export default class Exchange {
215
215
  }, digest?: "binary" | "hex" | "base64") => any;
216
216
  numberToString: typeof functions.numberToString;
217
217
  parseTimeframe: (timeframe: string) => number;
218
- safeInteger2: (o: any, k1: string | number, k2: string | number, $default?: number) => number;
219
- safeStringLower: (o: any, k: string | number, $default?: string) => string;
218
+ safeInteger2: (o: any, k1: IndexType, k2: IndexType, $default?: number) => number;
219
+ safeStringLower: (o: any, k: IndexType, $default?: string) => string;
220
220
  parse8601: (x: any) => number;
221
221
  yyyymmdd: (timestamp: any, infix?: string) => string;
222
- safeStringUpper: (o: any, k: string | number, $default?: string) => string;
223
- safeTimestamp: (o: any, k: string | number, $default?: number) => number;
222
+ safeStringUpper: (o: any, k: IndexType, $default?: string) => string;
223
+ safeTimestamp: (o: any, k: IndexType, $default?: number) => number;
224
224
  binaryConcatArray: (arr: any) => Uint8Array;
225
225
  uuidv1: () => string;
226
226
  numberToLE: (n: number, padding: number) => Uint8Array;
@@ -229,17 +229,17 @@ export default class Exchange {
229
229
  stringToBase64: (string: any) => string;
230
230
  decode: (data: Uint8Array) => string;
231
231
  uuid22: (a?: any) => string;
232
- safeIntegerProduct2: (o: any, k1: string | number, k2: string | number, $factor: number, $default?: number) => number;
233
- safeIntegerProduct: (o: any, k: string | number, $factor: number, $default?: number) => number;
232
+ safeIntegerProduct2: (o: any, k1: IndexType, k2: IndexType, $factor: number, $default?: number) => number;
233
+ safeIntegerProduct: (o: any, k: IndexType, $factor: number, $default?: number) => number;
234
234
  binaryToBase58: (data: Uint8Array) => string;
235
235
  base58ToBinary: (str: string) => Uint8Array;
236
236
  base64ToBinary: (str: string) => Uint8Array;
237
- safeTimestamp2: (o: any, k1: string | number, k2: string | number, $default?: any) => number;
237
+ safeTimestamp2: (o: any, k1: IndexType, k2: IndexType, $default?: any) => number;
238
238
  rawencode: (object: any) => string;
239
239
  keysort: (x: any, out?: {}) => {};
240
240
  inArray: (needle: any, haystack: any) => any;
241
- safeStringLower2: (o: any, k1: string | number, k2: string | number, $default?: string) => string;
242
- safeStringUpper2: (o: any, k1: string | number, k2: string | number, $default?: string) => string;
241
+ safeStringLower2: (o: any, k1: IndexType, k2: IndexType, $default?: string) => string;
242
+ safeStringUpper2: (o: any, k1: IndexType, k2: IndexType, $default?: string) => string;
243
243
  isEmpty: (object: any) => boolean;
244
244
  ordered: (x: any) => any;
245
245
  filterBy: (x: any, k: any, value?: any, out?: any[]) => any[];
@@ -249,14 +249,14 @@ export default class Exchange {
249
249
  binaryToBase64: (data: Uint8Array) => string;
250
250
  strip: (s: string) => string;
251
251
  toArray: (object: any) => unknown[];
252
- safeFloatN: (o: any, k: (string | number)[], $default?: number) => number;
253
- safeIntegerN: (o: any, k: (string | number)[], $default?: number) => number;
254
- safeIntegerProductN: (o: any, k: (string | number)[], $factor: number, $default?: number) => number;
255
- safeTimestampN: (o: any, k: (string | number)[], $default?: number) => number;
256
- safeValueN: (o: any, k: (string | number)[], $default?: any) => any;
257
- safeStringN: (o: any, k: (string | number)[], $default?: string) => string;
258
- safeStringLowerN: (o: any, k: (string | number)[], $default?: string) => string;
259
- safeStringUpperN: (o: any, k: (string | number)[], $default?: string) => string;
252
+ safeFloatN: (o: any, k: IndexType[], $default?: number) => number;
253
+ safeIntegerN: (o: any, k: IndexType[], $default?: number) => number;
254
+ safeIntegerProductN: (o: any, k: IndexType[], $factor: number, $default?: number) => number;
255
+ safeTimestampN: (o: any, k: IndexType[], $default?: number) => number;
256
+ safeValueN: (o: any, k: IndexType[], $default?: any) => any;
257
+ safeStringN: (o: any, k: IndexType[], $default?: string) => string;
258
+ safeStringLowerN: (o: any, k: IndexType[], $default?: string) => string;
259
+ safeStringUpperN: (o: any, k: IndexType[], $default?: string) => string;
260
260
  urlencodeNested: (object: any) => string;
261
261
  parseDate: (x: any) => number;
262
262
  ymd: (timestamp: any, infix: any, fullYear?: boolean) => string;
@@ -308,13 +308,12 @@ export default class Exchange {
308
308
  fetchBalance: boolean;
309
309
  fetchBidsAsks: any;
310
310
  fetchBorrowInterest: any;
311
- fetchBorrowRate: any;
312
311
  fetchBorrowRateHistory: any;
313
- fetchBorrowRatesPerSymbol: any;
314
- fetchBorrowRates: any;
315
312
  fetchCanceledOrders: any;
316
313
  fetchClosedOrder: any;
317
314
  fetchClosedOrders: any;
315
+ fetchCrossBorrowRate: any;
316
+ fetchCrossBorrowRates: any;
318
317
  fetchCurrencies: string;
319
318
  fetchDeposit: any;
320
319
  fetchDepositAddress: any;
@@ -329,6 +328,8 @@ export default class Exchange {
329
328
  fetchFundingRateHistory: any;
330
329
  fetchFundingRates: any;
331
330
  fetchIndexOHLCV: any;
331
+ fetchIsolatedBorrowRate: any;
332
+ fetchIsolatedBorrowRates: any;
332
333
  fetchL2OrderBook: boolean;
333
334
  fetchLastPrices: any;
334
335
  fetchLedger: any;
@@ -551,7 +552,7 @@ export default class Exchange {
551
552
  fetchMarginMode(symbol?: string, params?: {}): Promise<MarginMode>;
552
553
  fetchRestOrderBookSafe(symbol: any, limit?: any, params?: {}): Promise<OrderBook>;
553
554
  watchOrderBook(symbol: string, limit?: Int, params?: {}): Promise<OrderBook>;
554
- fetchTime(params?: {}): Promise<number>;
555
+ fetchTime(params?: {}): Promise<Int>;
555
556
  fetchTradingLimits(symbols?: string[], params?: {}): Promise<any>;
556
557
  parseMarket(market: any): Market;
557
558
  parseMarkets(markets: any): Market[];
@@ -563,7 +564,8 @@ export default class Exchange {
563
564
  parseAccount(account: any): void;
564
565
  parseLedgerEntry(item: any, currency?: Currency): void;
565
566
  parseOrder(order: any, market?: Market): Order;
566
- fetchBorrowRates(params?: {}): Promise<any>;
567
+ fetchCrossBorrowRates(params?: {}): Promise<any>;
568
+ fetchIsolatedBorrowRates(params?: {}): Promise<any>;
567
569
  parseMarketLeverageTiers(info: any, market?: Market): void;
568
570
  fetchLeverageTiers(symbols?: string[], params?: {}): Promise<any>;
569
571
  parsePosition(position: any, market?: Market): void;
@@ -580,6 +582,7 @@ export default class Exchange {
580
582
  setLeverage(leverage: any, symbol?: string, params?: {}): Promise<any>;
581
583
  parseToInt(number: any): number;
582
584
  parseToNumeric(number: any): number;
585
+ isRoundNumber(value: any): boolean;
583
586
  afterConstruct(): void;
584
587
  createNetworksByIdObject(): void;
585
588
  getDefaultOptions(): {
@@ -706,10 +709,11 @@ export default class Exchange {
706
709
  fetchDepositWithdrawFees(codes?: string[], params?: {}): Promise<any>;
707
710
  fetchDepositWithdrawFee(code: string, params?: {}): Promise<any>;
708
711
  getSupportedMapping(key: any, mapping?: {}): any;
709
- fetchBorrowRate(code: string, params?: {}): Promise<any>;
712
+ fetchCrossBorrowRate(code: string, params?: {}): Promise<any>;
713
+ fetchIsolatedBorrowRate(symbol: string, params?: {}): Promise<any>;
710
714
  handleOptionAndParams(params: any, methodName: any, optionName: any, defaultValue?: any): any[];
711
715
  handleOption(methodName: any, optionName: any, defaultValue?: any): any;
712
- handleMarketTypeAndParams(methodName: any, market?: any, params?: {}): any;
716
+ handleMarketTypeAndParams(methodName: string, market?: Market, params?: {}): any;
713
717
  handleSubTypeAndParams(methodName: any, market?: any, params?: {}, defaultValue?: any): any[];
714
718
  handleMarginModeAndParams(methodName: any, params?: {}, defaultValue?: any): any[];
715
719
  throwExactlyMatchedException(exact: any, string: any, message: any): void;
@@ -756,7 +760,7 @@ export default class Exchange {
756
760
  fetchFundingHistory(symbol?: string, since?: Int, limit?: Int, params?: {}): Promise<FundingHistory[]>;
757
761
  parseLastPrice(price: any, market?: Market): any;
758
762
  fetchDepositAddress(code: string, params?: {}): Promise<any>;
759
- account(): Balance;
763
+ account(): Account;
760
764
  commonCurrencyCode(currency: string): string;
761
765
  currency(code: any): any;
762
766
  market(symbol: string): MarketInterface;
@@ -815,7 +819,6 @@ export default class Exchange {
815
819
  convertTypeToAccount(account: any): any;
816
820
  checkRequiredArgument(methodName: any, argument: any, argumentName: any, options?: any[]): void;
817
821
  checkRequiredMarginArgument(methodName: string, symbol: string, marginMode: string): void;
818
- checkRequiredSymbol(methodName: string, symbol: string): void;
819
822
  parseDepositWithdrawFees(response: any, codes?: string[], currencyIdKey?: any): any;
820
823
  parseDepositWithdrawFee(fee: any, currency?: Currency): any;
821
824
  depositWithdrawFee(info: any): any;