Unsubscribe

Cancels device subscription

Send the uuid of the device you'd like to unsubscribe to

var ws = new WebSocket("wss://meshblu.octoblu.com/ws/v2");

ws.send(JSON.stringify([
  "unsubscribe",
  {
    "uuid":"26de691f-8068-4cdc-907a-4cb5961a1aba"
  }
]));

Unsubscribe by type

You can limit the types of messages you unsubscribe to by using the types parameter.

Valid types include:

  • broadcast - broadcast messages sent by the device
  • received - messages received by the device
  • sent - messages sent by the device

Default is all types.

var ws = new WebSocket("wss://meshblu.octoblu.com/ws/v2");

ws.send(JSON.stringify([
  "unsubscribe",
  {
    "uuid":"26de691f-8068-4cdc-907a-4cb5961a1aba",
    "types": ["broadcast", "sent"]
  }
]));