{"action":"created","comment":{"url":"https://api.github.com/repos/elifesciences/api-client-php/pulls/comments/96455354","pull_request_review_id":17037454,"id":96455354,"diff_hunk":"@@ -54,6 +55,13 @@ public function __construct(HttpClient $httpClient, array $headers = [])\n \n         $request = new Request('PUT', $uri, $headers, $content);\n \n+        return $this->send($request);\n+    }\n+\n+    private function send(RequestInterface $request) : PromiseInterface\n+    {\n+        $request = $request->withHeader('User-Agent', trim(sprintf('eLifeApiClient/%s %s', Version::get(), $request->getHeader('User-Agent')[0] ?? '')));","path":"src/ApiClient.php","position":43,"original_position":43,"commit_id":"0ef8f93264271544a59ddafa696065efa81a8e0e","original_commit_id":"0ef8f93264271544a59ddafa696065efa81a8e0e","user":{"login":"giorgiosironi","id":160299,"avatar_url":"https://avatars.githubusercontent.com/u/160299?v=3","gravatar_id":"","url":"https://api.github.com/users/giorgiosironi","html_url":"https://github.com/giorgiosironi","followers_url":"https://api.github.com/users/giorgiosironi/followers","following_url":"https://api.github.com/users/giorgiosironi/following{/other_user}","gists_url":"https://api.github.com/users/giorgiosironi/gists{/gist_id}","starred_url":"https://api.github.com/users/giorgiosironi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/giorgiosironi/subscriptions","organizations_url":"https://api.github.com/users/giorgiosironi/orgs","repos_url":"https://api.github.com/users/giorgiosironi/repos","events_url":"https://api.github.com/users/giorgiosironi/events{/privacy}","received_events_url":"https://api.github.com/users/giorgiosironi/received_events","type":"User","site_admin":false},"body":"why it is necessary to add the value also here? Who uses this trait?","created_at":"2017-01-17T16:48:19Z","updated_at":"2017-01-17T16:48:19Z","html_url":"https://github.com/elifesciences/api-client-php/pull/41#discussion_r96455354","pull_request_url":"https://api.github.com/repos/elifesciences/api-client-php/pulls/41","_links":{"self":{"href":"https://api.github.com/repos/elifesciences/api-client-php/pulls/comments/96455354"},"html":{"href":"https://github.com/elifesciences/api-client-php/pull/41#discussion_r96455354"},"pull_request":{"href":"https://api.github.com/repos/elifesciences/api-client-php/pulls/41"}}},"pull_request":{"url":"https://api.github.com/repos/elifesciences/api-client-php/pulls/41","id":101894003,"html_url":"https://github.com/elifesciences/api-client-php/pull/41","diff_url":"https://github.com/elifesciences/api-client-php/pull/41.diff","patch_url":"https://github.com/elifesciences/api-client-php/pull/41.patch","issue_url":"https://api.github.com/repos/elifesciences/api-client-php/issues/41","number":41,"state":"open","locked":false,"title":"Add User-Agent header","user":{"login":"thewilkybarkid","id":1784740,"avatar_url":"https://avatars.githubusercontent.com/u/1784740?v=3","gravatar_id":"","url":"https://api.github.com/users/thewilkybarkid","html_url":"https://github.com/thewilkybarkid","followers_url":"https://api.github.com/users/thewilkybarkid/followers","following_url":"https://api.github.com/users/thewilkybarkid/following{/other_user}","gists_url":"https://api.github.com/users/thewilkybarkid/gists{/gist_id}","starred_url":"https://api.github.com/users/thewilkybarkid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thewilkybarkid/subscriptions","organizations_url":"https://api.github.com/users/thewilkybarkid/orgs","repos_url":"https://api.github.com/users/thewilkybarkid/repos","events_url":"https://api.github.com/users/thewilkybarkid/events{/privacy}","received_events_url":"https://api.github.com/users/thewilkybarkid/received_events","type":"User","site_admin":false},"body":"/cc @giorgiosironi ","created_at":"2017-01-17T16:09:45Z","updated_at":"2017-01-17T16:48:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0822a31453c2b49c006d36afc179439e344f7a00","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/elifesciences/api-client-php/pulls/41/commits","review_comments_url":"https://api.github.com/repos/elifesciences/api-client-php/pulls/41/comments","review_comment_url":"https://api.github.com/repos/elifesciences/api-client-php/pulls/comments{/number}","comments_url":"https://api.github.com/repos/elifesciences/api-client-php/issues/41/comments","statuses_url":"https://api.github.com/repos/elifesciences/api-client-php/statuses/0ef8f93264271544a59ddafa696065efa81a8e0e","head":{"label":"thewilkybarkid:user-agent","ref":"user-agent","sha":"0ef8f93264271544a59ddafa696065efa81a8e0e","user":{"login":"thewilkybarkid","id":1784740,"avatar_url":"https://avatars.githubusercontent.com/u/1784740?v=3","gravatar_id":"","url":"https://api.github.com/users/thewilkybarkid","html_url":"https://github.com/thewilkybarkid","followers_url":"https://api.github.com/users/thewilkybarkid/followers","following_url":"https://api.github.com/users/thewilkybarkid/following{/other_user}","gists_url":"https://api.github.com/users/thewilkybarkid/gists{/gist_id}","starred_url":"https://api.github.com/users/thewilkybarkid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thewilkybarkid/subscriptions","organizations_url":"https://api.github.com/users/thewilkybarkid/orgs","repos_url":"https://api.github.com/users/thewilkybarkid/repos","events_url":"https://api.github.com/users/thewilkybarkid/events{/privacy}","received_events_url":"https://api.github.com/users/thewilkybarkid/received_events","type":"User","site_admin":false},"repo":{"id":67142923,"name":"api-client-php","full_name":"thewilkybarkid/api-client-php","owner":{"login":"thewilkybarkid","id":1784740,"avatar_url":"https://avatars.githubusercontent.com/u/1784740?v=3","gravatar_id":"","url":"https://api.github.com/users/thewilkybarkid","html_url":"https://github.com/thewilkybarkid","followers_url":"https://api.github.com/users/thewilkybarkid/followers","following_url":"https://api.github.com/users/thewilkybarkid/following{/other_user}","gists_url":"https://api.github.com/users/thewilkybarkid/gists{/gist_id}","starred_url":"https://api.github.com/users/thewilkybarkid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thewilkybarkid/subscriptions","organizations_url":"https://api.github.com/users/thewilkybarkid/orgs","repos_url":"https://api.github.com/users/thewilkybarkid/repos","events_url":"https://api.github.com/users/thewilkybarkid/events{/privacy}","received_events_url":"https://api.github.com/users/thewilkybarkid/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/thewilkybarkid/api-client-php","description":"PHP SDK for the eLife Sciences API [in development]","fork":true,"url":"https://api.github.com/repos/thewilkybarkid/api-client-php","forks_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/forks","keys_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/keys{/key_id}","collaborators_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/teams","hooks_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/hooks","issue_events_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/issues/events{/number}","events_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/events","assignees_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/assignees{/user}","branches_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/branches{/branch}","tags_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/tags","blobs_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/git/refs{/sha}","trees_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/git/trees{/sha}","statuses_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/statuses/{sha}","languages_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/languages","stargazers_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/stargazers","contributors_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/contributors","subscribers_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/subscribers","subscription_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/subscription","commits_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/commits{/sha}","git_commits_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/git/commits{/sha}","comments_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/comments{/number}","issue_comment_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/issues/comments{/number}","contents_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/contents/{+path}","compare_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/compare/{base}...{head}","merges_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/merges","archive_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/downloads","issues_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/issues{/number}","pulls_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/pulls{/number}","milestones_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/milestones{/number}","notifications_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/labels{/name}","releases_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/releases{/id}","deployments_url":"https://api.github.com/repos/thewilkybarkid/api-client-php/deployments","created_at":"2016-09-01T15:21:18Z","updated_at":"2016-09-01T15:21:19Z","pushed_at":"2017-01-17T16:21:56Z","git_url":"git://github.com/thewilkybarkid/api-client-php.git","ssh_url":"git@github.com:thewilkybarkid/api-client-php.git","clone_url":"https://github.com/thewilkybarkid/api-client-php.git","svn_url":"https://github.com/thewilkybarkid/api-client-php","homepage":"","size":47,"stargazers_count":0,"watchers_count":0,"language":"PHP","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":"elifesciences:master","ref":"master","sha":"21724189d4806557cceb229ebbfec142732408cb","user":{"login":"elifesciences","id":1777367,"avatar_url":"https://avatars.githubusercontent.com/u/1777367?v=3","gravatar_id":"","url":"https://api.github.com/users/elifesciences","html_url":"https://github.com/elifesciences","followers_url":"https://api.github.com/users/elifesciences/followers","following_url":"https://api.github.com/users/elifesciences/following{/other_user}","gists_url":"https://api.github.com/users/elifesciences/gists{/gist_id}","starred_url":"https://api.github.com/users/elifesciences/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/elifesciences/subscriptions","organizations_url":"https://api.github.com/users/elifesciences/orgs","repos_url":"https://api.github.com/users/elifesciences/repos","events_url":"https://api.github.com/users/elifesciences/events{/privacy}","received_events_url":"https://api.github.com/users/elifesciences/received_events","type":"Organization","site_admin":false},"repo":{"id":60767798,"name":"api-client-php","full_name":"elifesciences/api-client-php","owner":{"login":"elifesciences","id":1777367,"avatar_url":"https://avatars.githubusercontent.com/u/1777367?v=3","gravatar_id":"","url":"https://api.github.com/users/elifesciences","html_url":"https://github.com/elifesciences","followers_url":"https://api.github.com/users/elifesciences/followers","following_url":"https://api.github.com/users/elifesciences/following{/other_user}","gists_url":"https://api.github.com/users/elifesciences/gists{/gist_id}","starred_url":"https://api.github.com/users/elifesciences/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/elifesciences/subscriptions","organizations_url":"https://api.github.com/users/elifesciences/orgs","repos_url":"https://api.github.com/users/elifesciences/repos","events_url":"https://api.github.com/users/elifesciences/events{/privacy}","received_events_url":"https://api.github.com/users/elifesciences/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/elifesciences/api-client-php","description":"PHP client for the eLife Sciences API [in development]","fork":false,"url":"https://api.github.com/repos/elifesciences/api-client-php","forks_url":"https://api.github.com/repos/elifesciences/api-client-php/forks","keys_url":"https://api.github.com/repos/elifesciences/api-client-php/keys{/key_id}","collaborators_url":"https://api.github.com/repos/elifesciences/api-client-php/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/elifesciences/api-client-php/teams","hooks_url":"https://api.github.com/repos/elifesciences/api-client-php/hooks","issue_events_url":"https://api.github.com/repos/elifesciences/api-client-php/issues/events{/number}","events_url":"https://api.github.com/repos/elifesciences/api-client-php/events","assignees_url":"https://api.github.com/repos/elifesciences/api-client-php/assignees{/user}","branches_url":"https://api.github.com/repos/elifesciences/api-client-php/branches{/branch}","tags_url":"https://api.github.com/repos/elifesciences/api-client-php/tags","blobs_url":"https://api.github.com/repos/elifesciences/api-client-php/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/elifesciences/api-client-php/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/elifesciences/api-client-php/git/refs{/sha}","trees_url":"https://api.github.com/repos/elifesciences/api-client-php/git/trees{/sha}","statuses_url":"https://api.github.com/repos/elifesciences/api-client-php/statuses/{sha}","languages_url":"https://api.github.com/repos/elifesciences/api-client-php/languages","stargazers_url":"https://api.github.com/repos/elifesciences/api-client-php/stargazers","contributors_url":"https://api.github.com/repos/elifesciences/api-client-php/contributors","subscribers_url":"https://api.github.com/repos/elifesciences/api-client-php/subscribers","subscription_url":"https://api.github.com/repos/elifesciences/api-client-php/subscription","commits_url":"https://api.github.com/repos/elifesciences/api-client-php/commits{/sha}","git_commits_url":"https://api.github.com/repos/elifesciences/api-client-php/git/commits{/sha}","comments_url":"https://api.github.com/repos/elifesciences/api-client-php/comments{/number}","issue_comment_url":"https://api.github.com/repos/elifesciences/api-client-php/issues/comments{/number}","contents_url":"https://api.github.com/repos/elifesciences/api-client-php/contents/{+path}","compare_url":"https://api.github.com/repos/elifesciences/api-client-php/compare/{base}...{head}","merges_url":"https://api.github.com/repos/elifesciences/api-client-php/merges","archive_url":"https://api.github.com/repos/elifesciences/api-client-php/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/elifesciences/api-client-php/downloads","issues_url":"https://api.github.com/repos/elifesciences/api-client-php/issues{/number}","pulls_url":"https://api.github.com/repos/elifesciences/api-client-php/pulls{/number}","milestones_url":"https://api.github.com/repos/elifesciences/api-client-php/milestones{/number}","notifications_url":"https://api.github.com/repos/elifesciences/api-client-php/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/elifesciences/api-client-php/labels{/name}","releases_url":"https://api.github.com/repos/elifesciences/api-client-php/releases{/id}","deployments_url":"https://api.github.com/repos/elifesciences/api-client-php/deployments","created_at":"2016-06-09T10:54:57Z","updated_at":"2016-11-18T11:52:12Z","pushed_at":"2017-01-17T16:21:57Z","git_url":"git://github.com/elifesciences/api-client-php.git","ssh_url":"git@github.com:elifesciences/api-client-php.git","clone_url":"https://github.com/elifesciences/api-client-php.git","svn_url":"https://github.com/elifesciences/api-client-php","homepage":"","size":61,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":2,"forks":1,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/elifesciences/api-client-php/pulls/41"},"html":{"href":"https://github.com/elifesciences/api-client-php/pull/41"},"issue":{"href":"https://api.github.com/repos/elifesciences/api-client-php/issues/41"},"comments":{"href":"https://api.github.com/repos/elifesciences/api-client-php/issues/41/comments"},"review_comments":{"href":"https://api.github.com/repos/elifesciences/api-client-php/pulls/41/comments"},"review_comment":{"href":"https://api.github.com/repos/elifesciences/api-client-php/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/elifesciences/api-client-php/pulls/41/commits"},"statuses":{"href":"https://api.github.com/repos/elifesciences/api-client-php/statuses/0ef8f93264271544a59ddafa696065efa81a8e0e"}}}}
{"actor":{"display_login":"giorgiosironi"}}