Skip to content

pimlico_prepareMagicSpendAllowance

This method prepares a Allowance message, which user will have to sign, in order to withdraw funds from the MagicSpend++ protocol.

Request

{
    "jsonrpc": "2.0",
    "method": "pimlico_prepareMagicSpendAllowance",
    "params": [
        {
            "account": "0x77d1f68C3C924cFD4732e64E93AEBEA836797485",
            "asset": "0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",
            "amount": "0x7b"
        }
    ],
    "id": 1
}

Response

{
    "jsonrpc": "2.0",
    "id": 1,
    "result": {
        "account": "0x77d1f68C3C924cFD4732e64E93AEBEA836797485",
        "allowances": [
            {
                "chainId": "0xaa36a7",
                "asset": "0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",
                "amount": "0x7b"
            }
        ],
        "validAfter": "0x672a7f52",
        "validUntil": "0x672e9010",
        "salt": "0x347ef",
        "operator": "0x77d1f68C3C924cFD4732e64E93AEBEA836797485"
    }
}