Skip to main content

Batch Create Virtual Subaccount and Apikey

Frequency limit: 1 times/1s (User ID)

Description

Create the virtual sub-account and apikey in batch

HTTP request

  • POST /api/v2/user/batch-create-subaccount-and-apikey
Request Example
curl -X POST "https://api.bitget.com/api/v2/user/batch-create-subaccount-and-apikey" \
-H "ACCESS-KEY:*******" \
-H "ACCESS-SIGN:*" \
-H "ACCESS-PASSPHRASE:*" \
-H "ACCESS-TIMESTAMP:1659076670000" \
-H "locale:en-US" \
-H "Content-Type: application/json" \ -d \'[{"subAccountName":"armendon","passphrase":"1r1b6uX6PQ9tbKwa","permList":["spot_trade,contract_trade"],"label":"1681808312065"}]'

Request parameters

ParameterTypeRequiredDescription
subAccountNameStringYesVirtual sub-account alias8-character English letters
passphraseStringYesPasscode English letters of 832 characters + numbers
labelStringYesSub-account note Length 20
ipListListNoVirtual sub-account ApiKey ip whitelist, Max. 30
permListListNoSub-account apiKey permissions
contract-order Futures order
contract-position Contract position
spot-trade Spot trade
margin-trade Spot margin trading
copytrading-trade Copy trading
wallet-transfer Wallet transfer
wallet-withdraw Wallet withdraw
Wallet withdrawals are invalid when the read-only permission type is selected, and there is no read-only permission for withdrawing coins.
Response Example
{
"code": "00000",
"msg": "success",
"requestTime": 1682662465346,
"data": [
{
"subAccountUid": "4236327146",
"subAccountName": "armendon@virtual-bitget.com",
"label": "1681808312065",
"subAccountApiKey": "bg_d32ff9d9****c3d2bc5e23",
"secretKey": "af22848395e3d97e08dbd9a876a1XXXXXXXXXXXXXXX",
"permList": [
"contract_order",
"contract_position"
],
"ipList": [
"127.0.0.1"
]
}
]
}

Response Parameters

ParameterTypeDescription
subAccountUidStringVirtual sub-account Uid
subAccountNameStringVirtual sub-account alias8-character English letters
labelStringSub-account noteLength 20
subAccountApiKeyStringSub-account apikey
secretKeyStringSub-account secret key
permListListSub-account apiKey permissions
contract_order Futures order
contract_position Contract position
spot_trade Spot trade
margin_trade Spot margin trading
copytrading_trade Copy trading
wallet_transfer Wallet transfer
wallet_withdraw Wallet withdraw
Wallet withdrawals are invalid when the read-only permission type is selected, and there is no read-only permission for withdrawing coins.
ipListListip whitelist