Command Structure
All commands follow this structure:Global Flags
These flags are available for all commands:| Flag | Type | Description | Default |
|---|---|---|---|
--config | string | Path to config file | $HOME/.cctp/config.yaml |
--testnet | boolean | Use testnet instead of mainnet | false |
--keystore | string | Path to Ethereum keystore directory | OS-specific default |
Examples
transfer
Start a new cross-chain USDC transfer using the interactive TUI.Usage
Flags
| Flag | Type | Description | Example |
|---|---|---|---|
--source | string | Source chain name | ethereum, arbitrum |
--dest | string | Destination chain name | base, polygon |
--amount | string | Amount of USDC to transfer | 100, 1000.50 |
--recipient | string | Recipient address | 0x742d35Cc... |
--type | string | Transfer type: fast, standard, or auto | Default: auto |
All flags are optional. If not provided, the interactive TUI will prompt you for the required information.
Transfer Types
- auto (default)
- fast
- standard
Automatically selects the best transfer type:
- Uses Fast Transfer when available (non-instant finality source chains)
- Uses Standard Transfer for instant finality source chains
Examples
Chain Names
Mainnet Chains (16)
Mainnet Chains (16)
Use these exact names (case-sensitive) for the
--source and --dest flags:EthereumAvalanche(instant finality)OP MainnetArbitrumBasePolygon PoS(instant finality)UnichainLineaCodexSonic(instant finality)World ChainSei(instant finality)XDC(instant finality)HyperEVM(instant finality)InkPlume
Instant finality chains only support Standard Transfer when used as source, but complete in ~8 seconds.
Testnet Chains (17)
Testnet Chains (17)
Use these exact names for testnet transfers (requires
--testnet flag):Ethereum SepoliaAvalanche FujiOP SepoliaArbitrum SepoliaBase SepoliaPolygon PoS AmoyUnichain SepoliaLinea SepoliaCodex TestnetSonic TestnetWorld Chain SepoliaSei TestnetXDC ApothemHyperEVM TestnetInk TestnetPlume TestnetArc Testnet
Interactive Flow
When you runcctp transfer, the TUI guides you through these steps:
Wallet Selection
If using keystore, select an account from available keystore files and enter password.
Transfer Type
Choose Fast, Standard, or Auto transfer type. The CLI shows available options based on chain capabilities.
resume
Resume an existing transfer using the burn transaction hash.Usage
- A positional argument:
cctp resume 0x1234... - A flag:
cctp resume --tx-hash 0x1234... - Interactive prompt:
cctp resume(TUI will ask for tx hash)
Flags
| Flag | Type | Description |
|---|---|---|
--tx-hash | string | Burn transaction hash to resume |
Examples
When to Use Resume
Use theresume command when:
- Your terminal was closed during a transfer
- The CLI crashed or was interrupted
- You want to monitor the status of a previous transfer
- Network issues caused the transfer to pause
The resume command fetches the transfer state from the blockchain and Circle’s attestation service, so you can resume from any point in the transfer process.
Finding Your Transaction Hash
You can find the burn transaction hash:- From your wallet’s transaction history
- On a blockchain explorer (Etherscan, Arbiscan, etc.)
- From the CLI output during the initial transfer (look for “Burn transaction”)
version
Print the CLI version information.Usage
Example Output
Why Check Version?
- Verify successful installation
- Confirm you’re running the latest version
- Report version when filing bug reports
- Check compatibility with SDK versions
help
Display help information for any command.Usage
completion
Generate shell completion scripts for faster command-line usage.Usage
Shell-Specific Setup
- Bash
- Zsh
- Fish
- PowerShell
One-time setup (requires restart):Current session only:Permanent setup (add to
~/.bashrc):What Completion Provides
- Command name completion:
cctp tr<TAB>→cctp transfer - Flag completion:
cctp transfer --s<TAB>→cctp transfer --source - Subcommand help:
cctp <TAB>shows all available commands
Configuration Precedence
When you use multiple configuration sources, the CLI applies them in this order (highest to lowest priority):- Command-line flags (e.g.,
--testnet,--keystore) - Environment variables (e.g.,
CCTP_TESTNET=true) - Configuration file (
~/.cctp/config.yaml) - Default values
Example Precedence
Config file (~/.cctp/config.yaml):
testnet:true(env var overrides config)keystore_path:/custom/path(flag overrides env and config)
Exit Codes
The CLI uses standard exit codes:| Code | Meaning |
|---|---|
| 0 | Success |
| 1 | General error (configuration, validation, etc.) |
| 2 | User cancelled operation |
Next Steps
Configuration
Learn how to set up config files and customize defaults
Quick Start
Complete tutorial from installation to first transfer
SDK Reference
Integrate CCTP into your application
Troubleshooting
Common issues and solutions