# Aegis Smart Contract Full Audit

> Aegis Smart Contract Full Audit is a paid API for AI agents from api.tradeperpetua.xyz, paid per call via x402, $10/call, status down (last checked 2026-09-16).

Performs a comprehensive, multi-lens security audit of a deployed smart contract, returning a signed report with exploit scenarios, owner capability analysis, and unchecked scope disclosure.

## Facts

- Endpoint: GET https://api.tradeperpetua.xyz/audit
- Price: $10/call
- Payment: x402
- Status: down
- Last checked: 2026-09-16
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/aegis-smart-contract-full-audit-8c776948
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_oDEc7tcj4s6t5jY16fKqF

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 aegis-smart-contract-full-audit-8c776948
```

Example prompt: Can you run a full Aegis audit on the contract at 0x1234567890abcdef1234567890abcdef12345678 on Ethereum — I need the complete security report covering reentrancy, access control, arithmetic, and rug pull vectors?

## When to prefer this

Choose this endpoint over the quick scan sibling when you need a thorough, defensible audit report — with adversarial challenge of every finding, full exploit scenario writeups, an owner-capability table, and a signed artifact. It is best for pre-launch audits, investor due diligence, regulatory documentation, or any situation where false positives must be minimized and the scope of what was NOT checked must be disclosed. Expect batch latency rather than an instant result.

## Known failure modes

- Invalid or unrecognized contract address (must match ^0x[0-9a-fA-F]{40}$)
- Contract source code not verified on-chain or unreadable, causing audit failure
- Unsupported chain specified (only base, ethereum, arbitrum, optimism, polygon, bsc accepted)
- Job transitions to 'failed' state if contract bytecode cannot be decompiled or analyzed
- Payment failure via x402 protocol results in request rejection
- Rate limiting or capacity constraints causing delayed job queuing

## How this service works

Full contract audit across six focused lenses, access control, reentrancy and state order, arithmetic, economics and oracles, upgradeability, and token rug vectors. Every finding is then challenged by an adversarial pass that tries to refute it, so what ships is only what survived. Returns a job id at once, then a signed report with exploit scenarios, a table of what the owner can do, and a list of what was not checked.

## Output

Returns immediately with a job ID (12 hex characters) and a status URL (free to poll). When complete, delivers a signed audit report including: exploit scenarios for each finding that survived adversarial review, a table of actions the contract owner can perform, a list of items not covered in the audit, and a human-readable report URL. The job state progresses through queued → running → done/failed.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "address"
     ],
     "properties": {
      "chain": {
       "enum": [
        "base",
        "ethereum",
        "arbitrum",
        "optimism",
        "polygon",
        "bsc"
       ],
       "type": "string",
       "default": "base",
       "description": "Chain, one of base, ethereum, arbitrum, optimism, polygon, bsc"
      },
      "address": {
       "type": "string",
       "pattern": "^0x[0-9a-fA-F]{40}$",
       "description": "Deployed contract address to audit"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "state": {
       "enum": [
        "queued",
        "running",
        "done",
        "failed"
       ],
       "type": "string"
      },
      "job_id": {
       "type": "string",
       "description": "12 hex characters, use it on the free status route"
      },
      "target": {
       "type": "object",
       "properties": {
        "chain": {
         "type": "string"
        },
        "address": {
         "type": "string"
        },
        "compiler": {
         "type": "string"
        },
        "contractName": {
         "type": "string"
        }
       }
      },
      "report_url": {
       "type": "string",
       "description": "Human readable report page"
      },
      "status_url": {
       "type": "string",
       "description": "Free route that returns progress and the report"
      },
      "eta_seconds": {
       "type": "number"
      }
     }
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/aegis-smart-contract-full-audit-8c776948/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.tradeperpetua.xyz](https://www.zero.xyz/host/api.tradeperpetua.xyz/llms.txt)
