Logi Circle public API refactor and config flow (#20624)
* Logi Circle now uses OAuth2 for authentication, added config flow. * Service calls now dispatched to camera entities via signalled events * Update from PR review * Add unit tests for config flow * Updated CODEOWNERS * Reverted change to .coveragerc * Improved test coverage of config flow
This commit is contained in:
parent
f81ce0b720
commit
a48c0f2991
16 changed files with 822 additions and 210 deletions
43
homeassistant/components/logi_circle/const.py
Normal file
43
homeassistant/components/logi_circle/const.py
Normal file
|
@ -0,0 +1,43 @@
|
|||
"""Constants in Logi Circle component."""
|
||||
|
||||
CONF_CLIENT_ID = 'client_id'
|
||||
CONF_CLIENT_SECRET = 'client_secret'
|
||||
CONF_API_KEY = 'api_key'
|
||||
CONF_REDIRECT_URI = 'redirect_uri'
|
||||
|
||||
DEFAULT_CACHEDB = '.logi_cache.pickle'
|
||||
|
||||
DOMAIN = 'logi_circle'
|
||||
DATA_LOGI = DOMAIN
|
||||
|
||||
LED_MODE_KEY = 'LED'
|
||||
RECORDING_MODE_KEY = 'RECORDING_MODE'
|
||||
|
||||
# Sensor types: Name, unit of measure, icon per sensor key.
|
||||
LOGI_SENSORS = {
|
||||
'battery_level': [
|
||||
'Battery', '%', 'battery-50'],
|
||||
|
||||
'last_activity_time': [
|
||||
"Last Activity", None, 'history'],
|
||||
|
||||
'recording': [
|
||||
'Recording Mode', None, 'eye'],
|
||||
|
||||
'signal_strength_category': [
|
||||
"WiFi Signal Category", None, 'wifi'],
|
||||
|
||||
'signal_strength_percentage': [
|
||||
"WiFi Signal Strength", '%', 'wifi'],
|
||||
|
||||
'streaming': [
|
||||
'Streaming Mode', None, 'camera'],
|
||||
}
|
||||
|
||||
SIGNAL_LOGI_CIRCLE_RECONFIGURE = 'logi_circle_reconfigure'
|
||||
SIGNAL_LOGI_CIRCLE_SNAPSHOT = 'logi_circle_snapshot'
|
||||
SIGNAL_LOGI_CIRCLE_RECORD = 'logi_circle_record'
|
||||
|
||||
# Attribution
|
||||
ATTRIBUTION = "Data provided by circle.logi.com"
|
||||
DEVICE_BRAND = 'Logitech'
|
Loading…
Add table
Add a link
Reference in a new issue