mirror of
https://github.com/home-assistant/core.git
synced 2025-07-13 00:07:10 +00:00
Improved Add Sreen of the Z-WAve.Me intergration (#68568)
This commit is contained in:
parent
80f34e5e2e
commit
d9a6371679
@ -26,6 +26,13 @@ class ZWaveMeConfigFlow(config_entries.ConfigFlow, domain=DOMAIN):
|
|||||||
async def async_step_user(self, user_input=None):
|
async def async_step_user(self, user_input=None):
|
||||||
"""Handle a flow initialized by the user or started with zeroconf."""
|
"""Handle a flow initialized by the user or started with zeroconf."""
|
||||||
errors = {}
|
errors = {}
|
||||||
|
placeholders = {
|
||||||
|
"local_token": "/112f7a4a-0051-cc2b-3b61-1898181b9950",
|
||||||
|
"find_token": "0481effe8a5c6f757b455babb678dc0e764feae279/112f7a4a-0051-cc2b-3b61-1898181b9950",
|
||||||
|
"local_url": "192.168.1.39:8083",
|
||||||
|
"find_url": "wss://find.z-wave.me",
|
||||||
|
"remote_url": "wss://87.250.250.242:8083",
|
||||||
|
}
|
||||||
if self.url is None:
|
if self.url is None:
|
||||||
schema = vol.Schema(
|
schema = vol.Schema(
|
||||||
{
|
{
|
||||||
@ -64,6 +71,7 @@ class ZWaveMeConfigFlow(config_entries.ConfigFlow, domain=DOMAIN):
|
|||||||
|
|
||||||
return self.async_show_form(
|
return self.async_show_form(
|
||||||
step_id="user",
|
step_id="user",
|
||||||
|
description_placeholders=placeholders,
|
||||||
data_schema=schema,
|
data_schema=schema,
|
||||||
errors=errors,
|
errors=errors,
|
||||||
)
|
)
|
||||||
|
@ -2,10 +2,10 @@
|
|||||||
"config": {
|
"config": {
|
||||||
"step": {
|
"step": {
|
||||||
"user": {
|
"user": {
|
||||||
"description": "Input IP address of Z-Way server and Z-Way access token. IP address can be prefixed with wss:// if HTTPS should be used instead of HTTP. To get the token go to the Z-Way user interface > Menu > Settings > User > API token. It is suggested to create a new user for Home Assistant and grant access to devices you need to control from Home Assistant. It is also possible to use remote access via find.z-wave.me to connect a remote Z-Way. Input wss://find.z-wave.me in IP field and copy the token with Global scope (log-in to Z-Way via find.z-wave.me for this).",
|
"description": "Input IP address with port and access token of Z-Way server. To get the token go to the Z-Way user interface Smart Home UI > Menu > Settings > Users > Administrator > API token.\n\nExample of connecting to Z-Way in the local network:\nURL: {local_url}\nToken: {local_token}\n\nExample of connecting to Z-Way via remote access find.z-wave.me:\nURL: {find_url}\nToken: {find_token}\n\nExample of connecting to Z-Way with a static public IP address:\nURL: {remote_url}\nToken: {local_token}\n\nWhen connecting via find.z-wave.me you need to use a token with a global scope (log-in to Z-Way via find.z-wave.me for this).",
|
||||||
"data": {
|
"data": {
|
||||||
"url": "[%key:common::config_flow::data::url%]",
|
"url": "[%key:common::config_flow::data::url%]",
|
||||||
"token": "Token"
|
"token": "[%key:common::config_flow::data::api_token%]"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user