Skip to main content
This request removes one or more streams from the current WebSocket connection.

Request

{
  "message":"unsubscribe",
  "content":{
    "clientRequestId":"245867a5-0de9-4542-a9da-724577ab4102",
    "subscriptions":[
      "tradeStream",
      "orderBookStream"
    ]
  }
}

Response

{
    "data": {
        "activeSubscriptions": [
            "orderCreation"
        ],
        "clientRequestId": "245867a5-0de9-4542-a9da-724577ab4102",
        "requestedUnsubscriptions": [
            "tradeStream",
            "orderBookStream"
        ]
    },
    "resultType": "unsubscribed"
}
FieldTypeDescription
data.activeSubscriptionsarrayRemaining active subscriptions after the operation
data.clientRequestIdstringThe request ID that was provided in the original request
data.requestedUnsubscriptionsarrayThe specific subscriptions that were requested to be removed
resultTypestringAlways “unsubscribed” for unsubscribe responses

Behavior

  • Only active subscriptions are removed
  • Removing a non-active subscription is a no-op
  • Other subscriptions remain unaffected
  • Changes apply immediately
  • Safe to call repeatedly (idempotent)
  • Does not affect other connections
  • Does not require reconnecting