TRC-20 · USDT · Cross-Chain Swaps

Tron API for
AI Agents

Tron hosts over $60 billion in USDT circulation — more than any other chain. Purple Flea gives your agent a Tron address, TRX and TRC-20 balance checks, and cross-chain swap capabilities, all through a simple REST API.

$60B+
USDT on Tron
~$0.001
Per TRC-20 transfer
3 sec
Finality
T...
Address format

The most practical chain for
agent payment flows.

Tron was built for high-throughput, low-cost USDT movement. Those same properties make it the default choice for autonomous agents that need to send, receive, and bridge stablecoins without friction.

💰

Massive USDT liquidity

Tron hosts over $60 billion in TRC-20 USDT — the largest single-chain USDT pool in existence. Most exchanges, payment processors, and OTC desks settle USDT on Tron as a first choice.

🚩

Near-zero fees for TRC-20

Sending USDT on Tron costs roughly $0.001 regardless of network congestion. Agents can execute hundreds of stablecoin transfers per day without meaningful fee overhead — impossible on Ethereum.

Fast finality

Tron's delegated proof-of-stake confirms blocks in approximately 3 seconds. By the time your agent receives a 200 response from the send endpoint, the transaction is already finalized on-chain.

Same stablecoin. Very different economics.

Sending $5 in USDT on Ethereum can cost $2 in gas during busy periods — a 40% fee on a small transfer. On Tron that same transfer costs a fraction of a cent. For agents making micro-payments, the economics only work on Tron.

Property Tron TRC-20 USDT Ethereum ERC-20 USDT
Transfer fee ~$0.001 $1 – $10 (variable gas)
Confirmation time ~3 seconds ~15 – 60 seconds
USDT circulation Largest ($60B+) Second largest
Micropayments viable? Yes — $0.10 transfers make sense No — fees exceed small amounts
Address format Base58check, starts with T Hex, starts with 0x
Cross-chain bridging Supported via Purple Flea swap Supported via Purple Flea swap

What agents can do
on Tron.

Three core endpoints cover everything an agent needs: a deterministic Tron address, full TRC-20 balance visibility, and cross-chain USDT swaps.

GET

/v1/wallet/address?chain=tron

Returns your agent's Tron address in base58check format, starting with T. Derived deterministically from your BIP-39 mnemonic at path m/44'/195'/0'/0/0. Idempotent — always returns the same address.

response.json
{ "chain": "tron", "address": "TQn9Y2khEsLJW1ChVWFMSMeRDow5KcbLSE", "format": "base58check", "derivation_path": "m/44'/195'/0'/0/0" }
GET

/v1/wallet/balance?chain=tron

Returns TRX balance and all TRC-20 token balances including USDT, USDC, BTT, and SUN. Amounts are returned in human-readable decimal form with correct precision for each token contract.

response.json
{ "chain": "tron", "address": "TQn9Y2khEsLJW1ChVWFMSMeRDow5KcbLSE", "balances": { "trx": { "amount": "120.500000", "usd_value": "14.46" }, "usdt": { "amount": "845.00", "usd_value": "845.00", "standard": "TRC-20" }, "usdc": { "amount": "0.00", "usd_value": "0.00", "standard": "TRC-20" } }, "total_usd": "859.46" }
POST

/v1/wallet/swap

Swap USDT on Tron cross-chain to any supported destination chain (Base, Ethereum, BNB Chain, Solana). Purple Flea handles the bridge routing, fee estimation, and execution. Quotes are returned before confirmation.

request + response.json
// Request — bridge 200 USDT from Tron to USDC on Base { "from_chain": "tron", "from_token": "usdt", "to_chain": "base", "to_token": "usdc", "amount": "200.00", "slippage": "0.5" } // Response { "quote_id": "q_8f3a92...", "you_send": "200.00 USDT (Tron)", "you_receive": "199.12 USDC (Base)", "bridge_fee": "0.88 USDT", "estimated_time": "2-4 minutes", "status": "awaiting_confirmation" }

Tron addresses start with T.
Here is why.

Tron uses the same elliptic curve as Ethereum (secp256k1) but encodes addresses in base58check rather than hex. The result looks completely different from an Ethereum address, even though they share the same underlying key material.

Tron address (base58check, 34 chars)

TRON TQn9Y2khEsLJW1ChVWFMSMeRDow5KcbLSE

Same key, Ethereum format (hex, 42 chars)

ETH 0xa614f803B6FD780986A42c78Ec9c7f77e6DeD13
address_derivation_steps.txt
# BIP-32 derivation path (coin type 195 = Tron) Path: m/44'/195'/0'/0/0 # Address encoding — 6 steps: 1. Derive secp256k1 key pair at BIP-32 path 2. Keccak-256 hash of uncompressed public key (64 bytes) 3. Take the last 20 bytes → this is the raw EVM address 4. Prepend 0x41 mainnet byte → 21-byte payload 5. Double-SHA256 of payload → take first 4 bytes (checksum) 6. base58encode(payload + checksum) → T... # The 0x41 prefix is what produces the "T" prefix # Same mnemonic → same Tron address, always # Import to TronLink to verify independent control

TRC-20 tokens your agent
can hold and transfer.

All TRC-20 tokens are returned in balance queries automatically. Transfer any of these by symbol — no contract address required.

$

USDT

Tether USD on Tron. The largest stablecoin pool on any chain — $60B+ circulation. The primary use case for Tron-enabled agents.

USDC

USD Coin TRC-20. Circle's stablecoin on Tron. Interchangeable with USDT for most agent use cases and bridgeable cross-chain.

TRX

Native Tron token. Required for bandwidth and energy. Purple Flea maintains a TRX reserve automatically so your agent never stalls.

BTT & SUN

BitTorrent Token and SUN governance token. Native to the Tron DeFi ecosystem. Returned in balance queries when held.


Receive USDT on Tron.
Bridge anywhere.

The most common agent payment pattern: accept USDT on Tron (lowest friction for senders) then cross-chain bridge to wherever the agent needs funds — Base, Ethereum, Solana, or BNB Chain.

🔗
Agent Tron Address
TQn9Y2kh...
💰
Receive USDT
TRC-20, ~$0.001 fee
🏠
Monitor Balance
GET /v1/wallet/balance
Swap Cross-Chain
POST /v1/wallet/swap
USDC on Base
or ETH, Solana, BNB

Most exchanges deposit USDT to Tron by default. Your agent accepts it with zero friction, then converts to whatever chain its DeFi or payment logic requires.


Monitor incoming USDT on Tron,
auto-convert to USDC on Base.

A complete Python agent loop that polls the Tron balance, detects incoming USDT, and automatically bridges it to USDC on Base via the swap endpoint.

usdt_monitor_agent.py
import requests, time, logging from decimal import Decimal logging.basicConfig(level=logging.INFO, format="%(asctime)s %(message)s") API_KEY = "your_api_key" BASE_URL = "https://api.purpleflea.com" HEADERS = {"X-API-Key": API_KEY, "Content-Type": "application/json"} # Minimum USDT to trigger a bridge (avoid bridging dust) MIN_BRIDGE_USDT = Decimal("10.00") POLL_INTERVAL = 15 # seconds between balance checks def get_tron_usdt_balance() -> Decimal: """Fetch current USDT balance on Tron.""" resp = requests.get( f"{BASE_URL}/v1/wallet/balance", headers=HEADERS, params={"chain": "tron"} ) resp.raise_for_status() data = resp.json() return Decimal(data["balances"]["usdt"]["amount"]) def bridge_usdt_to_base(amount: Decimal) -> dict: """Swap USDT on Tron to USDC on Base via Purple Flea swap.""" resp = requests.post( f"{BASE_URL}/v1/wallet/swap", headers=HEADERS, json={ "from_chain": "tron", "from_token": "usdt", "to_chain": "base", "to_token": "usdc", "amount": str(amount), "slippage": "0.5" } ) resp.raise_for_status() return resp.json() def run_monitor(): logging.info("Starting USDT monitor — polling every %ds", POLL_INTERVAL) last_known = get_tron_usdt_balance() logging.info("Initial USDT balance: %s", last_known) while True: time.sleep(POLL_INTERVAL) try: current = get_tron_usdt_balance() delta = current - last_known if delta >= MIN_BRIDGE_USDT: logging.info("Received %.2f USDT — initiating bridge to USDC on Base", delta) result = bridge_usdt_to_base(delta) logging.info( "Bridge submitted: %s → receive %s | ETA %s", result["you_send"], result["you_receive"], result["estimated_time"] ) last_known = current - delta # reset baseline elif delta > 0: logging.info("Small inflow %.4f USDT — below bridge threshold, accumulating", delta) last_known = current else: logging.info("Balance unchanged: %s USDT", current) except Exception as exc: logging.error("Monitor error: %s — retrying next cycle", exc) if __name__ == "__main__": run_monitor()

Address derivation path:
m/44'/195'/0'/0/0

Tron uses BIP-44 coin type 195, registered in SLIP-44. The same BIP-39 mnemonic that produces your Ethereum address also produces your Tron address — at a different derivation path with a different encoding.

When you register an agent with Purple Flea, your BIP-39 mnemonic is the master secret. From that single mnemonic, deterministic addresses are derived for every supported chain: Ethereum, Tron, Solana, Bitcoin, BNB Chain, and Base.

For Tron specifically, the path is m/44'/195'/0'/0/0. The 195' component is Tron's SLIP-44 coin type. The underlying secp256k1 private key is identical in structure to an Ethereum key — only the address encoding differs.

Your agent's Tron address is self-sovereign. Import the mnemonic into TronLink or any TRON-compatible wallet to independently verify and control the address. Purple Flea never custodies the key — the API signs transactions locally with the derived key before broadcasting.

There is no on-chain account creation step. The moment the address exists in the derivation, it can receive TRX and TRC-20 tokens. Funds are spendable as soon as one confirmation occurs.

derive_tron_address.py
from bip_utils import Bip39SeedGenerator, Bip44, Bip44Coins import hashlib, base58 MNEMONIC = "abandon abandon abandon ... word12" # Derive secp256k1 key at m/44'/195'/0'/0/0 seed = Bip39SeedGenerator(Mnemonic(MNEMONIC)).Generate() bip44 = Bip44.FromSeed(seed, Bip44Coins.TRON) acct = bip44.Purpose().Coin().Account(0).Change().AddressIndex(0) addr = acct.PublicKey().ToAddress() print(addr) # TQn9Y2khEsLJW1ChVWFMSMeRDow5KcbLSE # Manual encoding (for reference): # 1. raw_addr = keccak256(pubkey)[-20:] # 2. payload = b'\x41' + raw_addr # 3. checksum = sha256(sha256(payload))[:4] # 4. tron_addr = base58.b58encode(payload + checksum)

Tron's bandwidth and energy model,
abstracted by Purple Flea.

Instead of variable gas fees, Tron uses a resource model. Your agent never interacts with it directly — Purple Flea handles it automatically.

📶

Bandwidth

Consumed by all transactions proportional to their byte size. Every Tron account receives 600 free bandwidth points per day. TRX transfers typically cost 265 bandwidth points. Exceeding the free daily allowance burns TRX at a fraction of a cent per byte.

Energy

Consumed by smart contract execution — including TRC-20 transfer() calls. USDT transfers cost approximately 65,000 energy units. Energy is obtained by freezing TRX or paid in TRX directly at roughly $0.0008 per transfer.

⚙️

Abstracted Away

Purple Flea maintains a TRX reserve in every agent wallet and automatically covers bandwidth and energy costs. The $0.001 all-in fee shown in quotes is the full cost of a TRC-20 USDT transfer. No manual resource management required.

Why this matters for high-volume agents: An agent making 500 USDT transfers per day on Tron spends roughly $0.50 in total fees. The same 500 Ethereum ERC-20 transfers would cost anywhere from $500 to $5,000 depending on gas prices. Tron's resource model makes agent-driven USDT flows economically viable at any scale.


Your first three API calls
in under a minute.

tron_quickstart.py
import requests API_KEY = "your_api_key" BASE = "https://api.purpleflea.com" HEADERS = {"X-API-Key": API_KEY} # ── 1. Get your agent's Tron address ────────────────────────────────────────── addr_resp = requests.get(f"{BASE}/v1/wallet/address", headers=HEADERS, params={"chain": "tron"}) tron_addr = addr_resp.json()["address"] print(f"Tron address: {tron_addr}") # → TQn9Y2khEsLJW1ChVWFMSMeRDow5KcbLSE # ── 2. Check TRX + TRC-20 balances ─────────────────────────────────────────── bal_resp = requests.get(f"{BASE}/v1/wallet/balance", headers=HEADERS, params={"chain": "tron"}) balances = bal_resp.json()["balances"] print(f"TRX: {balances['trx']['amount']}") print(f"USDT: {balances['usdt']['amount']}") print(f"USDC: {balances['usdc']['amount']}") # ── 3. Bridge 50 USDT from Tron → USDC on Base ─────────────────────────────── swap_resp = requests.post(f"{BASE}/v1/wallet/swap", headers=HEADERS, json={ "from_chain": "tron", "from_token": "usdt", "to_chain": "base", "to_token": "usdc", "amount": "50.00", "slippage": "0.5" }) quote = swap_resp.json() print(f"Swap: {quote['you_send']} → {quote['you_receive']} ({quote['estimated_time']})")

More chain-specific endpoints
for your agents.

Give your agent the world's deepest
USDT liquidity at near-zero cost.

Tron address, TRC-20 balances, cross-chain swaps. Free to start. No KYC.