Skip to main content
Simulate swaps, transfers, approvals — predict outcome & risks

Simulate Transaction

POST /api/simulate/execute-simulation Simulates an EVM transaction (e.g., token swap) and returns deltas, taxes, reentrancy, bytecode risks, and transfer history verdict. Use this endpoint to decide if a trade is safe before execution.

Request Body

{
  "userAddress": "0xYourEOA",
  "tokenAddress": "0xTokenToInteractWith",
  "amount": "1000000000000000000",
  "chainId": 1
}

Response

{
  "success": true,
  "ethDelta": "-0.15",
  "tokenDelta": "1234.56",
  "isProfit": false,
  "allowanceChanged": true,
  "allowanceDelta": "Unlimited",
  "estimatedTax": "800",
  "gasUsed": "145000",
  "isReentrancy": false,
  "isHoneypot": true,
  "errorReason": null,
  "simulation": { 
    "calls": [], 
    "logs": [] 
  },
  "bytecodeAnalysis": {
    "trustStatus": "Critical Risk",
    "humanWarning": "SELFDESTRUCT detected — contract can be killed at any time.",
    "riskFlags": [ 
      { 
        "threatLevel": "HIGH", 
        "title": "Kill Switch", 
        "description": "..." 
      } 
    ]
  },
  "transferHistory": {
    "activityPulse": "Very Active",
    "summary": { 
      "totalAnalyzed": 120, 
      "uniqueWallets": 45, 
      "lastTrade": "..." 
    }
  }
}