API Documentation
Programmatic access to iComBot BTC direction signals for Polymarket. Available on the Pro plan. REST + WebSocket.
Quickstart
Once you have a Pro subscription, generate an API key from your account page. Pass it in the Authorization header as a Bearer token.
curl -H "Authorization: Bearer YOUR_API_KEY" \
https://icombot.com/api/v1/signal
Authentication
All REST endpoints require an API key passed as a Bearer token:
Authorization: Bearer <api_key>
WebSocket connections use a query-string parameter instead, because browsers cannot set custom headers on WebSocket upgrade:
wss://icombot.com/api/v1/ws?key=<api_key>
Keep your API key secret. You can rotate it from the account page at any time.
Endpoints
| Method | Path | Description |
|---|---|---|
| GET | /api/v1/signal | Current live signal (canonical object) |
| GET | /api/v1/signal/history | Recent signal history (paginated) |
| GET | /api/v1/stats | Performance stats (win rates, totals) |
| GET | /api/v1/status | Service health and API key status |
| WSS | /api/v1/ws | Pro real-time signal push over WebSocket |
Response Example
GET /api/v1/signal returns the canonical signal object:
{
"roundId": "btc-updown-5m-1772164500",
"direction": "UP",
"strength": "STRONG",
"confidence": 0.83,
"timestamp": 1772164520,
"expiresAt": 1772164800,
"result": "PENDING"
}
Enum values:
direction:UP|DOWN|NONEstrength:STRONG|MODERATE|WEAKresult:WIN|LOSE|PENDING|VOID
WebSocket
The WebSocket feed pushes a new signal event as soon as each 5-minute round emits. Connect with your API key as a query parameter:
const ws = new WebSocket(
"wss://icombot.com/api/v1/ws?key=YOUR_API_KEY"
);
ws.onmessage = (ev) => {
const signal = JSON.parse(ev.data);
console.log(signal.direction, signal.confidence);
};
Pro subscribers also get a heartbeat frame every 30 seconds to keep the connection alive.
Rate Limits
| Plan | REST limit | WebSocket |
|---|---|---|
| Free | — | — |
| Basic | — | 1 connection |
| Pro | 60 req/min | 1 connection |
Exceeding the rate limit returns HTTP 429 with a Retry-After header.
Error Codes
| HTTP | Error | Meaning |
|---|---|---|
| 400 | bad_request | Malformed query or body |
| 401 | unauthorized | Missing or invalid API key |
| 403 | forbidden | Your plan does not include this endpoint |
| 404 | not_found | Resource does not exist |
| 429 | rate_limited | Exceeded request quota |
| 500 | internal | Server error — please retry |