Bitget APIBitget API
统一账户经典账户
旧文档
  • 概览
  • API 文档
  • WebSocket
  • Agent Hub
  • SDK
  • 更新日志
Copied to clipboard
接口文档
经典账户
    跟单 · 现货跟单 · 跟单员
      查询当前跟单信息get跟随者终止跟随post查询历史跟单信息get设置止盈止损post卖出和批量卖出post跟随者查询跟随配置get我的交易员列表get跟随者新增或修改跟随配置post取消跟随post查看交易员当前带单币对get
经典账户 · 现货跟单 · 跟单员 API
经典账户 · 现货跟单 · 跟单员 API

跟单 · 现货跟单 · 跟单员

经典账户 — 跟单 · 现货跟单 · 跟单员


查询当前跟单信息

GET
https://api.bitget.com
/api/v2/copy/spot-follower/query-current-orders

限速规则: 5次/秒/UID

查询当前跟单信息 › Request Parameters

symbol
​string

交易对

traderId
​string

交易员id

idLessThan
​string

请求此ID之前

idGreaterThan
​string

请求此ID之后

startTime
​string

开始时间戳

Unix时间戳的毫秒数格式,如 1597026383085(时间跨度最大支持三个月,若不传结束时间,则默认结束时间为三个月。)

endTime
​string

结束时间戳

Unix时间戳的毫秒数格式,如 1597026383085(时间跨度最大支持三个月,若不传开始时间,则默认开始时间为三个月。)

limit
​string

默认20条,最大支持50条。超过将返回20条

查询当前跟单信息 › Response Parameters

200

Successful response

code
​string
msg
​string
requestTime
​integer
​object
​object[]

跟单集合

endId
​string

最后的数据id。id值为跟踪单号,用于根据id查询

GET/api/v2/copy/spot-follower/query-current-orders
curl https://api.bitget.com/api/v2/copy/spot-follower/query-current-orders
Example Responses
{ "code": "00000", "msg": "success", "requestTime": 1695809370190, "data": { "endId": "1", "trackingList": [ { "trackingNo": "1", "traderId": "**********", "buyFillSize": "0.0317", "buyDelegateSize": "0.0317190800000000", "buyPrice": "34870.7", "unrealizedPL": "-0.77945295", "buyTime": "1695729895491", "buyFee": "-0.00001908", "unrealizedPLR": "-0.07", "symbol": "BTCUSDT", "stopSurplusPrice": null, "stopLossPrice": null } ] } }
json
application/json

跟随者终止跟随

POST
https://api.bitget.com
/api/v2/copy/spot-follower/stop-order

限速规则: 1次/秒/UID

跟随者终止跟随 › Request Parameters

trackingNoList
​string[] · required

跟单号列表

最多50个

要么全部成功,要么全部失败

跟随者终止跟随 › Response Parameters

200

Successful response

code
​string
msg
​string
requestTime
​integer
data
​string

执行结果

success 成功

其它值 失败

POST/api/v2/copy/spot-follower/stop-order
curl https://api.bitget.com/api/v2/copy/spot-follower/stop-order \ --request POST \ --header 'Content-Type: application/json' \ --data '{ "trackingNoList": [ "string" ] }'
Example Request Body
{ "trackingNoList": [ "string" ] }
json
Example Responses
{ "code": "00000", "msg": "success", "requestTime": 1656066841304, "data": "" }
json
application/json

查询历史跟单信息

GET
https://api.bitget.com
/api/v2/copy/spot-follower/query-history-orders

限速规则: 5次/秒/UID

查询历史跟单信息 › Request Parameters

symbol
​string

交易对

traderId
​string

交易员id

idLessThan
​string

请求此ID之前

idGreaterThan
​string

请求此ID之后

startTime
​string

开始时间戳

Unix时间戳的毫秒数格式,如 1597026383085(时间跨度最大支持三个月,若不传结束时间,则默认结束时间为三个月。)

endTime
​string

结束时间戳

Unix时间戳的毫秒数格式,如 1597026383085(时间跨度最大支持三个月,若不传开始时间,则默认开始时间为三个月。)

limit
​string

默认20条,最大支持50条。超过将返回20条

查询历史跟单信息 › Response Parameters

200

Successful response

code
​string
msg
​string
requestTime
​integer
​object
​object[]

跟单集合

endId
​string

最后的数据id。id值为跟踪单号,用于根据id查询

GET/api/v2/copy/spot-follower/query-history-orders
curl https://api.bitget.com/api/v2/copy/spot-follower/query-history-orders
Example Responses
{ "code": "00000", "msg": "success", "requestTime": 1695811537460, "data": { "endId": "1", "trackingList": [ { "trackingNo": "1", "traderId": "**********", "fillSize": "0.0316", "buyPrice": "34870.7", "sellPrice": "34865.5", "buyFee": "-0.00001902", "sellFee": "-0.66104988", "achievedPL": "-0.82756", "achievedPLR": "-0.07", "symbol": "BTCUSDT", "buyTime": "1695729617968", "sellTime": "1695729886269" } ] } }
json
application/json

设置止盈止损

POST
https://api.bitget.com
/api/v2/copy/spot-follower/setting-tpsl

限速规则: 1次/秒/UID

设置止盈止损 › Request Parameters

trackingNo
​string · required

跟踪订单号

stopSurplusPrice
​string

止盈价(为空时,不管存不存在止盈都忽略或不更新,为0时,若存在止盈则表示取消原有止盈。大于0时,则表示更新或设置止盈。)

stopLossPrice
​string

止损价(为空时,不管存不存在止损都忽略或不更新,为0时,若存在止损则表示取消原有止损。大于0时,则表示更新或设置止损。)

设置止盈止损 › Response Parameters

200

Successful response

code
​string
msg
​string
requestTime
​integer
data
​string

执行结果

success 成功

其它值 失败

POST/api/v2/copy/spot-follower/setting-tpsl
curl https://api.bitget.com/api/v2/copy/spot-follower/setting-tpsl \ --request POST \ --header 'Content-Type: application/json' \ --data '{ "trackingNo": "trackingNo", "stopSurplusPrice": "stopSurplusPrice", "stopLossPrice": "stopLossPrice" }'
Example Request Body
{ "trackingNo": "trackingNo", "stopSurplusPrice": "stopSurplusPrice", "stopLossPrice": "stopLossPrice" }
json
Example Responses
{ "code": "00000", "msg": "success", "requestTime": 1656066841304, "data": "" }
json
application/json

卖出和批量卖出

POST
https://api.bitget.com
/api/v2/copy/spot-follower/order-close-tracking

限速规则: 1次/秒/UID

卖出和批量卖出 › Request Parameters

trackingNoList
​string[] · required

按买入币对分组trackingNo,全部成功或全部失败,跟踪订单号,最大50个

symbol
​string · required

交易对

卖出和批量卖出 › Response Parameters

200

Successful response

code
​string
msg
​string
requestTime
​integer
data
​string

执行结果

success 成功

其它值 失败

POST/api/v2/copy/spot-follower/order-close-tracking
curl https://api.bitget.com/api/v2/copy/spot-follower/order-close-tracking \ --request POST \ --header 'Content-Type: application/json' \ --data '{ "trackingNoList": [ "string" ], "symbol": "symbol" }'
Example Request Body
{ "trackingNoList": [ "string" ], "symbol": "symbol" }
json
Example Responses
{ "code": "00000", "msg": "success", "requestTime": 1656066841304, "data": "" }
json
application/json

跟随者查询跟随配置

GET
https://api.bitget.com
/api/v2/copy/spot-follower/query-settings

限速规则: 5次/秒/UID

跟随者查询跟随配置 › Request Parameters

traderId
​string · required

交易员id

跟随者查询跟随配置 › Response Parameters

200

Successful response

code
​string
msg
​string
requestTime
​integer
​object
enable
​string

我是否在跟随, YES NO

profitRate
​string

分润比例

settledInDays
​string

交易员入驻天数(从他在平台注册开始)

traderHeadPic
​string

交易员头像

traderName
​string

交易员昵称

​object[]

我的跟单设置

​object[]

币对跟单配置

endId
​string

最后的数据id。id值为跟踪单号,用于根据id查询

GET/api/v2/copy/spot-follower/query-settings
curl 'https://api.bitget.com/api/v2/copy/spot-follower/query-settings?traderId=<string>'
Example Responses
{ "code": "00000", "data": { "enable": "YES", "profitRate": "5", "settledInDays": "53", "tradeSettingList": [ { "maxTraceAmount": "50000", "stopLossRation": "10", "stopSurplusRation": "10", "symbol": "ETHUSDT", "traceType": "FIXED_AMOUNT" } ], "tradeSymbolSettingList": [ { "maxStopLossRation": "90", "maxStopSurplusRation": "500", "maxTraceAmount": "1200", "maxTraceAmountSystem": "50000", "maxTraceSize": "500", "maxTraceRation": "20", "minStopLossRation": "0", "minStopSurplusRation": "0", "minTraceAmount": "10", "minTraceSize": "0.001", "minTraceRation": "0.1", "sliderMaxStopLossRatio": "90", "sliderMaxStopSurplusRatio": "500", "symbol": "BTCUSDT" } ], "traderHeadPic": "", "traderName": "139****0981" }, "msg": "success", "requestTime": 1682401856339 }
json
application/json

我的交易员列表

GET
https://api.bitget.com
/api/v2/copy/spot-follower/query-traders

限速规则: 5次/秒/UID

我的交易员列表 › Request Parameters

pageNo
​string

pageNo (default 1)

pageSize
​string

默认为20条,最大支持50条。

startTime
​string

开始时间

endTime
​string

结束时间

我的交易员列表 › Response Parameters

200

Successful response

code
​string
msg
​string
requestTime
​integer
​object
​object[]

交易员列表

GET/api/v2/copy/spot-follower/query-traders
curl https://api.bitget.com/api/v2/copy/spot-follower/query-traders
Example Responses
{ "code": "00000", "msg": "success", "requestTime": 1695813674738, "data": { "resultList": [ { "certificationType": "Uncertified", "traceTotalAmount": "16027.6543", "traceTotalNetProfit": "43.2480", "traceTotalProfit": "52.8743", "traderName": "BGU***9Z72", "traderId": "**********", "maxFollowLimit": "300", "bgbMaxFollowLimit": "", "followCount": "1", "bgbFollowCount": "", "followerTime": "1693533344295" } ] } }
json
application/json

跟随者新增或修改跟随配置

POST
https://api.bitget.com
/api/v2/copy/spot-follower/settings

限速规则: 1次/秒/UID

跟随者新增或修改跟随配置 › Request Parameters

traderId
​string · required

交易员ID

​object[] · required

配置

autoCopy
​string

是否自动跟随交易员新开的新币对(只在普通模式生效)

on:自动跟随

off:不自动跟随

mode
​string

跟单模式

basic:普通模式

advanced(默认值):高级模式

跟随者新增或修改跟随配置 › Response Parameters

200

Successful response

code
​string
msg
​string
requestTime
​integer
data
​string

执行结果

success 成功

其它值 失败

POST/api/v2/copy/spot-follower/settings
curl https://api.bitget.com/api/v2/copy/spot-follower/settings \ --request POST \ --header 'Content-Type: application/json' \ --data '{ "traderId": "traderId", "autoCopy": "autoCopy", "mode": "mode", "settings": [ { "symbol": "symbol", "traceType": "traceType", "maxHoldSize": "maxHoldSize", "traceValue": "traceValue", "stopLossRatio": "stopLossRatio", "stopSurplusRatio": "stopSurplusRatio" } ] }'
Example Request Body
{ "traderId": "traderId", "autoCopy": "autoCopy", "mode": "mode", "settings": [ { "symbol": "symbol", "traceType": "traceType", "maxHoldSize": "maxHoldSize", "traceValue": "traceValue", "stopLossRatio": "stopLossRatio", "stopSurplusRatio": "stopSurplusRatio" } ] }
json
Example Responses
{ "code": "00000", "msg": "success", "requestTime": 1656066841304, "data": "" }
json
application/json

取消跟随

POST
https://api.bitget.com
/api/v2/copy/spot-follower/cancel-trader

限速规则: 1次/秒/UID

取消跟随 › Request Parameters

traderId
​string · required

交易员ID

取消跟随 › Response Parameters

200

Successful response

code
​string
msg
​string
requestTime
​integer
data
​string

执行结果

success 成功

其它值 失败

POST/api/v2/copy/spot-follower/cancel-trader
curl https://api.bitget.com/api/v2/copy/spot-follower/cancel-trader \ --request POST \ --header 'Content-Type: application/json' \ --data '{ "traderId": "traderId" }'
Example Request Body
{ "traderId": "traderId" }
json
Example Responses
{ "code": "00000", "msg": "success", "requestTime": 1656066841304, "data": "" }
json
application/json

查看交易员当前带单币对

GET
https://api.bitget.com
/api/v2/copy/spot-follower/query-trader-symbols

限速规则: 10次/1s (uid)

查看交易员当前带单币对 › Request Parameters

traderId
​string · required

交易员ID

查看交易员当前带单币对 › Response Parameters

200

Successful response

code
​string
msg
​string
requestTime
​integer
​object
currentTradingList
​string[]

当前带单币对

GET/api/v2/copy/spot-follower/query-trader-symbols
curl 'https://api.bitget.com/api/v2/copy/spot-follower/query-trader-symbols?traderId=<string>'
Example Responses
{ "code": "00000", "data": { "currentTradingList": [ "ETHUSDT", "BTCUSDT" ] }, "msg": "success", "requestTime": 1627354109502 }
json
application/json