Skip to content

getStablecoin()

SIP Protocol API Reference v0.7.0


SIP Protocol API Reference / getStablecoin

getStablecoin(symbol, chain): Asset | null

Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:6238

Get stablecoin asset for a specific chain

StablecoinSymbol

Stablecoin symbol (e.g., ‘USDC’)

ChainId

Target chain

Asset | null

Asset object or null if not available on chain

const usdc = getStablecoin('USDC', 'ethereum')
// { chain: 'ethereum', symbol: 'USDC', address: '0xa0b8...', decimals: 6 }
const usdcSol = getStablecoin('USDC', 'solana')
// { chain: 'solana', symbol: 'USDC', address: 'EPjF...', decimals: 6 }