APIDocumentation

Comprehensive documentation for Helix Analytics APIs. Build powerful applications with our crypto analytics infrastructure.

Flow Analysis API

GET /api/flow

Analyze token flow patterns including whale movements, volume metrics, and flow indices.

Query Parameters

token
string
required
ERC-20 contract address

Example Request

GET /api/flow?token=0xA0b86a33E6417c5F8d35cA78c8294ba20F8e2a6D

Example Response

{
  "flowIndex": 6.2847,
  "whaleMoves": [
    {
      "transactionHash": "0x123abc...def789",
      "from": "0x3f5CE5FBFe3E9af3971dD833D26bA9b5C936f0bE",
      "to": "0xA0b86a33E6417c5F8d35cA78c8294ba20F8e2a6D",
      "value": "1234.567890",
      "timestamp": 1703123456
    }
  ],
  "metadata": {
    "tokenSymbol": "USDC",
    "tokenName": "USD Coin",
    "transfersCount": 145,
    "totalVolume": "45678.901234",
    "netInflow": "+1234.5678",
    "avgVolumePerHour": "2834.3125"
  }
}

MEV Detection API

GET /api/mev

Analyze transactions for MEV potential using Flashbots bundle simulation.

Query Parameters

txHash
string
required
Transaction hash (66 chars)

Example Request

GET /api/mev?txHash=0x123abc...def789

Example Response

{
  "mevScore": 4.2,
  "recommendedGasPrice": "25.5 gwei",
  "mevType": ["High Gas Price Competition", "DEX Interaction"],
  "riskFactors": ["Extremely high gas price suggests MEV competition"],
  "profitPotential": "Medium",
  "transactionDetails": {
    "from": "0x742d35Cc6642C4532c111Ea78eE6C5F96a1a8c46",
    "to": "0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D",
    "value": "0.5",
    "gasPrice": "50000000000"
  },
  "mevOpportunities": [
    {
      "type": "frontrun",
      "description": "High gas price suggests front-running attempt",
      "confidence": "medium"
    }
  ]
}

Flow Timeseries API

GET /api/flow-timeseries

Get historical flow data for top 10 tokens with time series analysis.

Query Parameters

days
number
optional
Number of days (1-30, default: 7)

Example Response

{
  "tokens": [
    {
      "symbol": "USDT",
      "name": "Tether",
      "address": "0xdAC17F958D2ee523a2206206994597C13D831ec7",
      "data": [
        {
          "timestamp": 1703123456000,
          "date": "2023-12-21",
          "flowIndex": 15.2,
          "realizedVolatility": 0.12
        }
      ]
    }
  ]
}

Portfolio API

GET /api/portfolio

Get comprehensive portfolio analysis for a wallet address.

Query Parameters

address
string
required
Ethereum wallet address
includeTransactions
boolean
optional
Include recent transactions (default: false)

Example Response

{
  "totalValue": "15234.56",
  "totalValueUSD": "15234.56",
  "tokens": [
    {
      "address": "0xA0b86a33E6417c5F8d35cA78c8294ba20F8e2a6D",
      "symbol": "USDC",
      "balance": "5000.000000",
      "valueUSD": "5000.00"
    }
  ],
  "metadata": {
    "processingTime": 245,
    "timestamp": 1703123456789
  }
}

Staking API

GET /api/stake

Retrieve staking information for a wallet address.

Query Parameters

address
string
required
Wallet address

Example Response

{
  "stakedBalance": "1000.0",
  "rewardBalance": "50.25",
  "totalStaked": "1000000.0",
  "apy": "12.5"
}

POST /api/stake

Perform staking operations (stake/unstake).

Request Body

{
  "action": "stake" | "unstake",
  "amount": "100.0",
  "address": "0x742d35Cc6642C4532c111Ea78eE6C5F96a1a8c46"
}

Example Response

{
  "success": true,
  "transactionHash": "0xabc123...def789",
  "newStakedBalance": "1100.0"
}

PUT /api/stake

Claim accumulated staking rewards.

Request Body

{
  "action": "claim",
  "address": "0x742d35Cc6642C4532c111Ea78eE6C5F96a1a8c46"
}

Example Response

{
  "success": true,
  "claimedAmount": "50.25",
  "transactionHash": "0xabc123...def789"
}

Error Codes

400
Bad Request
Invalid parameters or request format
404
Not Found
Resource not found or invalid address
500
Internal Server Error
Server error or external API failure
429
Rate Limited
Too many requests, please slow down

Rate Limits

Free Tier

  • • 100 requests per minute
  • • 1,000 requests per day
  • • No API key required
  • • Basic analytics data

Pro Tier

  • • 1,000 requests per minute
  • • 50,000 requests per day
  • • API key required
  • • Enhanced analytics + historical data

Getting Started

1. Make Your First Request

curl -X GET "https://helix-analytics.vercel.app/api/flow?token=0xA0b86a33E6417c5F8d35cA78c8294ba20F8e2a6D" \
  -H "Accept: application/json"

2. Handle Responses

All API responses are in JSON format. Check the HTTP status code for success (200) or error states.

3. Implement Error Handling

Always implement proper error handling for network failures, rate limits, and invalid responses.