The one by @bjpierron should work for the next couple of weeks if you want to try it and see if the issue is just that there’s a switch piece that you weren’t selecting on the Harmony side.
Do you have a smartthings hub? And if so which model? If you do have either a V3 smart things hub or Aeotec hub, there is a custom edge driver that works with the new architecture and can generate devices with both switch and sensor capabilities.
[ST Edge] vEdge Creator: a virtual device generator for end users
As for using just a Sonoff, I’m not sure I understand the question.