Smart Home Dock Trait Schema

action.devices.traits.Dock - This trait is designed for self-mobile devices that can be commanded to return for charging. By and large, these are currently robotic vacuum cleaners, but this would also apply to some drones, delivery robots, and other future devices.

Device ATTRIBUTES

None

Sample SYNC Request and Response

Request
{
  "requestId": "ff36a3cc-ec34-11e6-b1a0-64510650abcf",
  "inputs": [{
    "intent": "action.devices.SYNC",
  }]
}
Response
{
  "requestId": "ff36a3cc-ec34-11e6-b1a0-64510650abcf",
  "payload": {
    "agentUserId": "1836.15267389",
    "devices": [{
      "id": "123",
      "type": "action.devices.types.VACUUM",
      "traits": [
        "action.devices.traits.Dock"
      ],
      "name": {
        "defaultNames": ["AAA Cybernetics Corp Vacuum"],
        "name": "vacuum",
        "nicknames": []
      },
      "willReportState": true,
      "deviceInfo": {
        "manufacturer": "sirius",
        "model": "442",
        "hwVersion": "3.2",
        "swVersion": "11.4"
      },
      "customData": {
        "fooValue": 74,
        "barValue": true,
        "bazValue": "lambtwirl"
      }
    }]
  }
}
Validator

Device STATES

State Definition
isDocked Whether the current device is on the docking station or not.

Sample QUERY Request and Response

Request
{
  "requestId": "ff36a3cc-ec34-11e6-b1a0-64510650abcf",
  "inputs": [{
    "intent": "action.devices.QUERY",
    "payload": {
      "devices": [{
        "id": "123",
        "customData": {
          "fooValue": 74,
          "barValue": true,
          "bazValue": "lambtwirl"
        }
      }]
    }
  }]
}
Response
{
  "requestId": "ff36a3cc-ec34-11e6-b1a0-64510650abcf",
  "payload": {
    "devices": {
      "123": {
        "online": true
        "isDocked": true
      }
    }
  }
}

Device COMMANDS

Command Parameters/Definition
action.devices.commands.Dock Tells the device to return to the dock. The response will indicate whether the device is docked after it finishes executing the command.

Sample EXECUTE Request and Response

Request
{
  "requestId": "ff36a3cc-ec34-11e6-b1a0-64510650abcf",
  "inputs": [{
    "intent": "action.devices.EXECUTE",
    "payload": {
      "commands": [{
        "devices": [{
          "id": "123",
          "customData": {
            "fooValue": 74,
            "barValue": true,
            "bazValue": "sheepdip"
          }
        }],
        "execution": [{
          "command": "action.devices.commands.Dock"
        }]
      }]
    }
  }]
}
Response
{
  "requestId": "ff36a3cc-ec34-11e6-b1a0-64510650abcf",
  "payload": {
    "commands": [{
      "ids": ["123"],
      "status": "SUCCESS",
      "states": {
          "isDocked": "true"
      }
    }]
  }
}