{"action":"opened","number":19,"pull_request":{"url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/pulls/19","id":44503017,"html_url":"https://github.com/honeybadger-io/honeybadger-java/pull/19","diff_url":"https://github.com/honeybadger-io/honeybadger-java/pull/19.diff","patch_url":"https://github.com/honeybadger-io/honeybadger-java/pull/19.patch","issue_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/issues/19","number":19,"state":"open","locked":false,"title":"Accept apiKey in constructor.","user":{"login":"joshcough","id":37799,"avatar_url":"https://avatars.githubusercontent.com/u/37799?v=3","gravatar_id":"","url":"https://api.github.com/users/joshcough","html_url":"https://github.com/joshcough","followers_url":"https://api.github.com/users/joshcough/followers","following_url":"https://api.github.com/users/joshcough/following{/other_user}","gists_url":"https://api.github.com/users/joshcough/gists{/gist_id}","starred_url":"https://api.github.com/users/joshcough/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joshcough/subscriptions","organizations_url":"https://api.github.com/users/joshcough/orgs","repos_url":"https://api.github.com/users/joshcough/repos","events_url":"https://api.github.com/users/joshcough/events{/privacy}","received_events_url":"https://api.github.com/users/joshcough/received_events","type":"User","site_admin":false},"body":"This simple change allows users to simply pass in their api key into the constructor.\r\n\r\nUsers might not have access to set environment variables (at the least, it can be inconvenient, especially in production), and passing the apiKey into the constructor is simpler and clearer than setting a system property.  In my case, it's easiest to get my apiKey via my play config, and then I don't have to set it twice. This allows me to call HoneyBadger easily inside of a play app, but outside the context of an http request (in an akka actor).\r\n\r\nAll the existing functionality should work exactly as-is, and is fully backwards compatible. This includes checking for the ENV variable, and the system property.","created_at":"2015-09-09T01:55:59Z","updated_at":"2015-09-09T01:55:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/pulls/19/commits","review_comments_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/pulls/19/comments","review_comment_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/pulls/comments{/number}","comments_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/issues/19/comments","statuses_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/statuses/6d5a218c4a3427aa43c8c2bc0933c587c9fc0927","head":{"label":"localytics:master","ref":"master","sha":"6d5a218c4a3427aa43c8c2bc0933c587c9fc0927","user":{"login":"localytics","id":29205,"avatar_url":"https://avatars.githubusercontent.com/u/29205?v=3","gravatar_id":"","url":"https://api.github.com/users/localytics","html_url":"https://github.com/localytics","followers_url":"https://api.github.com/users/localytics/followers","following_url":"https://api.github.com/users/localytics/following{/other_user}","gists_url":"https://api.github.com/users/localytics/gists{/gist_id}","starred_url":"https://api.github.com/users/localytics/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/localytics/subscriptions","organizations_url":"https://api.github.com/users/localytics/orgs","repos_url":"https://api.github.com/users/localytics/repos","events_url":"https://api.github.com/users/localytics/events{/privacy}","received_events_url":"https://api.github.com/users/localytics/received_events","type":"Organization","site_admin":false},"repo":{"id":42149086,"name":"honeybadger-java","full_name":"localytics/honeybadger-java","owner":{"login":"localytics","id":29205,"avatar_url":"https://avatars.githubusercontent.com/u/29205?v=3","gravatar_id":"","url":"https://api.github.com/users/localytics","html_url":"https://github.com/localytics","followers_url":"https://api.github.com/users/localytics/followers","following_url":"https://api.github.com/users/localytics/following{/other_user}","gists_url":"https://api.github.com/users/localytics/gists{/gist_id}","starred_url":"https://api.github.com/users/localytics/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/localytics/subscriptions","organizations_url":"https://api.github.com/users/localytics/orgs","repos_url":"https://api.github.com/users/localytics/repos","events_url":"https://api.github.com/users/localytics/events{/privacy}","received_events_url":"https://api.github.com/users/localytics/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/localytics/honeybadger-java","description":"Java Client to report exceptions to Honeybadger.io","fork":true,"url":"https://api.github.com/repos/localytics/honeybadger-java","forks_url":"https://api.github.com/repos/localytics/honeybadger-java/forks","keys_url":"https://api.github.com/repos/localytics/honeybadger-java/keys{/key_id}","collaborators_url":"https://api.github.com/repos/localytics/honeybadger-java/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/localytics/honeybadger-java/teams","hooks_url":"https://api.github.com/repos/localytics/honeybadger-java/hooks","issue_events_url":"https://api.github.com/repos/localytics/honeybadger-java/issues/events{/number}","events_url":"https://api.github.com/repos/localytics/honeybadger-java/events","assignees_url":"https://api.github.com/repos/localytics/honeybadger-java/assignees{/user}","branches_url":"https://api.github.com/repos/localytics/honeybadger-java/branches{/branch}","tags_url":"https://api.github.com/repos/localytics/honeybadger-java/tags","blobs_url":"https://api.github.com/repos/localytics/honeybadger-java/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/localytics/honeybadger-java/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/localytics/honeybadger-java/git/refs{/sha}","trees_url":"https://api.github.com/repos/localytics/honeybadger-java/git/trees{/sha}","statuses_url":"https://api.github.com/repos/localytics/honeybadger-java/statuses/{sha}","languages_url":"https://api.github.com/repos/localytics/honeybadger-java/languages","stargazers_url":"https://api.github.com/repos/localytics/honeybadger-java/stargazers","contributors_url":"https://api.github.com/repos/localytics/honeybadger-java/contributors","subscribers_url":"https://api.github.com/repos/localytics/honeybadger-java/subscribers","subscription_url":"https://api.github.com/repos/localytics/honeybadger-java/subscription","commits_url":"https://api.github.com/repos/localytics/honeybadger-java/commits{/sha}","git_commits_url":"https://api.github.com/repos/localytics/honeybadger-java/git/commits{/sha}","comments_url":"https://api.github.com/repos/localytics/honeybadger-java/comments{/number}","issue_comment_url":"https://api.github.com/repos/localytics/honeybadger-java/issues/comments{/number}","contents_url":"https://api.github.com/repos/localytics/honeybadger-java/contents/{+path}","compare_url":"https://api.github.com/repos/localytics/honeybadger-java/compare/{base}...{head}","merges_url":"https://api.github.com/repos/localytics/honeybadger-java/merges","archive_url":"https://api.github.com/repos/localytics/honeybadger-java/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/localytics/honeybadger-java/downloads","issues_url":"https://api.github.com/repos/localytics/honeybadger-java/issues{/number}","pulls_url":"https://api.github.com/repos/localytics/honeybadger-java/pulls{/number}","milestones_url":"https://api.github.com/repos/localytics/honeybadger-java/milestones{/number}","notifications_url":"https://api.github.com/repos/localytics/honeybadger-java/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/localytics/honeybadger-java/labels{/name}","releases_url":"https://api.github.com/repos/localytics/honeybadger-java/releases{/id}","created_at":"2015-09-09T01:38:00Z","updated_at":"2015-09-09T01:38:01Z","pushed_at":"2015-09-09T01:55:13Z","git_url":"git://github.com/localytics/honeybadger-java.git","ssh_url":"git@github.com:localytics/honeybadger-java.git","clone_url":"https://github.com/localytics/honeybadger-java.git","svn_url":"https://github.com/localytics/honeybadger-java","homepage":null,"size":660,"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":"honeybadger-io:master","ref":"master","sha":"15197e8ac733968290f69fb54ed5e5910999fdf4","user":{"login":"honeybadger-io","id":1898541,"avatar_url":"https://avatars.githubusercontent.com/u/1898541?v=3","gravatar_id":"","url":"https://api.github.com/users/honeybadger-io","html_url":"https://github.com/honeybadger-io","followers_url":"https://api.github.com/users/honeybadger-io/followers","following_url":"https://api.github.com/users/honeybadger-io/following{/other_user}","gists_url":"https://api.github.com/users/honeybadger-io/gists{/gist_id}","starred_url":"https://api.github.com/users/honeybadger-io/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/honeybadger-io/subscriptions","organizations_url":"https://api.github.com/users/honeybadger-io/orgs","repos_url":"https://api.github.com/users/honeybadger-io/repos","events_url":"https://api.github.com/users/honeybadger-io/events{/privacy}","received_events_url":"https://api.github.com/users/honeybadger-io/received_events","type":"Organization","site_admin":false},"repo":{"id":38402023,"name":"honeybadger-java","full_name":"honeybadger-io/honeybadger-java","owner":{"login":"honeybadger-io","id":1898541,"avatar_url":"https://avatars.githubusercontent.com/u/1898541?v=3","gravatar_id":"","url":"https://api.github.com/users/honeybadger-io","html_url":"https://github.com/honeybadger-io","followers_url":"https://api.github.com/users/honeybadger-io/followers","following_url":"https://api.github.com/users/honeybadger-io/following{/other_user}","gists_url":"https://api.github.com/users/honeybadger-io/gists{/gist_id}","starred_url":"https://api.github.com/users/honeybadger-io/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/honeybadger-io/subscriptions","organizations_url":"https://api.github.com/users/honeybadger-io/orgs","repos_url":"https://api.github.com/users/honeybadger-io/repos","events_url":"https://api.github.com/users/honeybadger-io/events{/privacy}","received_events_url":"https://api.github.com/users/honeybadger-io/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/honeybadger-io/honeybadger-java","description":"Java Client to report exceptions to Honeybadger.io","fork":false,"url":"https://api.github.com/repos/honeybadger-io/honeybadger-java","forks_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/forks","keys_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/keys{/key_id}","collaborators_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/teams","hooks_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/hooks","issue_events_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/issues/events{/number}","events_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/events","assignees_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/assignees{/user}","branches_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/branches{/branch}","tags_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/tags","blobs_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/git/refs{/sha}","trees_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/git/trees{/sha}","statuses_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/statuses/{sha}","languages_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/languages","stargazers_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/stargazers","contributors_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/contributors","subscribers_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/subscribers","subscription_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/subscription","commits_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/commits{/sha}","git_commits_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/git/commits{/sha}","comments_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/comments{/number}","issue_comment_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/issues/comments{/number}","contents_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/contents/{+path}","compare_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/compare/{base}...{head}","merges_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/merges","archive_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/downloads","issues_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/issues{/number}","pulls_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/pulls{/number}","milestones_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/milestones{/number}","notifications_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/labels{/name}","releases_url":"https://api.github.com/repos/honeybadger-io/honeybadger-java/releases{/id}","created_at":"2015-07-02T00:22:34Z","updated_at":"2015-07-02T00:23:32Z","pushed_at":"2015-09-09T01:55:59Z","git_url":"git://github.com/honeybadger-io/honeybadger-java.git","ssh_url":"git@github.com:honeybadger-io/honeybadger-java.git","clone_url":"https://github.com/honeybadger-io/honeybadger-java.git","svn_url":"https://github.com/honeybadger-io/honeybadger-java","homepage":null,"size":660,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":3,"forks":1,"open_issues":3,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/honeybadger-io/honeybadger-java/pulls/19"},"html":{"href":"https://github.com/honeybadger-io/honeybadger-java/pull/19"},"issue":{"href":"https://api.github.com/repos/honeybadger-io/honeybadger-java/issues/19"},"comments":{"href":"https://api.github.com/repos/honeybadger-io/honeybadger-java/issues/19/comments"},"review_comments":{"href":"https://api.github.com/repos/honeybadger-io/honeybadger-java/pulls/19/comments"},"review_comment":{"href":"https://api.github.com/repos/honeybadger-io/honeybadger-java/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/honeybadger-io/honeybadger-java/pulls/19/commits"},"statuses":{"href":"https://api.github.com/repos/honeybadger-io/honeybadger-java/statuses/6d5a218c4a3427aa43c8c2bc0933c587c9fc0927"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":1,"additions":14,"deletions":4,"changed_files":1}}