Skip to content

Commit

Permalink
Merge pull request #51 from JJ-Cro/update081124
Browse files Browse the repository at this point in the history
chore(): Updated examples so each client matches the proper initialisation
  • Loading branch information
tiagosiebler authored Nov 11, 2024
2 parents 6fc463e + 218aaf9 commit 96f2ebe
Show file tree
Hide file tree
Showing 250 changed files with 250 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.batchCreateVirtualSubaccountAndAPIKey(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/borrowLoan.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.borrowLoan(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/cancelSpotFollowerOrder.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.cancelSpotFollowerOrder(params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.closeFuturesFollowerPositions(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/closeFuturesTraderOrder.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.closeFuturesTraderOrder(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/convert.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.convert(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/convertBGB.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.convertBGB(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/createSubaccount.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.createSubaccount(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/createSubaccountApiKey.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.createSubaccountApiKey(params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.createSubaccountDepositAddress(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/createVirtualSubaccount.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.createVirtualSubaccount(params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.createVirtualSubaccountAPIKey(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/earnSubscribeSavings.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.earnSubscribeSavings(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresBatchCancelOrders.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresBatchCancelOrders(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresBatchSubmitOrders.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresBatchSubmitOrders(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresCancelAllOrders.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresCancelAllOrders(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresCancelOrder.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresCancelOrder(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresCancelPlanOrder.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresCancelPlanOrder(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresFlashClosePositions.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresFlashClosePositions(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresModifyOrder.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresModifyOrder(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresModifyPlanOrder.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresModifyPlanOrder(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresModifyTPSLPOrder.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresModifyTPSLPOrder(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresSubmitOrder.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresSubmitOrder(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresSubmitPlanOrder.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresSubmitPlanOrder(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresSubmitPlanSubOrder.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresSubmitPlanSubOrder(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresSubmitReversal.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresSubmitReversal(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/futuresSubmitTPSLOrder.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.futuresSubmitTPSLOrder(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getAnnouncements.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getAnnouncements(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getBalances.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getBalances(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getBotAccount.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getBotAccount(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getBrokerInfo.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getBrokerInfo(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getBrokerTraders.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getBrokerTraders(params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getBrokerTradersHistoricalOrders(params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getBrokerTradersPendingOrders(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getConvertBGBCoins.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getConvertBGBCoins(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getConvertBGBHistory.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getConvertBGBHistory(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getConvertCoins.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getConvertCoins(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getConvertHistory.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getConvertHistory(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getConvertQuotedPrice.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getConvertQuotedPrice(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getEarnAccount.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getEarnAccount(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getEarnSavingsAccount.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getEarnSavingsAccount(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getEarnSavingsAssets.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getEarnSavingsAssets(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getEarnSavingsProducts.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getEarnSavingsProducts(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getEarnSavingsRecords.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getEarnSavingsRecords(params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getEarnSavingsRedemptionResult(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getEarnSavingsSubscription.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getEarnSavingsSubscription(params)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getEarnSavingsSubscriptionResult(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getFundingAssets.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getFundingAssets(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getFuturesAccountAsset.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getFuturesAccountAsset(params)
Expand Down
1 change: 1 addition & 0 deletions examples/apidoc/RestClientV2/getFuturesAccountAssets.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { RestClientV2 } = require('bitget-api');
const client = new RestClientV2({
apiKey: 'insert_api_key_here',
apiSecret: 'insert_api_secret_here',
apiPass: 'insert_api_pass_here',
});

client.getFuturesAccountAssets(params)
Expand Down
Loading

0 comments on commit 96f2ebe

Please sign in to comment.