Add wellness sensors to Tractive integration (#96719)

* Add sleep sensors

* Add minutes rest sensor

* Add calories sensor

* Add state_class to entity descriptions
This commit is contained in:
Maciej Bieniek 2023-07-17 07:02:42 +00:00 committed by GitHub
parent 085eebc903
commit 79bcca2853
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 102 additions and 4 deletions

View file

@ -6,11 +6,15 @@ DOMAIN = "tractive"
RECONNECT_INTERVAL = timedelta(seconds=10)
ATTR_DAILY_GOAL = "daily_goal"
ATTR_BUZZER = "buzzer"
ATTR_CALORIES = "calories"
ATTR_DAILY_GOAL = "daily_goal"
ATTR_LED = "led"
ATTR_LIVE_TRACKING = "live_tracking"
ATTR_MINUTES_ACTIVE = "minutes_active"
ATTR_MINUTES_DAY_SLEEP = "minutes_day_sleep"
ATTR_MINUTES_NIGHT_SLEEP = "minutes_night_sleep"
ATTR_MINUTES_REST = "minutes_rest"
ATTR_TRACKER_STATE = "tracker_state"
# This client ID was issued by Tractive specifically for Home Assistant.
@ -23,5 +27,6 @@ TRACKABLES = "trackables"
TRACKER_HARDWARE_STATUS_UPDATED = f"{DOMAIN}_tracker_hardware_status_updated"
TRACKER_POSITION_UPDATED = f"{DOMAIN}_tracker_position_updated"
TRACKER_ACTIVITY_STATUS_UPDATED = f"{DOMAIN}_tracker_activity_updated"
TRACKER_WELLNESS_STATUS_UPDATED = f"{DOMAIN}_tracker_wellness_updated"
SERVER_UNAVAILABLE = f"{DOMAIN}_server_unavailable"