Skip to content

Commit 9378f08

Browse files
committed
minor edits
1 parent b7a7694 commit 9378f08

File tree

2 files changed

+19
-17
lines changed

2 files changed

+19
-17
lines changed

examples2md.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ console.log ('📰 Creating Examples.md ');
1717
const readmePath = './examples/README.md';
1818
const readmeContent = fs.readFileSync(readmePath, 'utf8');
1919
// replace github links to docs links
20-
const modifiedContent = readmeContent.replaceAll('https://github.com/ccxt/ccxt/tree/master/examples', '/examples');
20+
const modifiedContent = readmeContent.replaceAll('https://github.com/ccxt/ccxt/tree/master/examples', '/examples').replace (/#+ See Also[\S\s]+/, '')
2121
fs.writeFileSync(path.join(docsDir, 'Examples.md'), modifiedContent);
2222

2323
const languagePaths = {
@@ -68,6 +68,8 @@ languages.forEach(language => {
6868
let code = fs.readFileSync(path.join(languageDir, file), 'utf8');
6969
if (language === 'python') {
7070
code = code.replace (/^.*os.path.dirname.*$/mg, '').replace (/^sys.path.append.*$\n\n?/mg, '')
71+
} else if (language === 'php') {
72+
code = code.replace (/\n^\$root = .*$\n/mg, '').replace (/^include \$root.*$/mg, 'include \'./ccxt.php\';')
7173
}
7274
code = code.replace (/\n^#\s?-+$\n\n?/mg, '')
7375
const codeMd = `- [${fileTitle}](${languageDir}/)\n\n\n \`\`\`${language.replace('typescript', 'javascript')}\n ${code} \n\`\`\``;

ts/src/bingx.ts

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -633,7 +633,7 @@ export default class bingx extends Exchange {
633633
* @see https://bingx-api.github.io/docs/#/spot/market-api.html#Query%20Symbols
634634
* @see https://bingx-api.github.io/docs/#/swapV2/market-api.html#Contract%20Information
635635
* @param {object} [params] extra parameters specific to the exchange api endpoint
636-
* @returns {[object]} an array of objects representing market data
636+
* @returns {object[]} an array of objects representing market data
637637
*/
638638
const requests = [ this.fetchSpotMarkets (params), this.fetchSwapMarkets (params) ];
639639
const promises = await Promise.all (requests);
@@ -657,7 +657,7 @@ export default class bingx extends Exchange {
657657
* @param {object} [params] extra parameters specific to the bingx api endpoint
658658
* @param {int} [params.until] timestamp in ms of the latest candle to fetch
659659
* @param {boolean} [params.paginate] default false, when true will automatically paginate by calling this endpoint multiple times. See in the docs all the [availble parameters](https://github.com/ccxt/ccxt/wiki/Manual#pagination-params)
660-
* @returns {[[int]]} A list of candles ordered as timestamp, open, high, low, close, volume
660+
* @returns {int[][]} A list of candles ordered as timestamp, open, high, low, close, volume
661661
*/
662662
await this.loadMarkets ();
663663
let paginate = false;
@@ -764,7 +764,7 @@ export default class bingx extends Exchange {
764764
* @param {int} [since] timestamp in ms of the earliest trade to fetch
765765
* @param {int} [limit] the maximum amount of trades to fetch
766766
* @param {object} [params] extra parameters specific to the bingx api endpoint
767-
* @returns {[object]} a list of [trade structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#public-trades}
767+
* @returns {object[]} a list of [trade structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#public-trades}
768768
*/
769769
await this.loadMarkets ();
770770
const market = this.market (symbol);
@@ -1097,7 +1097,7 @@ export default class bingx extends Exchange {
10971097
* @param {object} [params] extra parameters specific to the bingx api endpoint
10981098
* @param {int} [params.until] timestamp in ms of the latest funding rate to fetch
10991099
* @param {boolean} [params.paginate] default false, when true will automatically paginate by calling this endpoint multiple times. See in the docs all the [availble parameters](https://github.com/ccxt/ccxt/wiki/Manual#pagination-params)
1100-
* @returns {[object]} a list of [funding rate structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#funding-rate-history-structure}
1100+
* @returns {object[]} a list of [funding rate structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#funding-rate-history-structure}
11011101
*/
11021102
this.checkRequiredSymbol ('fetchFundingRateHistory', symbol);
11031103
await this.loadMarkets ();
@@ -1263,7 +1263,7 @@ export default class bingx extends Exchange {
12631263
* @name bingx#fetchTickers
12641264
* @description fetches price tickers for multiple markets, statistical calculations with the information calculated over the past 24 hours each market
12651265
* @see https://bingx-api.github.io/docs/#/swapV2/market-api.html#Get%20Ticker
1266-
* @param {[string]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
1266+
* @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
12671267
* @param {object} [params] extra parameters specific to the bingx api endpoint
12681268
* @returns {object} a dictionary of [ticker structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#ticker-structure}
12691269
*/
@@ -1500,10 +1500,10 @@ export default class bingx extends Exchange {
15001500
* @description fetch all open positions
15011501
* @see https://bingx-api.github.io/docs/#/swapV2/account-api.html#Perpetual%20Swap%20Positions
15021502
* @see https://bingx-api.github.io/docs/#/standard/contract-interface.html#Query%20standard%20contract%20balance
1503-
* @param {[string]|undefined} symbols list of unified market symbols
1503+
* @param {string[]|undefined} symbols list of unified market symbols
15041504
* @param {object} [params] extra parameters specific to the bingx api endpoint
15051505
* @param {boolean} [params.standard] whether to fetch standard contract positions
1506-
* @returns {[object]} a list of [position structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#position-structure}
1506+
* @returns {object[]} a list of [position structure]{@link https://github.com/ccxt/ccxt/wiki/Manual#position-structure}
15071507
*/
15081508
await this.loadMarkets ();
15091509
symbols = this.marketSymbols (symbols);
@@ -2020,7 +2020,7 @@ export default class bingx extends Exchange {
20202020
* @see https://bingx-api.github.io/docs/#/swapV2/trade-api.html#Cancel%20All%20Orders
20212021
* @param {string} [symbol] unified market symbol, only orders in the market of this symbol are cancelled when symbol is not undefined
20222022
* @param {object} [params] extra parameters specific to the bingx api endpoint
2023-
* @returns {[object]} a list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
2023+
* @returns {object[]} a list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
20242024
*/
20252025
this.checkRequiredSymbol ('cancelAllOrders', symbol);
20262026
await this.loadMarkets ();
@@ -2071,7 +2071,7 @@ export default class bingx extends Exchange {
20712071
* @description cancel multiple orders
20722072
* @see https://bingx-api.github.io/docs/#/swapV2/trade-api.html#Cancel%20a%20Batch%20of%20Orders
20732073
* @see https://bingx-api.github.io/docs/#/spot/trade-api.html#Cancel%20a%20Batch%20of%20Orders
2074-
* @param {[string]} ids order ids
2074+
* @param {string[]} ids order ids
20752075
* @param {string} symbol unified market symbol, default is undefined
20762076
* @param {object} [params] extra parameters specific to the bingx api endpoint
20772077
* @returns {object} an list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
@@ -2220,7 +2220,7 @@ export default class bingx extends Exchange {
22202220
* @param {int} [since] the earliest time in ms to fetch open orders for
22212221
* @param {int} [limit] the maximum number of open order structures to retrieve
22222222
* @param {object} [params] extra parameters specific to the bingx api endpoint
2223-
* @returns {[object]} a list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
2223+
* @returns {object[]} a list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
22242224
*/
22252225
this.checkRequiredSymbol ('fetchOrders', symbol);
22262226
await this.loadMarkets ();
@@ -2309,7 +2309,7 @@ export default class bingx extends Exchange {
23092309
* @param {object} [params] extra parameters specific to the bingx api endpoint
23102310
* @param {int} [params.until] the latest time in ms to fetch orders for
23112311
* @param {boolean} [params.standard] whether to fetch standard contract orders
2312-
* @returns {[object]} a list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
2312+
* @returns {object[]} a list of [order structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#order-structure}
23132313
*/
23142314
this.checkRequiredSymbol ('fetchClosedOrders', symbol);
23152315
await this.loadMarkets ();
@@ -2440,7 +2440,7 @@ export default class bingx extends Exchange {
24402440
* @param {int} [since] the earliest time in ms to fetch transfers for
24412441
* @param {int} [limit] the maximum number of transfers structures to retrieve
24422442
* @param {object} [params] extra parameters specific to the bingx api endpoint
2443-
* @returns {[object]} a list of [transfer structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#transfer-structure}
2443+
* @returns {object[]} a list of [transfer structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#transfer-structure}
24442444
*/
24452445
await this.loadMarkets ();
24462446
let currency = undefined;
@@ -2589,7 +2589,7 @@ export default class bingx extends Exchange {
25892589
* @param {int} [since] the earliest time in ms to fetch deposits for
25902590
* @param {int} [limit] the maximum number of deposits structures to retrieve
25912591
* @param {object} [params] extra parameters specific to the bingx api endpoint
2592-
* @returns {[object]} a list of [transaction structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#transaction-structure}
2592+
* @returns {object[]} a list of [transaction structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#transaction-structure}
25932593
*/
25942594
await this.loadMarkets ();
25952595
const request = {
@@ -2636,7 +2636,7 @@ export default class bingx extends Exchange {
26362636
* @param {int} [since] the earliest time in ms to fetch withdrawals for
26372637
* @param {int} [limit] the maximum number of withdrawals structures to retrieve
26382638
* @param {object} [params] extra parameters specific to the bingx api endpoint
2639-
* @returns {[object]} a list of [transaction structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#transaction-structure}
2639+
* @returns {object[]} a list of [transaction structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#transaction-structure}
26402640
*/
26412641
await this.loadMarkets ();
26422642
const request = {
@@ -2917,7 +2917,7 @@ export default class bingx extends Exchange {
29172917
* @param {int} [limit] the maximum number of trades structures to retrieve
29182918
* @param {object} [params] extra parameters specific to the bingx api endpoint
29192919
* @param {string} params.trandingUnit COIN (directly represent assets such as BTC and ETH) or CONT (represents the number of contract sheets)
2920-
* @returns {[object]} a list of [trade structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#trade-structure}
2920+
* @returns {object[]} a list of [trade structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#trade-structure}
29212921
*/
29222922
this.checkRequiredArgument ('fetchMyTrades', symbol, 'symbol');
29232923
this.checkRequiredArgument ('fetchMyTrades', since, 'since');
@@ -3029,7 +3029,7 @@ export default class bingx extends Exchange {
30293029
* @name bingx#fetchDepositWithdrawFees
30303030
* @description fetch deposit and withdraw fees
30313031
* @see https://bingx-api.github.io/docs/#/common/account-api.html#All%20Coins'%20Information
3032-
* @param {[string]|undefined} codes list of unified currency codes
3032+
* @param {string[]|undefined} codes list of unified currency codes
30333033
* @param {object} [params] extra parameters specific to the bingx api endpoint
30343034
* @returns {object} a list of [fee structures]{@link https://github.com/ccxt/ccxt/wiki/Manual#fee-structure}
30353035
*/

0 commit comments

Comments
 (0)