It would mean adding another device in the mix but have you looked into Node Red and the Samsung Automation Studio nodes?