def setup_platform(hass, config, add_entities, discovery_info=None):
    add_entities([
        ZigBeeSwitch(hass, ZigBeeDigitalOutConfig(config))
    ])
Create and add an entity based on the configuration.
dataset/ETHPy150Open home-assistant/home-assistant/homeassistant/components/switch/zigbee.py/setup_platform