# Check an EVM execution ticket before the wallet signs

Read the wallet’s native and ERC-20 balances, verify token allowances and simulate the exact prepared ticket before submitting a transaction.

Guide: https://www.bitpont.com/help/ai-agents/preflight-evm-transactions/

## 1. Read the balances and the actual spender

Use walletTokenBalances with the selected network, the signing wallet and the exact ERC-20 contracts. Check the native balance for gas. Supply the same network and wallet to walletAllowances, with the spender from the reviewed route and its input token in tokens. An unavailable amount is null. Compare integer amounts in the same token’s base units. An approval for another contract cannot fund this transfer.

## 2. Simulate the saved ticket

Use the private workspace that prepared the execution. Replace the example executionId with that ticket’s UUID, then call executionPreflight. Read simulation and estimatedGas separately. The base-fee estimate excludes priority fees and any network-specific data charge. If the call reverts, inspect the result, refresh the balance, allowance and quote expiry, and correct the cause before signing.

## 3. Check the final outcome

After a successful preflight, have the authorized wallet review and sign the exact ticket. Balance, allowance, gas and liquidity can change between simulation and inclusion. Save the transaction ID, check executionStatus and, for supported swaps, read swapReceipt for the actual output and fee evidence.

## Simulate a saved EVM ticket using its execution ID

```
curl -fsS "https://www.bitpont.com/api/v1/agent/execution/preflight" \
  -H 'Content-Type: application/json' \
  -H "X-Bitpont-Workspace: ${BITPONT_WORKSPACE:?Set your original workspace}" \
  -d '{"executionId":"11111111-1111-4111-8111-111111111111"}'
```

## Tools

- `walletTokenBalances`
- `walletAllowances`
- `executionPreflight`
- `executionStatus`
- `swapReceipt`

## Further reading

- [Execution tickets and wallet signing](<https://www.bitpont.com/developers/agent-execution/>)
- [Look up a receipt in Portfolio](<https://www.bitpont.com/portfolio/activity/#portfolioSwapReceipt>)
- [Sign wallet actions and recover an agent order](<https://www.bitpont.com/help/ai-agents/wallet-signing-and-order-recovery/>)
- [Verify the tokens and fees from an agent swap](<https://www.bitpont.com/help/ai-agents/verified-swap-receipts/>)
- [Approve and revoke a customer trading session](<https://www.bitpont.com/help/ai-agents/customer-trading-sessions/>)
