Skip to content

Crypto Data API (Surf)

83 endpoints across 12 domains via Surf. Exchange data (16 CEXes), Market Overview (rankings/fear-greed/ETF flows/liquidations/technical signals), On-Chain SQL (80+ ClickHouse tables across 7 networks), Wallet Intelligence (100M+ labeled wallets across 13 networks), Social/CT (Twitter mindshare/KOL tracking), Token Analytics, News, DeFi Protocols, VC Funds, Prediction Markets, and more. Standard $0.0075/call, Premium SQL $0.02/call.

Base URL: https://api.jarvisclaw.ai/v1/marketplace/surf

Dedicated Prediction Markets API

This page includes 17 prediction market endpoints via Surf. If you primarily need prediction data, consider the dedicated Prediction Markets (Predexon) service — 58 endpoints, deeper data (orderbooks, candlesticks, leaderboards, arbitrage), and lower pricing ($0.001/call vs $0.0075/call).

Pricing

TierPriceIncludes
Standard$0.0075/callexchange, market, social, wallet, token, news, fund, search, prediction-market, project, web
Premium SQL$0.02/callonchain/query, onchain/sql, onchain/schema

Exchange (7 endpoints)

EndpointDescription
GET /exchange/marketsTrading pairs catalog — list all available trading pairs
GET /exchange/priceCEX ticker price (params: pair, exchange)
GET /exchange/perpPerpetual contract snapshot — OI, funding rate, mark price (params: pair)
GET /exchange/depthOrder book depth — bids and asks (params: pair, exchange)
GET /exchange/klinesOHLCV candlesticks (params: pair, interval, limit)
GET /exchange/funding-historyFunding rate history (params: pair)
GET /exchange/long-short-ratioLong/short ratio (params: pair)

Example: Exchange Price

bash
curl "https://api.jarvisclaw.ai/v1/marketplace/surf/exchange/price?pair=BTC-USDT" \
  -H "Authorization: Bearer sk-your-api-key"
json
{
  "pair": "BTC-USDT",
  "exchange": "binance",
  "price": 98500.25,
  "volume_24h": 25000000000,
  "change_24h": 2.35,
  "timestamp": 1717200000
}

Market (11 endpoints)

EndpointDescription
GET /market/rankingToken rankings by market cap (params: limit, category)
GET /market/fear-greedFear & Greed index
GET /market/futuresFutures overview — aggregate futures data
GET /market/priceToken price history (params: symbol, interval)
GET /market/etfETF flow history — BTC/ETH ETF inflows/outflows
GET /market/optionsOptions market data (params: symbol)
GET /market/liquidation/exchange-listLiquidations by exchange
GET /market/liquidation/orderLarge liquidation orders (params: limit)
GET /market/liquidation/chartLiquidation chart data (params: symbol)
GET /market/onchain-metricOn-chain metrics — NUPL, SOPR, MVRV (params: symbol, metric)
GET /market/price-indicatorTechnical indicators — RSI, MACD, Bollinger (params: symbol, indicator)

Example: Fear & Greed

json
{
  "value": 72,
  "label": "Greed",
  "previous_close": 68,
  "timestamp": 1717200000
}

On-chain (7 endpoints)

EndpointDescription
GET /onchain/bridge/rankingBridge ranking — cross-chain bridge volume and TVL
GET /onchain/yield/rankingYield pool ranking — top DeFi yield opportunities
GET /onchain/gas-priceGas price across chains (params: chain)
GET /onchain/txTransaction details (params: hash, chain)
GET /onchain/schemaClickHouse schema — available tables and columns
POST /onchain/queryStructured blockchain query (params: query, limit)
POST /onchain/sqlRaw SQL query against ClickHouse tables (params: sql)

Example: SQL Query

bash
curl -X POST "https://api.jarvisclaw.ai/v1/marketplace/surf/onchain/sql" \
  -H "Authorization: Bearer sk-your-api-key" \
  -H "Content-Type: application/json" \
  -d '{"sql": "SELECT from_address, SUM(value/1e18) as total_eth FROM ethereum.transactions WHERE block_time > now() - interval 1 hour GROUP BY from_address ORDER BY total_eth DESC LIMIT 10"}'
json
{
  "columns": ["from_address", "total_eth"],
  "rows": [
    ["0xDef456...", 1250.5],
    ["0x789Abc...", 890.2]
  ],
  "row_count": 2,
  "execution_time_ms": 3200
}

Wallet (6 endpoints)

EndpointDescription
GET /wallet/detailWallet profile — labels, portfolio, risk score (params: address)
GET /wallet/historyTransaction history (params: address, limit)
GET /wallet/net-worthNet-worth time series (params: address)
GET /wallet/transfersTransfer history (params: address, limit)
GET /wallet/protocolsDeFi positions (params: address)
POST /wallet/labels/batchBatch label lookup — max 100 addresses (params: addresses[])

Example: Wallet Detail

json
{
  "address": "0xBE0eB53F46cd790Cd...",
  "labels": ["Binance", "Hot Wallet"],
  "net_worth_usd": 2500000000,
  "chains": ["ethereum", "bsc", "arbitrum"],
  "risk_score": 12
}

Social (11 endpoints)

EndpointDescription
GET /social/detailSocial analytics — engagement metrics (params: handle)
GET /social/rankingMindshare ranking — top influencers (params: limit)
GET /social/smart-followers/historySmart followers growth (params: handle)
GET /social/mindshareToken mention share (params: symbol)
GET /social/tweetsBulk tweet lookup (params: ids)
GET /social/tweet/repliesTweet replies (params: tweet_id, limit)
GET /social/userTwitter profile (params: handle)
GET /social/user/followersUser followers (params: handle, limit)
GET /social/user/followingUser following (params: handle, limit)
GET /social/user/postsRecent tweets (params: handle, limit)
GET /social/user/repliesRecent replies (params: handle, limit)

Token (4 endpoints)

EndpointDescription
GET /token/tokenomicsToken unlock/vesting schedule (params: symbol)
GET /token/dex-tradesDEX trade history (params: address, interval, limit)
GET /token/holdersTop holders by balance (params: address, chain, limit)
GET /token/transfersTransfer history (params: address, interval, limit)

Fund (3 endpoints)

EndpointDescription
GET /fund/detailVC fund profile (params: slug)
GET /fund/portfolioFund holdings (params: slug)
GET /fund/rankingTop VC funds (params: metric, limit, offset)

Project (3 endpoints)

EndpointDescription
GET /project/detailProject profile (params: slug)
GET /project/defi/metricsDeFi protocol metrics (params: metric)
GET /project/defi/rankingDeFi ranking by TVL (params: limit)

News (2 endpoints)

EndpointDescription
GET /news/feedAI-curated news feed (params: symbol, limit)
GET /news/detailArticle detail (params: id)

Search (11 endpoints)

EndpointDescription
GET /search/airdropSearch airdrops (params: q, limit)
GET /search/eventsSearch crypto events (params: q, limit)
GET /search/kalshiSearch Kalshi markets (params: q, limit)
GET /search/polymarketSearch Polymarket (params: q, limit)
GET /search/webWeb search (params: q, limit)
GET /search/projectSearch crypto projects (params: q, limit)
GET /search/newsSearch news articles (params: q, limit)
GET /search/walletSearch labeled wallets (params: q, limit)
GET /search/fundSearch VC funds (params: q, limit)
GET /search/social/peopleSearch influencers (params: q, limit)
GET /search/social/postsSearch social posts (params: q, limit)

Prediction Market (17 endpoints)

EndpointDescription
GET /prediction-market/category-metricsCategory aggregate stats
GET /prediction-market/polymarket/rankingTop Polymarket markets by volume
GET /prediction-market/polymarket/tradesRecent trades (params: ticker, limit)
GET /prediction-market/polymarket/marketsBrowse markets (params: market_slug, limit, category)
GET /prediction-market/polymarket/eventsGrouped markets by event (params: event_slug, limit)
GET /prediction-market/polymarket/pricesPrice history (params: condition_id)
GET /prediction-market/polymarket/volumesVolume history (params: condition_id)
GET /prediction-market/polymarket/open-interestOutstanding positions (params: condition_id)
GET /prediction-market/polymarket/positionsUser positions (params: address)
GET /prediction-market/polymarket/activityRecent activity (params: address, limit)
GET /prediction-market/kalshi/rankingTop Kalshi markets
GET /prediction-market/kalshi/marketsBrowse Kalshi markets (params: market_ticker, limit, category)
GET /prediction-market/kalshi/eventsKalshi events (params: limit)
GET /prediction-market/kalshi/pricesPrice history (params: ticker)
GET /prediction-market/kalshi/tradesRecent trades (params: ticker, limit)
GET /prediction-market/kalshi/volumesVolume history (params: ticker)
GET /prediction-market/kalshi/open-interestOutstanding contracts (params: ticker)

Web (1 endpoint)

EndpointDescription
GET /web/fetchFetch + clean web page (params: url)

Code Examples

bash
# x402 payment is handled automatically by the SDK
# These examples show the raw HTTP calls — in practice use the SDK

# Get BTC-USDT price
curl "https://api.jarvisclaw.ai/v1/marketplace/surf/exchange/price?pair=BTC-USDT"

# Get market rankings
curl "https://api.jarvisclaw.ai/v1/marketplace/surf/market/ranking?limit=10"

# Get Fear & Greed index
curl "https://api.jarvisclaw.ai/v1/marketplace/surf/market/fear-greed"

# On-chain SQL query
curl -X POST "https://api.jarvisclaw.ai/v1/marketplace/surf/onchain/sql" \
  -H "Content-Type: application/json" \
  -d '{"sql": "SELECT from_address, SUM(value/1e18) as total_eth FROM ethereum.transactions WHERE block_time > now() - interval 1 hour GROUP BY from_address ORDER BY total_eth DESC LIMIT 10"}'

# Search Polymarket
curl "https://api.jarvisclaw.ai/v1/marketplace/surf/search/polymarket?q=bitcoin&limit=5"
python
from jarvisclaw import MarketplaceClient

# ─── Option A: Base chain (EVM) ───
# Hex private key → USDC on Base (Chain ID 8453)
client = MarketplaceClient(private_key="0x<evm-private-key>")

# ─── Option B: Solana ───
# Base58 keypair → USDC SPL on Solana mainnet
client = MarketplaceClient(private_key="<solana-bs58-keypair>")

# SDK auto-detects chain from key format — no config needed
# All calls below work identically on either chain:

# Get BTC-USDT price
price = client.call("surf", "/exchange/price", params={"pair": "BTC-USDT"})
print(f"BTC: ${price['price']:,.2f} ({price['change_24h']:+.2f}%)")

# Get market rankings
rankings = client.call("surf", "/market/ranking", params={"limit": 10})
for coin in rankings["rankings"]:
    print(f"#{coin['rank']} {coin['symbol']}: ${coin['price']:,.2f}")

# Fear & Greed index
fg = client.call("surf", "/market/fear-greed")
print(f"Fear & Greed: {fg['value']} ({fg['label']})")

# On-chain SQL query (POST)
result = client.call("surf", "/onchain/sql", method="POST",
    json={"sql": "SELECT from_address, SUM(value/1e18) as total_eth FROM ethereum.transactions WHERE block_time > now() - interval '1 hour' GROUP BY from_address ORDER BY total_eth DESC LIMIT 10"})
for row in result["rows"]:
    print(f"  {row[0]}: {row[1]:.4f} ETH")

# Search prediction markets
markets = client.call("surf", "/search/polymarket", params={"q": "bitcoin", "limit": 5})
for m in markets["results"]:
    print(f"  {m['title']} — vol: ${m['volume']:,.0f}")

# Wallet intelligence
wallet = client.call("surf", "/wallet/detail", params={"address": "0xBE0eB53F46cd790Cd..."})
print(f"Labels: {wallet['labels']}, Net worth: ${wallet['net_worth_usd']:,.0f}")
go
package main

import (
    "context"
    "fmt"
    jc "github.com/api-jarvisclaw/go-sdk"
)

func main() {
    ctx := context.Background()

    // x402 Agent wallet — pays per-call via USDC on Base (Chain ID 8453)
    // For Solana, pass a base58 keypair instead of hex EVM key
    mc, _ := jc.NewMarketplaceClient(jc.WithPrivateKey("0x<evm-private-key>"))

    // Get BTC-USDT price
    price, _ := mc.Call(ctx, "surf", "/exchange/price",
        jc.WithParams(map[string]string{"pair": "BTC-USDT"}))
    fmt.Printf("BTC price: %v\n", price["price"])

    // Get market rankings
    rankings, _ := mc.Call(ctx, "surf", "/market/ranking",
        jc.WithParams(map[string]string{"limit": "10"}))
    fmt.Printf("Top coins: %v\n", rankings["rankings"])

    // Fear & Greed index
    fg, _ := mc.Call(ctx, "surf", "/market/fear-greed", nil)
    fmt.Printf("Fear & Greed: %v (%v)\n", fg["value"], fg["label"])

    // On-chain SQL query
    result, _ := mc.Call(ctx, "surf", "/onchain/sql",
        jc.WithMethod("POST"),
        jc.WithJSON(map[string]any{
            "sql": "SELECT from_address, SUM(value/1e18) as total_eth FROM ethereum.transactions WHERE block_time > now() - interval '1 hour' GROUP BY from_address ORDER BY total_eth DESC LIMIT 10",
        }),
    )
    fmt.Printf("Rows: %v\n", result["rows"])

    // Search prediction markets
    markets, _ := mc.Call(ctx, "surf", "/search/polymarket",
        jc.WithParams(map[string]string{"q": "bitcoin", "limit": "5"}))
    fmt.Printf("Markets: %v\n", markets["results"])

    // Wallet intelligence
    wallet, _ := mc.Call(ctx, "surf", "/wallet/detail",
        jc.WithParams(map[string]string{"address": "0xBE0eB53F46cd790Cd..."}))
    fmt.Printf("Labels: %v, Net worth: %v\n", wallet["labels"], wallet["net_worth_usd"])
}

Errors

CodeNameDescriptionResolution
400invalid_pairTrading pair format is invalidUse format: BASE-QUOTE (e.g. BTC-USDT)
400invalid_paramsRequired parameter missing or malformedCheck endpoint documentation for required parameters
400sql_syntax_errorOn-chain SQL query has syntax errorsValidate SQL syntax; use standard SELECT statements only
402payment_requiredx402 payment not provided or insufficient balanceEnsure wallet has sufficient USDC balance on Base or Solana
404not_foundResource not found (invalid slug, address, or ID)Verify the identifier exists
408query_timeoutSQL query took too long to execute (>30s)Add LIMIT clause or simplify the query
429rate_limitedToo many requestsBack off and retry with exponential delay

Limitations

  • Premium SQL queries have a 30-second execution timeout — add LIMIT clauses to complex queries
  • Social/CT data covers Twitter/X only — no Reddit, Discord, or Telegram
  • Wallet intelligence covers 13 networks — other chains may have incomplete labels
  • No WebSocket streaming — all endpoints are request/response (polling)
  • On-chain SQL tables updated with ~5 minute delay from chain tip
  • Batch label lookup limited to 100 addresses per request
  • Prediction market data covers Polymarket and Kalshi only

Pay per call. No subscription. No rate limits.