BTSE · AsyncAPI Specification
OTC WebSocket API
Version 1.0.0
OTC WebSocket stream for real-time OTC quote data. **Production Endpoint:** `wss://ws.btse.com/ws/otc` **Testnet Endpoint:** `wss://testws.btse.io/ws/otc` **Authentication:** Private topics require sending an `authKeyExpires` message with HMAC-SHA384 signature: `HMAC-SHA384(secret, "/ws/otc" + nonce)`
View Spec
View on GitHub
CompanyCryptocurrencyExchangeTradingDigital AssetsFuturesWebSocketAsyncAPIEventsWebSockets
Channels
auth
WebSocket Authentication
Authenticate the session to access private topics (Quote Stream). Signature: `HMAC-SHA384(secret, "/ws/otc" + nonce)` **Signature example:** ```shell echo -n "/ws/otc1624985375123" | openssl dgst -sha384 -hmac "" ``` Args array: - Index 0: API key - Index 1: Current timestamp (nonce) - Index 2: HMAC-SHA384 hex signature
quote
Subscribe / Unsubscribe Quote Stream
Subscribe to continuous OTC price quotes. Prices are pushed as market conditions change. Requires WebSocket authentication. To **accept** a quote, use the `buyQuoteId` or `sellQuoteId` from the stream with the Accept Quote REST endpoint. **REST vs WebSocket — when to use which:** - **REST `POST /public-api/otc/v1/quotes`** — request a single quote with a 5-second TTL. This is the standard one-shot RFQ workflow. - **WebSocket `quote` stream (this channel)** — subscribe to a continuous price feed for high-frequency consumers. Independent of the REST RFQ. **Subscribe payload differs from spot/futures.** OTC uses `op: quote` with a top-level `symbol` (and optional `side`, `quantity`); it does **not** use the spot/futures `{op: "subscribe", args: [...]}` form. Sending a spot/futures-style payload is silently acked with `{event: "subscribe", channel: []}` and produces no data. ```jsonc // ✅ OTC subscribe { "op": "quote", "symbol": "BTC-USD", "quantity": { "quantity": 1, "currency": "BTC" } } // ❌ Spot/futures style — does NOT work for OTC { "op": "subscribe", "args": ["quote"] } ``` **Operations:** - `quote`: subscribe to quote stream - `unsubscribe-quote`: unsubscribe from a specific quote stream - `unsubscribe-quote-all`: unsubscribe from all quote streams
Messages
QuoteSubscribeRequest
QuoteSubscribeRequest
Subscribe to quote stream
QuoteUnsubscribeRequest
QuoteUnsubscribeRequest
Unsubscribe from a specific quote stream
QuoteUnsubscribeAllRequest
QuoteUnsubscribeAllRequest
Unsubscribe from all quote streams
QuoteStreamMessage
QuoteStreamMessage
Real-time OTC quote update
Servers
wss
production
wss://ws.btse.com/ws/otc
Production
wss
testnet
wss://testws.btse.io/ws/otc
Testnet
AsyncAPI Specification
Work with this as data
Every AsyncAPI spec here is available over the APIs.io API and to AI agents over MCP.