Files
smom-dbis-138/scripts/SEND_20M_TOKENS_README.md
2026-03-02 12:14:09 -08:00

2.9 KiB

Send 20M cUSDT and cUSDC Script

Overview

This script sends 20,000,000 cUSDT and 20,000,000 cUSDC tokens to the specified wallet address.

Recipient Address: 0x4207aA9aC89B8bF4795dbAbBbE17fdd224E7947C

Usage

cd /home/intlc/projects/proxmox/smom-dbis-138
./scripts/send-20m-tokens.sh

How It Works

  1. Checks Deployer Balance: Verifies if the deployer address has sufficient tokens
  2. Smart Minting/Transfer:
    • If deployer has sufficient balance: Transfers tokens from deployer to recipient
    • If deployer has insufficient balance: Mints tokens directly to recipient (requires owner role)
  3. Verification: Confirms the transfers by checking recipient balances

Token Details

  • cUSDT Address: 0x93E66202A11B1772E55407B32B44e5Cd8eda7f22
  • cUSDC Address: 0xf22258f57794CC8E06237084b353Ab30fFfa640b
  • Amount: 20,000,000 tokens each (20000000000000 in base units with 6 decimals)

Prerequisites

  1. .env file must exist in the project root with:

    • PRIVATE_KEY: Private key of the deployer/owner
    • RPC_URL or RPC_URL_138: RPC endpoint URL
    • COMPLIANT_USDT_ADDRESS: cUSDT contract address (optional, has defaults)
    • COMPLIANT_USDC_ADDRESS: cUSDC contract address (optional, has defaults)
  2. The deployer address must be the owner of both token contracts (for minting)

  3. RPC endpoint must be accessible

Expected Output

╔══════════════════════════════════════════════════════════════╗
║     Send 20M cUSDT and cUSDC                               ║
╚══════════════════════════════════════════════════════════════╝

Deployer Address: 0x...
Recipient Address: 0x4207aA9aC89B8bF4795dbAbBbE17fdd224E7947C
Amount: 20,000,000 tokens (each)

Checking balances...
  Deployer cUSDT Balance: X tokens
  Deployer cUSDC Balance: X tokens

Minting 20M cUSDT to recipient...
✓ cUSDT mint successful
  Transaction Hash: 0x...

Minting 20M cUSDC to recipient...
✓ cUSDC mint successful
  Transaction Hash: 0x...

Verifying transfers...
  Recipient cUSDT Balance: 20000000.00 tokens
  Recipient cUSDC Balance: 20000000.00 tokens

╔══════════════════════════════════════════════════════════════╗
║     Transfers Complete!                                     ║
╚══════════════════════════════════════════════════════════════╝

Notes

  • The script uses cast from Foundry
  • Gas price is set to 20 gwei (20000000000)
  • Transactions use legacy format
  • Script will exit on any error