This section describes important resources found in the API and how everything works together. It is important to understand how the Comfort Life ecosystem works to use it or to build new features for it.
Authorization is a HTTP header used for most of the available API endpoints. It must be set to identify the end user for which targeted resources are requested. Refer to the API Documentation to know when this value is mandatory.
To retrieve the authorization, you may use one of the following methods :
A user is a structured resource identifying a single end user. A family is a structured resource aggregating multiple users with different roles. A role defines authorization within a family.
A location is a structured layer of resources owned by a family. A location is identified by a unique identifier called uid. A name can be set for a location to be displayed in the Comfort Life client.
A location is defined by a level. A location can be placed in another location if that location level is strictly higher, ordering locations in multiple layers. Available levels are ordered as follow, from the highest to the lowest :
A system is a non-user related resource. It describes common features among sets of resources definition. Resources found in modules belong to at least one system. If an entity belongs to a system, it means it is implementing at least one of this system features.
You may find an exhaustive list of existing systems and how to use them here.
A capability is a non-user related resource. A capability is an action that can be performed on or by a resource. Capabilities are features found in systems. It means a module resource belonging to a system can implement capabilities instances from that system. A module resource capability instance may have a value, which is always a string. The value may be one of mandatory values for this capability called states.
You may find an exhaustive list of existing capabilities and how to use them here.
A model is a non-user related resource. It identifies resources of the same type. A model is defined to belong to one or more systems.
Models can be requested thanks to the following API endpoint :
A device is a structured resource identifying a single device associated to an end user account. A device may be found as an encapsulated resource of a module. Each device has a model. It means a device implements capabilities from systems its model belong to.
You may target devices owned by a family for a request as follow (parenthesis mean it is optional) :