Documentation

Token Configuration

Guide for configuring tokens in BuilderKit flows.

Token Configuration

BuilderKit flows require proper token configuration to function correctly. This guide explains the required fields for different token configurations.

Basic Token Structure

All tokens in BuilderKit share a common base structure with these required fields:

interface BaseToken {
  // Contract address of the token, use "native" for native chain token
  address: string;      
  
  // Human-readable name of the token
  name: string;         
  
  // Token symbol/ticker
  symbol: string;       
  
  // Number of decimal places the token uses
  decimals: number;     
  
  // ID of the chain where this token exists
  chain_id: number;     
}

ICTT Token Fields

ICTT tokens extend the base structure with additional fields for cross-chain functionality:

interface ICTTToken extends BaseToken {
  // Whether this token can be used with ICTT
  supports_ictt: boolean;  
  
  // Address of the contract that handles transfers
  transferer?: string;     
  
  // Whether this token instance is a transferer
  is_transferer?: boolean; 
  
  // Information about corresponding tokens on other chains
  mirrors: {
    // Contract address of the mirrored token
    address: string;       
    
    // Transferer contract on the mirror chain
    transferer: string;    
    
    // Chain ID where the mirror exists
    chain_id: number;      
    
    // Decimal places of the mirrored token
    decimals: number;      
    
    // Whether this is the home/original chain
    home?: boolean;        
  }[];
}

Field Requirements

Base Token Fields

  • address: Must be a valid contract address or "native"
  • name: Should be human-readable
  • symbol: Should match the token's trading symbol
  • decimals: Must match the token's contract configuration
  • chain_id: Must be a valid chain ID

ICTT-Specific Fields

  • supports_ictt: Required for ICTT functionality
  • transferer: Required if token supports ICTT
  • is_transferer: Optional, indicates if token is a transferer
  • mirrors: Required for ICTT, must contain at least one mirror configuration

Mirror Configuration Fields

  • address: Required, contract address on mirror chain
  • transferer: Required, transferer contract on mirror chain
  • chain_id: Required, must be different from token's chain_id
  • decimals: Required, must match token contract
  • home: Optional, indicates original/home chain
Edit on GitHub

Last updated on

On this page