From 22f419ddd6dce9e6c09b2a4ae061c88521c83784 Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Tue, 21 Sep 2021 22:28:50 +0200 Subject: [PATCH 01/13] Fix yamllint --- .gitignore | 3 +++ .yamllint | 1 + packages/vacuum.yaml | 18 +++++++++--------- 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/.gitignore b/.gitignore index 410046d0..04e8aacb 100644 --- a/.gitignore +++ b/.gitignore @@ -32,3 +32,6 @@ out/ # homeassistant in different repo appdaemon/ + +# python +venv/ diff --git a/.yamllint b/.yamllint index e10b33cd..d622f993 100644 --- a/.yamllint +++ b/.yamllint @@ -2,6 +2,7 @@ ignore: | custom_components/ www/ + blueprints/ rules: braces: level: error diff --git a/packages/vacuum.yaml b/packages/vacuum.yaml index 6a498951..df31f962 100644 --- a/packages/vacuum.yaml +++ b/packages/vacuum.yaml @@ -101,15 +101,15 @@ automation: input: remote: f9593a92724b462e815eb27253bb7dab button_press_in: - - wait_for_trigger: - - platform: state - entity_id: input_boolean.is_home - to: 'off' - from: 'on' - - device_id: 9df393a887e04b2c952fa35d3a92ac59 - domain: vacuum - entity_id: vacuum.xiaomi_vacuum_cleaner - type: clean + - wait_for_trigger: + - platform: state + entity_id: input_boolean.is_home + to: 'off' + from: 'on' + - device_id: 9df393a887e04b2c952fa35d3a92ac59 + domain: vacuum + entity_id: vacuum.xiaomi_vacuum_cleaner + type: clean recorder: exclude: From 41f38f3f86597c49661cccac1c1390e4e16224e1 Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Wed, 13 Oct 2021 21:01:30 +0200 Subject: [PATCH 02/13] Replace oneplus 3t with nord 2 --- packages/person.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/person.yaml b/packages/person.yaml index eb5120fc..b9745026 100644 --- a/packages/person.yaml +++ b/packages/person.yaml @@ -7,5 +7,5 @@ homeassistant: entity_picture: /local/user_one.jpg person.sina: entity_picture: /local/user_two.JPG - device_tracker.oneplus_a3003: - entity_picture: /local/user_two.JPG + device_tracker.dn2103: + entity_picture: /local/user_two.JPG \ No newline at end of file From 24fff2f8db886cb49e832c514deb3a4da01f2c23 Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Wed, 13 Oct 2021 21:02:25 +0200 Subject: [PATCH 03/13] Remove shutdown/startup indicators --- packages/system.yaml | 33 --------------------------------- 1 file changed, 33 deletions(-) delete mode 100644 packages/system.yaml diff --git a/packages/system.yaml b/packages/system.yaml deleted file mode 100644 index 4744ebb0..00000000 --- a/packages/system.yaml +++ /dev/null @@ -1,33 +0,0 @@ ---- -automation: - - id: 537470e7-9d16-42da-bf31-9607ff953a0b - description: Bar leuchtet rot wenn Homeassistant runterfährt - alias: 'Bar Rot wenn Homeassistant runterfährt' - mode: single - trigger: - platform: homeassistant - event: shutdown - action: - - service: light.turn_on - data: - entity_id: light.bar_table - color_name: red - brightness: 255 - - id: 935122bc-4f2b-4993-acc5-8af23223c806 - description: Turn Bar green and then off after homeassistant started - alias: 'Bar Grün und aus wenn Homeassistant gestartet ist' - mode: single - trigger: - platform: homeassistant - event: start - action: - - service: light.turn_on - data: - entity_id: light.bar_table - color_name: green - brightness: 255 - - delay: - seconds: 5 - - service: light.turn_off - data: - entity_id: light.bar_table From d2f704d2ec6a6c8bd7a679cf8d6743d7ccfc9958 Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Wed, 13 Oct 2021 21:28:30 +0200 Subject: [PATCH 04/13] Fix device id for Starte Snowie wenn wir weg sind --- packages/vacuum.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/vacuum.yaml b/packages/vacuum.yaml index df31f962..c7ae0791 100644 --- a/packages/vacuum.yaml +++ b/packages/vacuum.yaml @@ -99,7 +99,7 @@ automation: use_blueprint: path: sp3cialck/deconz-xiaomi-aqara-wxkg11lm-smart-wireless-mini-switch.yaml input: - remote: f9593a92724b462e815eb27253bb7dab + remote: 4924aa9b422d4c18970529401bd1880f button_press_in: - wait_for_trigger: - platform: state From 3cfcf95ccaacb2e02936bbdf1da9050f968c36ab Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Wed, 13 Oct 2021 21:48:49 +0200 Subject: [PATCH 05/13] try fix away mode --- packages/away_mode.yaml | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/packages/away_mode.yaml b/packages/away_mode.yaml index 067b3eaa..9b401a18 100644 --- a/packages/away_mode.yaml +++ b/packages/away_mode.yaml @@ -16,8 +16,8 @@ script: example: input_boolean.user_one_home sequence: - choose: - # User just got home - - conditions: + - alias: User just got home + conditions: - condition: template value_template: > {{ is_state(person, 'home') @@ -27,27 +27,31 @@ script: data: entity_id: "{{ input_boolean }}" default: - # User is not yet/still home - - variables: + - alias: User is not yet/still home. Save current state + variables: current_state: "{{ states(person) }}" - service: "{{ mobile_app }}" data: message: "request_location_update" - # Wait until the state changes - - wait_for_trigger: + - alias: Wait until the state changes + wait_for_trigger: - platform: template value_template: "{{ not is_state(person, current_state) }}" + - platform: state + entity_id: binary_sensor.contact_door + to: "on" - choose: - conditions: - - condition: template + - alias: User got home + condition: template value_template: "{{ is_state(person, 'home') }}" sequence: - service: input_boolean.turn_on data: entity_id: "{{ input_boolean }}" - conditions: - - condition: template - # User changed to anything but home. So 'not_home' or a zone name + - alias: User changed to anything but home. So 'not_home' or a zone name + condition: template value_template: "{{ not is_state(person, 'home') }}" sequence: - service: input_boolean.turn_off From fb26cb795ea407710e30fb679d2ca51cfad8cecf Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Wed, 13 Oct 2021 21:49:38 +0200 Subject: [PATCH 06/13] yamllint --- packages/person.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/person.yaml b/packages/person.yaml index b9745026..55f2dcd5 100644 --- a/packages/person.yaml +++ b/packages/person.yaml @@ -8,4 +8,4 @@ homeassistant: person.sina: entity_picture: /local/user_two.JPG device_tracker.dn2103: - entity_picture: /local/user_two.JPG \ No newline at end of file + entity_picture: /local/user_two.JPG From 232283e6a33dac9661b6dc33a1c8949949bb20d4 Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Tue, 19 Oct 2021 15:52:10 +0200 Subject: [PATCH 07/13] fix vacuum button start --- packages/vacuum.yaml | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/packages/vacuum.yaml b/packages/vacuum.yaml index c7ae0791..785cf002 100644 --- a/packages/vacuum.yaml +++ b/packages/vacuum.yaml @@ -94,22 +94,23 @@ automation: inline_keyboard: - id: 4215d971-3572-4097-8f5f-269c3d5b614f alias: Starte Snowie wenn wir weg sind - description: If the button on vacuum station is pressed the vacuum will start as + description: If the button on the vacuum station is pressed the vacuum will start as soon as we leave. use_blueprint: path: sp3cialck/deconz-xiaomi-aqara-wxkg11lm-smart-wireless-mini-switch.yaml input: - remote: 4924aa9b422d4c18970529401bd1880f + remote: f9593a92724b462e815eb27253bb7dab button_press_in: - wait_for_trigger: - platform: state entity_id: input_boolean.is_home to: 'off' from: 'on' - - device_id: 9df393a887e04b2c952fa35d3a92ac59 - domain: vacuum + - condition: state + entity_id: vacuum.xiaomi_vacuum_cleaner + state: 'docked' + - service: vacuum.start entity_id: vacuum.xiaomi_vacuum_cleaner - type: clean recorder: exclude: @@ -120,3 +121,5 @@ homeassistant: customize: automation.frage_ob_staubsauger_gestartet_werden_soll_wenn_alle_weg_sind: icon: mdi:robot-vacuum + automation.starte_snowie_wenn_wir_weg_sind: + icon: mdi:robot-vacuum From 7c1fb965cee22aa2ca347f18e80a4817f827a86c Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Tue, 19 Oct 2021 16:02:53 +0200 Subject: [PATCH 08/13] Fix Sina left elmo --- packages/zone.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/zone.yaml b/packages/zone.yaml index 7012aa5c..f442d4e1 100644 --- a/packages/zone.yaml +++ b/packages/zone.yaml @@ -52,9 +52,9 @@ automation: entity_id: "person.sina" zone: "zone.elmo" event: "leave" - - alias: "Only if Kevin is not nearby" + - alias: "Only if Kevin is not within 5 km" condition: template - value_template: "{{ distance('device_tracker.sm_g975f', 'device_tracker.oneplus_a3003') > 1 }}" + value_template: "{{ distance('person.kevin', 'person.sina') > 5 }}" - alias: "Update travel time home of Sina" service: homeassistant.update_entity entity_id: sensor.travel_time_home_user_two_here From a9d1b7e5f88252b34a1c88401c23a7bd418a8219 Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Tue, 19 Oct 2021 16:14:30 +0200 Subject: [PATCH 09/13] Add announcement to start snowie button --- packages/vacuum.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/packages/vacuum.yaml b/packages/vacuum.yaml index 785cf002..572a0f48 100644 --- a/packages/vacuum.yaml +++ b/packages/vacuum.yaml @@ -101,6 +101,12 @@ automation: input: remote: f9593a92724b462e815eb27253bb7dab button_press_in: + - service: notify.alexa_media_kevins_echo_dot_wohnzimmer + data: + data: + type: announce + method: speak + message: 'Ich starte Snowie sobald ihr weg seid.' - wait_for_trigger: - platform: state entity_id: input_boolean.is_home From dad9eb408185d13585ee763803a166dd01cf2c20 Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Tue, 19 Oct 2021 16:16:55 +0200 Subject: [PATCH 10/13] yamllint --- packages/vacuum.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/vacuum.yaml b/packages/vacuum.yaml index 572a0f48..2903de65 100644 --- a/packages/vacuum.yaml +++ b/packages/vacuum.yaml @@ -101,12 +101,12 @@ automation: input: remote: f9593a92724b462e815eb27253bb7dab button_press_in: - - service: notify.alexa_media_kevins_echo_dot_wohnzimmer - data: - data: + - service: notify.alexa_media_kevins_echo_dot_wohnzimmer + data: + data: type: announce method: speak - message: 'Ich starte Snowie sobald ihr weg seid.' + message: 'Ich starte Snowie sobald ihr weg seid.' - wait_for_trigger: - platform: state entity_id: input_boolean.is_home From ea66991cd30cf0ad61db49dce8026c0aec9c6142 Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Tue, 19 Oct 2021 20:18:42 +0200 Subject: [PATCH 11/13] fix snowie start --- packages/vacuum.yaml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/packages/vacuum.yaml b/packages/vacuum.yaml index 2903de65..5fa51655 100644 --- a/packages/vacuum.yaml +++ b/packages/vacuum.yaml @@ -101,12 +101,15 @@ automation: input: remote: f9593a92724b462e815eb27253bb7dab button_press_in: - - service: notify.alexa_media_kevins_echo_dot_wohnzimmer + - alias: 'Confirm via Alexa' + service: notify.alexa_media data: + target: + - media_player.kevins_echo_dot_wohnzimmer data: type: announce method: speak - message: 'Ich starte Snowie sobald ihr weg seid.' + message: 'Ich starte Snowie sobald ihr weg seid.' - wait_for_trigger: - platform: state entity_id: input_boolean.is_home From 2694ead6c319b1303bce56c656072e0cca7dd520 Mon Sep 17 00:00:00 2001 From: eifinger Date: Tue, 19 Oct 2021 20:32:07 +0200 Subject: [PATCH 12/13] Update deps --- .../alexa_media/.translations/de.json | 14 +-- .../alexa_media/.translations/en.json | 14 +-- .../alexa_media/.translations/es.json | 14 +-- .../alexa_media/.translations/fr.json | 18 ++-- .../alexa_media/.translations/it.json | 36 +++---- .../alexa_media/.translations/nb.json | 14 +-- .../alexa_media/.translations/nl.json | 14 +-- .../alexa_media/.translations/pl.json | 22 ++--- .../alexa_media/.translations/pt_BR.json | 18 ++-- .../alexa_media/.translations/pt_PT.json | 14 +-- .../alexa_media/.translations/ru.json | 14 +-- .../alexa_media/.translations/zh-Hans.json | 18 ++-- custom_components/alexa_media/const.py | 2 +- custom_components/alexa_media/manifest.json | 4 +- custom_components/alexa_media/sensor.py | 2 +- custom_components/alexa_media/switch.py | 2 +- .../alexa_media/translations/de.json | 14 +-- .../alexa_media/translations/en.json | 14 +-- .../alexa_media/translations/es.json | 14 +-- .../alexa_media/translations/fr.json | 18 ++-- .../alexa_media/translations/it.json | 36 +++---- .../alexa_media/translations/nb.json | 14 +-- .../alexa_media/translations/nl.json | 14 +-- .../alexa_media/translations/pl.json | 22 ++--- .../alexa_media/translations/pt_BR.json | 18 ++-- .../alexa_media/translations/pt_PT.json | 14 +-- .../alexa_media/translations/ru.json | 14 +-- .../alexa_media/translations/zh-Hans.json | 18 ++-- custom_components/weenect/__init__.py | 8 +- custom_components/weenect/config_flow.py | 6 +- custom_components/weenect/const.py | 2 +- custom_components/weenect/device_tracker.py | 90 +++++++++++++++-- custom_components/weenect/sensor.py | 17 ++-- custom_components/weenect/services.py | 99 ++----------------- custom_components/weenect/services.yaml | 47 +++++---- custom_components/weenect/util.py | 2 +- 36 files changed, 350 insertions(+), 351 deletions(-) diff --git a/custom_components/alexa_media/.translations/de.json b/custom_components/alexa_media/.translations/de.json index 3127aa2e..15a60736 100644 --- a/custom_components/alexa_media/.translations/de.json +++ b/custom_components/alexa_media/.translations/de.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nDen Zwei Faktor Pin eingeben. \n{message}", "title": "Alexa Media Player - Zwei Faktor Authentifizierung" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Erweitertes debugging", "email": "Email Adresse", "exclude_devices": "Ausgeschlossene Geräte (komma getrennnt)", + "hass_url": "Url to access Home Assistant", "include_devices": "Eingebundene Geräte (komma getrennnt)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA Code (empfohlen, um Anmeldeprobleme zu vermeiden)", "url": "Amazon Region (z.B., amazon.de)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Bitte geben Sie ihre Informationen ein.", + "title": "Alexa Media Player - Konfiguration" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Erweitertes debugging", "email": "Email Adresse", "exclude_devices": "Ausgeschlossene Geräte (komma getrennnt)", - "hass_url": "Url to access Home Assistant", "include_devices": "Eingebundene Geräte (komma getrennnt)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA Code (empfohlen, um Anmeldeprobleme zu vermeiden)", "url": "Amazon Region (z.B., amazon.de)" }, - "description": "Bitte geben Sie ihre Informationen ein.", - "title": "Alexa Media Player - Konfiguration" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/.translations/en.json b/custom_components/alexa_media/.translations/en.json index 4b0ea68f..f52044a0 100644 --- a/custom_components/alexa_media/.translations/en.json +++ b/custom_components/alexa_media/.translations/en.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nEnter the One Time Password (OTP). \n{message}", "title": "Alexa Media Player - Two Factor Authentication" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "Cookies.txt data", "debug": "Advanced debugging", "email": "Email Address", "exclude_devices": "Excluded device (comma separated)", + "hass_url": "Url to access Home Assistant", "include_devices": "Included device (comma separated)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Amazon region domain (e.g., amazon.co.uk)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Please confirm the information below. For legacy configuration, disable `Use Login Proxy method` option.", + "title": "Alexa Media Player - Configuration" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "Cookies.txt data", "debug": "Advanced debugging", "email": "Email Address", "exclude_devices": "Excluded device (comma separated)", - "hass_url": "Url to access Home Assistant", "include_devices": "Included device (comma separated)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Amazon region domain (e.g., amazon.co.uk)" }, - "description": "Please confirm the information below. For legacy configuration, disable `Use Login Proxy method` option.", - "title": "Alexa Media Player - Configuration" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/.translations/es.json b/custom_components/alexa_media/.translations/es.json index eabeb590..d1ddc7a7 100644 --- a/custom_components/alexa_media/.translations/es.json +++ b/custom_components/alexa_media/.translations/es.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nIngrese la contraseña de un solo uso (OTP). \n{message}", "title": "Alexa Media Player - Autenticación de dos factores" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "Datos de Cookies.txt", "debug": "Depuración avanzada", "email": "Dirección de correo electrónico", "exclude_devices": "Dispositivo excluido (separado por comas)", + "hass_url": "Url to access Home Assistant", "include_devices": "Dispositivo incluido (separado por comas)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de inicio de sesión)", "url": "Región del dominio de Amazon (por ejemplo, amazon.es)" }, - "description": "Por favor introduce tu [información](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **El método más rápido es [Importar cookies](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import).** \n**ADVERTENCIA: Amazon informará 'Introduce un correo electrónico o número de teléfono válido' si tu cuenta utiliza [códigos 2FA - Segundo Factor de Autenticación](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Confirme la siguiente información. Para la configuración heredada, desactive la opción `Usar método de proxy de inicio de sesión`.", + "title": "Alexa Media Player - Configuración" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "Datos de Cookies.txt", "debug": "Depuración avanzada", "email": "Dirección de correo electrónico", "exclude_devices": "Dispositivo excluido (separado por comas)", - "hass_url": "Url to access Home Assistant", "include_devices": "Dispositivo incluido (separado por comas)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de inicio de sesión)", "url": "Región del dominio de Amazon (por ejemplo, amazon.es)" }, - "description": "Confirme la siguiente información. Para la configuración heredada, desactive la opción `Usar método de proxy de inicio de sesión`.", - "title": "Alexa Media Player - Configuración" + "description": "Por favor introduce tu [información](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **El método más rápido es [Importar cookies](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import).** \n**ADVERTENCIA: Amazon informará 'Introduce un correo electrónico o número de teléfono válido' si tu cuenta utiliza [códigos 2FA - Segundo Factor de Autenticación](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/.translations/fr.json b/custom_components/alexa_media/.translations/fr.json index 7bc3c144..6d73c4e9 100644 --- a/custom_components/alexa_media/.translations/fr.json +++ b/custom_components/alexa_media/.translations/fr.json @@ -62,14 +62,15 @@ "description": "**{email} - alexa.{url}** \nEntrez le mot de passe unique (OTP). \n{message}", "title": "Alexa Media Player - Authentification à deux facteurs" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "Données cookies.txt", "debug": "Débogage avancé", "email": "Adresse Email", "exclude_devices": "Appareil exclu (séparé par des virgules)", + "hass_url": "Url to access Home Assistant", "include_devices": "Appareil inclus (séparé par des virgules)", - "oauth_login": "Activer la méthode d'application oauth-token", + "oauth_login": "Enable oauth-token app method", "otp_secret": "Clé d'application 2FA intégrée (génère automatiquement des codes 2FA)", "password": "Mot de passe", "proxy": "Use Login Proxy method (2FA not required)", @@ -77,18 +78,17 @@ "securitycode": "Code 2FA (recommandé pour éviter les problèmes de connexion)", "url": "Domaine de la région Amazon (exemple, amazon.fr)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Veuillez confirmer les informations ci-dessous. Pour la configuration héritée, désactivez l'option `Utiliser la méthode proxy de connexion`.", + "title": "Alexa Media Player - Configuration" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "Données cookies.txt", "debug": "Débogage avancé", "email": "Adresse Email", "exclude_devices": "Appareil exclu (séparé par des virgules)", - "hass_url": "Url to access Home Assistant", "include_devices": "Appareil inclus (séparé par des virgules)", - "oauth_login": "Enable oauth-token app method", + "oauth_login": "Activer la méthode d'application oauth-token", "otp_secret": "Clé d'application 2FA intégrée (génère automatiquement des codes 2FA)", "password": "Mot de passe", "proxy": "Use Login Proxy method (2FA not required)", @@ -96,8 +96,8 @@ "securitycode": "Code 2FA (recommandé pour éviter les problèmes de connexion)", "url": "Domaine de la région Amazon (exemple, amazon.fr)" }, - "description": "Veuillez confirmer les informations ci-dessous. Pour la configuration héritée, désactivez l'option `Utiliser la méthode proxy de connexion`.", - "title": "Alexa Media Player - Configuration" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/.translations/it.json b/custom_components/alexa_media/.translations/it.json index f7a88a20..8d0c8998 100644 --- a/custom_components/alexa_media/.translations/it.json +++ b/custom_components/alexa_media/.translations/it.json @@ -62,24 +62,6 @@ "description": "**{email} - alexa.{url}** \nInserisci la password usa e getta (OTP). \n{message}", "title": "Alexa Media Player - Autenticazione a Due Fattori" }, - "user_legacy": { - "data": { - "cookies_txt": "config::step::user::data::cookies_txt", - "debug": "Debug avanzato", - "email": "Indirizzo email", - "exclude_devices": "Dispositivi da escludere (separati da virgola)", - "include_devices": "Dispositivi da includere (separati da virgola)", - "oauth_login": "Abilitare il metodo oauth-token app", - "otp_secret": "Chiave 2FA interna (genera automaticamente i codici 2FA)", - "password": "Password", - "proxy": "Usa il Proxy come metodo di login (2FA non richiesta)", - "scan_interval": "Tempo in secondi fra le scansioni", - "securitycode": "Codice 2FA (raccomandato per evitare problemi di login)", - "url": "Regione del dominio Amazon (e.g. amazon.it)" - }, - "description": "Prego inserisci le tue [informazioni](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) potrebbe essere più semplice!** \n**ATTENZIONE: Amazon risponde incorrettamente 'Inserire una mail valida o un numero di telefono' quando è richiesto il codice 2FA](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" - }, "user": { "data": { "cookies_txt": "Dati cookies.txt", @@ -98,6 +80,24 @@ }, "description": "Confermare le informazioni sottostanti. Per le vecchie configurazioni, disabilitare l'opzione `Usa Proxy come metodo di login`.", "title": "Alexa Media Player - Configurazione" + }, + "user_legacy": { + "data": { + "cookies_txt": "Dati cookies.txt", + "debug": "Debug avanzato", + "email": "Indirizzo email", + "exclude_devices": "Dispositivi da escludere (separati da virgola)", + "include_devices": "Dispositivi da includere (separati da virgola)", + "oauth_login": "Abilitare il metodo oauth-token app", + "otp_secret": "Chiave 2FA interna (genera automaticamente i codici 2FA)", + "password": "Password", + "proxy": "Usa il Proxy come metodo di login (2FA non richiesta)", + "scan_interval": "Tempo in secondi fra le scansioni", + "securitycode": "Codice 2FA (raccomandato per evitare problemi di login)", + "url": "Regione del dominio Amazon (e.g. amazon.it)" + }, + "description": "Prego inserisci le tue [informazioni](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) potrebbe essere più semplice!** \n**ATTENZIONE: Amazon risponde incorrettamente 'Inserire una mail valida o un numero di telefono' quando è richiesto il codice 2FA](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/.translations/nb.json b/custom_components/alexa_media/.translations/nb.json index 7aa95324..333797c9 100644 --- a/custom_components/alexa_media/.translations/nb.json +++ b/custom_components/alexa_media/.translations/nb.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nSkriv inn engangspassordet (OTP). \n>{message}", "title": "Alexa Media Player - Tofaktorautentisering" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Avansert feilsøking", "email": "Epostadresse", "exclude_devices": "Ekskludert enhet (kommaseparert)", + "hass_url": "Url to access Home Assistant", "include_devices": "Inkluder enhet (kommaseparert)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA-kode (anbefales for å unngå påloggingsproblemer)", "url": "Amazon-regiondomenet (f.eks. Amazon.co.uk)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Bekreft informasjonen nedenfor. For eldre konfigurasjon, deaktiver alternativet \"Bruk innlogging proxy-metode\".", + "title": "Alexa Media Player - Konfigurasjon" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Avansert feilsøking", "email": "Epostadresse", "exclude_devices": "Ekskludert enhet (kommaseparert)", - "hass_url": "Url to access Home Assistant", "include_devices": "Inkluder enhet (kommaseparert)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA-kode (anbefales for å unngå påloggingsproblemer)", "url": "Amazon-regiondomenet (f.eks. Amazon.co.uk)" }, - "description": "Bekreft informasjonen nedenfor. For eldre konfigurasjon, deaktiver alternativet \"Bruk innlogging proxy-metode\".", - "title": "Alexa Media Player - Konfigurasjon" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/.translations/nl.json b/custom_components/alexa_media/.translations/nl.json index 820662c5..9a4afdbe 100644 --- a/custom_components/alexa_media/.translations/nl.json +++ b/custom_components/alexa_media/.translations/nl.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nGeef de verificatiecode in. \n{message}", "title": "Alexa Media Player - Tweestapsverificatie" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Geavanceerd debuggen", "email": "E-mailadres", "exclude_devices": "Apparaten uitsluiten (Scheiding: komma)", + "hass_url": "Url to access Home Assistant", "include_devices": "Apparaten toevoegen (Scheiding: komma)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Domeinnaam van Amazon regio (bv.amazon.co.uk)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Vul je gegevens in a.u.b.", + "title": "Alexa Media Player - Configuratie" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Geavanceerd debuggen", "email": "E-mailadres", "exclude_devices": "Apparaten uitsluiten (Scheiding: komma)", - "hass_url": "Url to access Home Assistant", "include_devices": "Apparaten toevoegen (Scheiding: komma)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Domeinnaam van Amazon regio (bv.amazon.co.uk)" }, - "description": "Vul je gegevens in a.u.b.", - "title": "Alexa Media Player - Configuratie" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/.translations/pl.json b/custom_components/alexa_media/.translations/pl.json index 32d7f3a2..eb6a80ed 100644 --- a/custom_components/alexa_media/.translations/pl.json +++ b/custom_components/alexa_media/.translations/pl.json @@ -62,42 +62,42 @@ "description": "**{email} - alexa.{url}** \nWprowadź hasło jednorazowe (OTP). \n{message}", "title": "Alexa Media Player — uwierzytelnianie dwuskładnikowe" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "zawartość pliku cookies.txt", "debug": "Zaawansowane debugowanie", - "email": "Adres e-mail", + "email": "Adres email", "exclude_devices": "Wykluczone urządzenia (oddzielone przecinkami)", + "hass_url": "URL dostępu do Home Assistanta", "include_devices": "Dodawane urządzenia (oddzielone przecinkami)", "oauth_login": "Włącz metodę tokena OAuth aplikacji", "otp_secret": "Wbudowana aplikacja kluczy uwierzytelniania dwuskładnikowego (automatycznie generuje kody uwierzytelniania dwuskładnikowego)", "password": "Hasło", "proxy": "Użyj metody logowania proxy (2FA nie jest wymagane)", "scan_interval": "Interwał skanowania (sekundy)", - "securitycode": "Kod uwierzytelniania dwuskładnikowego", + "securitycode": "Kod uwierzytelniania dwuskładnikowego (zalecany w celu uniknięcia problemów z logowaniem)", "url": "Region/domena Amazon (np. amazon.co.uk)" }, - "description": "Wprowadź [dane](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Import pliku Cookie](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) może być najłatwiejszą metodą!** \n**OSTRZEŻENIE: Amazon nieprawidłowo zgłasza 'Wprowadź prawidłowy adres e-mail lub numer telefonu komórkowego', gdy wymagany jest [kod uwierzytelniania dwuskładnikowego](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player — starsza konfiguracja" + "description": "Potwierdź poniższe informacje. W przypadku starszych konfiguracji wyłącz opcję 'Użyj metody logowania proxy'.", + "title": "Alexa Media Player — konfiguracja" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "zawartość pliku cookies.txt", "debug": "Zaawansowane debugowanie", - "email": "Adres email", + "email": "Adres e-mail", "exclude_devices": "Wykluczone urządzenia (oddzielone przecinkami)", - "hass_url": "URL dostępu do Home Assistanta", "include_devices": "Dodawane urządzenia (oddzielone przecinkami)", "oauth_login": "Włącz metodę tokena OAuth aplikacji", "otp_secret": "Wbudowana aplikacja kluczy uwierzytelniania dwuskładnikowego (automatycznie generuje kody uwierzytelniania dwuskładnikowego)", "password": "Hasło", "proxy": "Użyj metody logowania proxy (2FA nie jest wymagane)", "scan_interval": "Interwał skanowania (sekundy)", - "securitycode": "Kod uwierzytelniania dwuskładnikowego (zalecany w celu uniknięcia problemów z logowaniem)", + "securitycode": "Kod uwierzytelniania dwuskładnikowego", "url": "Region/domena Amazon (np. amazon.co.uk)" }, - "description": "Potwierdź poniższe informacje. W przypadku starszych konfiguracji wyłącz opcję 'Użyj metody logowania proxy'.", - "title": "Alexa Media Player — konfiguracja" + "description": "Wprowadź [dane](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Import pliku Cookie](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) może być najłatwiejszą metodą!** \n**OSTRZEŻENIE: Amazon nieprawidłowo zgłasza 'Wprowadź prawidłowy adres e-mail lub numer telefonu komórkowego', gdy wymagany jest [kod uwierzytelniania dwuskładnikowego](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player — starsza konfiguracja" } } }, diff --git a/custom_components/alexa_media/.translations/pt_BR.json b/custom_components/alexa_media/.translations/pt_BR.json index c519b553..2696cc29 100644 --- a/custom_components/alexa_media/.translations/pt_BR.json +++ b/custom_components/alexa_media/.translations/pt_BR.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nInsira a senha de uso único (OTP).\n{message}", "title": "Alexa Media Player - Autenticação de dois fatores" }, - "user_legacy": { + "user": { "data": { - "cookies_txt": "Cookies.txt data", + "cookies_txt": "Dados de cookies.txt", "debug": "Depuração avançada", "email": "Endereço de email", "exclude_devices": "Dispositivos exclusos (separados por virgula)", + "hass_url": "Url para acesso ao Home Assistant", "include_devices": "Dispositivos inclusos (separados por vírgula)", "oauth_login": "Habilitar o aplicativo para método auth-token", "otp_secret": "Aplicativo integrado para chaves 2FA (Automaticamente gera códigos 2FA)", @@ -77,16 +78,15 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de login)", "url": "Domínio regional da amazon (ex: amazon.co.uk)" }, - "description": "Por favor insira sua [informação](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) pode ser mais fácil!** \n**AVISO! A amazon reporta incorretamente 'Insira um email ou número de telefone válido' quando [Código de 2FA é requirido](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Configurações legado" + "description": "Por favor, confirme as informações abaixo. Para configuração legada, desative a opção `Usar método de proxy de login'.", + "title": "Alexa Media Player - Configurações" }, - "user": { + "user_legacy": { "data": { - "cookies_txt": "Dados de cookies.txt", + "cookies_txt": "Cookies.txt data", "debug": "Depuração avançada", "email": "Endereço de email", "exclude_devices": "Dispositivos exclusos (separados por virgula)", - "hass_url": "Url para acesso ao Home Assistant", "include_devices": "Dispositivos inclusos (separados por vírgula)", "oauth_login": "Habilitar o aplicativo para método auth-token", "otp_secret": "Aplicativo integrado para chaves 2FA (Automaticamente gera códigos 2FA)", @@ -96,8 +96,8 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de login)", "url": "Domínio regional da amazon (ex: amazon.co.uk)" }, - "description": "Por favor, confirme as informações abaixo. Para configuração legada, desative a opção `Usar método de proxy de login'.", - "title": "Alexa Media Player - Configurações" + "description": "Por favor insira sua [informação](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) pode ser mais fácil!** \n**AVISO! A amazon reporta incorretamente 'Insira um email ou número de telefone válido' quando [Código de 2FA é requirido](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Configurações legado" } } }, diff --git a/custom_components/alexa_media/.translations/pt_PT.json b/custom_components/alexa_media/.translations/pt_PT.json index 1197e578..5cf76c7d 100644 --- a/custom_components/alexa_media/.translations/pt_PT.json +++ b/custom_components/alexa_media/.translations/pt_PT.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nDigite a senha de uso único (OTP). \n{message}", "title": "Alexa Media Player - autenticação de dois fatores" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "Dados de cookies.txt", "debug": "Depuração avançada", "email": "Endereço de e-mail", "exclude_devices": "Dispositivo excluído (separado por vírgula)", + "hass_url": "URL para aceder o Home Assistant", "include_devices": "Dispositivo incluído (separado por vírgula)", "oauth_login": "Habilitar método de aplicativo oauth-token", "otp_secret": "Chave de aplicativo 2FA integrada (gerar códigos 2FA automaticamente)", @@ -77,16 +78,15 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de login)", "url": "Região do domínio Amazon (ex. amazon.com.br)" }, - "description": "Por favor, introduza a sua [informação](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) pode ser mais fácil!** \n**Aviso: a Amazon informa incorretamente 'Insira um e-mail ou número de celular válido' quando [2FA Code é necessário](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Configuração de Compatibilidade" + "description": "Por favor, confirme as informações abaixo. Para configuração de compatibilidade, desative a opção 'Usar método de proxy de login'.", + "title": "Alexa Media Player - Configuração" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "Dados de cookies.txt", "debug": "Depuração avançada", "email": "Endereço de e-mail", "exclude_devices": "Dispositivo excluído (separado por vírgula)", - "hass_url": "URL para aceder o Home Assistant", "include_devices": "Dispositivo incluído (separado por vírgula)", "oauth_login": "Habilitar método de aplicativo oauth-token", "otp_secret": "Chave de aplicativo 2FA integrada (gerar códigos 2FA automaticamente)", @@ -96,8 +96,8 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de login)", "url": "Região do domínio Amazon (ex. amazon.com.br)" }, - "description": "Por favor, confirme as informações abaixo. Para configuração de compatibilidade, desative a opção 'Usar método de proxy de login'.", - "title": "Alexa Media Player - Configuração" + "description": "Por favor, introduza a sua [informação](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) pode ser mais fácil!** \n**Aviso: a Amazon informa incorretamente 'Insira um e-mail ou número de celular válido' quando [2FA Code é necessário](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Configuração de Compatibilidade" } } }, diff --git a/custom_components/alexa_media/.translations/ru.json b/custom_components/alexa_media/.translations/ru.json index b3519b58..ee10f828 100644 --- a/custom_components/alexa_media/.translations/ru.json +++ b/custom_components/alexa_media/.translations/ru.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}**\nВведите одноразовый пароль.\n{message}", "title": "Alexa Media Player - Двух факторная идентификация" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Расширенные возможности отладки", "email": "Адрес электронной почты", "exclude_devices": "Исключенные устройства (через запятую)", + "hass_url": "Url to access Home Assistant", "include_devices": "Включенные устройства (разделенное запятыми)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Домен региона Amazon (например, amazon.co.uk)" }, - "description": "Пожалуйста, введите свои данные.{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Пожалуйста, подтвердите информацию ниже. Для старой конфигурации отключите опцию `Use Login Proxy method`.", + "title": "Alexa Media Player - Конфигурация" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Расширенные возможности отладки", "email": "Адрес электронной почты", "exclude_devices": "Исключенные устройства (через запятую)", - "hass_url": "Url to access Home Assistant", "include_devices": "Включенные устройства (разделенное запятыми)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Домен региона Amazon (например, amazon.co.uk)" }, - "description": "Пожалуйста, подтвердите информацию ниже. Для старой конфигурации отключите опцию `Use Login Proxy method`.", - "title": "Alexa Media Player - Конфигурация" + "description": "Пожалуйста, введите свои данные.{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/.translations/zh-Hans.json b/custom_components/alexa_media/.translations/zh-Hans.json index e848d777..4af369e3 100644 --- a/custom_components/alexa_media/.translations/zh-Hans.json +++ b/custom_components/alexa_media/.translations/zh-Hans.json @@ -62,12 +62,13 @@ "description": "**{email} - Alexa.{url} ** \n输入一次性密码(OTP)。 \n {message}", "title": "Alexa Media Player - Two Factor Authentication" }, - "user_legacy": { + "user": { "data": { - "cookies_txt": "config::step::user::data::cookies_txt", + "cookies_txt": "Cookie.txt数据", "debug": "高级调试", "email": "电子邮件地址", "exclude_devices": "Excluded device (comma separated)", + "hass_url": "Url to access Home Assistant", "include_devices": "Included device (comma separated)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Amazon region domain (e.g., amazon.co.uk)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "请确认以下信息。对于旧版配置,请禁用“使用登录代理方法”选项。", + "title": "Alexa Media Player-配置" }, - "user": { + "user_legacy": { "data": { - "cookies_txt": "Cookie.txt数据", + "cookies_txt": "config::step::user::data::cookies_txt", "debug": "高级调试", "email": "电子邮件地址", "exclude_devices": "Excluded device (comma separated)", - "hass_url": "Url to access Home Assistant", "include_devices": "Included device (comma separated)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Amazon region domain (e.g., amazon.co.uk)" }, - "description": "请确认以下信息。对于旧版配置,请禁用“使用登录代理方法”选项。", - "title": "Alexa Media Player-配置" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/const.py b/custom_components/alexa_media/const.py index c812ed3f..24289675 100644 --- a/custom_components/alexa_media/const.py +++ b/custom_components/alexa_media/const.py @@ -8,7 +8,7 @@ """ from datetime import timedelta -__version__ = "3.10.8" +__version__ = "3.10.10" PROJECT_URL = "https://github.com/custom-components/alexa_media_player/" ISSUE_URL = f"{PROJECT_URL}issues" diff --git a/custom_components/alexa_media/manifest.json b/custom_components/alexa_media/manifest.json index c506a1db..4bed4f00 100644 --- a/custom_components/alexa_media/manifest.json +++ b/custom_components/alexa_media/manifest.json @@ -1,12 +1,12 @@ { "domain": "alexa_media", "name": "Alexa Media Player", - "version": "3.10.8", + "version": "3.10.10", "config_flow": true, "documentation": "https://github.com/custom-components/alexa_media_player/wiki", "issue_tracker": "https://github.com/custom-components/alexa_media_player/issues", "dependencies": ["persistent_notification", "http"], "codeowners": ["@keatontaylor", "@alandtse"], - "requirements": ["alexapy==1.25.1", "packaging~=20.3", "wrapt~=1.12.1"], + "requirements": ["alexapy==1.25.1", "packaging>=20.3", "wrapt~=1.12.1"], "iot_class": "cloud_polling" } diff --git a/custom_components/alexa_media/sensor.py b/custom_components/alexa_media/sensor.py index 7030e251..0b30f5ff 100644 --- a/custom_components/alexa_media/sensor.py +++ b/custom_components/alexa_media/sensor.py @@ -500,7 +500,7 @@ async def async_update(self): account_dict = self.hass.data[DATA_ALEXAMEDIA]["accounts"][self._account] self._timestamp = account_dict["notifications"]["process_timestamp"] try: - self._n_dict = account_dict["notifications"][self._dev_id][self._type] + self._n_dict = account_dict["notifications"][self._client.device_serial_number][self._type] except KeyError: self._n_dict = None self._process_raw_notifications() diff --git a/custom_components/alexa_media/switch.py b/custom_components/alexa_media/switch.py index 21ab7c34..ebce7ecc 100644 --- a/custom_components/alexa_media/switch.py +++ b/custom_components/alexa_media/switch.py @@ -309,7 +309,7 @@ def __init__(self, client): @property def icon(self): """Return the icon of the switch.""" - return super()._icon("mdi:do-not-disturb", "mdi:do-not-disturb-off") + return super()._icon("mdi:minus-circle", "mdi:minus-circle-off") def _handle_event(self, event): """Handle events.""" diff --git a/custom_components/alexa_media/translations/de.json b/custom_components/alexa_media/translations/de.json index 3127aa2e..15a60736 100644 --- a/custom_components/alexa_media/translations/de.json +++ b/custom_components/alexa_media/translations/de.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nDen Zwei Faktor Pin eingeben. \n{message}", "title": "Alexa Media Player - Zwei Faktor Authentifizierung" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Erweitertes debugging", "email": "Email Adresse", "exclude_devices": "Ausgeschlossene Geräte (komma getrennnt)", + "hass_url": "Url to access Home Assistant", "include_devices": "Eingebundene Geräte (komma getrennnt)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA Code (empfohlen, um Anmeldeprobleme zu vermeiden)", "url": "Amazon Region (z.B., amazon.de)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Bitte geben Sie ihre Informationen ein.", + "title": "Alexa Media Player - Konfiguration" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Erweitertes debugging", "email": "Email Adresse", "exclude_devices": "Ausgeschlossene Geräte (komma getrennnt)", - "hass_url": "Url to access Home Assistant", "include_devices": "Eingebundene Geräte (komma getrennnt)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA Code (empfohlen, um Anmeldeprobleme zu vermeiden)", "url": "Amazon Region (z.B., amazon.de)" }, - "description": "Bitte geben Sie ihre Informationen ein.", - "title": "Alexa Media Player - Konfiguration" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/translations/en.json b/custom_components/alexa_media/translations/en.json index 4b0ea68f..f52044a0 100644 --- a/custom_components/alexa_media/translations/en.json +++ b/custom_components/alexa_media/translations/en.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nEnter the One Time Password (OTP). \n{message}", "title": "Alexa Media Player - Two Factor Authentication" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "Cookies.txt data", "debug": "Advanced debugging", "email": "Email Address", "exclude_devices": "Excluded device (comma separated)", + "hass_url": "Url to access Home Assistant", "include_devices": "Included device (comma separated)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Amazon region domain (e.g., amazon.co.uk)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Please confirm the information below. For legacy configuration, disable `Use Login Proxy method` option.", + "title": "Alexa Media Player - Configuration" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "Cookies.txt data", "debug": "Advanced debugging", "email": "Email Address", "exclude_devices": "Excluded device (comma separated)", - "hass_url": "Url to access Home Assistant", "include_devices": "Included device (comma separated)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Amazon region domain (e.g., amazon.co.uk)" }, - "description": "Please confirm the information below. For legacy configuration, disable `Use Login Proxy method` option.", - "title": "Alexa Media Player - Configuration" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/translations/es.json b/custom_components/alexa_media/translations/es.json index eabeb590..d1ddc7a7 100644 --- a/custom_components/alexa_media/translations/es.json +++ b/custom_components/alexa_media/translations/es.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nIngrese la contraseña de un solo uso (OTP). \n{message}", "title": "Alexa Media Player - Autenticación de dos factores" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "Datos de Cookies.txt", "debug": "Depuración avanzada", "email": "Dirección de correo electrónico", "exclude_devices": "Dispositivo excluido (separado por comas)", + "hass_url": "Url to access Home Assistant", "include_devices": "Dispositivo incluido (separado por comas)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de inicio de sesión)", "url": "Región del dominio de Amazon (por ejemplo, amazon.es)" }, - "description": "Por favor introduce tu [información](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **El método más rápido es [Importar cookies](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import).** \n**ADVERTENCIA: Amazon informará 'Introduce un correo electrónico o número de teléfono válido' si tu cuenta utiliza [códigos 2FA - Segundo Factor de Autenticación](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Confirme la siguiente información. Para la configuración heredada, desactive la opción `Usar método de proxy de inicio de sesión`.", + "title": "Alexa Media Player - Configuración" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "Datos de Cookies.txt", "debug": "Depuración avanzada", "email": "Dirección de correo electrónico", "exclude_devices": "Dispositivo excluido (separado por comas)", - "hass_url": "Url to access Home Assistant", "include_devices": "Dispositivo incluido (separado por comas)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de inicio de sesión)", "url": "Región del dominio de Amazon (por ejemplo, amazon.es)" }, - "description": "Confirme la siguiente información. Para la configuración heredada, desactive la opción `Usar método de proxy de inicio de sesión`.", - "title": "Alexa Media Player - Configuración" + "description": "Por favor introduce tu [información](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **El método más rápido es [Importar cookies](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import).** \n**ADVERTENCIA: Amazon informará 'Introduce un correo electrónico o número de teléfono válido' si tu cuenta utiliza [códigos 2FA - Segundo Factor de Autenticación](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/translations/fr.json b/custom_components/alexa_media/translations/fr.json index 7bc3c144..6d73c4e9 100644 --- a/custom_components/alexa_media/translations/fr.json +++ b/custom_components/alexa_media/translations/fr.json @@ -62,14 +62,15 @@ "description": "**{email} - alexa.{url}** \nEntrez le mot de passe unique (OTP). \n{message}", "title": "Alexa Media Player - Authentification à deux facteurs" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "Données cookies.txt", "debug": "Débogage avancé", "email": "Adresse Email", "exclude_devices": "Appareil exclu (séparé par des virgules)", + "hass_url": "Url to access Home Assistant", "include_devices": "Appareil inclus (séparé par des virgules)", - "oauth_login": "Activer la méthode d'application oauth-token", + "oauth_login": "Enable oauth-token app method", "otp_secret": "Clé d'application 2FA intégrée (génère automatiquement des codes 2FA)", "password": "Mot de passe", "proxy": "Use Login Proxy method (2FA not required)", @@ -77,18 +78,17 @@ "securitycode": "Code 2FA (recommandé pour éviter les problèmes de connexion)", "url": "Domaine de la région Amazon (exemple, amazon.fr)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Veuillez confirmer les informations ci-dessous. Pour la configuration héritée, désactivez l'option `Utiliser la méthode proxy de connexion`.", + "title": "Alexa Media Player - Configuration" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "Données cookies.txt", "debug": "Débogage avancé", "email": "Adresse Email", "exclude_devices": "Appareil exclu (séparé par des virgules)", - "hass_url": "Url to access Home Assistant", "include_devices": "Appareil inclus (séparé par des virgules)", - "oauth_login": "Enable oauth-token app method", + "oauth_login": "Activer la méthode d'application oauth-token", "otp_secret": "Clé d'application 2FA intégrée (génère automatiquement des codes 2FA)", "password": "Mot de passe", "proxy": "Use Login Proxy method (2FA not required)", @@ -96,8 +96,8 @@ "securitycode": "Code 2FA (recommandé pour éviter les problèmes de connexion)", "url": "Domaine de la région Amazon (exemple, amazon.fr)" }, - "description": "Veuillez confirmer les informations ci-dessous. Pour la configuration héritée, désactivez l'option `Utiliser la méthode proxy de connexion`.", - "title": "Alexa Media Player - Configuration" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/translations/it.json b/custom_components/alexa_media/translations/it.json index f7a88a20..8d0c8998 100644 --- a/custom_components/alexa_media/translations/it.json +++ b/custom_components/alexa_media/translations/it.json @@ -62,24 +62,6 @@ "description": "**{email} - alexa.{url}** \nInserisci la password usa e getta (OTP). \n{message}", "title": "Alexa Media Player - Autenticazione a Due Fattori" }, - "user_legacy": { - "data": { - "cookies_txt": "config::step::user::data::cookies_txt", - "debug": "Debug avanzato", - "email": "Indirizzo email", - "exclude_devices": "Dispositivi da escludere (separati da virgola)", - "include_devices": "Dispositivi da includere (separati da virgola)", - "oauth_login": "Abilitare il metodo oauth-token app", - "otp_secret": "Chiave 2FA interna (genera automaticamente i codici 2FA)", - "password": "Password", - "proxy": "Usa il Proxy come metodo di login (2FA non richiesta)", - "scan_interval": "Tempo in secondi fra le scansioni", - "securitycode": "Codice 2FA (raccomandato per evitare problemi di login)", - "url": "Regione del dominio Amazon (e.g. amazon.it)" - }, - "description": "Prego inserisci le tue [informazioni](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) potrebbe essere più semplice!** \n**ATTENZIONE: Amazon risponde incorrettamente 'Inserire una mail valida o un numero di telefono' quando è richiesto il codice 2FA](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" - }, "user": { "data": { "cookies_txt": "Dati cookies.txt", @@ -98,6 +80,24 @@ }, "description": "Confermare le informazioni sottostanti. Per le vecchie configurazioni, disabilitare l'opzione `Usa Proxy come metodo di login`.", "title": "Alexa Media Player - Configurazione" + }, + "user_legacy": { + "data": { + "cookies_txt": "Dati cookies.txt", + "debug": "Debug avanzato", + "email": "Indirizzo email", + "exclude_devices": "Dispositivi da escludere (separati da virgola)", + "include_devices": "Dispositivi da includere (separati da virgola)", + "oauth_login": "Abilitare il metodo oauth-token app", + "otp_secret": "Chiave 2FA interna (genera automaticamente i codici 2FA)", + "password": "Password", + "proxy": "Usa il Proxy come metodo di login (2FA non richiesta)", + "scan_interval": "Tempo in secondi fra le scansioni", + "securitycode": "Codice 2FA (raccomandato per evitare problemi di login)", + "url": "Regione del dominio Amazon (e.g. amazon.it)" + }, + "description": "Prego inserisci le tue [informazioni](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) potrebbe essere più semplice!** \n**ATTENZIONE: Amazon risponde incorrettamente 'Inserire una mail valida o un numero di telefono' quando è richiesto il codice 2FA](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/translations/nb.json b/custom_components/alexa_media/translations/nb.json index 7aa95324..333797c9 100644 --- a/custom_components/alexa_media/translations/nb.json +++ b/custom_components/alexa_media/translations/nb.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nSkriv inn engangspassordet (OTP). \n>{message}", "title": "Alexa Media Player - Tofaktorautentisering" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Avansert feilsøking", "email": "Epostadresse", "exclude_devices": "Ekskludert enhet (kommaseparert)", + "hass_url": "Url to access Home Assistant", "include_devices": "Inkluder enhet (kommaseparert)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA-kode (anbefales for å unngå påloggingsproblemer)", "url": "Amazon-regiondomenet (f.eks. Amazon.co.uk)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Bekreft informasjonen nedenfor. For eldre konfigurasjon, deaktiver alternativet \"Bruk innlogging proxy-metode\".", + "title": "Alexa Media Player - Konfigurasjon" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Avansert feilsøking", "email": "Epostadresse", "exclude_devices": "Ekskludert enhet (kommaseparert)", - "hass_url": "Url to access Home Assistant", "include_devices": "Inkluder enhet (kommaseparert)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA-kode (anbefales for å unngå påloggingsproblemer)", "url": "Amazon-regiondomenet (f.eks. Amazon.co.uk)" }, - "description": "Bekreft informasjonen nedenfor. For eldre konfigurasjon, deaktiver alternativet \"Bruk innlogging proxy-metode\".", - "title": "Alexa Media Player - Konfigurasjon" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/translations/nl.json b/custom_components/alexa_media/translations/nl.json index 820662c5..9a4afdbe 100644 --- a/custom_components/alexa_media/translations/nl.json +++ b/custom_components/alexa_media/translations/nl.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nGeef de verificatiecode in. \n{message}", "title": "Alexa Media Player - Tweestapsverificatie" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Geavanceerd debuggen", "email": "E-mailadres", "exclude_devices": "Apparaten uitsluiten (Scheiding: komma)", + "hass_url": "Url to access Home Assistant", "include_devices": "Apparaten toevoegen (Scheiding: komma)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Domeinnaam van Amazon regio (bv.amazon.co.uk)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Vul je gegevens in a.u.b.", + "title": "Alexa Media Player - Configuratie" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Geavanceerd debuggen", "email": "E-mailadres", "exclude_devices": "Apparaten uitsluiten (Scheiding: komma)", - "hass_url": "Url to access Home Assistant", "include_devices": "Apparaten toevoegen (Scheiding: komma)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Domeinnaam van Amazon regio (bv.amazon.co.uk)" }, - "description": "Vul je gegevens in a.u.b.", - "title": "Alexa Media Player - Configuratie" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/translations/pl.json b/custom_components/alexa_media/translations/pl.json index 32d7f3a2..eb6a80ed 100644 --- a/custom_components/alexa_media/translations/pl.json +++ b/custom_components/alexa_media/translations/pl.json @@ -62,42 +62,42 @@ "description": "**{email} - alexa.{url}** \nWprowadź hasło jednorazowe (OTP). \n{message}", "title": "Alexa Media Player — uwierzytelnianie dwuskładnikowe" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "zawartość pliku cookies.txt", "debug": "Zaawansowane debugowanie", - "email": "Adres e-mail", + "email": "Adres email", "exclude_devices": "Wykluczone urządzenia (oddzielone przecinkami)", + "hass_url": "URL dostępu do Home Assistanta", "include_devices": "Dodawane urządzenia (oddzielone przecinkami)", "oauth_login": "Włącz metodę tokena OAuth aplikacji", "otp_secret": "Wbudowana aplikacja kluczy uwierzytelniania dwuskładnikowego (automatycznie generuje kody uwierzytelniania dwuskładnikowego)", "password": "Hasło", "proxy": "Użyj metody logowania proxy (2FA nie jest wymagane)", "scan_interval": "Interwał skanowania (sekundy)", - "securitycode": "Kod uwierzytelniania dwuskładnikowego", + "securitycode": "Kod uwierzytelniania dwuskładnikowego (zalecany w celu uniknięcia problemów z logowaniem)", "url": "Region/domena Amazon (np. amazon.co.uk)" }, - "description": "Wprowadź [dane](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Import pliku Cookie](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) może być najłatwiejszą metodą!** \n**OSTRZEŻENIE: Amazon nieprawidłowo zgłasza 'Wprowadź prawidłowy adres e-mail lub numer telefonu komórkowego', gdy wymagany jest [kod uwierzytelniania dwuskładnikowego](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player — starsza konfiguracja" + "description": "Potwierdź poniższe informacje. W przypadku starszych konfiguracji wyłącz opcję 'Użyj metody logowania proxy'.", + "title": "Alexa Media Player — konfiguracja" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "zawartość pliku cookies.txt", "debug": "Zaawansowane debugowanie", - "email": "Adres email", + "email": "Adres e-mail", "exclude_devices": "Wykluczone urządzenia (oddzielone przecinkami)", - "hass_url": "URL dostępu do Home Assistanta", "include_devices": "Dodawane urządzenia (oddzielone przecinkami)", "oauth_login": "Włącz metodę tokena OAuth aplikacji", "otp_secret": "Wbudowana aplikacja kluczy uwierzytelniania dwuskładnikowego (automatycznie generuje kody uwierzytelniania dwuskładnikowego)", "password": "Hasło", "proxy": "Użyj metody logowania proxy (2FA nie jest wymagane)", "scan_interval": "Interwał skanowania (sekundy)", - "securitycode": "Kod uwierzytelniania dwuskładnikowego (zalecany w celu uniknięcia problemów z logowaniem)", + "securitycode": "Kod uwierzytelniania dwuskładnikowego", "url": "Region/domena Amazon (np. amazon.co.uk)" }, - "description": "Potwierdź poniższe informacje. W przypadku starszych konfiguracji wyłącz opcję 'Użyj metody logowania proxy'.", - "title": "Alexa Media Player — konfiguracja" + "description": "Wprowadź [dane](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Import pliku Cookie](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) może być najłatwiejszą metodą!** \n**OSTRZEŻENIE: Amazon nieprawidłowo zgłasza 'Wprowadź prawidłowy adres e-mail lub numer telefonu komórkowego', gdy wymagany jest [kod uwierzytelniania dwuskładnikowego](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player — starsza konfiguracja" } } }, diff --git a/custom_components/alexa_media/translations/pt_BR.json b/custom_components/alexa_media/translations/pt_BR.json index c519b553..2696cc29 100644 --- a/custom_components/alexa_media/translations/pt_BR.json +++ b/custom_components/alexa_media/translations/pt_BR.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nInsira a senha de uso único (OTP).\n{message}", "title": "Alexa Media Player - Autenticação de dois fatores" }, - "user_legacy": { + "user": { "data": { - "cookies_txt": "Cookies.txt data", + "cookies_txt": "Dados de cookies.txt", "debug": "Depuração avançada", "email": "Endereço de email", "exclude_devices": "Dispositivos exclusos (separados por virgula)", + "hass_url": "Url para acesso ao Home Assistant", "include_devices": "Dispositivos inclusos (separados por vírgula)", "oauth_login": "Habilitar o aplicativo para método auth-token", "otp_secret": "Aplicativo integrado para chaves 2FA (Automaticamente gera códigos 2FA)", @@ -77,16 +78,15 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de login)", "url": "Domínio regional da amazon (ex: amazon.co.uk)" }, - "description": "Por favor insira sua [informação](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) pode ser mais fácil!** \n**AVISO! A amazon reporta incorretamente 'Insira um email ou número de telefone válido' quando [Código de 2FA é requirido](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Configurações legado" + "description": "Por favor, confirme as informações abaixo. Para configuração legada, desative a opção `Usar método de proxy de login'.", + "title": "Alexa Media Player - Configurações" }, - "user": { + "user_legacy": { "data": { - "cookies_txt": "Dados de cookies.txt", + "cookies_txt": "Cookies.txt data", "debug": "Depuração avançada", "email": "Endereço de email", "exclude_devices": "Dispositivos exclusos (separados por virgula)", - "hass_url": "Url para acesso ao Home Assistant", "include_devices": "Dispositivos inclusos (separados por vírgula)", "oauth_login": "Habilitar o aplicativo para método auth-token", "otp_secret": "Aplicativo integrado para chaves 2FA (Automaticamente gera códigos 2FA)", @@ -96,8 +96,8 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de login)", "url": "Domínio regional da amazon (ex: amazon.co.uk)" }, - "description": "Por favor, confirme as informações abaixo. Para configuração legada, desative a opção `Usar método de proxy de login'.", - "title": "Alexa Media Player - Configurações" + "description": "Por favor insira sua [informação](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) pode ser mais fácil!** \n**AVISO! A amazon reporta incorretamente 'Insira um email ou número de telefone válido' quando [Código de 2FA é requirido](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Configurações legado" } } }, diff --git a/custom_components/alexa_media/translations/pt_PT.json b/custom_components/alexa_media/translations/pt_PT.json index 1197e578..5cf76c7d 100644 --- a/custom_components/alexa_media/translations/pt_PT.json +++ b/custom_components/alexa_media/translations/pt_PT.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}** \nDigite a senha de uso único (OTP). \n{message}", "title": "Alexa Media Player - autenticação de dois fatores" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "Dados de cookies.txt", "debug": "Depuração avançada", "email": "Endereço de e-mail", "exclude_devices": "Dispositivo excluído (separado por vírgula)", + "hass_url": "URL para aceder o Home Assistant", "include_devices": "Dispositivo incluído (separado por vírgula)", "oauth_login": "Habilitar método de aplicativo oauth-token", "otp_secret": "Chave de aplicativo 2FA integrada (gerar códigos 2FA automaticamente)", @@ -77,16 +78,15 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de login)", "url": "Região do domínio Amazon (ex. amazon.com.br)" }, - "description": "Por favor, introduza a sua [informação](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) pode ser mais fácil!** \n**Aviso: a Amazon informa incorretamente 'Insira um e-mail ou número de celular válido' quando [2FA Code é necessário](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Configuração de Compatibilidade" + "description": "Por favor, confirme as informações abaixo. Para configuração de compatibilidade, desative a opção 'Usar método de proxy de login'.", + "title": "Alexa Media Player - Configuração" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "Dados de cookies.txt", "debug": "Depuração avançada", "email": "Endereço de e-mail", "exclude_devices": "Dispositivo excluído (separado por vírgula)", - "hass_url": "URL para aceder o Home Assistant", "include_devices": "Dispositivo incluído (separado por vírgula)", "oauth_login": "Habilitar método de aplicativo oauth-token", "otp_secret": "Chave de aplicativo 2FA integrada (gerar códigos 2FA automaticamente)", @@ -96,8 +96,8 @@ "securitycode": "Código 2FA (recomendado para evitar problemas de login)", "url": "Região do domínio Amazon (ex. amazon.com.br)" }, - "description": "Por favor, confirme as informações abaixo. Para configuração de compatibilidade, desative a opção 'Usar método de proxy de login'.", - "title": "Alexa Media Player - Configuração" + "description": "Por favor, introduza a sua [informação](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) pode ser mais fácil!** \n**Aviso: a Amazon informa incorretamente 'Insira um e-mail ou número de celular válido' quando [2FA Code é necessário](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Configuração de Compatibilidade" } } }, diff --git a/custom_components/alexa_media/translations/ru.json b/custom_components/alexa_media/translations/ru.json index b3519b58..ee10f828 100644 --- a/custom_components/alexa_media/translations/ru.json +++ b/custom_components/alexa_media/translations/ru.json @@ -62,12 +62,13 @@ "description": "**{email} - alexa.{url}**\nВведите одноразовый пароль.\n{message}", "title": "Alexa Media Player - Двух факторная идентификация" }, - "user_legacy": { + "user": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Расширенные возможности отладки", "email": "Адрес электронной почты", "exclude_devices": "Исключенные устройства (через запятую)", + "hass_url": "Url to access Home Assistant", "include_devices": "Включенные устройства (разделенное запятыми)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Домен региона Amazon (например, amazon.co.uk)" }, - "description": "Пожалуйста, введите свои данные.{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "Пожалуйста, подтвердите информацию ниже. Для старой конфигурации отключите опцию `Use Login Proxy method`.", + "title": "Alexa Media Player - Конфигурация" }, - "user": { + "user_legacy": { "data": { "cookies_txt": "config::step::user::data::cookies_txt", "debug": "Расширенные возможности отладки", "email": "Адрес электронной почты", "exclude_devices": "Исключенные устройства (через запятую)", - "hass_url": "Url to access Home Assistant", "include_devices": "Включенные устройства (разделенное запятыми)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Домен региона Amazon (например, amazon.co.uk)" }, - "description": "Пожалуйста, подтвердите информацию ниже. Для старой конфигурации отключите опцию `Use Login Proxy method`.", - "title": "Alexa Media Player - Конфигурация" + "description": "Пожалуйста, введите свои данные.{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/alexa_media/translations/zh-Hans.json b/custom_components/alexa_media/translations/zh-Hans.json index e848d777..4af369e3 100644 --- a/custom_components/alexa_media/translations/zh-Hans.json +++ b/custom_components/alexa_media/translations/zh-Hans.json @@ -62,12 +62,13 @@ "description": "**{email} - Alexa.{url} ** \n输入一次性密码(OTP)。 \n {message}", "title": "Alexa Media Player - Two Factor Authentication" }, - "user_legacy": { + "user": { "data": { - "cookies_txt": "config::step::user::data::cookies_txt", + "cookies_txt": "Cookie.txt数据", "debug": "高级调试", "email": "电子邮件地址", "exclude_devices": "Excluded device (comma separated)", + "hass_url": "Url to access Home Assistant", "include_devices": "Included device (comma separated)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -77,16 +78,15 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Amazon region domain (e.g., amazon.co.uk)" }, - "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", - "title": "Alexa Media Player - Legacy Configuration" + "description": "请确认以下信息。对于旧版配置,请禁用“使用登录代理方法”选项。", + "title": "Alexa Media Player-配置" }, - "user": { + "user_legacy": { "data": { - "cookies_txt": "Cookie.txt数据", + "cookies_txt": "config::step::user::data::cookies_txt", "debug": "高级调试", "email": "电子邮件地址", "exclude_devices": "Excluded device (comma separated)", - "hass_url": "Url to access Home Assistant", "include_devices": "Included device (comma separated)", "oauth_login": "Enable oauth-token app method", "otp_secret": "Built-in 2FA App Key (automatically generate 2FA Codes)", @@ -96,8 +96,8 @@ "securitycode": "2FA Code (recommended to avoid login issues)", "url": "Amazon region domain (e.g., amazon.co.uk)" }, - "description": "请确认以下信息。对于旧版配置,请禁用“使用登录代理方法”选项。", - "title": "Alexa Media Player-配置" + "description": "Please enter your [information](https://github.com/custom-components/alexa_media_player/wiki/Configuration#integrations-page). **[Cookie import](https://github.com/custom-components/alexa_media_player/wiki/Configuration#cookie-import) may be easiest!** \n**WARNING: Amazon incorrectly reports 'Enter a valid email or mobile number' when [2FA Code is required](https://github.com/custom-components/alexa_media_player/wiki/Configuration#enable-two-factor-authentication-for-your-amazon-account).** \n>{message}", + "title": "Alexa Media Player - Legacy Configuration" } } }, diff --git a/custom_components/weenect/__init__.py b/custom_components/weenect/__init__.py index 2277980d..f827f589 100644 --- a/custom_components/weenect/__init__.py +++ b/custom_components/weenect/__init__.py @@ -16,11 +16,9 @@ from homeassistant.helpers.aiohttp_client import async_get_clientsession from homeassistant.helpers.dispatcher import async_dispatcher_send from homeassistant.helpers.update_coordinator import DataUpdateCoordinator, UpdateFailed -from .util import parse_duration from .const import ( CONF_PASSWORD, - CONF_UPDATE_RATE, CONF_USERNAME, DEFAULT_UPDATE_RATE, DOMAIN, @@ -28,7 +26,7 @@ STARTUP_MESSAGE, TRACKER_ADDED, ) -from .services import async_setup_services, async_unload_services +from .util import parse_duration _LOGGER: logging.Logger = logging.getLogger(__package__) @@ -37,7 +35,6 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry): """Set up this integration using UI.""" if hass.data.get(DOMAIN) is None: hass.data.setdefault(DOMAIN, {}) - await async_setup_services(hass) _LOGGER.info(STARTUP_MESSAGE) username = entry.data.get(CONF_USERNAME) @@ -133,9 +130,6 @@ async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool: if unloaded: hass.data[DOMAIN].pop(entry.entry_id) - # If there is no instance of this integration registered anymore - if not hass.data[DOMAIN]: - await async_unload_services(hass) return unloaded diff --git a/custom_components/weenect/config_flow.py b/custom_components/weenect/config_flow.py index 69272e33..83a27570 100644 --- a/custom_components/weenect/config_flow.py +++ b/custom_components/weenect/config_flow.py @@ -6,11 +6,7 @@ from homeassistant.helpers.aiohttp_client import async_create_clientsession import voluptuous as vol -from .const import ( - CONF_PASSWORD, - CONF_USERNAME, - DOMAIN, -) +from .const import CONF_PASSWORD, CONF_USERNAME, DOMAIN _LOGGER: logging.Logger = logging.getLogger(__package__) diff --git a/custom_components/weenect/const.py b/custom_components/weenect/const.py index 7ee68ad4..df119667 100644 --- a/custom_components/weenect/const.py +++ b/custom_components/weenect/const.py @@ -12,7 +12,7 @@ NAME = "Weenect" DOMAIN = "weenect" DOMAIN_DATA = f"{DOMAIN}_data" -VERSION = "1.3.0" +VERSION = "2.0.2" ATTRIBUTION = "Data provided by https://my.weenect.com/" ISSUE_URL = "https://github.com/eifinger/hass-weenect/issues" diff --git a/custom_components/weenect/device_tracker.py b/custom_components/weenect/device_tracker.py index f6f2b128..c969ff3a 100644 --- a/custom_components/weenect/device_tracker.py +++ b/custom_components/weenect/device_tracker.py @@ -1,22 +1,44 @@ """Device tracker platform for weenect.""" -import logging from typing import List from homeassistant.components.device_tracker import SOURCE_TYPE_GPS from homeassistant.components.device_tracker.config_entry import TrackerEntity -from homeassistant.core import callback +from homeassistant.config_entries import ConfigEntry +from homeassistant.core import HomeAssistant, ServiceCall, callback +from homeassistant.helpers import entity_platform from homeassistant.helpers.dispatcher import async_dispatcher_connect +from homeassistant.helpers.entity_platform import AddEntitiesCallback + +from custom_components.weenect.services import ( + SERVICE_ACTIVATE_SUPER_LIVE, + SERVICE_REFRESH_LOCATION, + SERVICE_RING, + SERVICE_SCHEMA, + SERVICE_SET_UPDATE_INTERVAL, + SERVICE_SET_UPDATE_INTERVAL_SCHEMA, + SERVICE_VIBRATE, + UPDATE_INTERVAL, + async_activate_super_live, + async_refresh_location, + async_ring, + async_set_update_interval, + async_vibrate, +) from .const import DOMAIN, TRACKER_ADDED from .entity import WeenectEntity -_LOGGER = logging.getLogger(__name__) - -async def async_setup_entry(hass, config_entry, async_add_entities): +async def async_setup_entry( + hass: HomeAssistant, + entry: ConfigEntry, + async_add_entities: AddEntitiesCallback, +) -> None: """Set up the weenect device_trackers.""" - coordinator = hass.data[DOMAIN][config_entry.entry_id] + platform = entity_platform.async_get_current_platform() + + coordinator = hass.data[DOMAIN][entry.entry_id] @callback def async_add_device_trackers( @@ -37,13 +59,67 @@ def async_add_device_trackers( unsub_dispatcher = async_dispatcher_connect( hass, - f"{config_entry.entry_id}_{TRACKER_ADDED}", + f"{entry.entry_id}_{TRACKER_ADDED}", async_add_device_trackers, ) coordinator.unsub_dispatchers.append(unsub_dispatcher) if len(coordinator.data) > 0: async_add_device_trackers(coordinator.data.keys()) + async def async_call_service(service_call: ServiceCall) -> None: + """Handle dispatched services.""" + assert platform is not None + entities = await platform.async_extract_from_service(service_call) + + tracker_ids = [] + for entity in entities: + assert isinstance(entity, WeenectEntity) + tracker_ids.append(entity.id) + for tracker_id in set(tracker_ids): + if service_call.service == SERVICE_SET_UPDATE_INTERVAL: + await async_set_update_interval( + hass, tracker_id, service_call.data[UPDATE_INTERVAL] + ) + if service_call.service == SERVICE_ACTIVATE_SUPER_LIVE: + await async_activate_super_live(hass, tracker_id) + if service_call.service == SERVICE_REFRESH_LOCATION: + await async_refresh_location(hass, tracker_id) + if service_call.service == SERVICE_RING: + await async_ring(hass, tracker_id) + if service_call.service == SERVICE_VIBRATE: + await async_vibrate(hass, tracker_id) + + hass.services.async_register( + DOMAIN, + SERVICE_SET_UPDATE_INTERVAL, + async_call_service, + schema=SERVICE_SET_UPDATE_INTERVAL_SCHEMA, + ) + hass.services.async_register( + DOMAIN, + SERVICE_ACTIVATE_SUPER_LIVE, + async_call_service, + schema=SERVICE_SCHEMA, + ) + hass.services.async_register( + DOMAIN, + SERVICE_REFRESH_LOCATION, + async_call_service, + schema=SERVICE_SCHEMA, + ) + hass.services.async_register( + DOMAIN, + SERVICE_RING, + async_call_service, + schema=SERVICE_SCHEMA, + ) + hass.services.async_register( + DOMAIN, + SERVICE_VIBRATE, + async_call_service, + schema=SERVICE_SCHEMA, + ) + class WeenectDeviceTracker(WeenectEntity, TrackerEntity): """weenect device tracker.""" diff --git a/custom_components/weenect/sensor.py b/custom_components/weenect/sensor.py index 2b6b4735..5bf0c11b 100644 --- a/custom_components/weenect/sensor.py +++ b/custom_components/weenect/sensor.py @@ -1,21 +1,24 @@ """Sensor platform for weenect.""" -import logging from typing import Any, Dict, List -from homeassistant.core import callback +from homeassistant.config_entries import ConfigEntry +from homeassistant.core import HomeAssistant, callback from homeassistant.helpers.dispatcher import async_dispatcher_connect +from homeassistant.helpers.entity_platform import AddEntitiesCallback from homeassistant.helpers.update_coordinator import DataUpdateCoordinator from .const import DOMAIN, LOCATION_SENSOR_TYPES, SENSOR_TYPES, TRACKER_ADDED from .entity import WeenectEntity -_LOGGER = logging.getLogger(__name__) - -async def async_setup_entry(hass, config_entry, async_add_entities): +async def async_setup_entry( + hass: HomeAssistant, + entry: ConfigEntry, + async_add_entities: AddEntitiesCallback, +) -> None: """Set up the weenect sensors.""" - coordinator = hass.data[DOMAIN][config_entry.entry_id] + coordinator = hass.data[DOMAIN][entry.entry_id] @callback def async_add_sensors( @@ -36,7 +39,7 @@ def async_add_sensors( unsub_dispatcher = async_dispatcher_connect( hass, - f"{config_entry.entry_id}_{TRACKER_ADDED}", + f"{entry.entry_id}_{TRACKER_ADDED}", async_add_sensors, ) coordinator.unsub_dispatchers.append(unsub_dispatcher) diff --git a/custom_components/weenect/services.py b/custom_components/weenect/services.py index 4335de64..4bbe79c8 100644 --- a/custom_components/weenect/services.py +++ b/custom_components/weenect/services.py @@ -1,6 +1,7 @@ """weenect services.""" import logging +from homeassistant.core import HomeAssistant from homeassistant.helpers import config_validation as cv import voluptuous as vol @@ -8,13 +9,11 @@ DOMAIN_SERVICES = f"{DOMAIN}_services" -TRACKER_ID = "tracker_id" UPDATE_INTERVAL = "update_interval" SERVICE_SET_UPDATE_INTERVAL = "set_update_interval" -SERVICE_SET_UPDATE_INTERVAL_SCHEMA = vol.Schema( +SERVICE_SET_UPDATE_INTERVAL_SCHEMA = cv.make_entity_service_schema( { - vol.Required(TRACKER_ID): cv.string, vol.Optional(UPDATE_INTERVAL, default="30M"): cv.string, } ) @@ -23,86 +22,16 @@ SERVICE_REFRESH_LOCATION = "refresh_location" SERVICE_RING = "ring" SERVICE_VIBRATE = "vibrate" -SERVICE_SCHEMA = vol.Schema({vol.Required(TRACKER_ID): cv.string}) +SERVICE_SCHEMA = cv.make_entity_service_schema({}) _LOGGER: logging.Logger = logging.getLogger(__package__) -async def async_setup_services(hass): - """Set up services for weenect integration.""" - if hass.data.get(DOMAIN_SERVICES, False): - return - - hass.data[DOMAIN_SERVICES] = True - - async def async_call_service(service_call): - """Call correct weenect service.""" - service = service_call.service - service_data = service_call.data - - if service == SERVICE_SET_UPDATE_INTERVAL: - await async_set_update_interval(hass, service_data) - if service == SERVICE_ACTIVATE_SUPER_LIVE: - await async_activate_super_live(hass, service_data) - if service == SERVICE_REFRESH_LOCATION: - await async_refresh_location(hass, service_data) - if service == SERVICE_RING: - await async_ring(hass, service_data) - if service == SERVICE_VIBRATE: - await async_vibrate(hass, service_data) - - hass.services.async_register( - DOMAIN, - SERVICE_SET_UPDATE_INTERVAL, - async_call_service, - schema=SERVICE_SET_UPDATE_INTERVAL_SCHEMA, - ) - hass.services.async_register( - DOMAIN, - SERVICE_ACTIVATE_SUPER_LIVE, - async_call_service, - schema=SERVICE_SCHEMA, - ) - hass.services.async_register( - DOMAIN, - SERVICE_REFRESH_LOCATION, - async_call_service, - schema=SERVICE_SCHEMA, - ) - hass.services.async_register( - DOMAIN, - SERVICE_RING, - async_call_service, - schema=SERVICE_SCHEMA, - ) - hass.services.async_register( - DOMAIN, - SERVICE_VIBRATE, - async_call_service, - schema=SERVICE_SCHEMA, - ) - - -async def async_unload_services(hass): - """Unload weenect services.""" - if not hass.data.get(DOMAIN_SERVICES): - return - - hass.data[DOMAIN_SERVICES] = False - - hass.services.async_remove(DOMAIN, SERVICE_SET_UPDATE_INTERVAL) - hass.services.async_remove(DOMAIN, SERVICE_ACTIVATE_SUPER_LIVE) - hass.services.async_remove(DOMAIN, SERVICE_REFRESH_LOCATION) - hass.services.async_remove(DOMAIN, SERVICE_RING) - hass.services.async_remove(DOMAIN, SERVICE_VIBRATE) - - -async def async_set_update_interval(hass, data): +async def async_set_update_interval( + hass: HomeAssistant, tracker_id: int, update_interval: str +): """Set the update interval for this tracker id.""" - tracker_id = int(data[TRACKER_ID]) - update_interval = data[UPDATE_INTERVAL] - for config_entry in hass.data[DOMAIN]: if tracker_id in hass.data[DOMAIN][config_entry].data.keys(): await hass.data[DOMAIN][config_entry].client.set_update_interval( @@ -114,11 +43,9 @@ async def async_set_update_interval(hass, data): ) -async def async_activate_super_live(hass, data): +async def async_activate_super_live(hass: HomeAssistant, tracker_id: int): """Activate the super live mode for this tracker id""" - tracker_id = int(data[TRACKER_ID]) - for config_entry in hass.data[DOMAIN]: if tracker_id in hass.data[DOMAIN][config_entry].data.keys(): await hass.data[DOMAIN][config_entry].client.activate_super_live(tracker_id) @@ -128,11 +55,9 @@ async def async_activate_super_live(hass, data): ) -async def async_refresh_location(hass, data): +async def async_refresh_location(hass: HomeAssistant, tracker_id: int): """Request a position refresh for this tracker id""" - tracker_id = int(data[TRACKER_ID]) - for config_entry in hass.data[DOMAIN]: if tracker_id in hass.data[DOMAIN][config_entry].data.keys(): await hass.data[DOMAIN][config_entry].client.refresh_location(tracker_id) @@ -142,11 +67,9 @@ async def async_refresh_location(hass, data): ) -async def async_ring(hass, data): +async def async_ring(hass: HomeAssistant, tracker_id: int): """Send a ring command for this tracker id""" - tracker_id = int(data[TRACKER_ID]) - for config_entry in hass.data[DOMAIN]: if tracker_id in hass.data[DOMAIN][config_entry].data.keys(): await hass.data[DOMAIN][config_entry].client.ring(tracker_id) @@ -156,11 +79,9 @@ async def async_ring(hass, data): ) -async def async_vibrate(hass, data): +async def async_vibrate(hass: HomeAssistant, tracker_id: int): """Send a vibrate command for this tracker id""" - tracker_id = int(data[TRACKER_ID]) - for config_entry in hass.data[DOMAIN]: if tracker_id in hass.data[DOMAIN][config_entry].data.keys(): await hass.data[DOMAIN][config_entry].client.vibrate(tracker_id) diff --git a/custom_components/weenect/services.yaml b/custom_components/weenect/services.yaml index f79cf5ef..76c72849 100644 --- a/custom_components/weenect/services.yaml +++ b/custom_components/weenect/services.yaml @@ -1,37 +1,46 @@ set_update_interval: description: Set the tracker update interval. + target: + entity: + integration: weenect + device: + integration: weenect fields: - tracker_id: - description: The tracker id. - example: '10000' update_interval: description: The update interval. Possible values are 30S 1M 5M 10M 30M 1H + required: true example: "30M" + selector: + text: activate_super_live: description: Activate the super live mode. - fields: - tracker_id: - description: The tracker id. - example: '10000' + target: + entity: + integration: weenect + device: + integration: weenect refresh_location: description: Request a location update. - fields: - tracker_id: - description: The tracker id. - example: '10000' + target: + entity: + integration: weenect + device: + integration: weenect ring: description: Let the tracker ring. - fields: - tracker_id: - description: The tracker id. - example: '10000' + target: + entity: + integration: weenect + device: + integration: weenect vibrate: description: Let the tracker vibrate. - fields: - tracker_id: - description: The tracker id. - example: '10000' + target: + entity: + integration: weenect + device: + integration: weenect diff --git a/custom_components/weenect/util.py b/custom_components/weenect/util.py index 0053a1ae..65092dcb 100644 --- a/custom_components/weenect/util.py +++ b/custom_components/weenect/util.py @@ -1,7 +1,7 @@ """Utility methods for weenect.""" -import re from datetime import timedelta +import re from typing import Optional From b0bfa86684fe765e1b112843d7eb46207a99f96b Mon Sep 17 00:00:00 2001 From: Kevin Eifinger Date: Tue, 19 Oct 2021 20:34:20 +0200 Subject: [PATCH 13/13] Weenect 2.x --- packages/weenect.yaml | 6 ++++-- travis_secrets.yaml | 7 ------- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/packages/weenect.yaml b/packages/weenect.yaml index 6bc6780a..0b672318 100644 --- a/packages/weenect.yaml +++ b/packages/weenect.yaml @@ -12,8 +12,9 @@ automation: to: "off" action: - service: weenect.set_update_interval + target: + entity_id: device_tracker.naya data: - tracker_id: !secret naya_tracker_id update_interval: "1M" - id: 652b4b69-c951-4861-8b7d-3cbb15fc8b79 alias: "Setze Nayas Tracker Updaterate auf 60M wenn wir zu Hause sind" @@ -27,6 +28,7 @@ automation: to: "on" action: - service: weenect.set_update_interval + target: + entity_id: device_tracker.naya data: - tracker_id: !secret naya_tracker_id update_interval: "60M" diff --git a/travis_secrets.yaml b/travis_secrets.yaml index a1ba2c26..df3e7331 100644 --- a/travis_secrets.yaml +++ b/travis_secrets.yaml @@ -182,10 +182,3 @@ philips_miio_light_bulb_token: 21654d654261fe765ca417645121654e amcrest_wohnzimmer_ip: 192.168.0.35 amcrest_wohnzimmer_user: admin amcrest_wohnzimmer_password: admin - -room_assistant_livingroom_health_url: "http://192.168.0.36:6415/status" -room_assistant_bedroom_health_url: "http://192.168.0.37:6415/status" -room_assistant_studyroom_health_url: "http://192.168.0.38:6415/status" -room_assistant_bathroom_health_url: "http://192.168.0.39:6415/status" - -naya_tracker_id: "131673"