Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.mystrom.binary_sensor.MyStromView Class Reference
Inheritance diagram for homeassistant.components.mystrom.binary_sensor.MyStromView:
[legend]
Collaboration diagram for homeassistant.components.mystrom.binary_sensor.MyStromView:
[legend]

Public Member Functions

def __init__ (self, add_entities)
 
def get (self, request)
 

Public Attributes

 add_entities
 
 buttons
 

Static Public Attributes

string name = "api:mystrom"
 
list supported_actions = ["single", "double", "long", "touch"]
 
string url = "/api/mystrom"
 

Private Member Functions

def _handle (self, hass, data)
 

Detailed Description

View to handle requests from myStrom buttons.

Definition at line 30 of file binary_sensor.py.

Constructor & Destructor Documentation

◆ __init__()

def homeassistant.components.mystrom.binary_sensor.MyStromView.__init__ (   self,
  add_entities 
)
Initialize the myStrom URL endpoint.

Definition at line 37 of file binary_sensor.py.

Member Function Documentation

◆ _handle()

def homeassistant.components.mystrom.binary_sensor.MyStromView._handle (   self,
  hass,
  data 
)
private
Handle requests to the myStrom endpoint.

Definition at line 46 of file binary_sensor.py.

◆ get()

def homeassistant.components.mystrom.binary_sensor.MyStromView.get (   self,
  request 
)
Handle the GET request received from a myStrom button.

Definition at line 42 of file binary_sensor.py.

Member Data Documentation

◆ add_entities

homeassistant.components.mystrom.binary_sensor.MyStromView.add_entities

Definition at line 40 of file binary_sensor.py.

◆ buttons

homeassistant.components.mystrom.binary_sensor.MyStromView.buttons

Definition at line 39 of file binary_sensor.py.

◆ name

string homeassistant.components.mystrom.binary_sensor.MyStromView.name = "api:mystrom"
static

Definition at line 34 of file binary_sensor.py.

◆ supported_actions

list homeassistant.components.mystrom.binary_sensor.MyStromView.supported_actions = ["single", "double", "long", "touch"]
static

Definition at line 35 of file binary_sensor.py.

◆ url

string homeassistant.components.mystrom.binary_sensor.MyStromView.url = "/api/mystrom"
static

Definition at line 33 of file binary_sensor.py.


The documentation for this class was generated from the following file: