|  Developer
Updated on February 14, 2023

hub.scenes.device.group.find

  • Version: 1.0
  • Classes: UI
  • Title: Scene manager categories
  • Description: Find all device groups that match the parameters passed.
Edit
Field Type Required Description
category string Match all groups with this category.
subcategory string Match all groups with this subcategory.
deviceId string, ID Match all groups with this device in the “devices” collection and not in “exception” collection
deviceGroupIds array of group IDs Limit search only by device groups from that list.
deviceGroupId string, group ID Shortcut for deviceGroupIds with only one element.
Edit
  • Found array of device groups or version of device groups list.
Field Type Required Description
deviceGroups array of object + An array with references to objects found. Empty if nothing was found.
deviceGroups._id string, ID + An ID of a device group
deviceGroups.name string + A device group name
Edit
Code Message Data
-32602 Wrong params,
-32600 Bad params
Edit
Edit
				
					{
  "api": "1.0",
  "method": "hub.scenes.device.group.find",
  "params": {
    "category": "deviceCategory",
    "subcategory": "deviceSubcategory",
    "deviceId": "deviceId",
    "deviceGroupIds": [ "deviceGroupIds" ],
    "deviceGroupId": "deviceGroupId"
  }
}				
			
Edit
				
					{
  "error": null,
  "result": {
    "deviceGroups": [
      {
        "_id": "deviceGroupId",
        "name": "deviceGroupName"
      }
    ]
  }
}