Skip to main content
With the Cashmere Agent SDK, each pattern below is a call to cctp.transfer(): it fetches the quote, checks the recipient, approves USDC and waits for confirmation. The manual versions show what it does underneath.

Treasury Distributor (SDK)

Minimal React Hook (EVM)

Implement fetchEcdsaQuote, buildTransferV2Params and ensureAllowance with your network stack, following From Quote to Call: gasDropAmount 0, hookData 0x00, and maxFee from Circle Iris.

Node.js Treasury Distributor (Contracts)

Fetch Circle’s minimumFee for the route from https://iris-api.circle.com/v2/burn/USDC/fees/6/3 (source and destination domain): the response is an array with one entry per finalityThreshold. Use 1000 from Fast sources and 2000 otherwise.

Status Dashboard Snippet

confirmed means the source transaction confirmed; the transfer is complete once destination_tx_status is success, and failed means the destination mint transaction failed.

Solana Transfer (Anchor)

The complete transaction is in Smart Contracts → Solana.

Sui Transfer (V2)

  • recipientHex is the destination account as 32 bytes. Into Solana, it is the wallet’s USDC associated token account, with solanaOwnerHex set to the wallet.
  • With fee_is_native, the fee is in MIST (9 decimals) and comes from the gas coin split.

Aptos Transfer (ts-sdk)

  • recipientHex is the destination account as 32 bytes. Into Solana, it is the wallet’s USDC associated token account, with solanaOwnerHex set to the wallet.
  • Wallets such as Pontem expect the signature as a byte array; Array.from(Buffer.from(...)) gives one.
Quotes expire about 100 seconds after they are issued. If a quote is within about 30 seconds of its deadline, request a fresh one before asking the user to sign.