Skip to content

cloud.smarthq.service.oven.flextimer

  • Configuration


    Describes boundaries and fixed properties for the service.

    Go There

  • State


    A list of the states this service can be in.

    Go There

  • Commands


    How to change the state of the service.

    Go There

  • Data Types


    All the data types used for this service.

    Go There

Description

Flex timer Service on oven

Example Device Response (Digital Twin API)

Flex timer set on Lower & upper Oven

{
  "adapterId": "0000000000000000000000000000000000000000",
  "alertTypes": [],
  "createdDateTime": "2022-03-04T12:12:12.123Z",
  "deviceId": "0000000000000000000000000000000000000000000000000000000000000000",
  "deviceType": "cloud.smarthq.device.oven",
  "gatewayId": "0000000000000000000000000000000000000000000000000000000000000000",
  "kind": "device#item",
  "lastPresenceTime": "2022-03-04T12:12:12.123Z",
  "lastSyncTime": "2022-03-04T12:12:12.123Z",
  "presence": "OFFLINE",
  "removable": true,
  "services": [
    {
      "serviceType": "cloud.smarthq.service.oven.flextimer",
      "lastSyncTime": "2022-03-04T12:12:12.123Z",
      "domainType": "cloud.smarthq.domain.oven.lower",
      "supportedCommands": [
        "cloud.smarthq.command.oven.flextimer.addorsubtract.set",
        "cloud.smarthq.command.oven.flextimer.expiration.set"
      ],
      "state": {
        "addSubtractStatus": 200.0,
        "cookTimeTotalDuration": 1.2345678E7,
        "expirationStatus": true
      },
      "serviceId": "0000000000000000000000000000000000000000000000000000000000000000",
      "serviceDeviceType": "cloud.smarthq.device.oven",
      "config": {
        "maximumSubtraction": -32767.0,
        "integerUnits": "cloud.smarthq.type.integerunits.seconds",
        "maximumAddition": 32767.0
      },
      "lastStateTime": "2022-03-04T12:12:12.123Z"
    }
  ],
  "userId": "000000000000000"
}

Configuration

The following are properties for the gateway/device sync as part of the "config" object for each individual service.

Field Name Property Type Required Minimum Maximum
integerUnits INTEGER_UNITS No
maximumAddition INTEGER No -2147483648 2147483647
maximumSubtraction INTEGER No -2147483648 2147483647

State

The following are properties for the device state report as part of the "state" object for each individual service.

Field Name Property Type Required Minimum Maximum
addSubtractStatus INTEGER No -2147483648 2147483647
cookTimeTotalDuration LONG No
disabled BOOLEAN No
expirationStatus BOOLEAN No

Commands

The following are properties for both the Digital Twin API to send a command to the device as well as the properties passed as part of a command to the gateway to be processed by the device itself.

cloud.smarthq.command.oven.flextimer.expiration.set

Command used to set the Flex Timer expiration value on or off

Field Name Property Type Required
boolValue BOOLEAN Yes

Example Commands

Command to set flex timer expiration time on-off on upper/lower oven.

{
  "command": {
    "commandType": "cloud.smarthq.command.oven.flextimer.expiration.set",
    "boolValue": true
  },
  "deviceId": "00000000000000000000000000000000000000000000000000000000000000",
  "domainType": "cloud.smarthq.domain.oven.lower",
  "kind": "service#command",
  "serviceDeviceType": "cloud.smarthq.device.oven",
  "serviceType": "cloud.smarthq.service.oven.flextimer"
}

Supported Outcomes

Each service has an allow listed set of outcomes that the device may return when asked to execute a command.

Outcome Documentation
cloud.smarthq.outcome.badrequest The request was invalid.
cloud.smarthq.outcome.developererror Only used when there is a server side bug
cloud.smarthq.outcome.deviceoffline The device is offline.
cloud.smarthq.outcome.forbidden The request is forbidden due to permissions.
cloud.smarthq.outcome.internalerror The server had an issue processing the request
cloud.smarthq.outcome.missingconfig The service config is missing
cloud.smarthq.outcome.missingstate The service state is missing
cloud.smarthq.outcome.notallowed The command is not allowed.
cloud.smarthq.outcome.notfound The request is forbidden due to permissions.
cloud.smarthq.outcome.notsupported The command is not supported.
cloud.smarthq.outcome.outofbounds General out of bounds error
cloud.smarthq.outcome.servicedisabled Feature is currently disabled
cloud.smarthq.outcome.success Successful request
cloud.smarthq.outcome.timeout The server experienced timeout waiting for a response from the gateway

cloud.smarthq.command.oven.flextimer.addorsubtract.set

Command used to set the Flex Timer add or subtract request

Field Name Property Type Required Minimum Maximum
addSubtractTime INTEGER Yes -2147483648 2147483647
flexTimerRequestId INTEGER Yes -2147483648 2147483647

Example Commands

Command to set flex timer add or subtract values on upper/lower oven.

{
  "command": {
    "commandType": "cloud.smarthq.command.oven.flextimer.addorsubtract.set",
    "flexTimerRequestId": 123456.0,
    "addSubtractTime": 100.0
  },
  "deviceId": "00000000000000000000000000000000000000000000000000000000000000",
  "domainType": "cloud.smarthq.domain.oven.lower",
  "kind": "service#command",
  "serviceDeviceType": "cloud.smarthq.device.oven",
  "serviceType": "cloud.smarthq.service.oven.flextimer"
}

Supported Outcomes

Each service has an allow listed set of outcomes that the device may return when asked to execute a command.

Outcome Documentation
cloud.smarthq.outcome.badrequest The request was invalid.
cloud.smarthq.outcome.developererror Only used when there is a server side bug
cloud.smarthq.outcome.deviceoffline The device is offline.
cloud.smarthq.outcome.forbidden The request is forbidden due to permissions.
cloud.smarthq.outcome.internalerror The server had an issue processing the request
cloud.smarthq.outcome.missingconfig The service config is missing
cloud.smarthq.outcome.missingstate The service state is missing
cloud.smarthq.outcome.notallowed The command is not allowed.
cloud.smarthq.outcome.notfound The request is forbidden due to permissions.
cloud.smarthq.outcome.notsupported The command is not supported.
cloud.smarthq.outcome.outofbounds General out of bounds error
cloud.smarthq.outcome.servicedisabled Feature is currently disabled
cloud.smarthq.outcome.success Successful request
cloud.smarthq.outcome.timeout The server experienced timeout waiting for a response from the gateway

Data Types

BOOLEAN

Value must be either true or false.

INTEGER

Value must be an integer. Field specific restrictions such as a minimum and maximum may apply depending on the field.

LONG

Value must be a long. Field specific restrictions such as a minimum and maximum may apply depending on the field.

INTEGER_UNITS

INTEGER_UNITS Documentation
cloud.smarthq.type.integerunits.cfm Cubic feet per minute
cloud.smarthq.type.integerunits.count Integer count
cloud.smarthq.type.integerunits.days Days
cloud.smarthq.type.integerunits.dbm Decibel milliwatts
cloud.smarthq.type.integerunits.gallons Gallons
cloud.smarthq.type.integerunits.hours Hours
cloud.smarthq.type.integerunits.kwh Kilo watt hour
cloud.smarthq.type.integerunits.level level
cloud.smarthq.type.integerunits.minutes Minutes
cloud.smarthq.type.integerunits.ounces Ounces
cloud.smarthq.type.integerunits.ounces.fluid Fluid ounces
cloud.smarthq.type.integerunits.percentage Percentage
cloud.smarthq.type.integerunits.rpm Revolutions per Minute
cloud.smarthq.type.integerunits.seconds Seconds
cloud.smarthq.type.integerunits.temperature.fahrenheit Temperature in Fahrenheit
cloud.smarthq.type.integerunits.thermostatsignalv1 Thermostat Signal v1
cloud.smarthq.type.integerunits.unitless unitless
cloud.smarthq.type.integerunits.watts Watts