post https://api.staging.rysk.finance/v1/approved-signers
Approve or revoke a Signer for a SubAccount
Signature generation
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',
type: 'uint256',
},
{
name: 'verifyingContract', // <OrderDispatchAddress> - BLAST testnet |
type: 'address',
},
],
ApproveSigner: [
{
name: "account", // address of the account to approve the approvedSigner on
type: "address",
},
{
name: "subAccountId", // subAccountId of the subaccount to approve the signer on
Type: "uint8",
},
{
name: "approvedSigner", // the address of the account that will be an approvedSigner on the given subaccount
type: "address",
},
{
name: "isApproved", // boolean for whether to approve the approvedSigner on the account or not
type: "bool",
},
{
name: "nonce", // unique nonce for the transaction, nonces are tracked globally across all actions and cannot be repeated
type: "uint64",
},
],
}
Example request:
{
"account": "0x1234", // Address of the account logging in
"subAccountId": 0, // Id of the subaccount to approve/revoke signer on
"approvedSigner": "0x1234", // Address of the account to approve/revoke signing
"nonce": 123412421, // Unique identifier for the transaction, nonces are tracked globally across all actions and cannot be repeated
"signature":"0x1234...", // Signature for verifying the order
"isApproved": true // Approve signer (true) or revoke signer (false)
}
Example response:
{
"success":true,
"error": null
}