Skip to content

Commit d6b4874

Browse files
VdkaShakercdce8p
authored andcommitted
Update configure filter section (home-assistant#5071)
Adding detail to Configure Filter section.
1 parent d707f1a commit d6b4874

File tree

1 file changed

+31
-1
lines changed

1 file changed

+31
-1
lines changed

source/_components/homekit.markdown

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,37 @@ automation:
150150

151151
## {% linkable_title Configure Filter %}
152152

153-
To limit which entities are being exposed to `HomeKit`, you can use the `filter` parameter. By default no entity will be excluded. Keep in mind though that only supported components can be added.
153+
By default no entity will be excluded. To limit which entities are being exposed to `HomeKit`, you can use the `filter` parameter. Keep in mind only [supported components](#supported-components) can be added.
154+
155+
{% raw %}
156+
```yaml
157+
# Example filter to include specified domains and exclude specified entities
158+
homekit:
159+
filter:
160+
include_domains:
161+
- alarm_control_panel
162+
- light
163+
exclude_entities:
164+
- light.kitchen_light
165+
```
166+
{% endraw %}
167+
168+
Filters are applied as follows:
169+
170+
1. No includes or excludes - pass all entities
171+
2. Includes, no excludes - only include specified entities
172+
3. Excludes, no includes - only exclude specified entities
173+
4. Both includes and excludes:
174+
* Include domain specified
175+
- if domain is included, and entity not excluded, pass
176+
- if domain is not included, and entity not included, fail
177+
* Exclude domain specified
178+
- if domain is excluded, and entity not included, fail
179+
- if domain is not excluded, and entity not excluded, pass
180+
- if both include and exclude domains specified, the exclude domains are ignored
181+
* Neither include or exclude domain specified
182+
- if entity is included, pass (as #2 above)
183+
- if entity include and exclude, the entity exclude is ignored
154184

155185

156186
## {% linkable_title Supported Components %}

0 commit comments

Comments
 (0)