Thanks for offering to help! I’ve been quite busy last week (travelling) but I’ve still made some progress on the bindings, most of the code lives in my fork here: https://github.com/sebmarchand/openhab2-addons/tree/master/addons/binding/org.openhab.binding.wink
Note that this code isn’t really documented yet, I’ll clean it up and some comments as well as some details about the architecture of this binding later this week.
Note that in its current implementation the binding works by polling (rather than being interrupt driven), and so I’m not sure that you’ll be able to get a notification when an event is detected (you can regularly poll the camera to check if it’s detecting something but that doesn’t seem ideal ).
I think that in order to get a notification you’ll need to use their PubNub subscription service, in theory you should be able to subscribe to an item when you set it up in OpenHab2 and be notified when its state change. In practice it’s not that easy, adding a dependency to the PubNub library in my binding introduced a lot of dependency issues so I gave up, but if you can get it to work that’d be awesome! I’ve tried to do this but I gave up (I wanted to focus on writing a really simple binding first, and then add the fancy stuffs), you can check this commit for some idea on how I was trying to do it.
I think that you should start by trying to use the PubNub subscription service independently of OpenHab (in a simple Java project) to make sure that it can achieve what you’re trying to do (getting notifications when a there’s motion event). If you’re familiar with Python you can use this API (or this one) to handle the communication with the hub.
Note that for all of this you’ll need to get your client_id / client_socket pair from Wink, you can get them by sending an email to firstname.lastname@example.org or by pinging them on Twitter.