removeTimer(params: Object)

Requires:
DeviceKit≥1.2.6@ray-js/ray≥0.6.23
Platforms:
iOSAndroid
import { device } from '@ray-js/ray';

const { removeTimer } = device;

// Promise usage
try {
  const res = await removeTimer({ ...params });
  console.log(res);
} catch (err) {
  console.log(err.errorMsg);
}

Description

Delete a timer

Parameters

PropertyTypeRequiredDescription
deviceIdstringNodeviceId Device ID; at least one of deviceId or groupId is required
groupIdstringNogroupId Group ID; at least one of deviceId or groupId is required
timerIdstringYestimerId Timer ID
complete() => voidNoCompletion callback (executed on both success and failure)
success() => voidNoCallback on successful API call
fail(params: Object) => voidNoFailure callback
fail callback parameters
PropertyTypeDescription
errorMsgstringError message
errorCodestring | numberError code
Error extension

Return Value

None

Examples

import { device } from '@ray-js/ray'

device.removeTimer({
  deviceId: "vdevo177319884964790",
  timerId: "82818370",
  success: data => {
    console.log(data);
  },
  fail: error => {
    console.error(error);
  },
});