arbiterapi
v0.2.0
Published
TypeScript SDK for the Arbiter prediction market API
Maintainers
Readme
@arbiterapi/sdk
TypeScript SDK for the Arbiter prediction market API. Unified access to Polymarket and Kalshi with normalized data, historical trades, OHLCV candles, and real-time WebSocket streaming.
Install
npm install @arbiterapi/sdkQuick Start
import { ArbiterClient } from "@arbiterapi/sdk";
const client = new ArbiterClient({ apiKey: "YOUR_API_KEY" });
// List markets
const markets = await client.markets.list({ limit: 10 });
// Get a specific market
const market = await client.markets.get("poly_0x3a75...");
// Search markets
const results = await client.markets.search({ q: "bitcoin" });
// Get orderbook
const book = await client.markets.orderbook("poly_0x3a75...");
// Get trades
const trades = await client.markets.trades("poly_0x3a75...");
// Get OHLCV candles
const candles = await client.markets.candles("poly_0x3a75...", {
interval: "1h",
start: new Date("2026-01-01"),
end: new Date(),
});
// Get current or historical price
const price = await client.markets.price("poly_0x3a75...");
const historicalPrice = await client.markets.price("poly_0x3a75...", {
at_time: 1774650000,
});
// Events (grouped markets)
const events = await client.events.list({ limit: 10 });
const event = await client.events.get("us-presidential-election-2028");
// Cross-platform matching
const matches = await client.matching.list({ confidence: "high" });
// Wallet analytics (Polymarket)
const wallet = await client.wallets.get("0x1234...");
const pnl = await client.wallets.pnl("0x1234...");
const positions = await client.wallets.positions("0x1234...");
// Health check (no auth)
const health = await client.health();API Reference
Full documentation at docs.arbiterapi.com.
Get an API Key
Sign up at arbiterapi.com/signup.
