Skip to main content

npm (Global Install)

Install the CLI globally to use the lifi command anywhere:
npm install -g @lifi/cli
Verify the installation:
lifi health

npx (No Install)

Run any CLI command without installing:
npx @lifi/cli chains
npx @lifi/cli quote --from 1 --to 8453 --from-token USDC --to-token USDC --amount 1000000000

Configuration

All configuration is via environment variables. No config files needed.

API Key

Set your LI.FI API key for higher rate limits:
export LIFI_API_KEY=your_key_here
ConfigurationRate Limit
No API key (public)200 requests / 2 hours
With API key200 requests / minute

Verify Your Key

lifi auth show    # Display masked key
lifi auth test    # Validate key against the API

Testing Your Setup

Run the health check to verify API connectivity:
lifi health
List supported chains to confirm everything works:
lifi chains
If both commands return data successfully, your CLI is ready to use.

GitHub Repository

Source code and development instructions