mirror of
https://github.com/home-assistant/developers.home-assistant.git
synced 2025-07-13 12:26:29 +00:00
Tweak service filter blog post (#1828)
* Tweak service filter blog post * Update 2023-06-28-service-description-filters.md
This commit is contained in:
parent
635b69a2bc
commit
4f7b8d076b
@ -4,8 +4,11 @@ authorURL: https://github.com/emontnemery
|
|||||||
title: "Service call description filters"
|
title: "Service call description filters"
|
||||||
---
|
---
|
||||||
|
|
||||||
Service call fields now support filtering, to avoid showing service call parameters that are not supported by an entity to the user. For example, the `brightness` service call parameter for `light.turn_on` will only be shown if the light supports brightness.
|
Service call descriptions have been changed to support filtering.
|
||||||
|
It's possible to add a filter to a service call to not show entities which do not support the service call, it's also possible to add a filter to a service call field to not show fields which are not supported by a selected entity to the user.
|
||||||
|
|
||||||
This is an extension of the previously supported possibility to filter out entities that don't support a certain service call.
|
For example:
|
||||||
|
- The `brightness` service call parameter for `light.turn_on` will only be shown if the light supports brightness.
|
||||||
|
- The `climate.set_aux_heat` service call will only allow picking a climate entity which supports auxiliary heat.
|
||||||
|
|
||||||
This features was introduced in core [PR #86162](https://github.com/home-assistant/core/pull/86162) and is documented [here](/docs/dev_101_services#filtering-service-fields).
|
This features was introduced in core [PR #86162](https://github.com/home-assistant/core/pull/86162) and is documented [here](/docs/dev_101_services#filtering-service-fields).
|
||||||
|
Loading…
x
Reference in New Issue
Block a user