LI.FI Documentation
LI.FI WebsiteAPI ReferenceHelp / FAQ / Create support ticketRequest API Key
  • 🏡Getting Started
    • ❓What is LI.FI
    • 🌟Why LI.FI?
    • 🆚LI.FI vs Aggregators/DEXs/Bridges
    • 📖LI.FI Terminology
    • ❓FAQ
    • 💡Use Cases
      • Mobile/Gaming Wallets
    • 🏹LI.FI vs. Other Aggregators
    • 🤝Partnership
    • 🌐Powered by LI.FI
  • 🔐Security First
  • ✅List: Chains, Bridges, DEX Aggregators, Solvers
  • 💲Monetization / Take Fees
  • 🔎Transaction Explorer
  • 🔏Rate Limits & API Key
  • How to get integrated by LI.FI?
    • For Bridges
    • For DEXs/Aggregators/Solvers
  • 🆘Technical FAQ
  • LI.FI PRODUCTS
    • Glacis
    • LI.FI Solver
    • LI.FI Intents System
  • LI.FI API
    • ⚙️LI.FI API
      • Transferring Tokens (Example)
      • Requesting supported Chains
      • Requesting all supported Tools
      • Requesting all known Tokens
      • Getting Token Information
      • Getting all possible Connections
      • Requesting a Quote
        • Token Transfer
        • Optimizing quote response timing
        • Cross-Chain Contract Calls
        • Possible Tool Errors
        • Testing your integration
      • Status of a Transaction
      • Requesting Analytics Data
    • ⚔️TX-Batching aka "Zaps"
    • 🏄Solana
      • Request examples
    • 🪙Bitcoin
      • Request examples
    • ⛽LI.Fuel
  • Integrate LI.FI SDK
    • 🚀LI.FI SDK Overview
    • 📦Install LI.FI SDK
    • ⚙️Configure SDK
    • 🪐Configure SDK Providers
    • 📜Request Routes/Quotes
    • 🎯Execute Routes/Quotes
    • ⛓️Chains and Tools
    • 💰Token Management
    • 🕵️Testing Integration
    • 🚗Migrate from v2 to v3
  • INTEGRATE LI.FI WIDGET
    • 🧩LI.FI Widget Overview
    • 📦Install Widget
    • 🎮Select Widget Variants
    • ⚙️Configure Widget
    • 🎨Customize Widget
    • ⚡Widget Events
    • 👛Wallet Management
    • 🌍Internationalization
    • ⚛️Compatibility with Next.js, Remix, Nuxt, etc.
    • 🛣️React Router Compatibility
    • 📖Widget API Reference
    • 🚗Migrate from v2 to v3
  • Smart Contracts
    • Overview
    • Deployments/Contract Addresses
    • Audits
  • Support & Misc.
    • API Status
    • Technical Help Desk & FAQ
    • Create a Partner Ticket
    • Discord Support
    • Telegram Support
    • Twitter
    • Github
    • Licenses
Powered by GitBook
LogoLogo

Connect with us

  • Github
  • Twitter
  • Discord
  • LinkedIn

More Information

  • Help Desk / FAQ
  • API Reference
  • Website
On this page

Was this helpful?

Export as PDF
  1. LI.FI API
  2. LI.FI API

Requesting all known Tokens

Request all tokens known by the LI.FI services

Last updated 8 months ago

Was this helpful?

The complete API documentation for our /tokens endpoint can be found .

This endpoint gives a comprehensive list of all tokens that the LI.FI services are aware.

It is possible to filter them by chain to get a more concise and targeted result.

const getTokens = async () => {
    const optionalFilter = ['ETH', 137] // Both numeric and mnemonic can be used
    /// chainTypes can be of type SVM and EVM. By default, only EVM tokens will be returned
    const optionalChainTypes = "EVM"
    const result = await axios.get('https://li.quest/v1/tokens',
        {params: {
            chains: optionalFilter.join(','),
            chainTypes: optionalChainType 
        }});
    return result.data;
}

The response is an object with a tokens property. In turn this is an object with keys being ChainId and values being Token objects. The sample response for the sample request above is:

{
    "tokens": {
        "100": [
            {
                "address": "0x6a023ccd1ff6f2045c3309768ead9e68f978f6e1",
                "decimals": 18,
                "symbol": "ETH",
                "chainId": 100,
                "coinKey": "ETH",
                "name": "ETH",
                "logoURI": "https://static.debank.com/image/xdai_token/logo_url/0x6a023ccd1ff6f2045c3309768ead9e68f978f6e1/61844453e63cf81301f845d7864236f6.png",
                "priceUSD": "1740.38"
            }
        ],
        "137": [
            {
                "address": "0x7ceb23fd6bc0add59e62ac25578270cff1b9f619",
                "decimals": 18,
                "symbol": "ETH",
                "chainId": 137,
                "coinKey": "ETH",
                "name": "ETH",
                "logoURI": "https://static.debank.com/image/matic_token/logo_url/0x7ceb23fd6bc0add59e62ac25578270cff1b9f619/61844453e63cf81301f845d7864236f6.png",
                "priceUSD": "1740.38"
            }
        ]
    }
}

MATIC to POL migration: Please note that on the Polygon chain, the native token previously referred to as has been renamed to . Similarly, WMATIC is now referred to as WPOL. While the token symbols have changed, the underlying assets and their contract addresses remain the same unless token symbols are passed in the API.

On Ethereum, both POL and are available but with different contract addresses. Be sure to use the correct contract address when requesting token information for these assets on Ethereum

⚙️
here
MATIC
POL
MATIC