Getting all devices that are subscribed to a topic
Request
To get a list of devices that are subscribed to a topic, send a GET request to:
http://<host>:<port>/mib/v2/topics/topicname/{topicName}/devices
Headers
Content-Type: application/json
Mandatory fields
topicName(in URL) – the name of the topic
Example
This request gets a list of devices subscribed to the topic TopicForFootballNews:
http://<host>:<port>/mib/v2/topics/topicname/TopicForFootballNews/devices
Response
A successful request returns an HTTP 200 status.
An unsuccessful request returns an HTTP 404 status if the topic does not exist.
A successful request generates a response that looks like this:
{
"totalRecords": 1,
"data": [
{
"deviceId": "5fc9f023596f787fef9c43da",
"deviceHardwareType": "Mobile",
"deviceOS": "Android",
"msgPlatform": "fcm",
"subscriptionStatus": true
}
]
}
See also
For full details of this API, see the Device Messaging Manager (DMM) API documentation v2.