Integrations

Circle Products and Integrations

Exactly which Circle products SocialPay uses, what for, and where they live in the code.

What SocialPay uses from Circle

This page lists only integrations that exist in the repository today. Mentioning a product here means the code calls it. It does not imply a partnership or endorsement.

Circle productWhat SocialPay uses it forWhere in the code
USDCThe unit for payments, tips, approvals and bridges. Also the gas token on Arc.src/hooks/useArcWallet.ts, src/contracts/arcSocialPay.ts, contracts/ArcSocialPay.sol
EURC and cirBTCSelectable tokens in swaps and token lists on Arc.src/lib/arcTokens.ts, src/lib/uniswapArc.ts, src/components/swap/CircleSwap.tsx
Circle App Kit (@circle-fin/app-kit): bridgeNative USDC bridging over CCTP: estimate, bridge, retry and step events.src/components/bridge/CctpBridge.tsx, src/lib/circleKit.ts
Circle App Kit: swapEstimating and executing stablecoin swaps among USDC, EURC and cirBTC.src/components/swap/CircleSwap.tsx
Viem adapter (@circle-fin/adapter-viem-v2)Lets App Kit sign with the wallet connected through wagmi.src/lib/circleKit.ts
CCTP TokenMessengerV2 contractRecognises bridges out of Arc in Activity by reading the burn event.src/lib/bridgeDetect.ts

USDC

USDC on Arc is at 0x3600000000000000000000000000000000000000. As an ERC-20 it has 6 decimals. As the native gas token it is shown with 18 decimals. SocialPay reads one USDC balance, never adds the two views together, and does all money math with exact integers.

The ArcSocialPay contract takes the USDC address in its constructor and only ever calls the 6-decimal ERC-20 interface.

Circle routing in swaps

The Circle swap tab asks App Kit for an estimate and then asks it to execute. On Arc it offers USDC, EURC and cirBTC only. App Kit chooses the route, which can come from a third-party swap service provider, as the in-app notice says. SocialPay does not choose or re-check that route beyond the slippage you set.

The Best price and Any token tabs do not use Circle routing. They use Uniswap, KyberSwap and LI.FI.

Native CCTP

The Circle CCTP tab calls App Kit's bridge. App Kit performs the approve, burn, attestation and mint steps over Circle's Cross-Chain Transfer Protocol, and SocialPay shows each step. The destination mint is delivered with Circle's forwarding option.

The bridge calls App Kit; SocialPay does not call TokenMessenger directly to bridge. It reads the TokenMessengerV2 DepositForBurn event only to label a past transaction as a bridge in Activity.

kit.estimateBridge({ from, to: { ...to, useForwarder: true }, amount })
kit.bridge({ from, to, amount })
kit.retryBridge(result, { from, to })

Not integrated

To avoid confusion, SocialPay does not currently use these Circle products:

  • Circle Wallets (developer-controlled, user-controlled or modular). Users bring their own wallet.
  • Circle Gateway or Nanopayments. No Gateway contract or x402 flow is called, although some x402 packages appear in package.json.
  • Circle Mint, onramp or payouts.
  • Circle Paymaster or Gas Station. Gas is paid in USDC by the user.

Official references

Found something unclear or out of date? Open an issue on GitHub.