Onchain Read (EVM / Base)
agentbit.onchain_readCheap generic EVM reads on Base for AI agents: native balance, nonce, contract code, ERC-20 token balance, eth_call, gas price, latest block, and transaction/receipt lookups. One call, read-only, $0.001. Pay-per-call via x402 (USDC, Base).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"method": "<method>"
},
"name": "agentbit.onchain_read"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | No | Contract address for method=call | |
| data | No | 0x-prefixed hex calldata for method=call | |
| hash | No | Transaction hash (0x + 64 hex) for method=tx/receipt | |
| token | No | ERC-20 contract address for method=token_balance | |
| method | Yes | Which read to perform | |
| address | No | EVM address (0x + 40 hex) — for balance/nonce/code/token_balance (the holder) | |
| _payment | No | Optional base64 x402 PAYMENT-SIGNATURE payload. Omit to receive payment requirements. |