Subscriptions
Authentication
Your IP address must be whitelisted to connect. Once whitelisted via the /ip/add#post-ipadd)
endpoint, authentication is automatic - no headers or query parameters needed.
The server checks the client IP against the whitelist. If found, the connection is authenticated under the associated AlphaHype seat holder's address.
IP whitelisting can be managed on alphaticks.
Subscription Types
The subscription field in subscribe/unsubscribe messages is a discriminated union based on the type property.
| Type | Description | Updates |
|---|---|---|
l1Book | Top of book | Periodic snapshots |
l2Book | Aggregated price levels | Periodic snapshots |
l3Book | Order-level, lightweight | Snapshot + incremental |
l4Book | Order-level, full detail | Snapshot + incremental |
trades | Trade stream | Real-time |
candle | Candlestick data | Real-time |
allMids | All mid prices | Periodic (1s) |
impactPrice | Impact prices | Periodic |
orderUpdates | Order status | Real-time |
userFills | User fills | Real-time |
Coin Parameter
Most subscriptions require a coin parameter:
- Perpetual contracts:
"BTC","ETH","SOL", etc. - Spot markets: Use the
@prefix, e.g.,"@1"for spot asset ID 1
Rate Limits
See Rate Limits for subscription and message limits.
