mirror of
https://github.com/home-assistant/developers.home-assistant.git
synced 2025-07-08 18:06:29 +00:00
Document sensor last_reset (#949)
* Document sensor last_reset * Clarify that `last_reset` will be exposed as an ISO 8601-formatted string
This commit is contained in:
parent
4dacbae8da
commit
c0ceb15b09
@ -15,6 +15,7 @@ Properties should always only return information from memory and not do I/O (lik
|
||||
| ---- | ---- | ------- | -----------
|
||||
| state | string | **Required** | The value of the sensor.
|
||||
| device_class | string | `None` | Type of sensor.
|
||||
| last_reset | `datetime.datetime` | `None` | The time when an accumulating sensor such as an electricity usage meter, gas meter, water meter etc. was initialized. If the time of initialization is unknown and the meter will never reset, set to UNIX epoch 0: `datetime.fromtimestamp(0)`. Note that the `datetime.datetime` returned by the `last_reset` property will be converted to an ISO 8601-formatted string when the entity's state attributes are updated. When changing `last_reset`, the `state` must be a valid number.
|
||||
| state_class | string | `None` | Type of state.
|
||||
| unit_of_measurement | string | `None` | The unit of measurement that the sensor is expressed in.
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user