An asset is a representation of value on a blockchain network. Common types of assets include (fungible) tokens and NFTs (non-fungible tokens). CDP APIs support certain popular assets by their symbols and the vast majority by their contract addresses.

Assets supported by symbol

The CDP APIs support the following assets on the Base Sepolia & Mainnet networks to be identified by their symbols.

AssetTypeBase-MainnetBase-SepoliaDescription
Ether, also known as ETHnativeThis is the native token of many networks that run on the Ethereum Virtual Machine (EVM), including Base. ETH is used to pay for transactions on the network, and the network provides native APIs to send, receive, and otherwise interact with ETH.
USDCERC‑20backed 1:1 by a U.S. Dollar.
WETHERC-20backed 1:1 by ETH.
DAIERC-20Dai Stablecoin on Base-Mainnet.
RETHERC-20Rocket Pool ETH on Base-Mainnet.
BRETTERC-20Brett on Base-Mainnet.
WERC-20Wormhole Token on Base-Mainnet.
CBETHERC-20Coinbase Wrapped Ether on Base-Mainnet.
AXLERC-20Axelar on Base-Mainnet.
IOTXERC-20IoTeX on Base-Mainnet.
PRIMEERC-20Prime on Base-Mainnet.
AEROERC-20Aerodrome on Base-Mainnet.
RSRERC-20Reserve Rights on Base-Mainnet.
MOGERC-20Mog Coin on Base-Mainnet.
TBTCERC-20Base tBTC v2 on Base-Mainnet.
NPCERC-20Non-Playable Coin on Base-Mainnet.
YFIERC-20Yearn Finance on Base-Mainnet.

In addition to Base, CDP APIs also support ETH & USDC on Ethereum Mainnet, MATIC & USDC on Polygon Mainnet and ARB & USDC on Arbitrum Mainnet.

Assets supported by contract address

Besides the assets listed in the above table, CDP APIs support all other ERC20 tokens using their respective contract addresses.

Transfer an ERC20 from a wallet with contract address

The following example demonstrates how to create a transfer for USDC on Base-Sepolia using its contract address. Use Circle faucet to fund your wallet.

let wallet = await Wallet.create({ networkId: Coinbase.networks.BaseSepolia });

const transfer = await wallet.createTransfer({
amount: 0.0001,
assetId: "0x036CbD53842c5426634e7929541eC2318f3dCF7e",
destination: anotherWallet,
});

// Wait for the transfer to complete.
await transfer.wait();

Trade an ERC20 in a wallet with contract address

The following example demonstrates how to create a trade for USDC on Base-Mainnet using its contract address. Remember to fund your wallet with USDC to complete the trade.

let wallet = await Wallet.create({ networkId: Coinbase.networks.BaseMainnet });

// Out-of-band: Fund the wallet.

// Create trade from ETH to `0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913`.
let trade = await wallet.createTrade({
amount: 0.00001,
fromAssetId: Coinbase.assets.Eth,
toAssetId: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
});

// Wait for the trade to complete.
await trade.wait();

Fetch balances for assets

Fetch balance for assets identified by symbol

let balance = await wallet.getBalance(Coinbase.assets.Eth)

Fetch balance for assets identified by contract address

 let balance = await wallet.getBalance("0x036CbD53842c5426634e7929541eC2318f3dCF7e")

Denominations of ETH

ETH provides 18 places of decimal precision. The smallest amount of sendable ETH is 10-18, also known as a Wei.

Commonly used denominations of ETH:

DenominationAmount in WeiDescription
Wei1 WeiSmallest denomination of ETH
Gwei109 WeiDenomination of ETH commonly used for gas (i.e., transaction fee) calculations
Ether / ETH1018 WeiLargest denomination of ETH, commonly used for trading

The SDK supports transfers in denominations of Wei, Gwei, and ETH.

SDK Documentation

You can refer to the Asset class SDK docs for a full list of supported methods.

In Node.js, asset IDs are accessed through the assets property of the Coinbase class.

  • ETH’s asset ID is Coinbase.assets.Eth
  • USDC’s asset ID is Coinbase.assets.Usdc
  • WETH’s asset ID is Coinbase.assets.Weth