OpenTV ENTera & OpenTV Platform Documentation
25.52_Q4 25.26_Q2 25.12_Q1 24.50_Q4 24.38_Q3 24.26_Q2 23.50_Q4 23.24_Q2 23.12_Q1 22.50_Q4 22.38_Q3 22.24_Q2
25.52_Q4 25.26_Q2 25.12_Q1 24.50_Q4 24.38_Q3 24.26_Q2 23.50_Q4 23.24_Q2 23.12_Q1 22.50_Q4 22.38_Q3 22.24_Q2

Creating a topic and subscribing devices to it

Request

To create a new topic without subscribing any devices to it, send a PUT request to:

http://<host>:<port>/mib/v1/topics/{topicName}/devices

Headers

  • Content-Type: application/json

Mandatory fields

  • topicName (in both URL and payload) – the name of the topic

  • active – set to true to make the topic active (true is the default)

  • devices – the devices to subscribe to the topic. Each device must include:

    • deviceId – the unique ID of the device, as returned by ADM

    • subscriptionStatus – set to true to subscribe the device to the topic.

Example

A request with this payload creates a topic and subscribes the specified devices to it:

{
  "topicName": "New-Videos",
  "active": true,
  "devices": [
  {
      "deviceId": "5ca5e0ced2f2ff000118e9db",
      "subscriptionStatus": true
  },
  {
      "deviceId": "5cb0558b759587000105750a",
      "subscriptionStatus": true
  }
  ]
}

Response

A successful request returns an HTTP 200 status.

An unsuccessful request returns an HTTP 404 status if the topic does not exist.

See also

For full details of this API, see the DMM API documentation.