Skip to main content

What does transfer do?

The transfer command validates an ERC20 token transfer against the policy engine. It sets action to transfer automatically, so you only provide the recipient, amount, token, and reason. This is a convenience wrapper around validate for the most common operation.

Options

Raw mode flags (only with --raw)

Preflight mode (default)

In preflight mode, the command sends an action-based validation request. No gas parameters needed.

Output

If the policy blocks the transfer, the output includes error and blockReason:
If approval is required, the output includes the intentId and a next field pointing to mandate approve.

Raw mode (legacy)

Deprecated. Use preflight mode instead. Raw mode is kept for legacy self-custodial flows.
Raw mode encodes the ERC20 transfer(address,uint256) calldata, computes the intentHash, and sends a raw validation request. On success, it returns the unsigned transaction for manual signing.

Raw mode output

Sign the unsignedTx with your private key, broadcast it, then post the txHash with mandate event.

Next Steps

Post Transaction Hash

Report the txHash after signing and broadcasting.

Check Intent Status

Poll the intent state until confirmed.

MandateWallet SDK

Automate the full flow programmatically with the TypeScript SDK.