Matter Cluster 149 — Commodity Price
Matter Cluster 149 (0x0095) Commodity Price: attributes, commands, events, data types, shadow paths and bridge payload examples.
Matter Cluster 149 — Commodity Price Cluster
Matter Cluster 149, also written as 0x0095, is the Commodity Price Cluster.
The Commodity Price Cluster provides the mechanism for communicating Gas, Energy, or Water pricing information within the premises.
Cluster Identity
| Field | Value |
|---|---|
| Cluster ID decimal | 149 |
| Cluster ID hex | 0x0095 |
| Cluster name | Commodity Price |
| Cluster revision (Matter 1.6.1) | 4 |
| Role | application |
| Scope | Endpoint |
| PICS code | SEPR |
| Typical endpoint | 1 |
Revision history
| Revision | Change |
|---|---|
| 1 | Mandatory global ClusterRevision attribute added |
| 2 | Updated from SE1.4 version; CCB 1447 2964 2965 |
| 3 | CCBs 2043 2706 2810 2912 3566 |
| 4 | Initial Matter revision |
Shadow Path Format
Cluster 149 values in the device shadow use this format:
endpoint_id / 149 / attribute_id
Example:
{
"1/149/0": 0
}
| Part | Meaning |
|---|---|
1 | Endpoint ID |
149 | Commodity Price cluster |
0 | TariffUnit attribute |
Cluster 149 Features
The FeatureMap attribute (1/149/65532) is a bitmap. Each bit set means the device implements that feature and the attributes and commands that depend on it.
| Bit | Code | Feature | Conformance | Meaning |
|---|---|---|---|---|
| 0 | FORE | Forecasting | O | Forecasts upcoming pricing |
Example: FeatureMap = 0 means no optional feature is enabled; 1 means every feature listed above is enabled.
Data Types
CommodityPriceDetailBitmap (bitmap)
| Bit | Name | Conformance | Meaning |
|---|---|---|---|
| 0 | Description | M | A textual description of a price; e.g. the name of a rate plan. |
| 1 | Components | M | A breakdown of the component parts of a price; e.g. generation, delivery, etc. |
CommodityPriceComponentStruct (struct)
This represents a component of a given price; it is only used in the Components field.
| Field | Name | Type | Conformance | Constraint | Meaning |
|---|---|---|---|---|---|
| 0 | Price | money | M | — | Indicates the component price of the commodity per TariffUnit, with the currency indicated by the currency of the Price field of the parent CommodityPriceStruct. |
| 1 | Source | TariffPriceTypeEnum | M | — | Indicates the source of the price component. |
| 2 | Description | string | O | max length 32 | Indicates a description of the pricing plan yielding the value of the Price field. |
| 3 | TariffComponentID | uint32 | O | — | — |
CommodityPriceStruct (struct)
This represents a price over a given period.
| Field | Name | Type | Conformance | Constraint | Meaning |
|---|---|---|---|---|---|
| 0 | PeriodStart | epoch-s | M | — | Indicates the beginning timestamp in UTC of the period covered by the price indicated in the Price field, or the price level indicated in the Price Level field, or both. |
| 1 | PeriodEnd | epoch-s (nullable) | M | min compute | Indicates the ending timestamp in UTC of the period covered by the price indicated in the Price field, or the price level indicated in the Price Level field, or both. |
| 2 | Price | money | O | — | Indicates the price of the commodity per TariffUnit. |
| 3 | PriceLevel | int16 | O | — | Indicates the tariff price level. |
| 4 | Description | string | O | max length 32 | Indicates a description of the pricing plan yielding the value of the Price field, or the Price Level field. |
| 5 | Components | list of CommodityPriceComponentStruct | [Price] | max 10 entries | Indicates a list of the components that comprise the value in the Price field. |
Cluster 149 Attributes
Cluster 149 defines 4 attributes plus the global attributes. Conformance: M mandatory, O optional, a feature code means "mandatory when that feature is present", square brackets mean "optional when …".
| ID | Hex | Attribute | Type | Conformance | Access | Qualities | Default |
|---|---|---|---|---|---|---|---|
| 0 | 0x0000 | TariffUnit | TariffUnitEnum | M | R (read: view) | — | — |
| 1 | 0x0001 | Currency | CurrencyStruct | M | R (read: view) | nullable | — |
| 2 | 0x0002 | CurrentPrice | CommodityPriceStruct | M | R (read: view) | nullable | — |
| 3 | 0x0003 | PriceForecast | list of CommodityPriceStruct | FORE | R (read: view) | — | — |
Global attributes
| ID | Hex | Attribute | Meaning |
|---|---|---|---|
| 65528 | 0xFFF8 | GeneratedCommandList | Response command IDs this server generates. |
| 65529 | 0xFFF9 | AcceptedCommandList | Command IDs this server accepts. |
| 65531 | 0xFFFB | AttributeList | Attribute IDs implemented. |
| 65532 | 0xFFFC | FeatureMap | Implemented optional features (see above). |
| 65533 | 0xFFFD | ClusterRevision | Cluster revision implemented; 4 for a Matter 1.6.1 device. |
Attribute Details
Attribute 0 / 0x0000 — TariffUnit
Path example:
1/149/0
Indicates the unit of measure for all pricing reported by this cluster.
| Property | Value |
|---|---|
| Type | TariffUnitEnum |
| Conformance | M |
| Access | R (read: view) |
Example:
{
"1/149/0": 0
}
Attribute 1 / 0x0001 — Currency
Path example:
1/149/1
Indicates the currency for all pricing reported by this cluster. If the current currency is unknown, or cannot be determined, the value is null.
| Property | Value |
|---|---|
| Type | CurrencyStruct |
| Conformance | M |
| Access | R (read: view) |
| Qualities | nullable |
Example:
{
"1/149/1": 0
}
Attribute 2 / 0x0002 — CurrentPrice
Path example:
1/149/2
Indicates the current price. If the current price is unknown, or cannot be determined, the value is null. The Description and Components fields is omitted in this attribute's value.
| Property | Value |
|---|---|
| Type | CommodityPriceStruct |
| Conformance | M |
| Access | R (read: view) |
| Qualities | nullable |
Value is a CommodityPriceStruct struct (see Data Types).
Example:
{
"1/149/2": {
"periodStart": 1,
"periodEnd": 1,
"price": 1,
"priceLevel": 100
}
}
Attribute 3 / 0x0003 — PriceForecast
Path example:
1/149/3
Indicates the forecast of upcoming price changes. If the forecast is unable to be determined, this list is empty. The list entries is in time order: - All entries except the last one has a non-null PeriodEnd. - For all entries except the first one, PeriodStart is greater than the previous entry's PeriodEnd. The Description and Components fields is omitted from CommodityPriceStructs in this attribute's value.
| Property | Value |
|---|---|
| Type | list of CommodityPriceStruct |
| Conformance | FORE |
| Access | R (read: view) |
| Constraint | max 56 entries |
Each entry is a CommodityPriceStruct (see Data Types).
Example:
{
"1/149/3": []
}
Cluster 149 Commands
Cluster 149 has 2 client-to-server commands and 2 responses.
| ID | Hex | Command | Direction | Conformance | Response | Description |
|---|---|---|---|---|---|---|
| 0 | 0x00 | GetDetailedPriceRequest | client → server | O | GetDetailedPriceResponse | On receipt, this must generate a GetDetailedPrice Response command. |
| 1 | 0x01 | GetDetailedPriceResponse | server → client | GetDetailedPriceRequest | — | This command is generated in response to a GetDetailedPrice Request command. |
| 2 | 0x02 | GetDetailedForecastRequest | client → server | [FORE] | GetDetailedForecastResponse | On receipt, this must generate a GetDetailedForecast Response command. |
| 3 | 0x03 | GetDetailedForecastResponse | server → client | GetDetailedForecastRequest | — | This command is generated in response to a GetDetailedForecast Request command. |
AcceptedCommandList
The AcceptedCommandList attribute lists the command IDs the endpoint actually implements:
endpoint_id / 149 / 65529
{
"1/149/65529": [
0,
2
]
}
Before sending a Cluster 149 command, check that the command ID exists in endpoint/149/65529. Optional commands are only present when the matching feature is set in FeatureMap.
Bridge Command Payload Format
The bridge accepts Matter commands in this structure:
{
"message_id": "1",
"command": "device_command",
"args": {
"endpoint_id": 1,
"cluster_id": 149,
"command_name": "GetDetailedPriceRequest",
"payload": {},
"timed_request_timeout_ms": 1000
}
}
For Cluster 149, always use "cluster_id": 149. Payload keys are the command field names in lowerCamelCase. Octet-string fields are base64-encoded. timed_request_timeout_ms is required for timed commands and ignored otherwise.
Command: GetDetailedPriceRequest
Purpose
On receipt, this must generate a GetDetailedPrice Response command.
Command Identity
| Field | Value |
|---|---|
| Command ID | 0 |
| Command hex | 0x00 |
| Command name | GetDetailedPriceRequest |
| Direction | client → server |
| Conformance | O |
| Response | GetDetailedPriceResponse |
| Access | (invoke: operate) |
Payload Fields
| ID | Field | Payload key | Type | Conformance | Constraint | Meaning |
|---|---|---|---|---|---|---|
| 0 | Details | details | CommodityPriceDetailBitmap | M | — | Indicates which fields on the CommodityPriceStruct in the GetDetailedPriceResponseCurrentPrice field will be included. |
Bridge Command Example
{
"message_id": "1",
"command": "device_command",
"args": {
"endpoint_id": 1,
"cluster_id": 149,
"command_name": "GetDetailedPriceRequest",
"payload": {
"details": 0
}
}
}
The device answers with GetDetailedPriceResponse (see below).
Command: GetDetailedPriceResponse
Purpose
This command is generated in response to a GetDetailedPrice Request command.
Command Identity
| Field | Value |
|---|---|
| Command ID | 1 |
| Command hex | 0x01 |
| Command name | GetDetailedPriceResponse |
| Direction | server → client (response) |
| Conformance | GetDetailedPriceRequest |
Response Fields
| ID | Field | Payload key | Type | Conformance | Constraint | Meaning |
|---|---|---|---|---|---|---|
| 0 | CurrentPrice | currentPrice | CommodityPriceStruct (nullable) | M | — | Indicates the current price. Unlike the value returned from the CurrentPrice attribute, the Description and Components fields may be populated based on the value of the GetDetailedPriceRequestDetails field. |
Command: GetDetailedForecastRequest
Purpose
On receipt, this must generate a GetDetailedForecast Response command.
Command Identity
| Field | Value |
|---|---|
| Command ID | 2 |
| Command hex | 0x02 |
| Command name | GetDetailedForecastRequest |
| Direction | client → server |
| Conformance | [FORE] |
| Response | GetDetailedForecastResponse |
| Access | (invoke: operate) |
Payload Fields
| ID | Field | Payload key | Type | Conformance | Constraint | Meaning |
|---|---|---|---|---|---|---|
| 0 | Details | details | CommodityPriceDetailBitmap | M | — | Indicates which fields on the CommodityPriceStructs in the GetDetailedForecastResponsePriceForecast field will be included. |
Bridge Command Example
{
"message_id": "1",
"command": "device_command",
"args": {
"endpoint_id": 1,
"cluster_id": 149,
"command_name": "GetDetailedForecastRequest",
"payload": {
"details": 0
}
}
}
The device answers with GetDetailedForecastResponse (see below).
Command: GetDetailedForecastResponse
Purpose
This command is generated in response to a GetDetailedForecast Request command.
Command Identity
| Field | Value |
|---|---|
| Command ID | 3 |
| Command hex | 0x03 |
| Command name | GetDetailedForecastResponse |
| Direction | server → client (response) |
| Conformance | GetDetailedForecastRequest |
Response Fields
| ID | Field | Payload key | Type | Conformance | Constraint | Meaning |
|---|---|---|---|---|---|---|
| 0 | PriceForecast | priceForecast | list of CommodityPriceStruct | M | max 56 entries | Indicates the current forecast of upcoming price changes. |
Cluster 149 Events
| ID | Hex | Event | Priority | Conformance | Description |
|---|---|---|---|---|---|
| 0 | 0x00 | PriceChange | info | O | This event is generated when the value of the CurrentPrice attribute changes. |
Event 0 — PriceChange
This event is generated when the value of the CurrentPrice attribute changes.
| ID | Field | Type | Conformance | Meaning |
|---|---|---|---|---|
| 0 | CurrentPrice | CommodityPriceStruct (nullable) | M | This field is the new value of the CurrentPrice attribute. |
SmartphoneKey Notes
- Cluster 149 is not currently exposed by SmartphoneKey devices. This page documents the Matter 1.6.1 specification so that future devices can be interpreted without changes to the backend.
- Shadow paths follow
endpoint/149/attribute; attribute values that the device reports as unreadable are written asn/a. - Attribute IDs, command IDs and enum values on this page come from the CSA Matter 1.6.1 data model; descriptions are condensed from the specification text.