DOCUMENTATION

Complete API reference for Achilles EP AgentIAM. 9 paid endpoints, x402 micropayments, Base Mainnet USDC.

OVERVIEW

Achilles EP AgentIAM is a verification and intelligence infrastructure layer for autonomous AI agents. Every endpoint validates, scores, or verifies agent actions before execution.

BASE MAINNET   USDC PAYMENTS   x402 PROTOCOL

Base URL: https://achillesalpha.onrender.com

Network: Base Mainnet (eip155:8453)

Currency: USDC

Pay To: 0x069c6012E053DFBf50390B19FaE275aD96D22ed7

QUICK START

1. INSTALL x402 CLIENT

npm install @x402/fetch

2. MAKE YOUR FIRST CALL

import { fetchWithPayment } from '@x402/fetch';
import { createWalletClient } from 'viem';

const wallet = createWalletClient({ /* your Base wallet */ });

const result = await fetchWithPayment(
  'https://achillesalpha.onrender.com/x402/risk-check',
  {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({
      action: 'trade',
      value_usd: 500,
      asset: 'ETH',
      leverage: 2
    })
  },
  { wallet }
);

3. THAT'S IT

x402 handles payment automatically. Your agent sends USDC, gets verified data back. No API keys. No accounts. No subscriptions.

AUTHENTICATION

EP AgentIAM uses the x402 payment protocol instead of traditional API keys. Every paid request returns HTTP 402 with USDC payment instructions. An x402-compatible client handles payment automatically.

No signup. No API keys. No rate limit tiers. You pay per call, and the endpoint responds.

For free endpoints, no authentication is required.

x402 PROTOCOL

x402 is a machine-to-machine payment standard built on HTTP 402 (Payment Required). When an agent hits a paid endpoint without payment, it receives a 402 response containing payment instructions (amount, recipient, network). The x402 client library completes the USDC transfer on Base and retries the request with a payment proof header.

// How x402 works under the hood:

// 1. Agent sends POST to paid endpoint
// 2. Server returns 402 with payment details:
{
  "x402Version": 1,
  "accepts": [{
    "scheme": "exact",
    "network": "eip155:8453",
    "maxAmountRequired": "10000",
    "resource": "https://achillesalpha.onrender.com/x402/risk-check",
    "payTo": "0x069c6012E053DFBf50390B19FaE275aD96D22ed7"
  }]
}
// 3. x402 client signs USDC transfer, attaches proof
// 4. Server validates payment, returns data

Discovery: GET /.well-known/x402.json returns the full x402 manifest for automated agent integration.

PAID ENDPOINTS

POST /x402/validate $0.01
Full policy validation for agent trade proposals. Checks trade value, leverage, stop-loss placement against policy rules. Returns pass/fail with risk score and cryptographic proof hash.
REQUEST BODY
ParameterTypeDescription
agent_idstring requiredYour agent identifier
assetstring optionalAsset symbol (e.g. "ETH", "BTC")
directionstring optional"buy" or "sell"
amount_usdnumber optionalTrade value in USD (must be positive)
entry_pricenumber optionalProposed entry price
stop_lossnumber optionalStop loss price
take_profitnumber optionalTake profit price
leveragenumber optionalLeverage multiplier (max 3x policy)
proposal_idstring optionalYour internal proposal ID
RESPONSE
{
  "valid": true,
  "risk_score": "LOW",
  "violations": [],
  "proof_hash": "a1b2c3...",
  "plan_summary": "AGENT:my-bot | ETH BUY $50",
  "policy_set_id": "olympus-v1",
  "chain": "base",
  "timestamp": "2026-04-10T..."
}
POST /x402/risk-check $0.005
Quick pre-action risk assessment. Scores any agent action on a 0-100 scale across value, leverage, and action type. Returns risk level (LOW/MEDIUM/HIGH/CRITICAL) with recommendation.
REQUEST BODY
ParameterTypeDescription
actionstring requiredAction type: "trade", "swap", "bridge", "borrow", "transfer", etc.
value_usdnumber requiredDollar value of the action
assetstring optionalAsset involved
leveragenumber optionalLeverage multiplier (default 1)
contextstring optionalAdditional context for scoring
RESPONSE
{
  "risk_level": "MEDIUM",
  "risk_score": 35,
  "max_score": 100,
  "flags": ["MEDIUM_VALUE", "STANDARD_ACTION"],
  "recommendation": "Acceptable. Ensure proper sizing.",
  "timestamp": "2026-04-10T..."
}
POST /x402/noleak $0.01
Execution integrity check. Detects tampered execution environments, leaked credentials, and unauthorized data exfiltration. Verifies your agent's runtime hasn't been compromised.
REQUEST BODY
ParameterTypeDescription
agent_idstring requiredYour agent identifier
execution_hashstring optionalHash of current execution state
environmentobject optionalRuntime environment metadata
RESPONSE
{
  "status": "clean",
  "leak_detected": false,
  "tamper_detected": false,
  "integrity_score": 1.0,
  "proof_hash": "d4e5f6...",
  "timestamp": "2026-04-10T..."
}
POST /x402/memguard $0.01
Memory state verification. Compares current memory against baseline snapshots. Detects drift, corruption, truncation, and unauthorized modifications to your agent's memory.
REQUEST BODY
ParameterTypeDescription
agent_idstring requiredYour agent identifier
memory_hashstring optionalHash of current memory state
expected_statestring optionalExpected operational state
RESPONSE
{
  "status": "verified",
  "drift_detected": false,
  "corruption_detected": false,
  "unauthorized_mod": false,
  "integrity_score": 1.0,
  "timestamp": "2026-04-10T..."
}
POST /x402/riskoracle $0.01
Multi-factor pre-action risk scoring. Evaluates leverage risk, exposure analysis, and market conditions before your agent executes. Returns a 0-10 risk score with detailed breakdown.
REQUEST BODY
ParameterTypeDescription
agent_idstring requiredYour agent identifier
actionstring optionalProposed action description
value_usdnumber optionalDollar value at risk
leveragenumber optionalLeverage multiplier
assetstring optionalAsset involved
RESPONSE
{
  "risk_score": 3.2,
  "risk_level": "MEDIUM",
  "factors": {
    "leverage_risk": 2.1,
    "exposure_risk": 4.0,
    "market_risk": 3.5
  },
  "recommendation": "Proceed with caution",
  "proof_hash": "g7h8i9...",
  "timestamp": "2026-04-10T..."
}
POST /x402/secureexec $0.01
Sandboxed tool execution with security verification. Ensures only approved tools execute within authorized parameters. Returns execution proof hash for audit trail.
REQUEST BODY
ParameterTypeDescription
agent_idstring requiredYour agent identifier
toolstring optionalTool to execute
paramsobject optionalExecution parameters
sandboxboolean optionalForce sandboxed execution (default true)
RESPONSE
{
  "status": "executed",
  "tool": "trade_executor",
  "sandboxed": true,
  "result": { /* tool output */ },
  "proof_hash": "j1k2l3...",
  "timestamp": "2026-04-10T..."
}
POST /x402/flowcore $0.02
Full orchestration pipeline. Runs NoLeak + RiskOracle + SecureExec + MemGuard in sequence. One call verifies your entire agent action pipeline. Highest value per call.
REQUEST BODY
ParameterTypeDescription
agent_idstring requiredYour agent identifier
flowobject optionalFlow configuration (steps, params)
actionstring optionalAction to verify through full pipeline
RESPONSE
{
  "result": "verified",
  "steps_completed": 4,
  "pipeline": {
    "noleak": "pass",
    "riskoracle": "pass",
    "secureexec": "pass",
    "memguard": "pass"
  },
  "proof_hash": "m4n5o6...",
  "total_cost": "$0.02",
  "timestamp": "2026-04-10T..."
}
POST /x402/delphi $0.01
DELPHI intelligence signals. Query real-time AI-curated intel across crypto, AI agents, DeFi, and macro. Filter by signal type and severity. Returns structured signal data.
REQUEST BODY
ParameterTypeDescription
typestring optionalSignal type filter (e.g. "security/exploit", "market/price")
severitystring optionalSeverity filter: critical, high, medium, low, info
limitnumber optionalMax signals to return (default 20)
sincestring optionalISO timestamp — only signals after this time
agent_idstring optionalYour agent identifier for tracking
SIGNAL TYPES
// Available signal types:
security/exploit    security/vulnerability    security/rugpull
market/yield        market/price              market/liquidity    market/launch
ecosystem/new-agent ecosystem/new-service     ecosystem/funding
api-health/down     api-health/degraded       api-health/recovered
intelligence/research intelligence/trend      intelligence/opportunity
RESPONSE
{
  "signals": [
    {
      "id": "sig_abc123",
      "type": "market/price",
      "severity": "high",
      "title": "ETH breaks $4200 resistance",
      "confidence": 0.91,
      "source": "delphi-oracle",
      "created_at": "2026-04-10T..."
    }
  ],
  "count": 1,
  "timestamp": "2026-04-10T..."
}
POST /api/v1/research $0.05
AI-synthesized intelligence brief on any topic. Searches multiple sources, deduplicates findings, and returns a structured research report with key findings and sources.
REQUEST BODY
ParameterTypeDescription
topicstring requiredResearch topic (e.g. "Base network agent security")
depthstring optionalResearch depth: "quick" or "deep"
agent_idstring optionalYour agent identifier
RESPONSE
{
  "topic": "Base network agent security",
  "summary": "Research brief: 3 key findings from 8 sources.",
  "key_findings": [
    "Finding 1...",
    "Finding 2...",
    "Finding 3..."
  ],
  "sources": [
    { "title": "Source Title", "url": "https://..." }
  ],
  "result_count": 8,
  "generated_at": "2026-04-10T..."
}

ERRORS

CodeMeaningAction
400Bad Request — missing required fieldsCheck request body
402Payment Required — x402 payment neededUse @x402/fetch for auto-payment
500Internal Server ErrorRetry after 5 seconds
502Service Unreachable — backend service downRetry after 30 seconds (cold start)

RATE LIMITS

No rate limits. Every request is paid via x402 — the payment itself is the rate limiter. You can make as many calls as your agent needs.

SDKs & TOOLS

PackageLanguagePurpose
@x402/fetchJavaScript/TypeScriptDrop-in fetch replacement with auto x402 payment
@x402/axiosJavaScript/TypeScriptAxios interceptor for x402 payment
viemJavaScript/TypeScriptWallet client for signing USDC transactions on Base
# Install everything you need
npm install @x402/fetch viem

More resources:

x402.org — x402 protocol specification and documentation

Base Docs — Base network developer documentation

BaseScan — View treasury wallet and on-chain transactions