This section is under construction. Some functions may not work correctly.
Get Trader Open Order
Function name:
getTraderOpenOrderCopyTrade(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function getTraderOpenOrderCopyTrade(exchange, options) {
try {
let result = await exchange.getTraderOpenOrderCopyTrade(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await getTraderOpenOrderCopyTrade(myBitgetAccount,
{
symbol: "BTCUSDT_UMCBL",
productType: "umcbl",
pageSize: "20",
pageNo: "1"
});
Get Follower Open Orders
Function name:
getFollowersOpenOrderCopyTrade(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function getFollowersOpenOrderCopyTrade(exchange, options) {
try {
let result = await exchange.getFollowersOpenOrderCopyTrade(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await getFollowersOpenOrderCopyTrade(myBitgetAccount,
{
symbol: "BTCUSDT_UMCBL",
productType: "umcbl",
pageSize: "20",
pageNo: "1"
});
Get Follower History Orders
Function name:
getFollowerHistoryOrdersCopyTrade(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function getFollowerHistoryOrdersCopyTrade(exchange, options) {
try {
let result = await exchange.getFollowerHistoryOrdersCopyTrade(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await getFollowerHistoryOrdersCopyTrade(myBitgetAccount,
{
startTime: "1668073994000",
endTime: "1668073994206",
pageSize: "20",
pageNo: "1"
});
Trader Close Position
Function name:
traderClosePositionCopyTrade(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function traderClosePositionCopyTrade(exchange, options) {
try {
let result = await exchange.traderClosePositionCopyTrade(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await traderClosePositionCopyTrade(myBitgetAccount,
{
symbol: "BTCUSDT_UMCBL",
trackingNo: "6258224712558517"
});
Trader Modify TPSL
Function name:
traderModifyTsplCopyTrade(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function traderModifyTsplCopyTrade(exchange, options) {
try {
let result = await exchange.traderModifyTsplCopyTrade(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await traderModifyTsplCopyTrade(myBitgetAccount,
{
symbol: "BTCUSDT_UMCBL",
trackingNo: "6258224712558517",
stopProfitPrice:"24123.5",
stopLossPrice:"21487.5"
});
Get Traders History Orders
Function name:
getTradersHistoryOrdersCopyTrade(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function getTradersHistoryOrdersCopyTrade(exchange, options) {
try {
let result = await exchange.getTradersHistoryOrdersCopyTrade(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await getTradersHistoryOrdersCopyTrade(myBitgetAccount,
{
startTime: "1668073994000",
endTime: "1668073994206",
pageSize: "20",
pageNo: "1"
});
Get Trader Profit Summary
Function name:
getTraderProfitSummaryCopyTrade(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function getTraderProfitSummaryCopyTrade(exchange, options) {
try {
let result = await exchange.getTraderProfitSummaryCopyTrade(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await getTraderProfitSummaryCopyTrade(myBitgetAccount);
Get Trader History Profit Summary (currency)
Function name:
getTraderHistoryProfitSummaryCurrencyCopyTrade(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function getTraderHistoryProfitSummaryCurrencyCopyTrade(exchange, options) {
try {
let result = await exchange.getTraderHistoryProfitSummaryCurrencyCopyTrade(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await getTraderHistoryProfitSummaryCurrencyCopyTrade(myBitgetAccount);
Get Trader History Profit Summary (currency/date)
Function name:
getTraderHistoryProfitSummaryByCurrencyAndDateCopyTrade(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function getTraderHistoryProfitSummaryByCurrencyAndDateCopyTrade(exchange, options) {
try {
let result = await exchange.getTraderHistoryProfitSummaryByCurrencyAndDateCopyTrade(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await getTraderHistoryProfitSummaryByCurrencyAndDateCopyTrade(myBitgetAccount);
Get Trader History Profit Detail
Function name:
getTraderHistoryProfitDetailCopyTrade(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function getTraderHistoryProfitDetailCopyTrade(exchange, options) {
try {
let result = await exchange.getTraderHistoryProfitDetailCopyTrade(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await getTraderHistoryProfitDetailCopyTrade(myBitgetAccount,
{
marginCoin: "USDT",
date: "1627354109502",
pageSize: "20",
pageNo: "1"
});
Get Trader Profits Details
Function name:
getTraderProfitDetailsCopyTrade(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function getTraderProfitDetailsCopyTrade(exchange, options) {
try {
let result = await exchange.getTraderProfitDetailsCopyTrade(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await getTraderProfitDetailsCopyTrade(myBitgetAccount,
{
pageSize: "20",
pageNo: "1"
});
Get CopyTrade Symbols
Function name:
getCopyTradeSymbols(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function getCopyTradeSymbols(exchange, options) {
try {
let result = await exchange.getCopyTradeSymbols(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await getCopyTradeSymbols(myBitgetAccount);
Trader Change CopyTrade Symbol
Function name:
traderChangeCopyTradeSymbol(options)
Usage:
import { createExchange } from "./exchanges/exchange.js";
let myBitgetAccount = createExchange({
exchange: "bitget",
authenticate: "true",
key: "myKeys",
secret: "mySecret",
passphrase: "myPassphrase",
label: "bitget",
marginType: "usdt"
});
async function traderChangeCopyTradeSymbol(exchange, options) {
try {
let result = await exchange.traderChangeCopyTradeSymbol(options);
console.log(result);
} catch (error) {
console.log(error.message);
}
}
const result = await traderChangeCopyTradeSymbol(myBitgetAccount);