Skip to content

Commit 6d62fcd

Browse files
Mlaz-coderootPaperclip-Paperclip
authored
docs(streaming): update concurrent stream cap from 10 to 1 per key (#199)
Policy changed 2026-04-27: every paid tier defaults to 1 concurrent stream with newer-wins displacement. Fleet limits require a maxStreams override via Unkey metadata (contact sales). Updated streaming/overview.mdx, pricing.mdx, and api-reference/websocket.mdx. single-connection.mdx already reflected the correct policy. Co-authored-by: root <root@api-dev.hs.chocopancake.com> Co-authored-by: Paperclip <noreply@paperclip.ing>
1 parent 9c1030f commit 6d62fcd

3 files changed

Lines changed: 12 additions & 7 deletions

File tree

content/en/api-reference/websocket.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -592,7 +592,7 @@ WebSocket frames may also carry the HTTP-style `invalid_api_key`, `tier_restrict
592592
| `1000` | Normal close | Client or server initiated clean close |
593593
| `4001` | Authentication failure | Check your API key |
594594
| `4003` | No streaming access | Add WebSocket add-on ($99/mo) or upgrade to Enterprise |
595-
| `4029` | Stream limit exceeded | Close unused connections (max 10 concurrent) |
595+
| `4029` | Stream limit exceeded | Close unused connections (default: 1 per key; newer connection wins) |
596596

597597
## Sequence Numbers
598598

@@ -895,7 +895,7 @@ Exceeding your stream limit closes the connection with code `4029`. Close unused
895895
8. **Implement reconnection** -- Unlike SSE, WebSocket does not auto-reconnect. Use exponential backoff (1s, 2s, 4s, ...) with `from_seq` replay for brief outages
896896
9. **Wait for `snapshot:complete`** -- This signals all initial data has been sent. Hide loading states after receiving it
897897
10. **Handle `odds:removed`** -- Remove odds from your local state when you receive this message to avoid showing stale data
898-
11. **Close unused connections** -- Each connection counts against your 10-stream limit
898+
11. **Close unused connections** -- Each key allows 1 concurrent stream by default; a second connection on the same key displaces the older one (close `4001`)
899899

900900
## Related
901901

content/en/pricing.mdx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Choose the plan that fits your betting strategy. All plans include access to our
1919
| **Enterprise** | Custom | Custom | Custom | Real-time | All | + History, Futures, SLA |
2020

2121
<Callout type="info">
22-
*Streaming requires the **WebSocket Add-on** ($99/mo) which enables 10 concurrent streaming connections (SSE or WebSocket same add-on covers both transports).
22+
*Streaming requires the **WebSocket Add-on** ($99/mo). All paid tiers default to **1 concurrent stream per key** with newer-wins displacement (a second connection kicks the first). Need multiple simultaneous streams for fleet deployments? [Contact sales](mailto:sales@sharpapi.io). SSE and WebSocket share the same add-on and the same limit.
2323
</Callout>
2424

2525
## Plan Details
@@ -87,9 +87,10 @@ Choose the plan that fits your betting strategy. All plans include access to our
8787

8888
**$99/month** - Add real-time streaming to any paid tier.
8989

90-
- 10 concurrent SSE streams
90+
- 1 concurrent SSE/WebSocket stream per key (newer-wins displacement)
9191
- Sub-second latency
9292
- Works with Hobby, Pro, Sharp, and Enterprise tiers
93+
- Fleet limits (>1 stream) available on request
9394

9495
<Callout type="warning">
9596
The WebSocket add-on requires a paid subscription. Free tier does not support streaming.

content/en/streaming/overview.mdx

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,11 +56,15 @@ SSE automatically reconnects on disconnect. The server uses `Last-Event-ID` to r
5656
| Tier | Streaming Access |
5757
|------|------------------|
5858
| Free | Not available |
59-
| Hobby + Add-on ($99/mo) | 10 concurrent streams |
60-
| Pro + Add-on ($99/mo) | 10 concurrent streams |
61-
| Sharp + Add-on ($99/mo) | 10 concurrent streams |
59+
| Hobby + Add-on ($99/mo) | 1 stream (newer-wins displacement) |
60+
| Pro + Add-on ($99/mo) | 1 stream (newer-wins displacement) |
61+
| Sharp + Add-on ($99/mo) | 1 stream (newer-wins displacement) |
6262
| Enterprise | Included (custom limits) |
6363

64+
<Callout type="warning">
65+
**Newer-wins displacement:** opening a second stream from the same API key closes the first one. One well-managed connection is sufficient for most use cases — see [Single-Connection Patterns](/en/streaming/single-connection) for techniques. Fleet deployments needing multiple simultaneous streams can request a higher limit via [sales](mailto:sales@sharpapi.io).
66+
</Callout>
67+
6468
## Quick Start
6569

6670
### Browser

0 commit comments

Comments
 (0)