Export Ethereum USDC transfers.
Export USDC Transfer logs on Ethereum with bounded eth_getLogs ranges, adaptive splitting, request limits, and resumable block checkpoints. This recipe reads blockchain data. It does not create an account, sign a transaction, or fund credit.
Give your agent the task.
Export Ethereum USDC Transfer events for the block range I provide using SolidRPC. Estimate the request count, test a small historical range, and ask before spending. Use address and topic filters, bounded chunks, and persistent checkpoints. Do not treat an RPC error as an empty result.New to SolidRPC? Follow agent account setup first. A small task may fit public RPC. Account delegation requires paid access, and this script expects a separate ak_ RPC key.
Check coverage and limits.
Required methods: eth_chainId, eth_blockNumber, eth_getLogs. Read the network catalog and rate limits before a large run. One billable method call uses one response unit. Retries and range splits add requests.
Ethereum has chain ID 1. USDC is 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48. Filter by this contract and the Transfer(address,address,uint256) event topic. Historical logs are distinct from historical state. Check Ethereum coverage and sample your earliest required block before a large export.
There is no universal successful range size. Log density and response size matter. Start with 100 blocks, split size-limit errors, and stop on quota, authorization, or unresolved provider errors. The example caps ranges at 1,000 blocks per request and a run at 100,001 blocks. Those are example safeguards, not advertised service limits. Choose finalized historical ranges and reconcile block hashes when operating near the head.
Contract reference: Circle’s official USDC addresses. Do not substitute a similarly named bridged token.
Run the example.
Download ethereum-usdc-transfers.mjs and its shared rpc-client.mjs into the same folder. Review them before running. The helper refuses management tokens and redirects, sends the RPC key in a header, and makes read-only calls with bounded retries.
# Node.js 22 or newer. Save both linked scripts in one folder.
export RPC_ORIGIN='https://rpc.solidrpc.io'
export RPC_KEY_FILE='/absolute/path/to/private/rpc-key'# Replace these with the block range you intend to export.
FROM_BLOCK=21000000 TO_BLOCK=21000099 \
CHUNK_BLOCKS=100 MAX_REQUESTS=100 \
node ethereum-usdc-transfers.mjs > transfers.ndjson 2> progress.logKeep the key file outside your repository. The scripts print results without credentials. They do not automatically purchase more credit when the account runs out.
Know what success looks like.
Each output line is a decoded transfer with its block hash, transaction hash, log index, sender, recipient, and exact USDC amount. A successfully queried empty range produces no transfer rows and still writes a completed-range checkpoint to stderr.
On failure, preserve both output and the progress log. Resume at the next block after the last completed range, writing to a new output file. Deduplicate combined output by block hash, transaction hash, and log index. The request cap counts logical calls, and each can make up to four HTTP attempts. This is not a full continuously running indexer.
For errors, inspect HTTP status and the JSON-RPC error separately. Use the error reference. Report any partial result instead of claiming the entire task completed.
Need account access? Read the setup guide or open the management API contract.