Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.monzo.sensor Namespace Reference

Classes

class  MonzoSensor
 
class  MonzoSensorEntityDescription
 

Functions

None async_setup_entry (HomeAssistant hass, ConfigEntry config_entry, AddEntitiesCallback async_add_entities)
 

Variables

tuple ACCOUNT_SENSORS
 
string MODEL_POT = "Pot"
 
tuple POT_SENSORS
 

Detailed Description

Platform for sensor integration.

Function Documentation

◆ async_setup_entry()

None homeassistant.components.monzo.sensor.async_setup_entry ( HomeAssistant  hass,
ConfigEntry  config_entry,
AddEntitiesCallback  async_add_entities 
)
Defer sensor setup to the shared sensor module.

Definition at line 65 of file sensor.py.

Variable Documentation

◆ ACCOUNT_SENSORS

tuple homeassistant.components.monzo.sensor.ACCOUNT_SENSORS
Initial value:
1 = (
2  MonzoSensorEntityDescription(
3  key="balance",
4  translation_key="balance",
5  value_fn=lambda data: data["balance"]["balance"] / 100,
6  device_class=SensorDeviceClass.MONETARY,
7  native_unit_of_measurement="GBP",
8  suggested_display_precision=2,
9  ),
10  MonzoSensorEntityDescription(
11  key="total_balance",
12  translation_key="total_balance",
13  value_fn=lambda data: data["balance"]["total_balance"] / 100,
14  device_class=SensorDeviceClass.MONETARY,
15  native_unit_of_measurement="GBP",
16  suggested_display_precision=2,
17  ),
18 )

Definition at line 32 of file sensor.py.

◆ MODEL_POT

string homeassistant.components.monzo.sensor.MODEL_POT = "Pot"

Definition at line 62 of file sensor.py.

◆ POT_SENSORS

tuple homeassistant.components.monzo.sensor.POT_SENSORS
Initial value:
1 = (
2  MonzoSensorEntityDescription(
3  key="pot_balance",
4  translation_key="pot_balance",
5  value_fn=lambda data: data["balance"] / 100,
6  device_class=SensorDeviceClass.MONETARY,
7  native_unit_of_measurement="GBP",
8  suggested_display_precision=2,
9  ),
10 )

Definition at line 51 of file sensor.py.