Skip to content
Stove Website

Market Data Push ​

Overview ​

Market data push uses WebSocket V2 subscription endpoint, supporting real-time market data push of chain-denominated prices including router_quote and router_price.

Connection Information ​

Connection Endpoint: wss://{host}/ws/v2/stream

Description: WebSocket V2 subscription endpoint, supporting multiple data type subscriptions

Authentication: Institution credentials (API Key + Signature), passed via api_key, timestamp, and signature fields in each message. See WebSocket Authentication

Subscription Request ​

To subscribe to a router stream, send a JSON message in the following format:

json
{
	"id": "550e8400-e29b-41d4-a716-446655440002",
	"method": "market",
	"action": "subscribe",
	"params": {
		"type": "router_quote",
		"chain_id": 97,
		"tickers": ["AAPLs@usex"]
	},
	"api_key": "<your-api-key>",
	"timestamp": "1703123456789",
	"signature": "<computed-signature>"
}

Note: chain_id sits inside params, so it is covered by the signature.

Parameter Description ​

ParameterTypeRequiredDescription
idstringYesRequest unique identifier, recommended to use UUID
methodstringYesFixed value market
actionstringYessubscribe or unsubscribe
paramsobjectYesSubscription parameters
params.typestringYesData type: router_quote, router_price
params.chain_idintYesBlockchain network ID. The pushed price is denominated in this chain's settlement asset
params.tickersarrayYesList of tickers to subscribe
api_keystringYesInstitution API key
timestampstringYesUnix timestamp in milliseconds
signaturestringYesRequest signature. Set as empty string placeholder during signature calculation

See the Instant Swap API Overview for the chain IDs and stablecoin addresses currently supported.

Tickers Format ​

  • Format: symbol@market
  • Market: Market code. See Market enum type description
  • Example: AAPLs@usex

Data Push ​

Router Quote Data Push ​

When subscribing to router_quote, you will receive orderbook data push in the following format:

json
{
	"type": "router_quote",
	"data": {
		"symbol": "AAPLs",
		"market": "usex",
		"time": "2025-09-25 10:10:23.394",
		"ask": [
			{ "price": 714.98 }
		],
		"bid": [
			{ "price": 706.42 }
		]
	}
}
FieldTypeDescription
typestringFixed as "router_quote"
dataobjectOrderbook data
data.symbolstringTicker code
data.marketstringMarket code. See Market enum type description
data.timestringOrderbook data time
data.askobject[]Ask list, sorted by price in ascending order. Each entry carries price only
data.ask[].pricedecimalAsk price, in the settlement asset of the given chain_id
data.bidobject[]Bid list, sorted by price in descending order. Each entry carries price only
data.bid[].pricedecimalBid price, in the settlement asset of the given chain_id

Push Frequency: Real-time push.

Router Price Data Push ​

When subscribing to router_price, you will receive price data push in the following format:

json
{
	"type": "router_price",
	"data": {
		"symbol": "AAPLs",
		"time": "2025-05-30 15:58:17",
		"session": "trading",
		"price": 497.51
	}
}
FieldTypeDescription
typestringFixed as "router_price"
dataobjectRouter price data
data.symbolstringTicker code
data.timestringCurrent market data time
data.sessionstringTrading session (trading, pre_market, after_market, etc.)
data.pricedecimalLatest price, in the settlement asset of the given chain_id

Push Frequency: Real-time push, immediately when quote changes.

Unsubscription ​

Router streams are unsubscribed with their own type:

json
{
	"id": "550e8400-e29b-41d4-a716-446655440003",
	"method": "market",
	"action": "unsubscribe",
	"params": {
		"type": "router_price",
		"chain_id": 97,
		"tickers": ["AAPLs@usex"]
	},
	"api_key": "<your-api-key>",
	"timestamp": "1703123456789",
	"signature": "<computed-signature>"
}

Note: chain_id is required for router streams on both subscribe and unsubscribe.

The response format is the same as for the base streams — see Server Response.

Error Handling ​

In addition to the common WebSocket errors:

Error MessageCauseSolution
chain_id is required for router_quote/router_priceRouter stream request sent without chain_idInclude a valid chain_id in params

For the shared error messages (Invalid JSON format, Invalid params, Invalid or missing authentication header(s), Subscription limit reached, etc.), see Error Handling.

Notes ​

  • Multiple subscription messages can be sent on the same connection, each incrementally adding subscriptions.
  • All subscriptions are automatically cleaned up when the connection drops.
  • Tickers with invalid format or unrecognized market are silently skipped.