Support air purifier device type in homekit

While I think it would be great for HomeKit Bridge to support air purifiers, I would hesitate to endorse a system that automatically assumes just because an air quality sensor is present with a fan it means the device is an air purifier — I have air purifiers without built-in sensors, and I also added a PMS7001 to my range extraction fan but it doesn’t do any purification so I would prefer it still appear as a fan despite the co-existent sensor.

Instead I could envision an option similar to HomeKit valve support, which gives you the option to declare a switch as a valve type when bridging to HomeKit in accessory mode. Similarly, it would make sense to have the option to bridge a fan to HomeKit as an air purifier, for example something like this:

homekit:
  - name: "Fan as Air Purifier"
    port: 12345
    mode: accessory
    filter:
      include_entities:
         - fan.custom_fan_name
         - sensor.optional_pm_2.5_sensor
    entity_config:
      fan.custom_fan_name:
         type: air_purifier
4 Likes