curl --request GET \
--url https://test.deribit.com/api/v2/private/get_subaccounts \
--header 'Content-Type: application/json' \
--data '
{
"jsonrpc": "2.0",
"id": 4947,
"method": "private/get_subaccounts",
"params": {
"with_portfolio": true
}
}
'{
"jsonrpc": "2.0",
"id": 4947,
"result": [
{
"email": "user_AAA@email.com",
"id": 2,
"is_password": true,
"margin_model": "segregated_sm",
"login_enabled": true,
"portfolio": {
"eth": {
"additional_reserve": 0,
"spot_reserve": 0,
"available_funds": 5,
"available_withdrawal_funds": 5,
"balance": 5,
"currency": "eth",
"equity": 5,
"initial_margin": 0,
"maintenance_margin": 0,
"margin_balance": 5
},
"btc": {
"additional_reserve": 0,
"spot_reserve": 0,
"available_funds": 5.000413075,
"available_withdrawal_funds": 5.000413075,
"balance": 5.000593987,
"currency": "btc",
"equity": 5.000571846,
"initial_margin": 0.000158771,
"maintenance_margin": 0.000115715,
"margin_balance": 5.000571846
}
},
"receive_notifications": false,
"system_name": "user_1",
"security_keys_enabled": false,
"security_keys_assignments": [],
"type": "main",
"username": "user_1"
},
{
"email": "user_AAA@gmail.com",
"id": 7,
"is_password": true,
"margin_model": "cross_pm",
"login_enabled": false,
"portfolio": {
"eth": {
"additional_reserve": 0,
"spot_reserve": 0,
"available_funds": 0,
"available_withdrawal_funds": 0,
"balance": 0,
"currency": "eth",
"equity": 0,
"initial_margin": 0,
"maintenance_margin": 0,
"margin_balance": 0
},
"btc": {
"additional_reserve": 0,
"spot_reserve": 0,
"available_funds": 0,
"available_withdrawal_funds": 0,
"balance": 0,
"currency": "btc",
"equity": 0,
"initial_margin": 0,
"maintenance_margin": 0,
"margin_balance": 0
}
},
"receive_notifications": false,
"system_name": "user_1_1",
"security_keys_enabled": false,
"security_keys_assignments": [],
"type": "subaccount",
"username": "user_1_1"
}
]
}Retrieves information about all subaccounts associated with the main account. Returns details such as subaccount IDs, names, and status.
When called from a subaccount, the response includes limited details for the main account and full details for the subaccount initiating the request.
Set the with_portfolio parameter to true to include portfolio information (balances, positions, etc.) in the response. By default, only subaccount metadata is returned.
๐ Related Article: Managing Subaccounts
Scope: account:read
curl --request GET \
--url https://test.deribit.com/api/v2/private/get_subaccounts \
--header 'Content-Type: application/json' \
--data '
{
"jsonrpc": "2.0",
"id": 4947,
"method": "private/get_subaccounts",
"params": {
"with_portfolio": true
}
}
'{
"jsonrpc": "2.0",
"id": 4947,
"result": [
{
"email": "user_AAA@email.com",
"id": 2,
"is_password": true,
"margin_model": "segregated_sm",
"login_enabled": true,
"portfolio": {
"eth": {
"additional_reserve": 0,
"spot_reserve": 0,
"available_funds": 5,
"available_withdrawal_funds": 5,
"balance": 5,
"currency": "eth",
"equity": 5,
"initial_margin": 0,
"maintenance_margin": 0,
"margin_balance": 5
},
"btc": {
"additional_reserve": 0,
"spot_reserve": 0,
"available_funds": 5.000413075,
"available_withdrawal_funds": 5.000413075,
"balance": 5.000593987,
"currency": "btc",
"equity": 5.000571846,
"initial_margin": 0.000158771,
"maintenance_margin": 0.000115715,
"margin_balance": 5.000571846
}
},
"receive_notifications": false,
"system_name": "user_1",
"security_keys_enabled": false,
"security_keys_assignments": [],
"type": "main",
"username": "user_1"
},
{
"email": "user_AAA@gmail.com",
"id": 7,
"is_password": true,
"margin_model": "cross_pm",
"login_enabled": false,
"portfolio": {
"eth": {
"additional_reserve": 0,
"spot_reserve": 0,
"available_funds": 0,
"available_withdrawal_funds": 0,
"balance": 0,
"currency": "eth",
"equity": 0,
"initial_margin": 0,
"maintenance_margin": 0,
"margin_balance": 0
},
"btc": {
"additional_reserve": 0,
"spot_reserve": 0,
"available_funds": 0,
"available_withdrawal_funds": 0,
"balance": 0,
"currency": "btc",
"equity": 0,
"initial_margin": 0,
"maintenance_margin": 0,
"margin_balance": 0
}
},
"receive_notifications": false,
"system_name": "user_1_1",
"security_keys_enabled": false,
"security_keys_assignments": [],
"type": "subaccount",
"username": "user_1_1"
}
]
}Portfolio flag: true for portfolio information, false for subaccount information only. false by default
true
Success response
The JSON-RPC version (2.0)
2.0 Hide child attributes
main, subaccount Account/Subaccount identifier
User email
System generated user nickname
When true - receive all notification emails on the main email
true when password for the subaccount has been configured
New email address that has not yet been confirmed. This field is only included if with_portfolio == true.
Whether the Security Keys authentication is enabled
Names of assignments with Security Keys assigned
Margin model
Hashed identifier used in the Proof Of Liability for the subaccount. This identifier allows you to find your entries in the Deribit Proof-Of-Reserves files. IMPORTANT: Keep it secret to not disclose your entries in the Proof-Of-Reserves.
Signature used as a base string for proof_id hash. IMPORTANT: Keep it secret to not disclose your entries in the Proof-Of-Reserves.
Informs whether login to the subaccount is enabled
Only if with_portfolio == true
Hide child attributes
Hide child attributes
The account's margin balance. When cross collateral is enabled, this aggregated value is calculated by converting the sum of each cross collateral currency's value to the given currency, using each cross collateral currency's index.
The selected currency
btc, eth The maintenance margin. When cross collateral is enabled, this aggregated value is calculated by converting the sum of each cross collateral currency's value to the given currency, using each cross collateral currency's index.
The account's initial margin. When cross collateral is enabled, this aggregated value is calculated by converting the sum of each cross collateral currency's value to the given currency, using each cross collateral currency's index.
The account's current equity
The account's balance
The account's available to withdrawal funds
The account's available funds. When cross collateral is enabled, this aggregated value is calculated by converting the sum of each cross collateral currency's value to the given currency, using each cross collateral currency's index.
The account's balance reserved in other orders
0.3
The account's balance reserved in active spot orders
The id that was sent in the request
Was this page helpful?