Improve unpair schema in homekit (#150235)

This commit is contained in:
Artur Pragacz
2025-09-02 08:41:48 +00:00
committed by Franck Nijhof
parent 9f4369dc8b
commit bbe66f5cea
3 changed files with 16 additions and 7 deletions
+2 -3
View File
@@ -224,9 +224,8 @@ RESET_ACCESSORY_SERVICE_SCHEMA = vol.Schema(
)
UNPAIR_SERVICE_SCHEMA = vol.All(
vol.Schema(cv.ENTITY_SERVICE_FIELDS),
cv.has_at_least_one_key(ATTR_DEVICE_ID),
UNPAIR_SERVICE_SCHEMA = vol.Schema(
{vol.Required(ATTR_DEVICE_ID): vol.All(cv.ensure_list, [str])}
)
@@ -6,6 +6,10 @@ reset_accessory:
entity: {}
unpair:
target:
device:
integration: homekit
fields:
device_id:
required: true
selector:
device:
multiple: true
integration: homekit
@@ -80,7 +80,13 @@
},
"unpair": {
"name": "Unpair an accessory or bridge",
"description": "Forcefully removes all pairings from an accessory to allow re-pairing. Use this action if the accessory is no longer responsive, and you want to avoid deleting and re-adding the entry. Room locations, and accessory preferences will be lost."
"description": "Forcefully removes all pairings from an accessory to allow re-pairing. Use this action if the accessory is no longer responsive and you want to avoid deleting and re-adding the entry. Room locations and accessory preferences will be lost.",
"fields": {
"device_id": {
"name": "Device",
"description": "Device to unpair."
}
}
}
}
}