Back

DOCUMENTATION

Getting Started

prysmic provides real-time insights into capital dynamics in prediction markets through a simple API. Connect to the network, track smart money movements, and stay ahead of emerging trends.

npm install @prysmic/client

Core Concepts

Capital Streams

Real-time feeds of capital inflow and outflow data in prediction markets. Each stream emits updates at market-level granularity. Subscribers receive timely insights into market movements and trends.

• Latency: 200-800ms from market activity

• Data size: 2-8 KB per event

• Retention: 90 days (historical queries supported)

Market Insights

Aggregated data providing insights into significant market movements. Insights include entry points of major players, trend momentum, and predictive analytics. Every insight is independently verifiable.

• Analysis method: Momentum-based trend detection

• Confidence threshold: 3+ significant player confirmations

• Failure mode: Reject on data inconsistency

API Endpoints

GET/v1/capital/:market/:timestamp

Retrieve capital flow data for a specific market at a given timestamp.

POST/v1/streams/subscribe

Subscribe to real-time capital flow stream for specified market and filter criteria.

GET/v1/insights/:market/:address

Query market insights for a specific address with proof attestation.

POST/v1/verify

Submit data for independent verification against capital flow analytics.

Integration Guide

Basic Connection

import { prysmicClient } from '@prysmic/client'

const client = new prysmicClient({
  apiKey: process.env.PRYS_API_KEY,
  network: 'mainnet'
})

// Query single capital flow
const capitalFlow = await client.getCapital('predictionMarket', '2023-10-01T00:00:00Z')
console.log(capitalFlow) // Data for the specified timestamp

Stream Subscription

// Subscribe to capital flow stream
const stream = client.subscribeToStream({
  market: 'predictionMarket',
  filter: { address: '0x...' }
})

stream.on('capital', (data) => {
  console.log('New capital flow data:', data)
})

stream.on('error', (err) => {
  console.error('Stream error:', err)
})

Developer Notes

Rate Limits

Free tier: 100 queries/minute. Staked tier (10K+ $PRSM): 1000 queries/minute. Enterprise: Unlimited (custom $PRSM stake required).

Data Verification

All data includes verification parameters. Client SDK verifies locally by default. Disable with verifyLocal: false to trust network consensus.

Error Handling

Network rejects invalid queries immediately. Failed verifications return verified: false with detailed rejection reason. Never trust unverified data.