# base-simulate

> base-simulate is a paid API for AI agents from x402.agentindex.world, paid per call via x402, $0.005/call, status unknown (last checked 2026-10-11).

Simulate a Base mainnet transaction to check if it will succeed, estimate gas usage, and decode revert reasons if it would fail.

## Facts

- Endpoint: GET https://x402.agentindex.world/base/simulate?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-11
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/base-simulate-7f3821ea
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_B0QcPpf7dVgpNi3wYwhIj

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability base-simulate-7f3821ea
```

Example prompt: Before I send this transaction, can you simulate it on Base mainnet to check if it'll succeed — the 'to' address is 0xAbC123..., the calldata is 0xa9059cbb000...abc, it's sending 0 wei, and my wallet is 0xDeF456...?

## When to prefer this

Use this endpoint when you need to dry-run a specific Base mainnet transaction before broadcasting it — especially useful for validating smart contract calls, estimating gas, or diagnosing revert reasons without spending real ETH. Prefer this over general gas price checkers (which don't simulate specific calldata) or honeypot checkers (which focus on token sell-ability). Ideal for agent workflows that need a safety check before executing on-chain actions.

## Known failure modes

- Invalid or malformed 'to' address returns a validation error
- Malformed hex calldata causes a parse error
- If the from_address has insufficient ETH balance, the simulation may fail with an out-of-gas or balance error
- RPC node unavailability may cause a timeout or 503 error
- Simulation of proxy contracts with unresolved logic may return unhelpful revert strings

## How this service works

Simulate a Base mainnet transaction before sending it - will it succeed, estimated gas, and the decoded revert reason if it would fail.

## Output

Returns whether the transaction would succeed or fail on Base mainnet, the estimated gas required, and if it would fail, the decoded revert reason explaining why (e.g. 'ERC20: insufficient allowance').

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "to": {
   "type": "string",
   "title": "To"
  },
  "data": {
   "type": "string",
   "title": "Data",
   "default": "0x"
  },
  "value_wei": {
   "type": "integer",
   "title": "Value Wei",
   "default": 0
  },
  "from_address": {
   "type": "string",
   "title": "From Address"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/base-simulate-7f3821ea/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402.agentindex.world](https://www.zero.xyz/host/x402.agentindex.world/llms.txt)
