Skip to main content
This guide will help you integrate the Eco Routes CLI to enable one-click stablecoin transfers across chains. In this quickstart, you will:
1

Install CLI

Install the Eco Routes CLI and configure your environment.
2

Configure private keys

Set up your private keys for the chains you want to use.
3

Request a quote and publishing the intent

Get quotes for the Eco Network to fulfill your intent and publish it onchain.
4

Track Fulfillment

Track the fulfillment of your intent on the destination chain.

Step 1: Installation

Install the SDK along with its peer dependencies:
git clone https://github.com/eco-protocol/routes-cli.git
cd routes-cli
pnpm install
pnpm build
pnpm link
Now you can use eco-routes-cli globally.

Step 2: Environment configuration

Copy the example environment file and add your private keys:
cp .env.example .env
Edit .env with your private keys:
# Private keys for each chain type
EVM_PRIVATE_KEY=0x...
TVM_PRIVATE_KEY=...
SVM_PRIVATE_KEY=...

# Optional: Custom RPC endpoints
EVM_RPC_URL=https://eth-mainnet.g.alchemy.com/v2/...
TVM_RPC_URL=https://api.trongrid.io
SVM_RPC_URL=https://api.mainnet-beta.solana.com

# Optional: Portal contract addresses
PORTAL_ADDRESS_ETH=0x...
PORTAL_ADDRESS_OPTIMISM=0x...
PORTAL_ADDRESS_TRON=T...
PORTAL_ADDRESS_SOLANA=...
Never commit .env files. Always add to .gitignore and use environment variables. Don’t hardcode private keys.

Step 3: Requesting a quote and publishing an intent

To send USDC from Optimism to Base, use the publish command with chain options
pnpm dev publish --source optimism --destination base
The CLI will launch an interactive wizard that guides you through:
1

Chain selection

Source chain: optimism (where rewards come from)Destination chain: base (where route executes)Automatic quote fetching for optimal routing
2

Token selection

Route Token: Choose destination chain token (native or ERC20/TRC20/SPL)Route Amount: Specify amount to transfer on destinationReward Token: Choose source chain token for prover rewardReward Amount: Specify reward amount for proof submission
3

Automatic Configuration

  • Creator address derived from your wallet
  • Prover address from chain configuration
  • Portal address from destination chain
  • Smart deadline calculation:
    • Route deadline: 2 hours from now
    • Reward deadline: 3 hours from now
4

Review & Confirm

  • Display complete intent details
  • Show estimated gas costs
  • Confirm before blockchain submission
After confirming, your intent will be published to the Optimism chain.

Step 4: Tracking the Intent fulfillment.

Currently, the routes-cli focuses on intent creation and publishing. For tracking fulfillment, you can monitor the destination chain using the intent hash returned after publishing. The intent hash is generated after successful publication and can be used to track the Fulfillment event on the Inbox contract on the destination chain (Base). Congrats! You just finished your first stablesend using Eco.