AutoDeleveraging
Last updated
Last updated
Name | Rule |
---|---|
type
1byte with the value 0x0b
accountId
4 bytes
subAccountId
1 byte
subAccountNonce
4 bytes
oraclePrices
31 bytes, encode the ContractPrice
and MarginPrice
in order, pass the bytes to Rust SDK rescue_hash
method
adlAccountId
4 bytes
pairId
1 byte
adlSize
5 bytes, refer to amount
pack method in BigUint pack algorithm
adlPrice
15 bytes, encode to big endian bytes, then pass to thepad_front
function in Rust SDK
fee
2 bytes, refer to fee
pack method in BigUint pack algorithm
feeToken
2 bytes
pariId
1 byte
marketPrice
15 bytes, encode in big endian, then pass to the pad_front
function in Rsut SDK
tokenId
2 byte, change to u16
, then encode in big endian
marketPrice
15 bytes, encode in big endian, then pass to thepad_front
function in Rust SDK