For the complete documentation index, see llms.txt. This page is also available as Markdown.

All Coin Prices Stream

Coin price and margin ratio for all coins pushed on updating. This stream is available for perps only. Note that only coin prices that have changed will be present in the update array.

Update Speed

  • Pushed on each block that is at least 1 second since the last push when price or margin ratio changes.

Subscribe Request

  • Subscribe Schema

See WsAllCoinPriceSubscriptionParams in Schema.

interface SubscribeRequest {
  op: "subscribe";
  id: number | null; // Optional client originated request identifier sent as acknowledgment in the response.
  params: WsAllCoinPriceSubscriptionParams;
}
  • Subscribe Ack Schema

See WsAllCoinPriceSubscriptionResult in Schema.

interface SubscriptionResult {
  op: "subscribe";
  id: number | null; // Optional client originated request identifier sent as acknowledgment in the response.
  result: WsAllCoinPriceSubscriptionResult | null;
  success: boolean; // Indicates if the request was successfully processed by the engine.
  connID: string;
  error: string | null; // Condition: If success is false. Error message.
  time_in: number; // The timestamp when the subscription was received on the wire, just prior to parsing data, in milliseconds.
  time_out: number; // The timestamp when the acknowledgement was sent on the wire, just prior to transmitting data, in milliseconds.
}
  • Example: Subscribe

  • Example: Subscribe Ack

Unsubscribe Request

  • Unsubscribe Schema

See WsAllCoinPriceSubscriptionParams in Schema.

  • Unsubscribe Ack Schema

See WsAllCoinPriceSubscriptionResult in Schema.

  • Example: Unsubscribe

  • Example: Unsubscribe Ack

Snapshot / Update Response

  • Snapshot / Update Schema

See WsCoinPriceData in Schema.

  • Example: Snapshot

  • Example: Update

Last updated