Transactions
evm-withdraw
Claim TAO deposited to the coldkey's truncated EVM mirror.
Every native account controls one EVM address: the first 20 bytes of its
public key (the truncated mapping). TAO sent from MetaMask to that
address's mirror can be pulled into the native account with this call —
the EVM-to-substrate path that needs no EVM gas. The flow: send TAO from
the EVM wallet to the address shown by btcli evm deposit-address, then
claim it with btcli evm claim-deposit (or btcli tx evm-withdraw).
This is not btcli evm send-to-ss58, which spends from a stored EVM key
via the balance-transfer precompile. Fails if the mirror holds less than
the amount.
| Signer | Pallet | Wraps |
|---|---|---|
coldkey | EVM | EVM.withdraw |
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
amount_tao | number | "all" | yes | How much TAO to pull from the mirror. |
Address parameters (--hotkey, --coldkey, --dest, ...) accept a raw ss58
address, an address-book or proxy-book name, or a local wallet/hotkey name.
CLI
Preview with --dry-run (shows fee, effects, and policy result without
submitting), then submit:
btcli tx evm-withdraw \
--amount-tao <amount|all> --dry-run
btcli tx evm-withdraw \
--amount-tao <amount|all> -w my_coldkeyPython
import bittensor as sub
from bittensor.wallet import Wallet
wallet = Wallet(name="my_coldkey", hotkey="my_hotkey")
intent = sub.EvmWithdraw(amount_tao=1.0)
async with sub.Client("finney") as client:
plan = await client.plan(intent, wallet) # fee, effects, policy — no submission
result = await client.execute(intent, wallet)
if not result.success:
print(result.error.code, result.error.remediation)Or build it by op name, as an agent would:
await client.execute_tool("evm_withdraw", {...}, wallet)