带单员接口
跟单 OpenAPI 使用 /api/v2/copy-trading/leader 前缀。所有接口仅访问当前 API Key 对应带单员自己的数据或设置,返回结构沿用 OpenAPI V2:
{ "code": 200, "msg": "success", "data": {} }- 所有接口都需要签名,API Key 账户类型必须为
COPY_TRADING。 - 查询接口允许 read-only API Key;写接口不支持 read-only API Key。
- OpenAPI 公共签名参数请参考基础信息。
- 64 位整型字段在 JSON 中按现有 OpenAPI 序列化口径多以字符串返回。
当前带单
查询当前带单员的当前带单列表。
Request Weight
1
Request URL
GET /api/v2/copy-trading/leader/orders/current
Parameters
无业务参数。
Response
data 为数组,每个元素包含:
| 字段 | 类型 | 说明 |
|---|---|---|
| symbolId | string | 交易对 ID |
| symbolName | string | 交易对展示名 |
| isLong | integer | 方向,0 空,1 多 |
| positionType | integer | 仓位类型 |
| leverage | string | 杠杆 |
| openTime | string | 开仓时间,epoch millis |
| quantity | string | 数量 |
| newPrice | string | 当前价格 |
| openPrice | string | 开仓均价 |
| totalFollowerCount | string | 跟单人数 |
| totalFollowerMargin | string | 用户跟单总额 |
| profitRate | string | 收益率 |
| markPrice | string | 标记价格 |
Example
GET /api/v2/copy-trading/leader/orders/current{
"code": 200,
"msg": "success",
"data": [
{
"symbolId": "BTC-SWAP-USDT",
"symbolName": "BTCUSDT Perpetual",
"isLong": 1,
"positionType": 0,
"leverage": "20",
"openTime": "1717200000000",
"quantity": "0.000058242",
"newPrice": "52246.217",
"openPrice": "51110.77",
"totalFollowerCount": "12",
"totalFollowerMargin": "1000",
"profitRate": "0.0123",
"markPrice": "68100.2"
}
]
}Errors
| code | msg | 说明 |
|---|---|---|
| 200 | success | 成功 |
| -1130 | Data sent for paramter ... | 参数错误 |
| -120041 | Copy trading leader is not available. | 当前签名账户不是有效带单员 |
| -1000 | unknown | 未知异常 |
历史带单
查询当前带单员的历史带单列表。
Request Weight
1
Request URL
GET /api/v2/copy-trading/leader/orders/history
Parameters
| 名称 | 位置 | 类型 | 是否必须 | 默认值 | 说明 |
|---|---|---|---|---|---|
| page | query | LONG | NO | 1 | 页码,从 1 开始 |
| size | query | LONG | NO | 10 | 每页数量 |
Response
data 为分页对象:
| 字段 | 类型 | 说明 |
|---|---|---|
| pages | string | 总页数 |
| total | string | 总条数 |
| list | array | 历史带单列表 |
data.list[] 字段:
| 字段 | 类型 | 说明 |
|---|---|---|
| symbolId | string | 交易对 |
| isLong | number | 方向,0 空,1 多 |
| positionType | number | 仓位类型,0 全仓,1 逐仓 |
| leverage | string | 杠杆 |
| openPrice | string | 开仓价 |
| closePrice | string | 平仓价 |
| openTime | string | 开仓时间,epoch millis |
| closeTime | string | 平仓时间,epoch millis |
| profit | string | 已实现盈亏 |
| status | number | 1 部分平仓,2 完全平仓 |
| openQty | string | 最大持仓量 |
| closeQty | string | 已平仓数量 |
| positionProfit | string | 仓位盈亏 |
| openFee | string | 开仓手续费 |
| closeFee | string | 平仓手续费 |
Example
GET /api/v2/copy-trading/leader/orders/history?page=1&size=10{
"code": 200,
"msg": "success",
"data": {
"pages": "3",
"total": "21",
"list": [
{
"symbolId": "BTC-SWAP-USDT",
"isLong": 1,
"positionType": 0,
"leverage": "20",
"openPrice": "51110.77",
"closePrice": "52246.217",
"openTime": "1717200000000",
"closeTime": "1717203600000",
"profit": "12.34",
"status": 2,
"openQty": "0.1",
"closeQty": "0.1",
"positionProfit": "12.34",
"openFee": "0.1",
"closeFee": "0.1"
}
]
}
}Errors
| code | msg | 说明 |
|---|---|---|
| 200 | success | 成功 |
| -1130 | Data sent for paramter ... | page 或 size 不合法 |
| -120041 | Copy trading leader is not available. | 当前签名账户不是有效带单员 |
| -1000 | unknown | 未知异常 |
交易数据
查询当前带单员的交易数据。
Request Weight
1
Request URL
GET /api/v2/copy-trading/leader/trade-data
Parameters
| 名称 | 位置 | 类型 | 是否必须 | 默认值 | 说明 |
|---|---|---|---|---|---|
| type | query | INTEGER | NO | 7 | 固定周期,仅支持 7、30、90、180、365 |
Response
data 为数组,每个元素包含:
| 字段 | 类型 | 说明 |
|---|---|---|
| profitRate | string | 收益率 |
| accumulatedProfit | string | 累计收益 USDT |
| orderCount | integer | 交易笔数 |
| winRate | string | 胜率 |
| currentFollowerCount | string | 当前跟单人数 |
| followerTotalProfit | string | 跟单者总收益 |
| sharpeRatio | string | 夏普比率 |
| totalFollowerCount | string | 累计跟单人数 |
| assetManagementScale | string | 资产管理规模 |
| profitLossRatio | string | 盈亏比 |
| tradingFrequency | string | 交易频次 |
| tradingDays | integer | 交易天数 |
Example
GET /api/v2/copy-trading/leader/trade-data?type=30{
"code": 200,
"msg": "success",
"data": [
{
"profitRate": "0.1234",
"accumulatedProfit": "888.1234",
"orderCount": 18,
"winRate": "0.6111",
"currentFollowerCount": "21",
"followerTotalProfit": "100.1234",
"sharpeRatio": "1.2345",
"totalFollowerCount": "89",
"assetManagementScale": "12345.6789",
"profitLossRatio": "2.18:1",
"tradingFrequency": "0.6",
"tradingDays": 30
}
]
}Errors
| code | msg | 说明 |
|---|---|---|
| 200 | success | 成功 |
| -1130 | Data sent for paramter 'type' is not valid. | type 不合法 |
| -120041 | Copy trading leader is not available. | 当前签名账户不是有效带单员 |
| -1000 | unknown | 未知异常 |
分润历史
查询当前带单员的分润历史,保持最近 100 条口径。
Request Weight
1
Request URL
GET /api/v2/copy-trading/leader/profit-sharings/history
Parameters
无业务参数。
Response
data 为数组,每个元素包含:
| 字段 | 类型 | 说明 |
|---|---|---|
| totalProfitSharing | string | 周期内获得的总分润 |
| weekOfYear | integer | 第几周 |
| year | integer | 年份 |
| sharingDate | string | 分润日期 |
| recommendUserShare | string | 推荐用户分成金额 |
| realProfitShare | string | 带单员真实获得金额 |
Example
GET /api/v2/copy-trading/leader/profit-sharings/history{
"code": 200,
"msg": "success",
"data": [
{
"totalProfitSharing": "10.5",
"weekOfYear": 22,
"year": 2026,
"sharingDate": "2026-06-01",
"recommendUserShare": "1.5",
"realProfitShare": "9"
}
]
}Errors
| code | msg | 说明 |
|---|---|---|
| 200 | success | 成功 |
| -1130 | Data sent for paramter ... | 参数错误 |
| -120041 | Copy trading leader is not available. | 当前签名账户不是有效带单员 |
| -1000 | unknown | 未知异常 |
带单交易对
查询当前带单员可用于 OpenAPI 的带单交易对。
Request Weight
1
Request URL
GET /api/v2/copy-trading/leader/symbols
Parameters
无业务参数。
Response
data 为数组,每个元素包含:
| 字段 | 类型 | 说明 |
|---|---|---|
| symbolId | string | 带单交易对 ID |
| leverage | string | 带单杠杆 |
| isLead | integer | 是否带单,0 否,1 是 |
Example
GET /api/v2/copy-trading/leader/symbols{
"code": 200,
"msg": "success",
"data": [
{
"symbolId": "BTC-SWAP-USDT",
"leverage": "20",
"isLead": 1
}
]
}Errors
| code | msg | 说明 |
|---|---|---|
| 200 | success | 成功 |
| -1130 | Data sent for paramter ... | 参数错误 |
| -120041 | Copy trading leader is not available. | 当前签名账户不是有效带单员 |
| -1000 | unknown | 未知异常 |
修改带单设置
修改当前带单员的带单设置。交易对设置通过 symbolIds 与其他配置同一个接口提交。
Request Weight
1
Request URL
PUT /api/v2/copy-trading/leader/config
Parameters
Request body 使用 JSON。
| 字段 | 类型 | 是否必须 | 说明 |
|---|---|---|---|
| unLeadType | integer | YES | 0 无冷却时间,1 自定义冷却时间 |
| unLeadStartTime | LONG | NO | 冷却开始时间,epoch millis |
| unLeadEndTime | LONG | NO | 冷却结束时间,epoch millis |
| leadPositionType | integer | YES | 带单仓位类型:-1 全部,0 全仓,1 逐仓 |
| tradeProtect | integer | YES | 交易保护开关 |
| profitPeriod | integer | YES | 分润周期:1 按日,7 按周 |
| profitRate | DECIMAL | YES | 分润比例 |
| followAssetLowerLimit | DECIMAL | YES | 最低跟单资产 |
| fixedAmountFollowMin | DECIMAL | YES | 固定金额跟单最小值 |
| fixedRateFollowMin | DECIMAL | YES | 固定比例跟单最小值 |
| isNeedInvite | integer | YES | 是否私域 |
| inviteScope | integer | YES | 私域邀请范围 |
| symbolIds | ARRAY | YES | 本次完整提交的带单交易对列表 |
| recommendShare | integer | NO | 是否允许推荐分润;不传表示不修改 |
| recommendShareRate | DECIMAL | NO | 推荐分润比例,小数位最多 8 位 |
| inviteCode | string | NO | 私域邀请码,仅 isNeedInvite=1 时处理 |
规则说明
- 当
unLeadType=1时,unLeadEndTime必须传且不能为0,并且unLeadEndTime >= unLeadStartTime;当unLeadType=0时,服务端会将冷却开始和结束时间置为0。 profitPeriod只支持1和7。profitRate、followAssetLowerLimit、fixedAmountFollowMin、fixedRateFollowMin除字段范围和精度限制外,还必须满足当前带单员等级配置;profitRate上下限会受私域和自定义分润状态影响。- 当前为私域且配置过自定义分润比例的带单员,不允许切换为公域。
symbolIds是完整提交列表;未提交的当前可带单交易对会被视为需要禁用;仍有带单中订单的交易对不能取消。recommendShare不传表示不修改推荐分润开关;当recommendShare=1时,recommendShareRate必须> 0且<= 1。inviteCode仅在isNeedInvite=1时处理;非空时长度必须为 6 到 10 位、不能包含中文,并会校验敏感词和唯一性。- read-only API Key 调用该写接口会被拒绝。
Response
成功时 data 为 null。
Example
PUT /api/v2/copy-trading/leader/config{
"unLeadType": 1,
"unLeadStartTime": 1717200000000,
"unLeadEndTime": 1717286400000,
"leadPositionType": 0,
"tradeProtect": 1,
"profitPeriod": 7,
"profitRate": "0.1",
"followAssetLowerLimit": "100",
"fixedAmountFollowMin": "10",
"fixedRateFollowMin": "10",
"isNeedInvite": 1,
"inviteScope": 2,
"symbolIds": [
"BTC-SWAP-USDT",
"ETH-SWAP-USDT"
],
"recommendShare": 1,
"recommendShareRate": "0.2",
"inviteCode": "LEADER2026"
}成功响应:
{
"code": 200,
"msg": "success",
"data": null
}Errors
| code | msg | 说明 |
|---|---|---|
| 200 | success | 成功 |
| -1020 | This operation is not supported. | read-only API Key 调用写接口 |
| -1102 | Mandatory parameter ... | 必填字段缺失或格式错误 |
| -1130 | Data sent for paramter ... | 字段范围、精度或格式不合法 |
| -120041 | Copy trading leader is not available. | 当前签名账户不是有效带单员 |
| -120047 | Leader does not exist. | 带单员不存在 |
| -120067 | Copy trading level config not found. | 等级配置不存在 |
| -120072 | Copy trading leader config is invalid. | 带单设置业务参数不合法,例如等级限制、分润比例或推荐分润比例不满足要求 |
| -120073 | Unable to switch invite setting. | 当前私域且配置过自定义分润比例时,不允许切换为公域 |
| -120078 | unLeadStartTime or unLeadEndTime is invalid. | 冷却时间窗口不合法 |
| -32090 | Trading pair change is not allowed. | 要取消的交易对仍存在带单中订单 |
| -32093 | Copy trading position type cannot be changed. | 当前实际持仓不满足仓位模式切换条件 |
| -120510 | Invite code already exists. | 邀请码重复 |
| -120511 | Invite code contains sensitive content. | 邀请码包含敏感内容 |
| -120512 | Invite code is invalid. | 邀请码格式不合法 |
| -1000 | unknown | 未知异常 |
我的跟单用户
查询当前带单员的当前跟单用户列表。
Request Weight
1
Request URL
GET /api/v2/copy-trading/leader/followers
Parameters
| 名称 | 位置 | 类型 | 是否必须 | 默认值 | 说明 |
|---|---|---|---|---|---|
| page | query | LONG | NO | 1 | 页码,从 1 开始 |
| size | query | LONG | NO | 10 | 每页数量 |
Response
data 为分页对象:
| 字段 | 类型 | 说明 |
|---|---|---|
| pages | string | 总页数 |
| total | string | 总条数 |
| list | array | 跟单用户列表 |
data.list[] 字段:
| 字段 | 类型 | 说明 |
|---|---|---|
| followerNickname | string | 跟随者脱敏展示名 |
| followAmountLimit | string | 跟单投入总额,单位 USDT |
| totalFollowMargin | string | 累计跟单本金 |
| totalProfit | string | 累计跟单收益,单位 USDT |
| followRunningMills | string | 运行时长,毫秒 |
Example
GET /api/v2/copy-trading/leader/followers?page=1&size=10{
"code": 200,
"msg": "success",
"data": {
"pages": "1",
"total": "1",
"list": [
{
"followerNickname": "****644",
"followAmountLimit": "880",
"totalFollowMargin": "0",
"totalProfit": "0",
"followRunningMills": "61200000"
}
]
}
}Errors
| code | msg | 说明 |
|---|---|---|
| 200 | success | 成功 |
| -1130 | Data sent for paramter ... | page 或 size 不合法 |
| -120041 | Copy trading leader is not available. | 当前签名账户不是有效带单员 |
| -1000 | unknown | 未知异常 |
移除跟单用户
移除当前带单员自己的跟单用户。
Request Weight
1
Request URL
DELETE /api/v2/copy-trading/leader/followers/{followerUserId}
Parameters
| 名称 | 位置 | 类型 | 是否必须 | 说明 |
|---|---|---|---|---|
| followerUserId | path | LONG | YES | 要移除的跟随者用户 ID,必须大于等于 1 |
Response
成功时 data 为 null。
Example
DELETE /api/v2/copy-trading/leader/followers/123456789{
"code": 200,
"msg": "success",
"data": null
}Errors
| code | msg | 说明 |
|---|---|---|
| 200 | success | 成功 |
| -1020 | This operation is not supported. | read-only API Key 调用写接口 |
| -1130 | Data sent for paramter 'followerUserId' is not valid. | followerUserId 不合法 |
| -120047 | Leader does not exist. | 带单员不存在 |
| -32045 | Copy trading follower not found. | 跟随关系不存在 |
| -120055 | The follower currently has copy position, cannot be removed. | 跟随者当前有跟单仓位,不能移除 |
| -1000 | unknown | 未知异常 |