Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.bungee.exchange/llms.txt

Use this file to discover all available pages before exploring further.

Bungee Auto supports trading any token with sufficient liquidity, regardless of whether it appears in the token list responses.

Token Sources and Verification

Bungee maintains a primary data source for token information and categorizes tokens in two ways:
  • Verified Tokens: These are recognized by Bungee and are considered verified.
  • Unverified Tokens: These are tokens added to our own database that may not be widely listed yet. When these are displayed, we recommend showing a warning to users to exercise caution.

How the Endpoints and Parameters Work

  • /tokens/list (Default):
    • Returns a curated list of trending tokens, all of which are “verified” (recognized by Bungee).
    • “Trending” is currently determined by trading volume, showing the tokens with the highest volume on each supported network.
    • This list is dynamic, and the trending algorithm may evolve to include other factors for relevance.
  • /tokens/list (with list=full parameter):
    • Returns the full, unabridged list of all tokens known to Bungee (including both verified and unverified tokens).
    • Warning: This is a very heavy and slow API call. We strongly recommend not using it in a production frontend application.
  • /tokens/search:
    • Designed to find a specific token by its name, symbol, or address (e.g., “USDC”).
    • Searches across the entire dataset, including both verified and unverified tokens.

Best Practices

  • For the best user experience, we recommend:
    • Using the default /tokens/list to display a relevant, curated list of trending tokens.
    • Maintaining your own list of tokens that are most relevant to your users.
  • Most tokens with sufficient liquidity should return a valid route through Bungee, regardless of which list they appear on.

Token list endpoint example usage

The /tokens/list endpoint retrieves a list of available tokens, with optional parameters to customize the response.
const BUNGEE_API_BASE_URL = "https://public-backend.bungee.exchange";

async function getTokenList(userAddress, chainIds = [1], isTrending = true) {
  const url = `${BUNGEE_API_BASE_URL}/api/v1/tokens/list`;
  const params = {
    userAddress,
    chainIds: chainIds.join(","),
    list: isTrending ? "trending" : "full",
  };

  const queryParams = new URLSearchParams(params);
  const response = await fetch(`${url}?${queryParams}`);
  const data = await response.json();

  return data;
}

Token search endpoint example usage

The /tokens/search endpoint allows you to search for tokens by address, name, or symbol. Use this endpoint to verify if a specific token can be traded, even if it doesn’t appear in the token list.
async function searchToken(query, userAddress) {
  const url = `${BUNGEE_API_BASE_URL}/api/v1/tokens/search`;
  const params = {
    q: query,
    userAddress,
  };

  const queryParams = new URLSearchParams(params);
  const response = await fetch(`${url}?${queryParams}`);
  const data = await response.json();

  return data;
}