{"action":"created","comment":{"url":"https://api.github.com/repos/openT2T/translators/pulls/comments/66656942","id":66656942,"diff_hunk":"@@ -0,0 +1,113 @@\n+'use strict';\r\n+\r\n+var https = require('https');\r\n+\r\n+// logs device state\r\n+function logDeviceState(device) {\r\n+    if (typeof (device) !== 'undefined') {\r\n+        console.log('  device.name          : ' + device.name);\r\n+        console.log('  device.props         : ' + device.props);\r\n+    } else {\r\n+        console.log('device is undefined');\r\n+    }\r\n+};\r\n+\r\n+// Helper method to send power state commands to Wink\r\n+function sendPowerStateCommandToDevice(powerState) {\r","path":"org.OpenT2T.Sample.SuperPopular.Outlet/Wink Binary Switch/js/thingTranslator.js","position":16,"original_position":16,"commit_id":"7f0038421a3fecf1d5f526ccaf3b18d8b7cc33e2","original_commit_id":"7f0038421a3fecf1d5f526ccaf3b18d8b7cc33e2","user":{"login":"tjaffri","id":749277,"avatar_url":"https://avatars.githubusercontent.com/u/749277?v=3","gravatar_id":"","url":"https://api.github.com/users/tjaffri","html_url":"https://github.com/tjaffri","followers_url":"https://api.github.com/users/tjaffri/followers","following_url":"https://api.github.com/users/tjaffri/following{/other_user}","gists_url":"https://api.github.com/users/tjaffri/gists{/gist_id}","starred_url":"https://api.github.com/users/tjaffri/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tjaffri/subscriptions","organizations_url":"https://api.github.com/users/tjaffri/orgs","repos_url":"https://api.github.com/users/tjaffri/repos","events_url":"https://api.github.com/users/tjaffri/events{/privacy}","received_events_url":"https://api.github.com/users/tjaffri/received_events","type":"User","site_admin":false},"body":"This looks like it is pretty common across a lot of Wink-type translators... no change for now, but I will set up time with you to pair-program a \"helper\" library that we can use to refactor these API calls into a single node module. We could fork this https://github.com/TheThingSystem/node-winkapi or start fresh if we need a different type of interface.","created_at":"2016-06-10T18:08:44Z","updated_at":"2016-06-10T18:08:44Z","html_url":"https://github.com/openT2T/translators/pull/6#discussion_r66656942","pull_request_url":"https://api.github.com/repos/openT2T/translators/pulls/6","_links":{"self":{"href":"https://api.github.com/repos/openT2T/translators/pulls/comments/66656942"},"html":{"href":"https://github.com/openT2T/translators/pull/6#discussion_r66656942"},"pull_request":{"href":"https://api.github.com/repos/openT2T/translators/pulls/6"}}},"pull_request":{"url":"https://api.github.com/repos/openT2T/translators/pulls/6","id":73318932,"html_url":"https://github.com/openT2T/translators/pull/6","diff_url":"https://github.com/openT2T/translators/pull/6.diff","patch_url":"https://github.com/openT2T/translators/pull/6.patch","issue_url":"https://api.github.com/repos/openT2T/translators/issues/6","number":6,"state":"open","locked":false,"title":"added Translator for Wink Binary Switches","user":{"login":"rlingineni","id":5509813,"avatar_url":"https://avatars.githubusercontent.com/u/5509813?v=3","gravatar_id":"","url":"https://api.github.com/users/rlingineni","html_url":"https://github.com/rlingineni","followers_url":"https://api.github.com/users/rlingineni/followers","following_url":"https://api.github.com/users/rlingineni/following{/other_user}","gists_url":"https://api.github.com/users/rlingineni/gists{/gist_id}","starred_url":"https://api.github.com/users/rlingineni/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rlingineni/subscriptions","organizations_url":"https://api.github.com/users/rlingineni/orgs","repos_url":"https://api.github.com/users/rlingineni/repos","events_url":"https://api.github.com/users/rlingineni/events{/privacy}","received_events_url":"https://api.github.com/users/rlingineni/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-06-10T04:00:45Z","updated_at":"2016-06-10T18:08:44Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8c1ade5bf3f00ad2621a587e7baf0d2855d34f80","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/openT2T/translators/pulls/6/commits","review_comments_url":"https://api.github.com/repos/openT2T/translators/pulls/6/comments","review_comment_url":"https://api.github.com/repos/openT2T/translators/pulls/comments{/number}","comments_url":"https://api.github.com/repos/openT2T/translators/issues/6/comments","statuses_url":"https://api.github.com/repos/openT2T/translators/statuses/7f0038421a3fecf1d5f526ccaf3b18d8b7cc33e2","head":{"label":"rlingineni:master","ref":"master","sha":"7f0038421a3fecf1d5f526ccaf3b18d8b7cc33e2","user":{"login":"rlingineni","id":5509813,"avatar_url":"https://avatars.githubusercontent.com/u/5509813?v=3","gravatar_id":"","url":"https://api.github.com/users/rlingineni","html_url":"https://github.com/rlingineni","followers_url":"https://api.github.com/users/rlingineni/followers","following_url":"https://api.github.com/users/rlingineni/following{/other_user}","gists_url":"https://api.github.com/users/rlingineni/gists{/gist_id}","starred_url":"https://api.github.com/users/rlingineni/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rlingineni/subscriptions","organizations_url":"https://api.github.com/users/rlingineni/orgs","repos_url":"https://api.github.com/users/rlingineni/repos","events_url":"https://api.github.com/users/rlingineni/events{/privacy}","received_events_url":"https://api.github.com/users/rlingineni/received_events","type":"User","site_admin":false},"repo":{"id":60822843,"name":"translators","full_name":"rlingineni/translators","owner":{"login":"rlingineni","id":5509813,"avatar_url":"https://avatars.githubusercontent.com/u/5509813?v=3","gravatar_id":"","url":"https://api.github.com/users/rlingineni","html_url":"https://github.com/rlingineni","followers_url":"https://api.github.com/users/rlingineni/followers","following_url":"https://api.github.com/users/rlingineni/following{/other_user}","gists_url":"https://api.github.com/users/rlingineni/gists{/gist_id}","starred_url":"https://api.github.com/users/rlingineni/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rlingineni/subscriptions","organizations_url":"https://api.github.com/users/rlingineni/orgs","repos_url":"https://api.github.com/users/rlingineni/repos","events_url":"https://api.github.com/users/rlingineni/events{/privacy}","received_events_url":"https://api.github.com/users/rlingineni/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/rlingineni/translators","description":"Repository for Open Translators to Things. ","fork":true,"url":"https://api.github.com/repos/rlingineni/translators","forks_url":"https://api.github.com/repos/rlingineni/translators/forks","keys_url":"https://api.github.com/repos/rlingineni/translators/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rlingineni/translators/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rlingineni/translators/teams","hooks_url":"https://api.github.com/repos/rlingineni/translators/hooks","issue_events_url":"https://api.github.com/repos/rlingineni/translators/issues/events{/number}","events_url":"https://api.github.com/repos/rlingineni/translators/events","assignees_url":"https://api.github.com/repos/rlingineni/translators/assignees{/user}","branches_url":"https://api.github.com/repos/rlingineni/translators/branches{/branch}","tags_url":"https://api.github.com/repos/rlingineni/translators/tags","blobs_url":"https://api.github.com/repos/rlingineni/translators/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rlingineni/translators/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rlingineni/translators/git/refs{/sha}","trees_url":"https://api.github.com/repos/rlingineni/translators/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rlingineni/translators/statuses/{sha}","languages_url":"https://api.github.com/repos/rlingineni/translators/languages","stargazers_url":"https://api.github.com/repos/rlingineni/translators/stargazers","contributors_url":"https://api.github.com/repos/rlingineni/translators/contributors","subscribers_url":"https://api.github.com/repos/rlingineni/translators/subscribers","subscription_url":"https://api.github.com/repos/rlingineni/translators/subscription","commits_url":"https://api.github.com/repos/rlingineni/translators/commits{/sha}","git_commits_url":"https://api.github.com/repos/rlingineni/translators/git/commits{/sha}","comments_url":"https://api.github.com/repos/rlingineni/translators/comments{/number}","issue_comment_url":"https://api.github.com/repos/rlingineni/translators/issues/comments{/number}","contents_url":"https://api.github.com/repos/rlingineni/translators/contents/{+path}","compare_url":"https://api.github.com/repos/rlingineni/translators/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rlingineni/translators/merges","archive_url":"https://api.github.com/repos/rlingineni/translators/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rlingineni/translators/downloads","issues_url":"https://api.github.com/repos/rlingineni/translators/issues{/number}","pulls_url":"https://api.github.com/repos/rlingineni/translators/pulls{/number}","milestones_url":"https://api.github.com/repos/rlingineni/translators/milestones{/number}","notifications_url":"https://api.github.com/repos/rlingineni/translators/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rlingineni/translators/labels{/name}","releases_url":"https://api.github.com/repos/rlingineni/translators/releases{/id}","deployments_url":"https://api.github.com/repos/rlingineni/translators/deployments","created_at":"2016-06-10T03:54:04Z","updated_at":"2016-06-10T03:54:05Z","pushed_at":"2016-06-10T04:35:40Z","git_url":"git://github.com/rlingineni/translators.git","ssh_url":"git@github.com:rlingineni/translators.git","clone_url":"https://github.com/rlingineni/translators.git","svn_url":"https://github.com/rlingineni/translators","homepage":"http://www.opentranslatorstothings.org","size":59,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"openT2T:master","ref":"master","sha":"8d95cb6a40da159fd2804fea6acc6ff1cc45b147","user":{"login":"openT2T","id":17659874,"avatar_url":"https://avatars.githubusercontent.com/u/17659874?v=3","gravatar_id":"","url":"https://api.github.com/users/openT2T","html_url":"https://github.com/openT2T","followers_url":"https://api.github.com/users/openT2T/followers","following_url":"https://api.github.com/users/openT2T/following{/other_user}","gists_url":"https://api.github.com/users/openT2T/gists{/gist_id}","starred_url":"https://api.github.com/users/openT2T/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openT2T/subscriptions","organizations_url":"https://api.github.com/users/openT2T/orgs","repos_url":"https://api.github.com/users/openT2T/repos","events_url":"https://api.github.com/users/openT2T/events{/privacy}","received_events_url":"https://api.github.com/users/openT2T/received_events","type":"Organization","site_admin":false},"repo":{"id":55200869,"name":"translators","full_name":"openT2T/translators","owner":{"login":"openT2T","id":17659874,"avatar_url":"https://avatars.githubusercontent.com/u/17659874?v=3","gravatar_id":"","url":"https://api.github.com/users/openT2T","html_url":"https://github.com/openT2T","followers_url":"https://api.github.com/users/openT2T/followers","following_url":"https://api.github.com/users/openT2T/following{/other_user}","gists_url":"https://api.github.com/users/openT2T/gists{/gist_id}","starred_url":"https://api.github.com/users/openT2T/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openT2T/subscriptions","organizations_url":"https://api.github.com/users/openT2T/orgs","repos_url":"https://api.github.com/users/openT2T/repos","events_url":"https://api.github.com/users/openT2T/events{/privacy}","received_events_url":"https://api.github.com/users/openT2T/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/openT2T/translators","description":"Repository for Open Translators to Things. ","fork":false,"url":"https://api.github.com/repos/openT2T/translators","forks_url":"https://api.github.com/repos/openT2T/translators/forks","keys_url":"https://api.github.com/repos/openT2T/translators/keys{/key_id}","collaborators_url":"https://api.github.com/repos/openT2T/translators/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/openT2T/translators/teams","hooks_url":"https://api.github.com/repos/openT2T/translators/hooks","issue_events_url":"https://api.github.com/repos/openT2T/translators/issues/events{/number}","events_url":"https://api.github.com/repos/openT2T/translators/events","assignees_url":"https://api.github.com/repos/openT2T/translators/assignees{/user}","branches_url":"https://api.github.com/repos/openT2T/translators/branches{/branch}","tags_url":"https://api.github.com/repos/openT2T/translators/tags","blobs_url":"https://api.github.com/repos/openT2T/translators/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/openT2T/translators/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/openT2T/translators/git/refs{/sha}","trees_url":"https://api.github.com/repos/openT2T/translators/git/trees{/sha}","statuses_url":"https://api.github.com/repos/openT2T/translators/statuses/{sha}","languages_url":"https://api.github.com/repos/openT2T/translators/languages","stargazers_url":"https://api.github.com/repos/openT2T/translators/stargazers","contributors_url":"https://api.github.com/repos/openT2T/translators/contributors","subscribers_url":"https://api.github.com/repos/openT2T/translators/subscribers","subscription_url":"https://api.github.com/repos/openT2T/translators/subscription","commits_url":"https://api.github.com/repos/openT2T/translators/commits{/sha}","git_commits_url":"https://api.github.com/repos/openT2T/translators/git/commits{/sha}","comments_url":"https://api.github.com/repos/openT2T/translators/comments{/number}","issue_comment_url":"https://api.github.com/repos/openT2T/translators/issues/comments{/number}","contents_url":"https://api.github.com/repos/openT2T/translators/contents/{+path}","compare_url":"https://api.github.com/repos/openT2T/translators/compare/{base}...{head}","merges_url":"https://api.github.com/repos/openT2T/translators/merges","archive_url":"https://api.github.com/repos/openT2T/translators/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/openT2T/translators/downloads","issues_url":"https://api.github.com/repos/openT2T/translators/issues{/number}","pulls_url":"https://api.github.com/repos/openT2T/translators/pulls{/number}","milestones_url":"https://api.github.com/repos/openT2T/translators/milestones{/number}","notifications_url":"https://api.github.com/repos/openT2T/translators/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/openT2T/translators/labels{/name}","releases_url":"https://api.github.com/repos/openT2T/translators/releases{/id}","deployments_url":"https://api.github.com/repos/openT2T/translators/deployments","created_at":"2016-04-01T03:25:20Z","updated_at":"2016-05-29T18:39:10Z","pushed_at":"2016-06-10T04:35:40Z","git_url":"git://github.com/openT2T/translators.git","ssh_url":"git@github.com:openT2T/translators.git","clone_url":"https://github.com/openT2T/translators.git","svn_url":"https://github.com/openT2T/translators","homepage":"http://www.opentranslatorstothings.org","size":56,"stargazers_count":16,"watchers_count":16,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":12,"mirror_url":null,"open_issues_count":1,"forks":12,"open_issues":1,"watchers":16,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/openT2T/translators/pulls/6"},"html":{"href":"https://github.com/openT2T/translators/pull/6"},"issue":{"href":"https://api.github.com/repos/openT2T/translators/issues/6"},"comments":{"href":"https://api.github.com/repos/openT2T/translators/issues/6/comments"},"review_comments":{"href":"https://api.github.com/repos/openT2T/translators/pulls/6/comments"},"review_comment":{"href":"https://api.github.com/repos/openT2T/translators/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/openT2T/translators/pulls/6/commits"},"statuses":{"href":"https://api.github.com/repos/openT2T/translators/statuses/7f0038421a3fecf1d5f526ccaf3b18d8b7cc33e2"}}}}
{"actor":{"display_login":"tjaffri"}}