Groups and Scenes
Groups and Scenes (GSS) service is used to create applications that enrich home automation experience for end-users. The following common terminologies and examples will help you to understand the basics of GSS service and implement the GSS service in your applications.
Household/Home
- The term Household or Home is used to represent the user’s physical place of residence or location where all their smart devices are set up.
- Ayla Networks supports single Household per user.
Room
- In a smart home setting, Rooms enable the user to meaningfully represent a collection of devices that belong to a specific physical area in a home. For example, a room could be a set of smart devices located in the living room, kitchen, garage, master bedroom, or basement.
- A Room may contain any combination of individual devices and/or Groups of devices. The devices may be of diverse types and have different attributes. For example, a living room may contain a single ceiling fan, an air purifier, a camera, and a Group of light bulbs.
- Rooms are simply a way to organize and visualize a collection of devices and Groups of devices. Each device and group of devices within a room is typically organized to be controlled individually. In some cases, the user may also want to turn On/Off all devices belonging to a specific Room.
Group
A group is a collection of devices that can be viewed and controlled as a single entity. The devices in a group are of a similar type, or have common attributes (e.g., On/Off) that can be controlled as a whole. The most common example is a group of lights. Groups enable the users to perform a single action to a collection of devices at the same time.
Example: | The most common control action performed on a group is turning all devices On/Off at once. Other common actions include setting brightness or color on a group of light bulbs at once. |
Scene
A scene is a collection of devices with different actions/states (attributes). A scene allows us to perform various actions to diverse types of devices at the same time.
When a scene is activated, a set of pre-defined actions are performed on all the devices associated with a scene. A scene is activated manually (tapping a button in the mobile app) or can be automated based on a schedule.
Example use cases: | - Consider a scene called “Good Morning,” when this scene is activated, it could turn on all the living room lights, set the thermostat to 75F, start the coffee machine in the kitchen, and raise all window shades. - Consider a scene called “Movie Time,” when this scene is activated, it could lower the window shades and dim all the living room lights to 10%. |
NOTE: In general, a household, a group, or a scene is referred to as a collection.
Groups and Scenes Hierarchy
We can use the hierarchy diagram above as an example to visualize the hierarchy of Groups and Scenes concepts. By default, a user account comes with a household at the root level. Under the household, the user can create groups and/or scenes, this is at the parent level. Under a Parent level group, the user can create child groups and/or scenes. Multiple child levels are allowed within the allowed limitations.
Groups and Scenes APIs
GSS service APIs/methods are included in the AylaSDK. To learn more about the GSS APIs, please refer to API Reference.
Updated over 1 year ago