post https://api.staging.rysk.finance/v1/withdraw
Withdraw USDB from rysk account.
Signature verification
The api expects a EIP712 signature constructed with the following typed data:
{
EIP712Domain: [
{
name: 'name', // rysk
type: 'string',
},
{
name: 'version', // "0.0.0"
type: 'string',
},
{
name: 'chainId', // 168587773 - BLAST testnet |
type: 'uint256',
},
{
name: 'verifyingContract', // <OrderDispatchAddress> - BLAST testnet |
type: 'address',
},
],
Withdraw: [
{
name: "account", // address of the account withdrawing
type: "address",
},
{
name: "subAccountId", // subAccountId of the subaccount to withdraw from
type: "uint8",
},
{
name: "asset", // address of the asset in the margin account to withdraw
type: "address",
},
{
name: "quantity", // quantity to withdraw in e18 format
type: "uint128",
},
{
name: "nonce", // unique nonce for the transaction, nonces are tracked globally across all actions and cannot be repeated
type: "uint64",
},
],
}
Example request:
{
"account": "0x1234", // Account address
"subAccountId": 0, // Subaccount id
"asset": "0x4300000000000000000000000000000000000003", // Address of the asset to withdraw (USDB)
"quantity": "10000000000000000", // Quantity of the order in e18 decimals
"nonce": 1718718131305466, // Unique nonce for the transaction, nonces are tracked globally across all actions and cannot be repeated
"signature": "0x1234..." // Signature for verifying the order
}
Example response:
{
"success":true,
"error": null
}