Api set sub account collateral preference request
ApiSetSubAccountCollateralPreferenceRequest
Enable or disable one or more currencies as collateral for a Multi-Asset Mode sub account.
USDT (the quote currency) cannot be disabled. Disabling collateral currencies reduces MarginBalance, and the batch is rejected when Initial Margin would no longer be covered.
NameLite |
Type | RequiredDefault |
Description |
|---|---|---|---|
sub_account_idsa |
string | True | The sub account ID to set collateral preferences for |
preferencesp |
[ApiCollateralPreferenceItem] | True | Per-currency preferences applied atomically. Duplicate currencies and empty lists are rejected. |
signatures |
Signature | True | The signature of this operation |
ApiCollateralPreferenceItem
A single (currency, enable) pair to toggle as collateral.
NameLite |
Type | RequiredDefault |
Description |
|---|---|---|---|
currencyc |
string | True | The currency whose collateral preference is being changed |
enablee |
boolean | True | True to include the currency as collateral, false to exclude it |
Signature
NameLite |
Type | RequiredDefault |
Description |
|---|---|---|---|
signers |
string | True | The address (public key) of the wallet signing the payload |
rr |
string | True | Signature R |
ss1 |
string | True | Signature S |
vv |
integer | True | Signature V |
expiratione |
string | True | Timestamp after which this signature expires, expressed in unix nanoseconds. Must be capped at 30 days |
noncen |
integer | True | Users can randomly generate this value, used as a signature deconflicting key. ie. You can send the same exact instruction twice with different nonces. When the same nonce is used, the same payload will generate the same signature. Our system will consider the payload a duplicate, and ignore it. Range: 0 to 4,294,967,295 (uint32) |
chain_idci |
string | True | Chain ID used in EIP-712 domain. Zero value fallbacks to GRVT Chain ID. |