跳到主要内容

修改子账户API key权限

限速规则 10次/1s (UID)

描述

独立经纪商母账户修改子账户API key权限,仅限主账户请求

HTTP请求

  • POST /api/v2/broker/manage/modify-subaccount-apikey
请求示例
curl -X POST "https://api.bitget.com/api/v2/broker/manage/modify-subaccount-apikey" \
-H "ACCESS-KEY:your apiKey" \
-H "ACCESS-SIGN:*" \
-H "ACCESS-PASSPHRASE:*" \
-H "ACCESS-TIMESTAMP:1659076670000" \
-H "locale:zh-CN" \
-H "Content-Type: application/json" \
-d '{"subUid": "**********","passphrase": "12345678","apiKey": "bg_****01xxxxxx19b****4a4","label": "old remark","ipList":["127.0.0.1"],"permType": "readonly","permList":["spot_trade"]}'

请求参数

参数名参数类型是否必须描述
subUidString子账户uid
apikeyString子账户apikey
labelString备注
passphraseString创建API key时的传入的口令,如果忘记passphrase请重新创建API key
ipListList<String>IP数组,新传入IP组会覆盖旧的IP组,最多传入30个;不传则视为不变
permTypeString新增权限组会覆盖旧权限组,不传则视为不变
权限类型:
read_and_write: 读写权限
readonly: 只读权限
permListList<String>新增权限组会覆盖旧权限组,不传则视为不变
权限枚举:
contract_order: 合约订单
contract_position: 合约持仓
spot_trade: 现货交易
margin_trade: 现货杠杆交易
copytrading_trade: 跟单交易
wallet_transfer: 钱包划转
返回示例
{
"code": "00000",
"msg": "success",
"requestTime": 1695785738672,
"data": {
"subUid": "*************",
"apiKey": "bg_*****************",
"label": "old remark",
"ipList":["127.0.0.1"],
"permType": "readonly",
"permList":["spot_trade"]
}
}

返回参数

返回字段参数类型字段说明
subUidString子账户uid
labelStringapikey备注
apikeyStringapikey
permTypeString权限类型:
read_and_write 读写权限
readonly 只读权限
permListList<String>权限枚举:
contract_order: 合约订单
contract_position: 合约持仓
spot_trade: 现货交易
margin_trade: 现货杠杆交易
copytrading_trade: 跟单交易
wallet_transfer: 钱包划转
ipListList<String>IP数组