{"action":"created","comment":{"url":"https://api.github.com/repos/Automattic/happychat-client/pulls/comments/178282044","pull_request_review_id":108321087,"id":178282044,"diff_hunk":"@@ -0,0 +1,199 @@\n+/** @format */\n+\n+/**\n+ * External dependencies\n+ */\n+import wpComRequest from 'wpcom-xhr-request';\n+import debugFactory from 'debug';\n+\n+/**\n+ * Internal dependencies\n+ */\n+import { WPcomStrategy } from './index';\n+\n+/**\n+ * Module variables\n+ */\n+const debug = debugFactory( 'happychat-client:auth:wpcom:oauth' );\n+const oAuth = require( 'wpcom-oauth-cors' )( '54006' );","path":"src/lib/auth/strategies/wpcom/oauth.js","position":null,"original_position":18,"commit_id":"6ff2c94e1d2f4a054326fb12b1736b40783c9858","original_commit_id":"3baf871bab54c960873c7693722d84c70098b234","user":{"login":"unDemian","id":2129455,"avatar_url":"https://avatars1.githubusercontent.com/u/2129455?v=4","gravatar_id":"","url":"https://api.github.com/users/unDemian","html_url":"https://github.com/unDemian","followers_url":"https://api.github.com/users/unDemian/followers","following_url":"https://api.github.com/users/unDemian/following{/other_user}","gists_url":"https://api.github.com/users/unDemian/gists{/gist_id}","starred_url":"https://api.github.com/users/unDemian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unDemian/subscriptions","organizations_url":"https://api.github.com/users/unDemian/orgs","repos_url":"https://api.github.com/users/unDemian/repos","events_url":"https://api.github.com/users/unDemian/events{/privacy}","received_events_url":"https://api.github.com/users/unDemian/received_events","type":"User","site_admin":false},"body":"it was part of a config file but forgot to move it back. Will do 🙇 ","created_at":"2018-03-30T12:19:27Z","updated_at":"2018-03-30T12:19:28Z","html_url":"https://github.com/Automattic/happychat-client/pull/188#discussion_r178282044","pull_request_url":"https://api.github.com/repos/Automattic/happychat-client/pulls/188","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/Automattic/happychat-client/pulls/comments/178282044"},"html":{"href":"https://github.com/Automattic/happychat-client/pull/188#discussion_r178282044"},"pull_request":{"href":"https://api.github.com/repos/Automattic/happychat-client/pulls/188"}},"in_reply_to_id":178065975},"pull_request":{"url":"https://api.github.com/repos/Automattic/happychat-client/pulls/188","id":178163020,"html_url":"https://github.com/Automattic/happychat-client/pull/188","diff_url":"https://github.com/Automattic/happychat-client/pull/188.diff","patch_url":"https://github.com/Automattic/happychat-client/pull/188.patch","issue_url":"https://api.github.com/repos/Automattic/happychat-client/issues/188","number":188,"state":"open","locked":false,"title":"Add support for wpcom proxy auth","user":{"login":"unDemian","id":2129455,"avatar_url":"https://avatars1.githubusercontent.com/u/2129455?v=4","gravatar_id":"","url":"https://api.github.com/users/unDemian","html_url":"https://github.com/unDemian","followers_url":"https://api.github.com/users/unDemian/followers","following_url":"https://api.github.com/users/unDemian/following{/other_user}","gists_url":"https://api.github.com/users/unDemian/gists{/gist_id}","starred_url":"https://api.github.com/users/unDemian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unDemian/subscriptions","organizations_url":"https://api.github.com/users/unDemian/orgs","repos_url":"https://api.github.com/users/unDemian/repos","events_url":"https://api.github.com/users/unDemian/events{/privacy}","received_events_url":"https://api.github.com/users/unDemian/received_events","type":"User","site_admin":false},"body":"**Built on top of https://github.com/Automattic/happychat-client/pull/184**\r\n\r\n## Summary\r\nAdd authentication library with multiple strategies in order to integrate the client with Calypso. Usage of this library can be seen in https://github.com/Automattic/happychat-client/pull/189\r\n\r\nIt would be nice to add some tests if we find time.\r\n\r\n## Testing\r\n- Code looks good\r\n- Docs make sense","created_at":"2018-03-28T21:01:47Z","updated_at":"2018-03-30T12:19:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"545167aefbc664029a10ea73fa07e7b2a3759675","assignee":{"login":"unDemian","id":2129455,"avatar_url":"https://avatars1.githubusercontent.com/u/2129455?v=4","gravatar_id":"","url":"https://api.github.com/users/unDemian","html_url":"https://github.com/unDemian","followers_url":"https://api.github.com/users/unDemian/followers","following_url":"https://api.github.com/users/unDemian/following{/other_user}","gists_url":"https://api.github.com/users/unDemian/gists{/gist_id}","starred_url":"https://api.github.com/users/unDemian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unDemian/subscriptions","organizations_url":"https://api.github.com/users/unDemian/orgs","repos_url":"https://api.github.com/users/unDemian/repos","events_url":"https://api.github.com/users/unDemian/events{/privacy}","received_events_url":"https://api.github.com/users/unDemian/received_events","type":"User","site_admin":false},"assignees":[{"login":"unDemian","id":2129455,"avatar_url":"https://avatars1.githubusercontent.com/u/2129455?v=4","gravatar_id":"","url":"https://api.github.com/users/unDemian","html_url":"https://github.com/unDemian","followers_url":"https://api.github.com/users/unDemian/followers","following_url":"https://api.github.com/users/unDemian/following{/other_user}","gists_url":"https://api.github.com/users/unDemian/gists{/gist_id}","starred_url":"https://api.github.com/users/unDemian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unDemian/subscriptions","organizations_url":"https://api.github.com/users/unDemian/orgs","repos_url":"https://api.github.com/users/unDemian/repos","events_url":"https://api.github.com/users/unDemian/events{/privacy}","received_events_url":"https://api.github.com/users/unDemian/received_events","type":"User","site_admin":false}],"requested_reviewers":[{"login":"nosolosw","id":583546,"avatar_url":"https://avatars1.githubusercontent.com/u/583546?v=4","gravatar_id":"","url":"https://api.github.com/users/nosolosw","html_url":"https://github.com/nosolosw","followers_url":"https://api.github.com/users/nosolosw/followers","following_url":"https://api.github.com/users/nosolosw/following{/other_user}","gists_url":"https://api.github.com/users/nosolosw/gists{/gist_id}","starred_url":"https://api.github.com/users/nosolosw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nosolosw/subscriptions","organizations_url":"https://api.github.com/users/nosolosw/orgs","repos_url":"https://api.github.com/users/nosolosw/repos","events_url":"https://api.github.com/users/nosolosw/events{/privacy}","received_events_url":"https://api.github.com/users/nosolosw/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[{"id":753252268,"url":"https://api.github.com/repos/Automattic/happychat-client/labels/[Status]%20Needs%20Review","name":"[Status] Needs Review","color":"fef2c0","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/Automattic/happychat-client/pulls/188/commits","review_comments_url":"https://api.github.com/repos/Automattic/happychat-client/pulls/188/comments","review_comment_url":"https://api.github.com/repos/Automattic/happychat-client/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Automattic/happychat-client/issues/188/comments","statuses_url":"https://api.github.com/repos/Automattic/happychat-client/statuses/6ff2c94e1d2f4a054326fb12b1736b40783c9858","head":{"label":"Automattic:add/support-for-wpcom-proxy-auth","ref":"add/support-for-wpcom-proxy-auth","sha":"6ff2c94e1d2f4a054326fb12b1736b40783c9858","user":{"login":"Automattic","id":887802,"avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"repo":{"id":82994148,"name":"happychat-client","full_name":"Automattic/happychat-client","owner":{"login":"Automattic","id":887802,"avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Automattic/happychat-client","description":"Happychat customer client code","fork":false,"url":"https://api.github.com/repos/Automattic/happychat-client","forks_url":"https://api.github.com/repos/Automattic/happychat-client/forks","keys_url":"https://api.github.com/repos/Automattic/happychat-client/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Automattic/happychat-client/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Automattic/happychat-client/teams","hooks_url":"https://api.github.com/repos/Automattic/happychat-client/hooks","issue_events_url":"https://api.github.com/repos/Automattic/happychat-client/issues/events{/number}","events_url":"https://api.github.com/repos/Automattic/happychat-client/events","assignees_url":"https://api.github.com/repos/Automattic/happychat-client/assignees{/user}","branches_url":"https://api.github.com/repos/Automattic/happychat-client/branches{/branch}","tags_url":"https://api.github.com/repos/Automattic/happychat-client/tags","blobs_url":"https://api.github.com/repos/Automattic/happychat-client/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Automattic/happychat-client/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Automattic/happychat-client/git/refs{/sha}","trees_url":"https://api.github.com/repos/Automattic/happychat-client/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Automattic/happychat-client/statuses/{sha}","languages_url":"https://api.github.com/repos/Automattic/happychat-client/languages","stargazers_url":"https://api.github.com/repos/Automattic/happychat-client/stargazers","contributors_url":"https://api.github.com/repos/Automattic/happychat-client/contributors","subscribers_url":"https://api.github.com/repos/Automattic/happychat-client/subscribers","subscription_url":"https://api.github.com/repos/Automattic/happychat-client/subscription","commits_url":"https://api.github.com/repos/Automattic/happychat-client/commits{/sha}","git_commits_url":"https://api.github.com/repos/Automattic/happychat-client/git/commits{/sha}","comments_url":"https://api.github.com/repos/Automattic/happychat-client/comments{/number}","issue_comment_url":"https://api.github.com/repos/Automattic/happychat-client/issues/comments{/number}","contents_url":"https://api.github.com/repos/Automattic/happychat-client/contents/{+path}","compare_url":"https://api.github.com/repos/Automattic/happychat-client/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Automattic/happychat-client/merges","archive_url":"https://api.github.com/repos/Automattic/happychat-client/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Automattic/happychat-client/downloads","issues_url":"https://api.github.com/repos/Automattic/happychat-client/issues{/number}","pulls_url":"https://api.github.com/repos/Automattic/happychat-client/pulls{/number}","milestones_url":"https://api.github.com/repos/Automattic/happychat-client/milestones{/number}","notifications_url":"https://api.github.com/repos/Automattic/happychat-client/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Automattic/happychat-client/labels{/name}","releases_url":"https://api.github.com/repos/Automattic/happychat-client/releases{/id}","deployments_url":"https://api.github.com/repos/Automattic/happychat-client/deployments","created_at":"2017-02-24T02:47:57Z","updated_at":"2018-03-27T18:07:41Z","pushed_at":"2018-03-30T12:19:10Z","git_url":"git://github.com/Automattic/happychat-client.git","ssh_url":"git@github.com:Automattic/happychat-client.git","clone_url":"https://github.com/Automattic/happychat-client.git","svn_url":"https://github.com/Automattic/happychat-client","homepage":null,"size":5197,"stargazers_count":2,"watchers_count":2,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":29,"license":null,"forks":1,"open_issues":29,"watchers":2,"default_branch":"master"}},"base":{"label":"Automattic:add/npm-package-compliance","ref":"add/npm-package-compliance","sha":"6297c634156ec14e17e4a5b48f224014c34a3922","user":{"login":"Automattic","id":887802,"avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"repo":{"id":82994148,"name":"happychat-client","full_name":"Automattic/happychat-client","owner":{"login":"Automattic","id":887802,"avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Automattic/happychat-client","description":"Happychat customer client code","fork":false,"url":"https://api.github.com/repos/Automattic/happychat-client","forks_url":"https://api.github.com/repos/Automattic/happychat-client/forks","keys_url":"https://api.github.com/repos/Automattic/happychat-client/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Automattic/happychat-client/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Automattic/happychat-client/teams","hooks_url":"https://api.github.com/repos/Automattic/happychat-client/hooks","issue_events_url":"https://api.github.com/repos/Automattic/happychat-client/issues/events{/number}","events_url":"https://api.github.com/repos/Automattic/happychat-client/events","assignees_url":"https://api.github.com/repos/Automattic/happychat-client/assignees{/user}","branches_url":"https://api.github.com/repos/Automattic/happychat-client/branches{/branch}","tags_url":"https://api.github.com/repos/Automattic/happychat-client/tags","blobs_url":"https://api.github.com/repos/Automattic/happychat-client/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Automattic/happychat-client/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Automattic/happychat-client/git/refs{/sha}","trees_url":"https://api.github.com/repos/Automattic/happychat-client/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Automattic/happychat-client/statuses/{sha}","languages_url":"https://api.github.com/repos/Automattic/happychat-client/languages","stargazers_url":"https://api.github.com/repos/Automattic/happychat-client/stargazers","contributors_url":"https://api.github.com/repos/Automattic/happychat-client/contributors","subscribers_url":"https://api.github.com/repos/Automattic/happychat-client/subscribers","subscription_url":"https://api.github.com/repos/Automattic/happychat-client/subscription","commits_url":"https://api.github.com/repos/Automattic/happychat-client/commits{/sha}","git_commits_url":"https://api.github.com/repos/Automattic/happychat-client/git/commits{/sha}","comments_url":"https://api.github.com/repos/Automattic/happychat-client/comments{/number}","issue_comment_url":"https://api.github.com/repos/Automattic/happychat-client/issues/comments{/number}","contents_url":"https://api.github.com/repos/Automattic/happychat-client/contents/{+path}","compare_url":"https://api.github.com/repos/Automattic/happychat-client/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Automattic/happychat-client/merges","archive_url":"https://api.github.com/repos/Automattic/happychat-client/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Automattic/happychat-client/downloads","issues_url":"https://api.github.com/repos/Automattic/happychat-client/issues{/number}","pulls_url":"https://api.github.com/repos/Automattic/happychat-client/pulls{/number}","milestones_url":"https://api.github.com/repos/Automattic/happychat-client/milestones{/number}","notifications_url":"https://api.github.com/repos/Automattic/happychat-client/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Automattic/happychat-client/labels{/name}","releases_url":"https://api.github.com/repos/Automattic/happychat-client/releases{/id}","deployments_url":"https://api.github.com/repos/Automattic/happychat-client/deployments","created_at":"2017-02-24T02:47:57Z","updated_at":"2018-03-27T18:07:41Z","pushed_at":"2018-03-30T12:19:10Z","git_url":"git://github.com/Automattic/happychat-client.git","ssh_url":"git@github.com:Automattic/happychat-client.git","clone_url":"https://github.com/Automattic/happychat-client.git","svn_url":"https://github.com/Automattic/happychat-client","homepage":null,"size":5197,"stargazers_count":2,"watchers_count":2,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":29,"license":null,"forks":1,"open_issues":29,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Automattic/happychat-client/pulls/188"},"html":{"href":"https://github.com/Automattic/happychat-client/pull/188"},"issue":{"href":"https://api.github.com/repos/Automattic/happychat-client/issues/188"},"comments":{"href":"https://api.github.com/repos/Automattic/happychat-client/issues/188/comments"},"review_comments":{"href":"https://api.github.com/repos/Automattic/happychat-client/pulls/188/comments"},"review_comment":{"href":"https://api.github.com/repos/Automattic/happychat-client/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Automattic/happychat-client/pulls/188/commits"},"statuses":{"href":"https://api.github.com/repos/Automattic/happychat-client/statuses/6ff2c94e1d2f4a054326fb12b1736b40783c9858"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"unDemian"}}