| name | tokamak-cli |
| description | Interact with Tokamak Network (TON/WTON tokens, staking, unstaking, withdrawals) using the tokamak-cli tool. Use this skill whenever the user asks about TON or WTON token balances, transfers, approvals, wrapping/unwrapping, staking to Layer2 operators, unstaking, or withdrawing staked tokens. Also use when the user mentions Tokamak Network, TON staking, WTON, Layer2 operators like tokamak1/DSRV/Talken, or wants to check staking status. Even if the user just says 'check my TON balance' or 'stake some tokens', this skill applies. |
tokamak-cli — Tokamak Network CLI
A CLI tool for interacting with Tokamak Network's TON and WTON smart contracts on Ethereum.
Quick Start
All amounts are in human-readable TON units (e.g. 100 means 100 TON). The CLI handles internal unit conversion (WAD 1e18 / RAY 1e27) automatically.
Default network is mainnet. Add -n sepolia for testnet.
Read commands (no private key needed)
tokamak-cli ton balance <address>
tokamak-cli wton balance <address>
tokamak-cli stake balance <layer2> <address>
Write commands (require -k <private-key> or PRIVATE_KEY env)
tokamak-cli ton transfer <to> <amount> -k <key>
tokamak-cli stake deposit <layer2> <amount> -k <key>
Command Reference
When the user's request matches a specific operation, run the appropriate command. For details on each command group, read the reference files below.
Level 1 — Token Operations (most common)
| Task | Command |
|---|
| TON balance | tokamak-cli ton balance <address> |
| WTON balance | tokamak-cli wton balance <address> |
| TON total supply | tokamak-cli ton total-supply |
| WTON total supply | tokamak-cli wton total-supply |
| TON allowance | tokamak-cli ton allowance <owner> <spender> |
| WTON allowance | tokamak-cli wton allowance <owner> <spender> |
Level 2 — Token Transfers & Approvals
| Task | Command |
|---|
| Transfer TON | tokamak-cli ton transfer <to> <amount> -k <key> |
| Transfer WTON | tokamak-cli wton transfer <to> <amount> -k <key> |
| Approve TON | tokamak-cli ton approve <spender> <amount> -k <key> |
| Approve WTON | tokamak-cli wton approve <spender> <amount> -k <key> |
| Wrap TON → WTON | tokamak-cli wton wrap <amount> -k <key> |
| Wrap + transfer | tokamak-cli wton wrap-to <to> <amount> -k <key> |
| Unwrap WTON → TON | tokamak-cli wton unwrap <amount> -k <key> |
| Unwrap + transfer | tokamak-cli wton unwrap-to <to> <amount> -k <key> |
Level 3 — Staking Lifecycle
For the full staking flow, read references/staking.md.
| Task | Command |
|---|
| Check staked balance | tokamak-cli stake balance <layer2> <address> |
| Stake TON | tokamak-cli stake deposit <layer2> <amount> -k <key> |
| Stake WTON | tokamak-cli stake deposit-wton <layer2> <amount> -k <key> |
| Request unstake | tokamak-cli unstake request <layer2> <amount> -k <key> |
| Check pending | tokamak-cli unstake pending <layer2> <address> |
| Withdraw as TON | tokamak-cli withdraw process <layer2> -k <key> |
| Withdraw as WTON | tokamak-cli withdraw process-wton <layer2> -k <key> |
Global Options
These options can be placed before or after the command group:
| Option | Description |
|---|
-n, --network <name> | mainnet (default) or sepolia |
-k, --private-key <key> | Private key for write operations. Also reads PRIVATE_KEY env. |
--json | Output structured JSON instead of human-readable text |
Layer2 Operators
The <layer2> argument accepts either an operator name or a hex address (0x...).
Mainnet: tokamak1, DXM_Corp, DSRV, Talken, staked, level, decipher, DeSpread, Danal_Fintech, Hammer
Sepolia: TokamakOperator_v2, poseidon
For the full address mapping, read references/addresses.md.
Guidelines
- Always prefer
--json when you need to parse or process the output programmatically.
- For staking:
stake deposit (TON via approveAndCall) is the simplest path. Use stake deposit-wton only when the user already holds WTON.
- The staking lifecycle has a mandatory delay between unstake request and withdrawal. Use
unstake pending to check if a request is ready before calling withdraw process.
- If a user asks something like "how do I stake?" without specifying an operator, list the available operators and ask which one they want.