Device Settings

Pre-requisite:

  • The user has to be signed in to perform the following operations.
  • The Device should be a cluster device to perform the following operations.

Get Cluster for a Device

To get the device cluster, The following method can be used:

  • spaceId (required): The space ID of the device.
  • deviceId (required): The device ID.
Factory.deviceService.getDeviceClusters(spaceId: String, deviceId: String) -> IVPublisher<CameraClustersModel>

Update Device Cluster

To update the device cluster, The following method can be used:

  • spaceId (required): The space ID of the device.
  • deviceId (required): The device ID.
  • clusterId (required): The id of the cluster to be update.
  • request (required): The request object containing the list of attributes in the cluster.
Factory.deviceService.updateDeviceCluster(spaceId: String, deviceId: String, clusterId: String, wakeup: Bool, request: UpdateClusterMultipleAttributeRequestModel) -> IVPublisher<ClusterUpdateRespModel>

Update Device Cluster attribute

To update the device cluster, The following method can be used:

  • spaceId (required): The space ID of the device.
  • deviceId (required): The device ID.
  • clusterId (required): The id of the cluster to be update.
  • attributeId (required): the id of the attribute to be updated.
  • request (required): The request object containing the new value for the attribute.
Factory.deviceService.updateDeviceClustersAttribute(spaceId: String, deviceId: String, clusterId: String, attributeId: String, wakeup: Bool, request: UpdateClusterAttributeRequestModel) -> IVPublisher<ClusterUpdateRespModel>

Get Cloud Settings for a Device

To get the cloud settings for a device, The following method can be used:

  • spaceId (required): The space ID of the device.
  • deviceId (required): The device ID.
Factory.deviceService.getDeviceCloudSettings(spaceId: String, deviceId: String) -> IVPublisher<DeviceCloudSettings>