Python wrapper for the Sirius Prediction Market API — real-time prediction markets, trading signals, sentiment, sports odds, and more.
Project description
Sirius Prediction Market API
Python wrapper for the Sirius Prediction Market API on RapidAPI.
Access real-time prediction markets, AI-generated trading signals, market sentiment, sports odds, weather data, and cross-platform odds comparison — all from a single, zero-dependency package.
Installation
pip install sirius-prediction-api
Quick Start
from sirius_prediction_api import SiriusAPI
api = SiriusAPI("your-rapidapi-key")
# Check API status
print(api.health())
# Get active prediction markets
markets = api.markets()
for market in markets:
print(market["question"], market["odds"])
Get Your API Key
- Go to RapidAPI - Sirius Prediction Market API
- Subscribe to a plan (free tier available)
- Copy your
X-RapidAPI-Keyfrom the dashboard
Endpoints
Free Tier
api = SiriusAPI("your-key")
# Active prediction markets with odds
markets = api.markets()
# Trading signals with optional filters
signals = api.signals(limit=10, layer="L1", min_gap=0.10)
# Historical signals with outcomes
history = api.signals_history()
# Market sentiment — Fear & Greed + long/short ratios
sentiment = api.sentiment()
# Sports odds (ESPN + Kalshi)
sports = api.sports()
# Weather-related prediction data
weather = api.weather()
# Cross-platform odds comparison
odds = api.odds()
Basic Tier
# Bot performance — win rate, PnL, track record
performance = api.performance()
# Full trade history with entry/exit details
trades = api.trades()
Pro Tier
# AI brain — optimization decisions and reasoning
brain = api.brain()
Signal Layers
The API provides signals from multiple detection layers:
| Layer | Source | Description |
|---|---|---|
| L1 | Price lag | Cross-platform price discrepancies |
| L2 | News | News-driven market moves |
| L3 | Weather | Weather-based predictions |
| L4 | Kalshi | Kalshi platform arbitrage |
| L5 | Sports | ESPN + Kalshi sports signals |
Filter by layer:
# Only price-lag signals with at least 10% gap
signals = api.signals(layer="L1", min_gap=0.10)
Error Handling
The library raises specific exceptions for different error types:
from sirius_prediction_api import (
SiriusAPI,
SiriusAuthError,
SiriusForbiddenError,
SiriusRateLimitError,
SiriusAPIError,
)
api = SiriusAPI("your-key")
try:
brain = api.brain()
except SiriusAuthError:
print("Invalid API key")
except SiriusForbiddenError:
print("Upgrade your plan for this endpoint")
except SiriusRateLimitError:
print("Rate limited — slow down or upgrade")
except SiriusAPIError as e:
print(f"API error [{e.status_code}]: {e.message}")
| Exception | HTTP Code | Meaning |
|---|---|---|
SiriusAuthError |
401 | Invalid or missing API key |
SiriusForbiddenError |
403 | Endpoint not in your tier |
SiriusNotFoundError |
404 | Resource not found |
SiriusRateLimitError |
429 | Rate limit exceeded |
SiriusServerError |
5xx | Server-side error |
SiriusAPIError |
any | Base class for all errors |
Configuration
api = SiriusAPI(
api_key="your-key",
timeout=60, # request timeout in seconds (default: 30)
)
Requirements
- Python 3.8+
- Zero dependencies — uses only
urllib.requestfrom the standard library
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sirius_prediction_api-1.1.0.tar.gz.
File metadata
- Download URL: sirius_prediction_api-1.1.0.tar.gz
- Upload date:
- Size: 9.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5a6de503f80bb89cfdb1990c1f1e07421de3e68dbf5c74d69c537f3306d0904e
|
|
| MD5 |
a544a5cfd2c3395061afc05de662189c
|
|
| BLAKE2b-256 |
b8ad12d510dece30bff64e572d9fdd91274ff1ca21ab56b93119a2bfb034aa42
|
File details
Details for the file sirius_prediction_api-1.1.0-py3-none-any.whl.
File metadata
- Download URL: sirius_prediction_api-1.1.0-py3-none-any.whl
- Upload date:
- Size: 8.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f0edcf8b5c7b9f2ed43634f944ffd1cc8cfa0c6e5cca5809b3d3b5520b07d6a6
|
|
| MD5 |
8c1d52b75441f88ea8ecf6704bb5c4a5
|
|
| BLAKE2b-256 |
5007cabb42f600c023e633157cbd083ffeb94447979bd034ec7d54b1f29fd169
|