Devices List

This view will show a list of selectable devices to the user. Devices that have already been paired with Homey will automatically be filtered out, based on their data property.

Usage: "template": "list_devices"

/drivers/<driver_id>/driver.compose.json
{
  "name": { "en": "My Driver" },
  "images": {
    "small": "/drivers/my_driver/assets/images/small.png",
    "large": "/drivers/my_driver/assets/images/large.png"
  },
  "pair": [
    {
      "id": "list_devices",
      "template": "list_devices",
      "navigation": { "next": "add_devices" },
      "options": { "singular": true }
    },
    {
      "id": "add_devices",
      "template": "add_devices"
    }
  ]
}

Options

Key
Type
Default
Description

singular

boolean

false

Only allow a single device to be selected

Because the list_devices template is very common the Driver#onPairListDevices() method exists which you can implement instead of the Driver#onPair() method.

Last updated

Was this helpful?