Mine is even simpler - I just control an off-the-shelf smart bulb via a couple of macOS Shortcuts, which is trivial using Homekit. Those are driven by Hammerspoon which triggers the shortcuts based on the camera events. No custom hardware and like 20 lines of code (not including the shortcuts, I guess). I have the bulb in a normal lamp base outside my door. It's properly event driven rather than polling, too.
Is there any way to do this with a bulb near you if you use multiple rooms? Like using closest Bluetooth range or something?
The custom hardware is the apple device and the smart bulb. Homekit doesn't appear to be usable outside that ecosystem, so I wouldn't call it non-custom
Similar - Hammerspoon detects whether I have a Teams meeting window open (I never have my camera on) and calls out to Home Assistant to control a WLED strip visible outside the room. Also have a Zigbee button for ad-hoc control if I'm called into a Slack huddle, etc.
(I've also got it parsing my Outlook iCal to do "meeting pending", "meeting maybe pending" but it turns out that Outlook's iCal is nonsense and parsing it is a fool's errand.)