{"action":"opened","number":454,"pull_request":{"url":"https://api.github.com/repos/Qabel/qabel-core/pulls/454","id":58889317,"html_url":"https://github.com/Qabel/qabel-core/pull/454","diff_url":"https://github.com/Qabel/qabel-core/pull/454.diff","patch_url":"https://github.com/Qabel/qabel-core/pull/454.patch","issue_url":"https://api.github.com/repos/Qabel/qabel-core/issues/454","number":454,"state":"open","locked":false,"title":"allow external request authorization with accounting token","user":{"login":"julianseeger","id":3258762,"avatar_url":"https://avatars.githubusercontent.com/u/3258762?v=3","gravatar_id":"","url":"https://api.github.com/users/julianseeger","html_url":"https://github.com/julianseeger","followers_url":"https://api.github.com/users/julianseeger/followers","following_url":"https://api.github.com/users/julianseeger/following{/other_user}","gists_url":"https://api.github.com/users/julianseeger/gists{/gist_id}","starred_url":"https://api.github.com/users/julianseeger/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/julianseeger/subscriptions","organizations_url":"https://api.github.com/users/julianseeger/orgs","repos_url":"https://api.github.com/users/julianseeger/repos","events_url":"https://api.github.com/users/julianseeger/events{/privacy}","received_events_url":"https://api.github.com/users/julianseeger/received_events","type":"User","site_admin":false},"body":"As the block client needs to send an auth token, we need a way to extract it from the AccountingHttp. This way, the block client can \"authorize\" it's request without knowing how to communicate with the accounting server itself.\r\n\r\nThis feature is required for Qabel/qabel-desktop#112\r\n\r\nPS: the diff looks pretty bad. Actually I just extracted the `addHeader(\"Authorization\"` stuff to the `authorize(HttpRequest)` method and moved the repeated \r\n```JAVA\r\nif (server.getAuthToken() == null) {\r\n\tlogin();\r\n}\r\n... server.getAuthToken()\r\n```\r\ncode to a single `getAuthToken()` call","created_at":"2016-02-10T13:21:38Z","updated_at":"2016-02-10T13:21:38Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Qabel/qabel-core/pulls/454/commits","review_comments_url":"https://api.github.com/repos/Qabel/qabel-core/pulls/454/comments","review_comment_url":"https://api.github.com/repos/Qabel/qabel-core/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Qabel/qabel-core/issues/454/comments","statuses_url":"https://api.github.com/repos/Qabel/qabel-core/statuses/f181fcab2fa77a2ba1e2f62fd3374379f745a3f9","head":{"label":"julianseeger:accountingHttpToken","ref":"accountingHttpToken","sha":"f181fcab2fa77a2ba1e2f62fd3374379f745a3f9","user":{"login":"julianseeger","id":3258762,"avatar_url":"https://avatars.githubusercontent.com/u/3258762?v=3","gravatar_id":"","url":"https://api.github.com/users/julianseeger","html_url":"https://github.com/julianseeger","followers_url":"https://api.github.com/users/julianseeger/followers","following_url":"https://api.github.com/users/julianseeger/following{/other_user}","gists_url":"https://api.github.com/users/julianseeger/gists{/gist_id}","starred_url":"https://api.github.com/users/julianseeger/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/julianseeger/subscriptions","organizations_url":"https://api.github.com/users/julianseeger/orgs","repos_url":"https://api.github.com/users/julianseeger/repos","events_url":"https://api.github.com/users/julianseeger/events{/privacy}","received_events_url":"https://api.github.com/users/julianseeger/received_events","type":"User","site_admin":false},"repo":{"id":49273936,"name":"qabel-core","full_name":"julianseeger/qabel-core","owner":{"login":"julianseeger","id":3258762,"avatar_url":"https://avatars.githubusercontent.com/u/3258762?v=3","gravatar_id":"","url":"https://api.github.com/users/julianseeger","html_url":"https://github.com/julianseeger","followers_url":"https://api.github.com/users/julianseeger/followers","following_url":"https://api.github.com/users/julianseeger/following{/other_user}","gists_url":"https://api.github.com/users/julianseeger/gists{/gist_id}","starred_url":"https://api.github.com/users/julianseeger/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/julianseeger/subscriptions","organizations_url":"https://api.github.com/users/julianseeger/orgs","repos_url":"https://api.github.com/users/julianseeger/repos","events_url":"https://api.github.com/users/julianseeger/events{/privacy}","received_events_url":"https://api.github.com/users/julianseeger/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/julianseeger/qabel-core","description":"Implementation of Qabel-Core in Java","fork":true,"url":"https://api.github.com/repos/julianseeger/qabel-core","forks_url":"https://api.github.com/repos/julianseeger/qabel-core/forks","keys_url":"https://api.github.com/repos/julianseeger/qabel-core/keys{/key_id}","collaborators_url":"https://api.github.com/repos/julianseeger/qabel-core/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/julianseeger/qabel-core/teams","hooks_url":"https://api.github.com/repos/julianseeger/qabel-core/hooks","issue_events_url":"https://api.github.com/repos/julianseeger/qabel-core/issues/events{/number}","events_url":"https://api.github.com/repos/julianseeger/qabel-core/events","assignees_url":"https://api.github.com/repos/julianseeger/qabel-core/assignees{/user}","branches_url":"https://api.github.com/repos/julianseeger/qabel-core/branches{/branch}","tags_url":"https://api.github.com/repos/julianseeger/qabel-core/tags","blobs_url":"https://api.github.com/repos/julianseeger/qabel-core/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/julianseeger/qabel-core/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/julianseeger/qabel-core/git/refs{/sha}","trees_url":"https://api.github.com/repos/julianseeger/qabel-core/git/trees{/sha}","statuses_url":"https://api.github.com/repos/julianseeger/qabel-core/statuses/{sha}","languages_url":"https://api.github.com/repos/julianseeger/qabel-core/languages","stargazers_url":"https://api.github.com/repos/julianseeger/qabel-core/stargazers","contributors_url":"https://api.github.com/repos/julianseeger/qabel-core/contributors","subscribers_url":"https://api.github.com/repos/julianseeger/qabel-core/subscribers","subscription_url":"https://api.github.com/repos/julianseeger/qabel-core/subscription","commits_url":"https://api.github.com/repos/julianseeger/qabel-core/commits{/sha}","git_commits_url":"https://api.github.com/repos/julianseeger/qabel-core/git/commits{/sha}","comments_url":"https://api.github.com/repos/julianseeger/qabel-core/comments{/number}","issue_comment_url":"https://api.github.com/repos/julianseeger/qabel-core/issues/comments{/number}","contents_url":"https://api.github.com/repos/julianseeger/qabel-core/contents/{+path}","compare_url":"https://api.github.com/repos/julianseeger/qabel-core/compare/{base}...{head}","merges_url":"https://api.github.com/repos/julianseeger/qabel-core/merges","archive_url":"https://api.github.com/repos/julianseeger/qabel-core/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/julianseeger/qabel-core/downloads","issues_url":"https://api.github.com/repos/julianseeger/qabel-core/issues{/number}","pulls_url":"https://api.github.com/repos/julianseeger/qabel-core/pulls{/number}","milestones_url":"https://api.github.com/repos/julianseeger/qabel-core/milestones{/number}","notifications_url":"https://api.github.com/repos/julianseeger/qabel-core/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/julianseeger/qabel-core/labels{/name}","releases_url":"https://api.github.com/repos/julianseeger/qabel-core/releases{/id}","deployments_url":"https://api.github.com/repos/julianseeger/qabel-core/deployments","created_at":"2016-01-08T13:36:33Z","updated_at":"2016-01-15T09:25:00Z","pushed_at":"2016-02-10T13:15:03Z","git_url":"git://github.com/julianseeger/qabel-core.git","ssh_url":"git@github.com:julianseeger/qabel-core.git","clone_url":"https://github.com/julianseeger/qabel-core.git","svn_url":"https://github.com/julianseeger/qabel-core","homepage":null,"size":3943,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"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":"Qabel:master","ref":"master","sha":"46d794d000bbbc9a21018070d720ee2757df0df8","user":{"login":"Qabel","id":7711470,"avatar_url":"https://avatars.githubusercontent.com/u/7711470?v=3","gravatar_id":"","url":"https://api.github.com/users/Qabel","html_url":"https://github.com/Qabel","followers_url":"https://api.github.com/users/Qabel/followers","following_url":"https://api.github.com/users/Qabel/following{/other_user}","gists_url":"https://api.github.com/users/Qabel/gists{/gist_id}","starred_url":"https://api.github.com/users/Qabel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Qabel/subscriptions","organizations_url":"https://api.github.com/users/Qabel/orgs","repos_url":"https://api.github.com/users/Qabel/repos","events_url":"https://api.github.com/users/Qabel/events{/privacy}","received_events_url":"https://api.github.com/users/Qabel/received_events","type":"Organization","site_admin":false},"repo":{"id":22873447,"name":"qabel-core","full_name":"Qabel/qabel-core","owner":{"login":"Qabel","id":7711470,"avatar_url":"https://avatars.githubusercontent.com/u/7711470?v=3","gravatar_id":"","url":"https://api.github.com/users/Qabel","html_url":"https://github.com/Qabel","followers_url":"https://api.github.com/users/Qabel/followers","following_url":"https://api.github.com/users/Qabel/following{/other_user}","gists_url":"https://api.github.com/users/Qabel/gists{/gist_id}","starred_url":"https://api.github.com/users/Qabel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Qabel/subscriptions","organizations_url":"https://api.github.com/users/Qabel/orgs","repos_url":"https://api.github.com/users/Qabel/repos","events_url":"https://api.github.com/users/Qabel/events{/privacy}","received_events_url":"https://api.github.com/users/Qabel/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Qabel/qabel-core","description":"Implementation of Qabel-Core in Java","fork":false,"url":"https://api.github.com/repos/Qabel/qabel-core","forks_url":"https://api.github.com/repos/Qabel/qabel-core/forks","keys_url":"https://api.github.com/repos/Qabel/qabel-core/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Qabel/qabel-core/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Qabel/qabel-core/teams","hooks_url":"https://api.github.com/repos/Qabel/qabel-core/hooks","issue_events_url":"https://api.github.com/repos/Qabel/qabel-core/issues/events{/number}","events_url":"https://api.github.com/repos/Qabel/qabel-core/events","assignees_url":"https://api.github.com/repos/Qabel/qabel-core/assignees{/user}","branches_url":"https://api.github.com/repos/Qabel/qabel-core/branches{/branch}","tags_url":"https://api.github.com/repos/Qabel/qabel-core/tags","blobs_url":"https://api.github.com/repos/Qabel/qabel-core/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Qabel/qabel-core/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Qabel/qabel-core/git/refs{/sha}","trees_url":"https://api.github.com/repos/Qabel/qabel-core/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Qabel/qabel-core/statuses/{sha}","languages_url":"https://api.github.com/repos/Qabel/qabel-core/languages","stargazers_url":"https://api.github.com/repos/Qabel/qabel-core/stargazers","contributors_url":"https://api.github.com/repos/Qabel/qabel-core/contributors","subscribers_url":"https://api.github.com/repos/Qabel/qabel-core/subscribers","subscription_url":"https://api.github.com/repos/Qabel/qabel-core/subscription","commits_url":"https://api.github.com/repos/Qabel/qabel-core/commits{/sha}","git_commits_url":"https://api.github.com/repos/Qabel/qabel-core/git/commits{/sha}","comments_url":"https://api.github.com/repos/Qabel/qabel-core/comments{/number}","issue_comment_url":"https://api.github.com/repos/Qabel/qabel-core/issues/comments{/number}","contents_url":"https://api.github.com/repos/Qabel/qabel-core/contents/{+path}","compare_url":"https://api.github.com/repos/Qabel/qabel-core/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Qabel/qabel-core/merges","archive_url":"https://api.github.com/repos/Qabel/qabel-core/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Qabel/qabel-core/downloads","issues_url":"https://api.github.com/repos/Qabel/qabel-core/issues{/number}","pulls_url":"https://api.github.com/repos/Qabel/qabel-core/pulls{/number}","milestones_url":"https://api.github.com/repos/Qabel/qabel-core/milestones{/number}","notifications_url":"https://api.github.com/repos/Qabel/qabel-core/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Qabel/qabel-core/labels{/name}","releases_url":"https://api.github.com/repos/Qabel/qabel-core/releases{/id}","deployments_url":"https://api.github.com/repos/Qabel/qabel-core/deployments","created_at":"2014-08-12T10:25:10Z","updated_at":"2016-01-11T14:19:42Z","pushed_at":"2016-02-10T12:56:10Z","git_url":"git://github.com/Qabel/qabel-core.git","ssh_url":"git@github.com:Qabel/qabel-core.git","clone_url":"https://github.com/Qabel/qabel-core.git","svn_url":"https://github.com/Qabel/qabel-core","homepage":null,"size":5276,"stargazers_count":6,"watchers_count":6,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":14,"mirror_url":null,"open_issues_count":27,"forks":14,"open_issues":27,"watchers":6,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Qabel/qabel-core/pulls/454"},"html":{"href":"https://github.com/Qabel/qabel-core/pull/454"},"issue":{"href":"https://api.github.com/repos/Qabel/qabel-core/issues/454"},"comments":{"href":"https://api.github.com/repos/Qabel/qabel-core/issues/454/comments"},"review_comments":{"href":"https://api.github.com/repos/Qabel/qabel-core/pulls/454/comments"},"review_comment":{"href":"https://api.github.com/repos/Qabel/qabel-core/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Qabel/qabel-core/pulls/454/commits"},"statuses":{"href":"https://api.github.com/repos/Qabel/qabel-core/statuses/f181fcab2fa77a2ba1e2f62fd3374379f745a3f9"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":1,"additions":14,"deletions":12,"changed_files":1}}