diff --git a/content/de/api-reference/account.mdx b/content/de/api-reference/account.mdx index e15a1ff..4b10f5d 100644 --- a/content/de/api-reference/account.mdx +++ b/content/de/api-reference/account.mdx @@ -37,9 +37,9 @@ const response = await fetch( ); const { data } = await response.json(); -console.log(`Tier: ${data.key.tier}`); -console.log(`Rate limit: ${data.limits.requests_per_minute} req/min`); -console.log(`Max books: ${data.limits.max_books}`); +console.log(`Tier: ${data.tier}`); +console.log(`Rate limit: ${data.rate_limit.requests_per_minute} req/min`); +console.log(`Max books: ${data.rate_limit.max_books}`); ``` @@ -52,9 +52,9 @@ response = requests.get( ) account = response.json()['data'] -print(f"Tier: {account['key']['tier']}") +print(f"Tier: {account['tier']}") print(f"Features: {account['features']}") -print(f"Add-ons: {account['addons']}") +print(f"Streaming: {account['streaming']['enabled']}") ``` @@ -66,34 +66,28 @@ print(f"Add-ons: {account['addons']}") ```json { "data": { - "key": { - "id": "key_abc123def456", - "tier": "pro" - }, - "limits": { + "key_id": "key_abc123def456", + "tier": "pro", + "rate_limit": { "requests_per_minute": 300, - "max_streams": 10, - "odds_delay_seconds": 0, "max_books": 15 }, - "features": { - "ev": true, - "arbitrage": true, - "middles": true, - "streaming": true - }, - "addons": ["websocket"], - "streaming_trial": { - "active": false, - "eligible": false, - "used": true, - "activated_at": "2026-01-15T12:00:00Z", - "expires_at": "2026-01-15T16:00:00Z" + "features": [ + "odds", + "schedule", + "ev", + "arbitrage", + "middles", + "low_hold", + "closing_line", + "splits" + ], + "streaming": { + "enabled": true, + "max_connections": 10 } }, - "meta": { - "updated_at": "2026-02-08T14:44:32.123Z" - } + "updated_at": "2026-02-08T14:44:32.123Z" } ``` @@ -122,50 +116,48 @@ X-Request-Id: req_acct123xyz ## Antwortfelder -### Key-Objekt +### `data`-Objekt | Feld | Typ | Beschreibung | |-------|------|-------------| -| `id` | string | Bezeichner für den in dieser Anfrage verwendeten API-Schlüssel | +| `key_id` | string | Bezeichner für den in dieser Anfrage verwendeten API-Schlüssel | | `tier` | string | Abonnementstufe: `free`, `hobby`, `pro`, `sharp` oder `enterprise` | -| `user_id` | string | Benutzerkennung (sofern verfügbar) | - -### Limits-Objekt +| `rate_limit` | object | Rate Limit und Sportsbook-Zugriff — siehe unten | +| `features` | string[] | Auf Ihrer Stufe aktivierte Funktionen — siehe unten | +| `streaming` | object | Verfügbarkeit von SSE-/WebSocket-Streaming — siehe unten | -| Feld | Typ | Beschreibung | -|-------|------|-------------| -| `requests_per_minute` | number | Maximal zulässige API-Anfragen pro Minute | -| `max_streams` | number | Maximale gleichzeitige SSE-/WebSocket-Streams (0 wenn Streaming nicht aktiviert ist) | -| `odds_delay_seconds` | number | Verzögerung der Odds-Daten in Sekunden (`0` für kostenpflichtige Stufen, `60` für kostenlos) | -| `max_books` | number | Maximale Anzahl der für Ihre Stufe zugänglichen Sportsbooks | +Ein `updated_at`-Feld auf oberster Ebene (ISO 8601-Zeitstempel) begleitet `data`. -### Features-Objekt +### `rate_limit`-Objekt | Feld | Typ | Beschreibung | |-------|------|-------------| -| `ev` | boolean | Zugriff auf +EV-Gelegenheitserkennung | -| `arbitrage` | boolean | Zugriff auf Arbitrage-Erkennung | -| `middles` | boolean | Zugriff auf Middles-Erkennung | -| `streaming` | boolean | Zugriff auf SSE-/WebSocket-Streaming (über Add-on, Testversion oder Enterprise) | +| `requests_per_minute` | number | Maximal zulässige API-Anfragen pro Minute auf Ihrer Stufe | +| `max_books` | number | Maximale Anzahl der für Ihre Stufe zugänglichen Sportsbooks (`999` bedeutet unbegrenzt) | -### Add-ons +### `features`-Array -| Feld | Typ | Beschreibung | -|-------|------|-------------| -| `addons` | string[] | Aktive Add-ons (z. B. `["websocket"]`) | +Array von Funktions-Tokens, die auf Ihrer Stufe aktiviert sind. Mögliche Werte: -### Streaming-Testversion-Objekt (optional) +| Wert | Beschreibung | +|-------|-------------| +| `odds` | Live-Odds-Endpoints | +| `schedule` | Event-/Spielplan-Endpoints | +| `ev` | +EV-Gelegenheitserkennung | +| `arbitrage` | Arbitrage-Erkennung | +| `middles` | Middles-Erkennung | +| `low_hold` | Low-Hold-Gelegenheitserkennung | +| `history` | Historische Odds-Endpoints | +| `futures` | Futures-Märkte | +| `closing_line` | Closing-Line-Value-Endpoints | +| `splits` | Öffentliche Wett-Splits | -Vorhanden, wenn der Benutzer eine aktive Testversion hat, berechtigt ist oder bereits eine Testversion genutzt hat. +### `streaming`-Objekt | Feld | Typ | Beschreibung | |-------|------|-------------| -| `active` | boolean | Ob aktuell eine Streaming-Testversion aktiv ist | -| `eligible` | boolean | Ob der Benutzer für eine Testversion berechtigt ist | -| `used` | boolean | Ob der Benutzer seine Testversion bereits genutzt hat | -| `activated_at` | string | ISO 8601-Zeitstempel der Aktivierung der Testversion | -| `expires_at` | string | ISO 8601-Zeitstempel des Ablaufs der Testversion | -| `remaining_hours` | number | Verbleibende Stunden der Testversion | +| `enabled` | boolean | Ob SSE-/WebSocket-Streaming verfügbar ist (über Stufe, Add-on oder Testversion) | +| `max_connections` | number | Maximale Anzahl gleichzeitiger Streaming-Verbindungen (`0` wenn Streaming nicht aktiviert ist) | ## Anwendungsfälle @@ -177,7 +169,7 @@ const { data: account } = await fetch( { headers: { 'X-API-Key': 'YOUR_API_KEY' } } ).then(r => r.json()); -if (!account.features.ev) { +if (!account.features.includes('ev')) { console.log('Upgrade to Pro tier for +EV detection'); } else { // Proceed with EV endpoint diff --git a/content/en/api-reference/account.mdx b/content/en/api-reference/account.mdx index 2a368f1..2236e29 100644 --- a/content/en/api-reference/account.mdx +++ b/content/en/api-reference/account.mdx @@ -37,9 +37,9 @@ const response = await fetch( ); const { data } = await response.json(); -console.log(`Tier: ${data.key.tier}`); -console.log(`Rate limit: ${data.limits.requests_per_minute} req/min`); -console.log(`Max books: ${data.limits.max_books}`); +console.log(`Tier: ${data.tier}`); +console.log(`Rate limit: ${data.rate_limit.requests_per_minute} req/min`); +console.log(`Max books: ${data.rate_limit.max_books}`); ``` @@ -52,9 +52,9 @@ response = requests.get( ) account = response.json()['data'] -print(f"Tier: {account['key']['tier']}") +print(f"Tier: {account['tier']}") print(f"Features: {account['features']}") -print(f"Add-ons: {account['addons']}") +print(f"Streaming: {account['streaming']['enabled']}") ``` @@ -66,34 +66,28 @@ print(f"Add-ons: {account['addons']}") ```json { "data": { - "key": { - "id": "key_abc123def456", - "tier": "pro" - }, - "limits": { + "key_id": "key_abc123def456", + "tier": "pro", + "rate_limit": { "requests_per_minute": 300, - "max_streams": 10, - "odds_delay_seconds": 0, "max_books": 15 }, - "features": { - "ev": true, - "arbitrage": true, - "middles": true, - "streaming": true - }, - "addons": ["websocket"], - "streaming_trial": { - "active": false, - "eligible": false, - "used": true, - "activated_at": "2026-01-15T12:00:00Z", - "expires_at": "2026-01-15T16:00:00Z" + "features": [ + "odds", + "schedule", + "ev", + "arbitrage", + "middles", + "low_hold", + "closing_line", + "splits" + ], + "streaming": { + "enabled": true, + "max_connections": 10 } }, - "meta": { - "updated_at": "2026-02-08T14:44:32.123Z" - } + "updated_at": "2026-02-08T14:44:32.123Z" } ``` @@ -122,50 +116,48 @@ X-Request-Id: req_acct123xyz ## Response Fields -### Key Object +### `data` Object | Field | Type | Description | |-------|------|-------------| -| `id` | string | Identifier for the API key used in this request | +| `key_id` | string | Identifier for the API key used in this request | | `tier` | string | Subscription tier: `free`, `hobby`, `pro`, `sharp`, or `enterprise` | -| `user_id` | string | User identifier (when available) | - -### Limits Object +| `rate_limit` | object | Rate limit and book access — see below | +| `features` | string[] | Capabilities enabled on this tier — see below | +| `streaming` | object | SSE/WebSocket streaming availability — see below | -| Field | Type | Description | -|-------|------|-------------| -| `requests_per_minute` | number | Maximum API requests allowed per minute | -| `max_streams` | number | Maximum concurrent SSE/WebSocket streams (0 if streaming not enabled) | -| `odds_delay_seconds` | number | Odds data delay in seconds (`0` for paid tiers, `60` for free) | -| `max_books` | number | Maximum sportsbooks accessible on your tier | +A top-level `updated_at` field (ISO 8601 timestamp) accompanies `data`. -### Features Object +### `rate_limit` Object | Field | Type | Description | |-------|------|-------------| -| `ev` | boolean | Access to +EV opportunity detection | -| `arbitrage` | boolean | Access to arbitrage detection | -| `middles` | boolean | Access to middles detection | -| `streaming` | boolean | Access to SSE/WebSocket streaming (via add-on, trial, or enterprise) | +| `requests_per_minute` | number | Maximum API requests allowed per minute on your tier | +| `max_books` | number | Maximum sportsbooks accessible on your tier (`999` indicates unlimited) | -### Add-ons +### `features` Array -| Field | Type | Description | -|-------|------|-------------| -| `addons` | string[] | Active add-ons (e.g., `["websocket"]`) | +Array of capability tokens enabled on your tier. Possible values: -### Streaming Trial Object (Optional) +| Value | Description | +|-------|-------------| +| `odds` | Live odds endpoints | +| `schedule` | Event/schedule endpoints | +| `ev` | +EV opportunity detection | +| `arbitrage` | Arbitrage detection | +| `middles` | Middles detection | +| `low_hold` | Low-hold opportunity detection | +| `history` | Historical odds endpoints | +| `futures` | Futures markets | +| `closing_line` | Closing line value endpoints | +| `splits` | Public betting splits | -Present when the user has an active trial, is eligible, or has used a trial. +### `streaming` Object | Field | Type | Description | |-------|------|-------------| -| `active` | boolean | Whether a streaming trial is currently active | -| `eligible` | boolean | Whether the user is eligible for a trial | -| `used` | boolean | Whether the user has already used their trial | -| `activated_at` | string | ISO 8601 timestamp when the trial was activated | -| `expires_at` | string | ISO 8601 timestamp when the trial expires | -| `remaining_hours` | number | Hours remaining on the trial | +| `enabled` | boolean | Whether SSE/WebSocket streaming is available (via tier, add-on, or trial) | +| `max_connections` | number | Maximum concurrent streaming connections (`0` if streaming not enabled) | ## Use Cases @@ -177,7 +169,7 @@ const { data: account } = await fetch( { headers: { 'X-API-Key': 'YOUR_API_KEY' } } ).then(r => r.json()); -if (!account.features.ev) { +if (!account.features.includes('ev')) { console.log('Upgrade to Pro tier for +EV detection'); } else { // Proceed with EV endpoint diff --git a/content/es/api-reference/account.mdx b/content/es/api-reference/account.mdx index 1414dc9..8cf2d3b 100644 --- a/content/es/api-reference/account.mdx +++ b/content/es/api-reference/account.mdx @@ -37,9 +37,9 @@ const response = await fetch( ); const { data } = await response.json(); -console.log(`Tier: ${data.key.tier}`); -console.log(`Rate limit: ${data.limits.requests_per_minute} req/min`); -console.log(`Max books: ${data.limits.max_books}`); +console.log(`Tier: ${data.tier}`); +console.log(`Rate limit: ${data.rate_limit.requests_per_minute} req/min`); +console.log(`Max books: ${data.rate_limit.max_books}`); ``` @@ -52,9 +52,9 @@ response = requests.get( ) account = response.json()['data'] -print(f"Tier: {account['key']['tier']}") +print(f"Tier: {account['tier']}") print(f"Features: {account['features']}") -print(f"Add-ons: {account['addons']}") +print(f"Streaming: {account['streaming']['enabled']}") ``` @@ -66,34 +66,28 @@ print(f"Add-ons: {account['addons']}") ```json { "data": { - "key": { - "id": "key_abc123def456", - "tier": "pro" - }, - "limits": { + "key_id": "key_abc123def456", + "tier": "pro", + "rate_limit": { "requests_per_minute": 300, - "max_streams": 10, - "odds_delay_seconds": 0, "max_books": 15 }, - "features": { - "ev": true, - "arbitrage": true, - "middles": true, - "streaming": true - }, - "addons": ["websocket"], - "streaming_trial": { - "active": false, - "eligible": false, - "used": true, - "activated_at": "2026-01-15T12:00:00Z", - "expires_at": "2026-01-15T16:00:00Z" + "features": [ + "odds", + "schedule", + "ev", + "arbitrage", + "middles", + "low_hold", + "closing_line", + "splits" + ], + "streaming": { + "enabled": true, + "max_connections": 10 } }, - "meta": { - "updated_at": "2026-02-08T14:44:32.123Z" - } + "updated_at": "2026-02-08T14:44:32.123Z" } ``` @@ -122,50 +116,48 @@ X-Request-Id: req_acct123xyz ## Campos de respuesta -### Objeto Key +### Objeto `data` | Campo | Tipo | Descripción | |-------|------|-------------| -| `id` | string | Identificador de la API key utilizada en esta solicitud | +| `key_id` | string | Identificador de la API key utilizada en esta solicitud | | `tier` | string | Nivel de suscripción: `free`, `hobby`, `pro`, `sharp` o `enterprise` | -| `user_id` | string | Identificador del usuario (cuando esté disponible) | - -### Objeto Limits +| `rate_limit` | object | Límite de tasa y acceso a sportsbooks — ver abajo | +| `features` | string[] | Capacidades habilitadas en tu nivel — ver abajo | +| `streaming` | object | Disponibilidad de streaming SSE/WebSocket — ver abajo | -| Campo | Tipo | Descripción | -|-------|------|-------------| -| `requests_per_minute` | number | Número máximo de solicitudes a la API permitidas por minuto | -| `max_streams` | number | Número máximo de streams SSE/WebSocket concurrentes (0 si el streaming no está habilitado) | -| `odds_delay_seconds` | number | Retraso de los datos de cuotas en segundos (`0` para los niveles de pago, `60` para el gratuito) | -| `max_books` | number | Número máximo de sportsbooks accesibles en tu nivel | +Un campo `updated_at` de nivel superior (timestamp ISO 8601) acompaña a `data`. -### Objeto Features +### Objeto `rate_limit` | Campo | Tipo | Descripción | |-------|------|-------------| -| `ev` | boolean | Acceso a la detección de oportunidades +EV | -| `arbitrage` | boolean | Acceso a la detección de arbitraje | -| `middles` | boolean | Acceso a la detección de middles | -| `streaming` | boolean | Acceso al streaming SSE/WebSocket (mediante add-on, prueba o enterprise) | +| `requests_per_minute` | number | Número máximo de solicitudes a la API permitidas por minuto en tu nivel | +| `max_books` | number | Número máximo de sportsbooks accesibles en tu nivel (`999` indica ilimitado) | -### Add-ons +### Array `features` -| Campo | Tipo | Descripción | -|-------|------|-------------| -| `addons` | string[] | Add-ons activos (p. ej., `["websocket"]`) | +Array de tokens de capacidad habilitados en tu nivel. Valores posibles: -### Objeto Streaming Trial (opcional) +| Valor | Descripción | +|-------|-------------| +| `odds` | Endpoints de cuotas en vivo | +| `schedule` | Endpoints de eventos/calendario | +| `ev` | Detección de oportunidades +EV | +| `arbitrage` | Detección de arbitraje | +| `middles` | Detección de middles | +| `low_hold` | Detección de oportunidades low-hold | +| `history` | Endpoints de cuotas históricas | +| `futures` | Mercados de futuros | +| `closing_line` | Endpoints de valor de línea de cierre | +| `splits` | Distribución de apuestas públicas | -Presente cuando el usuario tiene una prueba activa, es elegible o ha utilizado una prueba. +### Objeto `streaming` | Campo | Tipo | Descripción | |-------|------|-------------| -| `active` | boolean | Indica si una prueba de streaming está actualmente activa | -| `eligible` | boolean | Indica si el usuario es elegible para una prueba | -| `used` | boolean | Indica si el usuario ya ha utilizado su prueba | -| `activated_at` | string | Marca de tiempo ISO 8601 de cuándo se activó la prueba | -| `expires_at` | string | Marca de tiempo ISO 8601 de cuándo expira la prueba | -| `remaining_hours` | number | Horas restantes de la prueba | +| `enabled` | boolean | Indica si el streaming SSE/WebSocket está disponible (por nivel, add-on o prueba) | +| `max_connections` | number | Número máximo de conexiones de streaming concurrentes (`0` si el streaming no está habilitado) | ## Casos de uso @@ -177,7 +169,7 @@ const { data: account } = await fetch( { headers: { 'X-API-Key': 'YOUR_API_KEY' } } ).then(r => r.json()); -if (!account.features.ev) { +if (!account.features.includes('ev')) { console.log('Upgrade to Pro tier for +EV detection'); } else { // Proceed with EV endpoint diff --git a/content/pt-BR/api-reference/account.mdx b/content/pt-BR/api-reference/account.mdx index 4daf25f..460fe08 100644 --- a/content/pt-BR/api-reference/account.mdx +++ b/content/pt-BR/api-reference/account.mdx @@ -37,9 +37,9 @@ const response = await fetch( ); const { data } = await response.json(); -console.log(`Tier: ${data.key.tier}`); -console.log(`Rate limit: ${data.limits.requests_per_minute} req/min`); -console.log(`Max books: ${data.limits.max_books}`); +console.log(`Tier: ${data.tier}`); +console.log(`Rate limit: ${data.rate_limit.requests_per_minute} req/min`); +console.log(`Max books: ${data.rate_limit.max_books}`); ``` @@ -52,9 +52,9 @@ response = requests.get( ) account = response.json()['data'] -print(f"Tier: {account['key']['tier']}") +print(f"Tier: {account['tier']}") print(f"Features: {account['features']}") -print(f"Add-ons: {account['addons']}") +print(f"Streaming: {account['streaming']['enabled']}") ``` @@ -66,34 +66,28 @@ print(f"Add-ons: {account['addons']}") ```json { "data": { - "key": { - "id": "key_abc123def456", - "tier": "pro" - }, - "limits": { + "key_id": "key_abc123def456", + "tier": "pro", + "rate_limit": { "requests_per_minute": 300, - "max_streams": 10, - "odds_delay_seconds": 0, "max_books": 15 }, - "features": { - "ev": true, - "arbitrage": true, - "middles": true, - "streaming": true - }, - "addons": ["websocket"], - "streaming_trial": { - "active": false, - "eligible": false, - "used": true, - "activated_at": "2026-01-15T12:00:00Z", - "expires_at": "2026-01-15T16:00:00Z" + "features": [ + "odds", + "schedule", + "ev", + "arbitrage", + "middles", + "low_hold", + "closing_line", + "splits" + ], + "streaming": { + "enabled": true, + "max_connections": 10 } }, - "meta": { - "updated_at": "2026-02-08T14:44:32.123Z" - } + "updated_at": "2026-02-08T14:44:32.123Z" } ``` @@ -122,50 +116,48 @@ X-Request-Id: req_acct123xyz ## Campos da Resposta -### Objeto Key +### Objeto `data` | Campo | Tipo | Descrição | |-------|------|-------------| -| `id` | string | Identificador da chave de API usada nesta requisição | +| `key_id` | string | Identificador da chave de API usada nesta requisição | | `tier` | string | Nível de assinatura: `free`, `hobby`, `pro`, `sharp` ou `enterprise` | -| `user_id` | string | Identificador do usuário (quando disponível) | - -### Objeto Limits +| `rate_limit` | object | Limite de taxa e acesso a sportsbooks — veja abaixo | +| `features` | string[] | Recursos habilitados no seu nível — veja abaixo | +| `streaming` | object | Disponibilidade de streaming SSE/WebSocket — veja abaixo | -| Campo | Tipo | Descrição | -|-------|------|-------------| -| `requests_per_minute` | number | Número máximo de requisições à API permitidas por minuto | -| `max_streams` | number | Número máximo de streams SSE/WebSocket simultâneos (0 se streaming não estiver habilitado) | -| `odds_delay_seconds` | number | Atraso dos dados de odds em segundos (`0` para níveis pagos, `60` para o gratuito) | -| `max_books` | number | Número máximo de sportsbooks acessíveis no seu nível | +Um campo `updated_at` no nível superior (timestamp ISO 8601) acompanha `data`. -### Objeto Features +### Objeto `rate_limit` | Campo | Tipo | Descrição | |-------|------|-------------| -| `ev` | boolean | Acesso à detecção de oportunidades +EV | -| `arbitrage` | boolean | Acesso à detecção de arbitragem | -| `middles` | boolean | Acesso à detecção de middles | -| `streaming` | boolean | Acesso a streaming SSE/WebSocket (via add-on, trial ou enterprise) | +| `requests_per_minute` | number | Número máximo de requisições à API permitidas por minuto no seu nível | +| `max_books` | number | Número máximo de sportsbooks acessíveis no seu nível (`999` indica ilimitado) | -### Add-ons +### Array `features` -| Campo | Tipo | Descrição | -|-------|------|-------------| -| `addons` | string[] | Add-ons ativos (ex.: `["websocket"]`) | +Array de tokens de recurso habilitados no seu nível. Valores possíveis: -### Objeto Streaming Trial (Opcional) +| Valor | Descrição | +|-------|-------------| +| `odds` | Endpoints de odds ao vivo | +| `schedule` | Endpoints de eventos/calendário | +| `ev` | Detecção de oportunidades +EV | +| `arbitrage` | Detecção de arbitragem | +| `middles` | Detecção de middles | +| `low_hold` | Detecção de oportunidades low-hold | +| `history` | Endpoints de odds históricas | +| `futures` | Mercados de futuros | +| `closing_line` | Endpoints de valor de linha de fechamento | +| `splits` | Distribuição pública de apostas | -Presente quando o usuário possui um trial ativo, é elegível ou já utilizou um trial. +### Objeto `streaming` | Campo | Tipo | Descrição | |-------|------|-------------| -| `active` | boolean | Indica se um trial de streaming está atualmente ativo | -| `eligible` | boolean | Indica se o usuário é elegível para um trial | -| `used` | boolean | Indica se o usuário já utilizou seu trial | -| `activated_at` | string | Timestamp ISO 8601 de quando o trial foi ativado | -| `expires_at` | string | Timestamp ISO 8601 de quando o trial expira | -| `remaining_hours` | number | Horas restantes do trial | +| `enabled` | boolean | Indica se o streaming SSE/WebSocket está disponível (por nível, add-on ou trial) | +| `max_connections` | number | Número máximo de conexões de streaming simultâneas (`0` se o streaming não estiver habilitado) | ## Casos de Uso @@ -177,7 +169,7 @@ const { data: account } = await fetch( { headers: { 'X-API-Key': 'YOUR_API_KEY' } } ).then(r => r.json()); -if (!account.features.ev) { +if (!account.features.includes('ev')) { console.log('Upgrade to Pro tier for +EV detection'); } else { // Proceed with EV endpoint diff --git a/public/openapi.json b/public/openapi.json index b936f7c..17b493f 100644 --- a/public/openapi.json +++ b/public/openapi.json @@ -2,8 +2,8 @@ "openapi": "3.1.0", "info": { "title": "SharpAPI", - "version": "2.0.0", - "description": "Real-time sports betting odds API with +EV detection, arbitrage, middles, and low-hold opportunities.\n\n## Authentication\n\nAll authenticated endpoints accept an API key via one of three methods:\n\n| Method | Header / Param | Use case |\n|--------|---------------|----------|\n| `X-API-Key` | `X-API-Key: sk_live_...` | Recommended for server-side |\n| `Authorization` | `Authorization: Bearer sk_live_...` | Standard Bearer token |\n| `api_key` query | `?api_key=sk_live_...` | SSE/EventSource (cannot set headers) |\n\n## Subscription Tiers\n\n| Tier | Rate Limit | Data Delay | Max Books | EV | Arb | Middles | Game State |\n|------|-----------|------------|-----------|-----|-----|---------|------------|\n| Free | 12/min | 60s | 2 (DK, FD) | - | - | - | - |\n| Hobby | 120/min | Real-time | 5 | - | Yes | - | - |\n| Pro | 300/min | Real-time | 15 | Yes | Yes | Yes | - |\n| Sharp | 1000/min | Real-time | All | Yes | Yes | Yes | - |\n| Enterprise | Custom | Real-time | All | Yes | Yes | Yes | Yes |\n\n## Rate Limit Headers\n\nEvery authenticated response includes:\n\n- `X-RateLimit-Limit` - Requests allowed per minute\n- `X-RateLimit-Remaining` - Requests remaining in current window\n- `X-RateLimit-Reset` - Unix timestamp when the window resets\n- `X-Data-Delay` - Odds delay in seconds for your tier (0 = real-time)\n- `X-Request-Id` - Unique request identifier for support\n\n## WebSocket Streaming\n\nThe WebSocket endpoint at `wss://ws.sharpapi.io` is documented separately in [`asyncapi.yaml`](./asyncapi.yaml) (AsyncAPI 3.0). OpenAPI 3.x cannot express WebSocket subprotocols and message channels, so the SSE endpoint (`/stream`) is the only stream covered by this document.\n\n## MCP Server\n\nThe `POST /mcp` endpoint is a Model Context Protocol server (JSON-RPC 2.0 over Streamable HTTP). Tools are self-described at runtime via `tools/list`, so it's documented as a setup guide rather than an OpenAPI path — see [`/sdks/mcp`](https://docs.sharpapi.io/sdks/mcp).\n", + "version": "2.1.0", + "description": "Real-time sports betting odds API with +EV detection, arbitrage, middles, and low-hold opportunities.\n\n## Spec Versioning\n\n`info.version` is bumped on every schema or path change. Minor version (`2.x.0`) for additive changes or breaking shape fixes that align the spec to the live response; major version (`x.0.0`) for backward-incompatible redesigns. Removed paths and renamed fields always bump the minor at minimum. Check `x-generated-at` and `x-commit-sha` for the build provenance of a given snapshot.\n\n## Authentication\n\nAll authenticated endpoints accept an API key via one of three methods:\n\n| Method | Header / Param | Use case |\n|--------|---------------|----------|\n| `X-API-Key` | `X-API-Key: sk_live_...` | Recommended for server-side |\n| `Authorization` | `Authorization: Bearer sk_live_...` | Standard Bearer token |\n| `api_key` query | `?api_key=sk_live_...` | SSE/EventSource (cannot set headers) |\n\n## Subscription Tiers\n\n| Tier | Rate Limit | Data Delay | Max Books | EV | Arb | Middles | Game State |\n|------|-----------|------------|-----------|-----|-----|---------|------------|\n| Free | 12/min | 60s | 2 (DK, FD) | - | - | - | - |\n| Hobby | 120/min | Real-time | 5 | - | Yes | - | - |\n| Pro | 300/min | Real-time | 15 | Yes | Yes | Yes | - |\n| Sharp | 1000/min | Real-time | All | Yes | Yes | Yes | - |\n| Enterprise | Custom | Real-time | All | Yes | Yes | Yes | Yes |\n\n## Rate Limit Headers\n\nEvery authenticated response includes:\n\n- `X-RateLimit-Limit` - Requests allowed per minute\n- `X-RateLimit-Remaining` - Requests remaining in current window\n- `X-RateLimit-Reset` - Unix timestamp when the window resets\n- `X-Data-Delay` - Odds delay in seconds for your tier (0 = real-time)\n- `X-Request-Id` - Unique request identifier for support\n\n## WebSocket Streaming\n\nThe WebSocket endpoint at `wss://ws.sharpapi.io` is documented separately in [`asyncapi.yaml`](./asyncapi.yaml) (AsyncAPI 3.0). OpenAPI 3.x cannot express WebSocket subprotocols and message channels, so the SSE endpoint (`/stream`) is the only stream covered by this document.\n\n## MCP Server\n\nThe `POST /mcp` endpoint is a Model Context Protocol server (JSON-RPC 2.0 over Streamable HTTP). Tools are self-described at runtime via `tools/list`, so it's documented as a setup guide rather than an OpenAPI path — see [`/sdks/mcp`](https://docs.sharpapi.io/sdks/mcp).\n", "contact": { "name": "SharpAPI Support", "url": "https://sharpapi.io", @@ -2391,27 +2391,29 @@ ] }, "example": { - "success": true, "data": { - "key": { - "id": "key_abc123", - "tier": "pro", - "user_id": "user_xyz" - }, - "limits": { + "key_id": "key_abc123", + "tier": "pro", + "rate_limit": { "requests_per_minute": 300, - "max_streams": 0, - "odds_delay_seconds": 0, "max_books": 15 }, - "features": { - "ev": true, - "arbitrage": true, - "middles": true, - "streaming": false - }, - "addons": [] - } + "features": [ + "odds", + "schedule", + "ev", + "arbitrage", + "middles", + "low_hold", + "closing_line", + "splits" + ], + "streaming": { + "enabled": false, + "max_connections": 0 + } + }, + "updated_at": "2026-02-08T14:44:32.123Z" } } } @@ -5322,115 +5324,80 @@ }, "Account": { "type": "object", + "description": "Flat account shape returned by `GET /api/v1/account`. All fields are always present.", "required": [ - "key", - "limits", + "key_id", + "tier", + "rate_limit", "features", - "addons" + "streaming" ], "properties": { - "key": { - "type": "object", - "required": [ - "id", - "tier" - ], - "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string" - }, - "tier": { - "type": "string", - "enum": [ - "free", - "hobby", - "pro", - "sharp", - "enterprise" - ] - }, - "user_id": { - "type": "string" - } - } + "key_id": { + "type": "string", + "description": "Identifier for the API key used in this request." + }, + "tier": { + "type": "string", + "description": "Subscription tier.", + "enum": [ + "free", + "hobby", + "pro", + "sharp", + "enterprise" + ] }, - "limits": { + "rate_limit": { "type": "object", "required": [ "requests_per_minute", - "max_streams", - "odds_delay_seconds", "max_books" ], "properties": { "requests_per_minute": { - "type": "integer" - }, - "max_streams": { - "type": "integer" - }, - "odds_delay_seconds": { - "type": "integer" + "type": "integer", + "description": "Maximum API requests allowed per minute on this tier." }, "max_books": { - "type": "integer" + "type": "integer", + "description": "Maximum sportsbooks accessible on this tier (999 = unlimited)." } } }, "features": { - "type": "object", - "required": [ - "ev", - "arbitrage", - "middles", - "streaming" - ], - "properties": { - "ev": { - "type": "boolean" - }, - "arbitrage": { - "type": "boolean" - }, - "middles": { - "type": "boolean" - }, - "streaming": { - "type": "boolean" - } - } - }, - "addons": { "type": "array", + "description": "Capabilities enabled on this tier.", "items": { - "type": "string" + "type": "string", + "enum": [ + "odds", + "schedule", + "ev", + "arbitrage", + "middles", + "low_hold", + "history", + "futures", + "closing_line", + "splits" + ] } }, - "streaming_trial": { + "streaming": { "type": "object", + "required": [ + "enabled", + "max_connections" + ], "properties": { - "active": { - "type": "boolean" - }, - "eligible": { - "type": "boolean" - }, - "used": { - "type": "boolean" + "enabled": { + "type": "boolean", + "description": "Whether SSE/WebSocket streaming is available (via tier, add-on, or trial)." }, - "activated_at": { - "type": "string", - "format": "date-time" - }, - "expires_at": { - "type": "string", - "format": "date-time" - }, - "remaining_hours": { - "type": "number" + "max_connections": { + "type": "integer", + "description": "Maximum concurrent SSE/WebSocket connections (0 if streaming not enabled)." } } }