Reference

TypeScript SDK

Typed TypeScript client for the Scanna API (@scanna/sdk).

Pre-release

@scanna/sdk is pre-release (0.1.x) and not yet published to npm. The interface below is what ships; package publishing is coming soon. Until then you can build against the REST API directly.

A zero-dependency TypeScript client for the Scanna API, with dual ESM + CJS output and full types.

npm install @scanna/sdk
import { ScannaClient } from '@scanna/sdk';

const scanna = new ScannaClient({ apiKey: 'sk_...' });

// Trending markets
const hot = await scanna.getHot({ limit: 5 });
for (const m of hot.markets) {
  console.log(`${m.question}: heat=${m.heat_score.toFixed(2)}`);
}

// Mispricing signal
const pred = await scanna.getLivePredict({ marketId: '0x...' });
console.log(`Market: ${pred.market_price}, Model: ${pred.predicted_probability}, Divergence: ${pred.divergence}`);

Methods

MethodEndpointDescription
getHot()GET /hotTrending markets by heat score
getHeat()POST /heatSingle-market deep dive
getSignals()GET /signals6-factor signal analysis
getPredict()GET /predictAI prediction (resolved model)
getLivePredict()GET /live-predictLive mispricing signal
getRiskScore()GET /risk-scoreMarket risk grade (A–F)
getArbitrage()GET /arbitrageArbitrage scanner
getInsiderScore()GET /insider-scoreWallet insider risk (0–100)
getClusters()GET /clustersWallet entity clustering
getSmartMoney()GET /smart-moneySmart money leaderboard
getDivergence()GET /divergenceCross-venue price gaps
getExport()GET /exportML training data
getHealth()GET /healthHealth check

Error handling

import { ScannaClient, AuthError, NotFoundError, RateLimitError } from '@scanna/sdk';

Errors are typed, so you can catch AuthError, NotFoundError, and RateLimitError distinctly.