# SolMachina Transaction Simulator

> SolMachina Transaction Simulator is a paid API for AI agents from api.solmachina.com, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-15).

Dry-runs a serialized Solana transaction and returns a success prediction, compute units consumed, accounts touched, and any error details — without broadcasting to the chain.

## Facts

- Endpoint: GET https://api.solmachina.com/v1/simulate
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/solmachina-transaction-simulator-16551bc3
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap__AlQ_czYB6EV5PL6oug8K

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 solmachina-transaction-simulator-16551bc3
```

Example prompt: Before I submit this Solana transaction, simulate it and tell me whether it will succeed, how many compute units it'll use, and which accounts it touches — here's the base64-encoded tx: [base64tx].

## When to prefer this

Use SolMachina's simulate endpoint when an AI agent needs to pre-flight check a Solana transaction before committing it on-chain — particularly for DeFi operations, smart contract calls, or any scenario where transaction failure would have financial consequences. Prefer this over on-chain simulation RPCs when you want a structured, agent-friendly JSON response with success prediction and compute cost in a single pay-per-call model requiring no API key or account setup.

## Known failure modes

- Invalid or malformed base64 encoding returns a parse error
- Transaction references accounts or programs that don't exist on-chain, causing simulation failure
- Expired blockhash causes simulation to fail with a blockhash-not-found error
- Insufficient funds in simulated fee payer account triggers an error
- Network or RPC availability issues may return a timeout or 5xx response
- Payment failure via x402/USDC results in 402 Payment Required before simulation runs

## How this service works

Before an AI agent executes on Solana, it asks SolMachina: risk + a decision (EXECUTE/REVIEW/REJECT) + an SMRI score + a signed receipt, paid per call over x402 in USDC. Trust-first — cites every source, says 'unknown' over guessing. No account, no API key.

## Output

Returns a JSON object indicating whether the transaction would succeed (willSucceed boolean), compute units consumed (unitsConsumed integer), number of accounts touched (accountsTouched integer), any simulation error (err field, null on success), and an optional human-readable note about the simulation result.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "tx"
 ],
 "properties": {
  "tx": {
   "type": "string",
   "description": "Base64-encoded serialized Solana transaction to dry-run."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "err": {},
  "note": {
   "type": "string"
  },
  "willSucceed": {
   "type": "boolean"
  },
  "unitsConsumed": {
   "type": "integer"
  },
  "accountsTouched": {
   "type": "integer"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/solmachina-transaction-simulator-16551bc3/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.solmachina.com](https://www.zero.xyz/host/api.solmachina.com/llms.txt)
