A method in a system comprising a plurality of devices (106a, 106b, 106c, 106d, 106e, 106f) that include an intermediary node (106b; 106c) that comprises a sensor and communicates with a set of the plurality of devices (106a, 106d, 106e; 106a, 106f) via a network, the method comprising, at the intermediary node: sending a data aggregation request message (116a, 116b, 116c, 116d, 116e, 116f) to an application protocol layer of the set of the plurality of devices so as to retrieve data from a plurality of different applications, the data aggregation request message including an aggregation rule; and in response to the data aggregation request message, receiving a data aggregation response message (118a, 118b, 118c, 118d, 118e, 118f) that includes data representative of the set of the plurality of devices (106a, 106b, 106c, 106d, 106e, 106f) based on the aggregation rule and an aggregation group identity, wherein the set is located downstream in the system from the intermediary node, and the data aggregation request message is an application-protocol layer message; based on the aggregation rule, calculating one of a maximum, minimum, or average value associated with one of the devices in the set of the plurality of devices (106a, 106b, 106c, 106d, 106e, 106f), the data representative of the set of the plurality of devices including the one of the maximum, minimum or average value; generating sensory data; aggregating the sensory data with the data representative of the set of the plurality of devices to create an aggregation result; creating a new data aggregation response message that includes the aggregation result; and sending the new data aggregation response message to at least one device of the plurality of devices, the at least one device located upstream in the system from the intermediary node. sending a data aggregation request message (116a, 116b, 116c, 116d, 116e, 116f) to an application protocol layer of the set of the plurality of devices so as to retrieve data from a plurality of different applications, the data aggregation request message including an aggregation rule; and in response to the data aggregation request message, receiving a data aggregation response message (118a, 118b, 118c, 118d, 118e, 118f) that includes data representative of the set of the plurality of devices (106a, 106b, 106c, 106d, 106e, 106f) based on the aggregation rule and an aggregation group identity, wherein the set is located downstream in the system from the intermediary node, and the data aggregation request message is an application-protocol layer message; based on the aggregation rule, calculating one of a maximum, minimum, or average value associated with one of the devices in the set of the plurality of devices (106a, 106b, 106c, 106d, 106e, 106f), the data representative of the set of the plurality of devices including the one of the maximum, minimum or average value; generating sensory data; aggregating the sensory data with the data representative of the set of the plurality of devices to create an aggregation result; creating a new data aggregation response message that includes the aggregation result; and sending the new data aggregation response message to at least one device of the plurality of devices, the at least one device located upstream in the system from the intermediary node.