Wanchain - We Are All Connected!
WebsiteBridgeExplorerEcosystem
  • 👋 Welcome to Wanchain
  • Products
    • WanBridge
      • Bridge-to-Earn
      • XP
    • XFlows
      • XP
    • XPort
      • XPort developer handbook
      • Supported chains
    • XStake
  • Cross-Chain Infrastructure
    • Wanchain Bridge Node Group
    • Wanchain L1 blockchain
      • Network information
    • WAN coin
      • How to get WAN coins
      • WAN coin faucets
      • xWAN
  • The Convert n' Burn System
    • Overview
    • Bridge fees
      • Conversion and distribution
    • Discounts
  • Developers
    • WanBridge API
      • 1. Information Retrieval
        • 1.1 Supported Chains and Tokense 1
        • 1.2 Cross-chain Quota and Fees
        • 1.3 Asset Lock Address
        • 1.4 Storeman Group ID (smgID)
      • 2. Creating Cross-chain Transactions for WanBridge
        • 2.1 Direct Interaction with On-chain Contracts
        • 2.2 Creating Cross-Chain Transactions Using API
      • 3. Circle CCTP Cross-Chain
        • 3.1 EVM Compatible Chains
      • 4. Status Query
    • XFlows API
      • 1.1 Basic Information
      • 1.2 Request Parameters
      • 1.3 Response Parameters
      • 1.4 Examples
      • 1.5 Notes
      • 1.6 Status Query
    • XPort Developer Handbook
  • PoS Validator Nodes
    • Important Terms and Parameter
    • Recommended Hardware & Software
    • Mainnet Node Setup (Quick Start)
    • Mainnet Node Setup (Manually)
    • Getting Started With AWS
    • Common Operations (CLI)
    • Delegation Guide
    • Commonly Used Scripts
    • GWAN PoS API
    • Partner Model Staking Guide
    • Staking FAQ
  • Wanchain Bridge Nodes
    • Fact Sheet
    • How to deploy a Bridge Node
  • External Links
    • Blog
    • Email
    • GitHub
    • Telegram
    • Telegram Tech Support
    • Twitter/X
    • WanBridge
    • XFlows
    • XStake
    • WanScan
    • Website
Powered by GitBook
On this page
  1. Developers
  2. WanBridge API
  3. 1. Information Retrieval

1.1 Supported Chains and Tokense 1

Previous1. Information RetrievalNext1.2 Cross-chain Quota and Fees

Last updated 1 day ago

This section provides APIs to query the chains and tokens currently supported by the Wanchain Bridge.

There are two primary endpoints:

  • tokenPairs

  • tokenPairsHash

The tokenPairs endpoint returns detailed information about all supported chains and cross-chain tokens. Since this response can be large, it is recommended to first retrieve tokenPairsHash and compare it with the previously stored value. If there is no change, the locally cached data can be used to avoid unnecessary network requests each time.

tokenPairs Endpoint

URL:

Response Example:

{
  "success": true,
  "data": [
    {
      "tokenPairID": "453",
			"symbol": "USDC",
      "fromChain": {
        "chainId": "0xa4b1",
        "slip44ChainID": "0x40000002",
        "chainType": "ARETH",
        "chainName": "Arbitrum"
      },
      "toChain": {
        "chainId": "0x38",
        "slip44ChainID": "0x800002ca",
        "chainType": "BNB",
        "chainName": "BNB Chain"
      },
      "fromToken": {
        "address": "0xaf88d065e77c8cc2239327c5edb3a432268e5831",
        "name": "USD Coin",
        "symbol": "USDC",
        "decimals": "6"
      },
      "toToken": {
        "address": "0x8ac76a51cc950d9822d68b83fe1ad97b32cd580d",
        "name": "USD Coin",
        "symbol": "USDC",
        "decimals": "18"
      }
    },
	  ...
  ]
}

As shown above, the returned data is an array containing all supported cross-chain token pairs on Wanchain, totaling over 300 items. You can apply local filtering based on your requirements before using the data. For instance, you can filter by fromToken and toToken addresses.

It is important to note that the tokenPairs data is bidirectional, meaning you do not need to consider the direction of from and to—as long as the chain and token addresses match, the pair is valid.

tokenPairsHash Endpoint

URL:

Response Example:

{
  "success": true,
  "data": "39736194f3b3ecedb401fdfa6e4410b0"
}

This endpoint is used to check whether the tokenPairs data has changed before fetching the full dataset from the tokenPairs endpoint.

https://bridge-api.wanchain.org/api/tokenPairs
https://bridge-api.wanchain.org/api/tokenPairsHash