• Discover
  • Partner with us
  • Chapters
  • Blog

Learn everything about Circle and USDC

Course Intro
Blockchain in a Nutshell
Introduction to Circle
Stablecoins
USDC
Wallets

Section Overview
Getting API Key
Introduction to Wallets
Getting App Id
Create a User
Acquire Session Token
Initialize User
Create Wallet
Submit Your Homework 1
Section Summary

Section Overview
Check Wallet Status
Getting Test USDC
Check Wallet Balance
Getting Native Test Token
Initiate Transaction
Validating Transaction
Submit Your Homework 2
Section Summary
Bonus: Complete a Challenge with WebSDK

Section Overview
Account Types
Create SCA
Transfer and Verify
Submit Your Homework 3
Section Summary

Section Overview
Working With Dev Controlled Wallets
Submit Your Homework 4
Section Summary

Section Overview
CCTP in a Nutshell
CCTP
Section Summary

Submit Your Final Project

Getting USDC Using ZKP2P and Turkish Lira
Resources

To check the wallet balance, we need to make an additional API call.

Before making the call, ensure that you have already obtained your WALLETID and saved it in the .env file.

NodeJS Code For Checking Wallet Balance

import dotenv from "dotenv";

import fetch from "node-fetch";

dotenv.config();

const url = `https://api.circle.com/v1/w3s/wallets/${process.env.WALLET_ID}/balances`;

const options = {

  method: "GET",

  headers: {

    "Content-Type": "application/json",

    Authorization: `Bearer ${process.env.API_KEY}`,

  },

};

fetch(url, options)

  .then((res) => res.json())

  .then((json) => console.dir(json, { depth: null }))

  .catch((err) => console.error("error:" + err));

This code is almost identical with the one that you have used in the previous lesson to get the wallet status.

  • The different thing is the URL you are calling. Be aware that you are passing WALLET_ID for this call.

Understanding The Response

If everything goes well, you will a response like the following:

{

  data: {

    tokenBalances: \\\[

      {

        token: {

          id: "e4f549f9-a910-59b1-b5cd-8f972871f5db",

          blockchain: "MATIC-AMOY",

          name: "Polygon-Mumbai",

          symbol: "MATIC-AMOY",

          decimals: 18,

          isNative: true,

          updateDate: "2023-06-29T02:37:14Z",

          createDate: "2023-06-29T02:37:14Z",

        },

        amount: "0",

        updateDate: "2024-01-30T16:57:04Z",

      },

      {

        token: {

          id: "7adb2b7d-c9cd-5164-b2d4-b73b088274dc",

          blockchain: "MATIC-AMOY",

          tokenAddress: "0x9999f7fea5938fd3b1e26a12c3f2fb024e194f97",

          standard: "ERC20",

          name: "USD Coin",

          symbol: "USDC",

          decimals: 6,

          isNative: false,

          updateDate: "2023-10-18T14:29:44Z",

          createDate: "2023-10-18T14:29:44Z",

        },

        amount: "10",

        updateDate: "2024-01-30T16:57:04Z",

      },

    \\\];

  }

}
  • As you can see, under the data, there is an array named tokenBalances.
  • This array holds the tokens that this wallet owns.
  • There are two types of tokens this address holds since there are two elements this array has.
  • The first one is:
{

        token: {

          id: "e4f549f9-a910-59b1-b5cd-8f972871f5db",

          blockchain: "MATIC-AMOY",

          name: "Polygon-Mumbai",

          symbol: "MATIC-AMOY",

          decimals: 18,

          isNative: true,

          updateDate: "2023-06-29T02:37:14Z",

          createDate: "2023-06-29T02:37:14Z",

        },

        amount: "0",

        updateDate: "2024-01-30T16:57:04Z",

}
  • This is the native token for MATIC-AMOY.
  • In this tutorial, you will be working with the testnet USDC stable coin, which you have acquired in the previous lesson.

Here is the token, which is the second item in the array:

{

        token: {

          id: "7adb2b7d-c9cd-5164-b2d4-b73b088274dc",

          blockchain: "MATIC-AMOY",

          tokenAddress: "0x9999f7fea5938fd3b1e26a12c3f2fb024e194f97",

          standard: "ERC20",

          name: "USD Coin",

          symbol: "USDC",

          decimals: 6,

          isNative: false,

          updateDate: "2023-10-18T14:29:44Z",

          createDate: "2023-10-18T14:29:44Z",

        },

        amount: "10",

        updateDate: "2024-01-30T16:57:04Z",

}

Let's look at this token a little bit deeper:

  • id: This is the token id. It uniquely identifies the token.
  • blockchain: This is the network that the token is in.
  • tokenAddress: This is the address of the smart contract that governs the token.
  • standard: This is the token standard. In this example, the token is using ERC20 Ethereum Fungible Token Standard.
  • name: This is the name of the token.
  • symbol: This is the symbol of the token.
  • decimals: For USDC and many other tokens, decimals are set to 6. This means that the token can be divided down to 0.000001 USDC. This is similar to how a dollar can be divided down to a cent.
  • isNative: This indicates that this token is not the native token of this network. If you look at the previous token example above, you can see that this variable is true since it is the native token of the network.
  • amount: This shows how much of this token does this wallet hold. If this is 0 for you, then it means that you failed to acquire a test token in the previous lesson. If this is the case, please go back to the previous lesson and acquire test USDC tokens.

Here you have it folks. You have successfully created and funded a user controlled wallet with a test USDC token.

Before moving forward, add the id of the USDC token to .env file under the name USDC_TOKEN_ID

Now, it is time for your first transaction. But before that, there is one more step to complete and that is getting native tokens.

Previous
Next

Lesson discussion

Swap insights and ask questions about “Learn everything about Circle and USDC”.

Enroll to participate
Start the course to unlock the discussion. Enrolling helps us keep conversations relevant to learners.
WebsiteDiscoverPartner with UsBlogEvents
Discover
CoursesCircleRustSoliditySolanaWeb3 FundamentalsBlockchain Basics
CompanyAbout UsBrand GuidelineFAQsTerms of UsePrivacy PolicyGDPR NoticeCookies
Don't miss any update!

Disclaimer: The information, programs, and events provided on https://risein.com is strictly for upskilling and networking purposes related to the technical infrastructure of blockchain platforms. We do not provide financial or investment advice, nor do we make any representations regarding the value, profitability, or future price of any blockchain or cryptocurrency. Users are encouraged to conduct their own research and consult with licensed financial professionals before engaging in any investment activities. https://risein.com disclaims any responsibility for financial decisions made by users based on the information provided here.

© 2026 Rise In, All rights reserved