刪除子帳戶
刪除子帳戶. 在刪除前, 確保該帳戶已經沒有資產了
僅可使用母帳戶api key調用.
提示
在調用接口時,使用的API key至少需要擁有以下其中一種權限
- 母API key: "Account Transfer(資產帳戶劃轉)", "Subaccount Transfer(母子帳戶劃轉)", "Withdrawal(提幣)"
HTTP 請求
POST /v5/user/del-submember
請求參數
參數 | 是否必須 | 類型 | 說明 |
---|---|---|---|
subMemberId | true | string | Sub UID |
返回參數
無
請求示例
- HTTP
- Python
- Node.js
POST /v5/user/del-submember HTTP/1.1
Host: api.bybit.com
X-BAPI-API-KEY: XXXXXX
X-BAPI-TIMESTAMP: 1698907012755
X-BAPI-RECV-WINDOW: 5000
X-BAPI-SIGN: XXXXXX
Content-Type: application/json
Content-Length: 34
{
"subMemberId": "112725187"
}
const { RestClientV5 } = require('bybit-api');
const client = new RestClientV5({
testnet: true,
key: 'apikey',
secret: 'apisecret',
});
client
.deleteSubMember({
subMemberId: 'subUID',
})
.then((response) => {
console.log(response);
})
.catch((error) => {
console.error(error);
});
響應示例
{
"retCode": 0,
"retMsg": "OK",
"result": {},
"retExtInfo": {},
"time": 1698907012962
}