Docs/CryptoGuard

CryptoGuard API Reference

Physics-powered crypto trade validation. 30 endpoints across three tiers: Core Scan, Intel Suite, and Physics Intelligence.

Base URL: https://api.emergentphysicslab.com/cryptoguardOpen Swagger UIRapidAPI Marketplace

#Authentication

CryptoGuard supports three authentication methods:

RAPIDAPI
Subscribe on RapidAPI and pass X-RapidAPI-Key header. Free tier: 500K calls/month.
x402Micropayments ($0.05/scan) via USDC on Base — for AI agents
DIRECTDirect REST calls — rate-limited, no key required

#Core Scan Endpoints

The essentials: trade validation, batch scanning, and portfolio sweeps.

POST/v1/validate-trade

Validate a single crypto trade. Returns PROCEED, CAUTION, or BLOCK with confidence score and risk factors.

Request
{
  "coin_id": "bitcoin",
  "action": "buy",
  "amount_usd": 1000
}
Response
{
  "verdict": "PROCEED",
  "confidence": 0.87,
  "risk_score": 0.13,
  "risk_factors": [],
  "market_data": {
    "price": 67234.50,
    "24h_change": -2.1,
    "volatility": "moderate",
    "regime": "trending_up"
  },
  "physics": {
    "anomaly_score": 1.2,
    "spectral_regime": "stable",
    "resonance_peaks": []
  }
}
POST/v1/validate-trades

Batch validate up to 20 trades in a single request.

Request
{
  "trades": [
    {"coin_id": "bitcoin", "action": "buy", "amount_usd": 1000},
    {"coin_id": "ethereum", "action": "sell", "amount_usd": 500}
  ]
}
Response
{
  "results": [
    {"coin_id": "bitcoin", "verdict": "PROCEED", "confidence": 0.87},
    {"coin_id": "ethereum", "verdict": "CAUTION", "confidence": 0.62}
  ],
  "summary": {"proceed": 1, "caution": 1, "block": 0}
}
GET/v1/scan/{coin}

Full anomaly report for a specific coin. Fetches 90 days of price data and runs physics analysis.

Request
GET /v1/scan/bitcoin
Response
{
  "coin": "bitcoin",
  "anomaly_detected": false,
  "anomaly_score": 1.8,
  "volatility": "moderate",
  "regime": "trending_up",
  "spectral_analysis": { ... },
  "risk_factors": [],
  "timestamp": "2026-03-15T10:30:00Z"
}
POST/v1/portfolio/scan

Sweep up to 50 tokens in your portfolio for anomalies.

Request
{
  "tokens": ["bitcoin", "ethereum", "solana", "cardano"]
}
Response
{
  "results": [
    {"token": "bitcoin", "status": "clean", "score": 1.2},
    {"token": "solana", "status": "warning", "score": 3.8}
  ],
  "alerts": 1
}
GET/v1/rug-check/{pair}

DEX pair safety check. Analyze liquidity, holder concentration, and contract risk.

Request
GET /v1/rug-check/0x1234...abcd
Response
{
  "pair": "0x1234...abcd",
  "risk_level": "medium",
  "flags": ["low_liquidity", "concentrated_holders"],
  "score": 0.65,
  "recommendation": "CAUTION"
}

#Intel Suite Endpoints

Advanced analysis: counterfactuals, instability checks, causal mechanisms, and trajectory forecasting.

POST/v1/validate-trade-plus

Premium bundle: validation + intel + physics in one call.

POST/v1/counterfactual

What-if analysis: simulate alternate trade scenarios.

POST/v1/instability-check/{coin}

Collapse risk assessment using resonance detection.

POST/v1/mechanism-explain/{coin}

Causal factor analysis: WHY is this coin moving?

POST/v1/trajectory/{coin}

Price path forecast using wave physics extrapolation.

#Physics Intelligence Endpoints

Deep physics analysis: spectral decomposition, regime detection, momentum pulses, and cross-asset resonance.

GET/v1/trend-detect/{coin}

Wave-physics trend identification. Detects trend changes before they show in moving averages.

GET/v1/regime-detect/{coin}

Market phase classifier: trending, mean-reverting, volatile, or stable.

GET/v1/spectral-scan/{coin}

Full FFT frequency analysis of price history. Identifies dominant cycles and resonance peaks.

GET/v1/volatility-forecast/{coin}

Volatility surface model using wave energy decomposition.

GET/v1/whale-detector/{coin}

Large-holder activity signal detection from volume anomalies.

GET/v1/momentum-pulse/{coin}

Burst detection: identifies sudden momentum injection into the market.

GET/v1/correlation-scan

Cross-asset resonance analysis. Finds hidden correlations between token pairs.

#Verdict System

PROCEED

Trade looks safe

No anomalies detected. Market structure is stable. Risk score < 0.3.

CAUTION

Elevated risk detected

Mild anomalies or unusual patterns. Consider reducing position size. Risk score 0.3 - 0.7.

BLOCK

High risk — do not trade

Significant anomalies, instability, or structural breakdown. Risk score > 0.7.

#AI Agent Integration

MCP (Model Context Protocol)

MCP Config
{
  "mcpServers": {
    "cryptoguard": {
      "command": "npx",
      "args": [
        "-y", "@smithery/cli@latest", "run",
        "@gpartin/cryptoguard-mcp",
        "--config",
        "{\"serverUrl\": \"https://api.emergentphysicslab.com/cryptoguard\"}"
      ]
    }
  }
}

x402 Micropayments

$0.05 per scan in USDC on Base. Discovery at GET /.well-known/x402

#Pricing

TierPriceRate LimitPlatform
BasicFree500K/mo, 1/hrRapidAPI
Pro$9.99/mo10K/mo, 60/minRapidAPI
Ultra$29.99/mo100K/mo, 300/minRapidAPI
x402$0.05/scanUnlimitedDirect (USDC)

#Error Handling

StatusMeaningAction
200SuccessParse JSON result
400Bad requestCheck coin_id, action, amount fields
402Payment requiredInclude x402 or RapidAPI header
404Coin not foundVerify coin_id against CoinGecko IDs
422Validation errorCheck request body schema
429Rate limitedUpgrade RapidAPI tier or use x402
503Cold startRetry in 10-30 seconds