Quote Stream
WSProduction
wss://ws.btse.com/ws/otcTestnetwss://testws.btse.io/ws/otcSubscribe 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
quotestream (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.
// β
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 streamunsubscribe-quote: unsubscribe from a specific quote streamunsubscribe-quote-all: unsubscribe from all quote streams
Request Parametersβ
| Name | Type | Required | Description |
|---|---|---|---|
| op | String | Yes | Subscribe operation |
| symbol | String | Yes | Market symbol (from getMarket) |
| side | String | No | buy Β· sell (case sensitive). Both sides returned when omitted |
| clOrderId | String | No | Custom client order ID |
| quantity | Object | Yes |
Response Contentβ
| Name | Type | Required | Description |
|---|---|---|---|
| topic | String | No | Always quote |
| buyQuoteId | String | No | Quote ID for buy side. null if not subscribed to buy or not authenticated |
| sellQuoteId | String | No | Quote ID for sell side. null if not subscribed to sell or not authenticated |
| clOrderId | String | No | Client order ID |
| buyQuantity | Double | No | Buy quantity. null if not subscribed to buy side |
| buyUnitPrice | Double | No | Unit buy price. null if not subscribed to buy side |
| buyTotalAmount | Double | No | Total buy amount. null if not subscribed to buy side |
| sellQuantity | Double | No | Sell quantity. null if not subscribed to sell side |
| sellUnitPrice | Double | No | Unit sell price. null if not subscribed to sell side |
| sellTotalAmount | Double | No | Total sell amount. null if not subscribed to sell side |
| status | String | No | Response status (null on normal updates) |
| reason | String | No | Error reason if present |
example
Request
{
"op": "quote",
"symbol": "BTC-USD",
"side": "buy",
"clOrderId": "ClientOrder1",
"quantity": {
"quantity": 1,
"currency": "BTC"
}
}
Request
{
"op": "unsubscribe-quote",
"symbol": "BTC-USD",
"clOrderId": "ClientOrder1",
"quantity": {
"quantity": 1,
"currency": "BTC"
}
}
Request
{
"op": "unsubscribe-quote-all"
}
Response
{
"topic": "quote",
"buyQuoteId": "015f05ba-1d55-46d7-94d9-214229414ae7",
"sellQuoteId": "0683a41a-a2ad-467b-99b3-241f3ab0cec4",
"clOrderId": null,
"buyQuantity": 10,
"buyUnitPrice": 47865.580838,
"buyTotalAmount": 478655.80838,
"sellQuantity": 10,
"sellUnitPrice": 47649.40351972,
"sellTotalAmount": 476494.0352,
"status": null,
"reason": null
}