{"action":"created","issue":{"url":"https://api.github.com/repos/golang/oauth2/issues/288","repository_url":"https://api.github.com/repos/golang/oauth2","labels_url":"https://api.github.com/repos/golang/oauth2/issues/288/labels{/name}","comments_url":"https://api.github.com/repos/golang/oauth2/issues/288/comments","events_url":"https://api.github.com/repos/golang/oauth2/issues/288/events","html_url":"https://github.com/golang/oauth2/pull/288","id":323292239,"number":288,"title":"Pass private claims into JWTAccessTokenSourceFromJSON","user":{"login":"sbsends","id":21231577,"avatar_url":"https://avatars2.githubusercontent.com/u/21231577?v=4","gravatar_id":"","url":"https://api.github.com/users/sbsends","html_url":"https://github.com/sbsends","followers_url":"https://api.github.com/users/sbsends/followers","following_url":"https://api.github.com/users/sbsends/following{/other_user}","gists_url":"https://api.github.com/users/sbsends/gists{/gist_id}","starred_url":"https://api.github.com/users/sbsends/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sbsends/subscriptions","organizations_url":"https://api.github.com/users/sbsends/orgs","repos_url":"https://api.github.com/users/sbsends/repos","events_url":"https://api.github.com/users/sbsends/events{/privacy}","received_events_url":"https://api.github.com/users/sbsends/received_events","type":"User","site_admin":false},"labels":[{"id":831707009,"url":"https://api.github.com/repos/golang/oauth2/labels/cla:%20yes","name":"cla: yes","color":"0e8a16","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-05-15T16:26:40Z","updated_at":"2018-05-15T16:33:45Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/golang/oauth2/pulls/288","html_url":"https://github.com/golang/oauth2/pull/288","diff_url":"https://github.com/golang/oauth2/pull/288.diff","patch_url":"https://github.com/golang/oauth2/pull/288.patch"},"body":" ```golang\r\n//example usage\r\nprivateClaims := map[string]interface{}{\"target_audience\": \"https://api.<PROJECT>.com/\"}\r\ntokenSource, _ := google.JWTAccessTokenSourceFromJSON(data, \"https://www.googleapis.com/oauth2/v4/token\", privateClaims)\r\n```\r\n\r\n## Use cases:\r\nA target audience must be specified when exchanging a service account signed token for a Google ID token ([see corresponding Cloud Endpoints documentation](https://cloud.google.com/endpoints/docs/openapi/service-account-authentication#using_a_google_id_token)).\r\n\r\nCreating **custom** tokens signed by a service account."},"comment":{"url":"https://api.github.com/repos/golang/oauth2/issues/comments/389231354","html_url":"https://github.com/golang/oauth2/pull/288#issuecomment-389231354","issue_url":"https://api.github.com/repos/golang/oauth2/issues/288","id":389231354,"user":{"login":"gopherbot","id":8566911,"avatar_url":"https://avatars1.githubusercontent.com/u/8566911?v=4","gravatar_id":"","url":"https://api.github.com/users/gopherbot","html_url":"https://github.com/gopherbot","followers_url":"https://api.github.com/users/gopherbot/followers","following_url":"https://api.github.com/users/gopherbot/following{/other_user}","gists_url":"https://api.github.com/users/gopherbot/gists{/gist_id}","starred_url":"https://api.github.com/users/gopherbot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gopherbot/subscriptions","organizations_url":"https://api.github.com/users/gopherbot/orgs","repos_url":"https://api.github.com/users/gopherbot/repos","events_url":"https://api.github.com/users/gopherbot/events{/privacy}","received_events_url":"https://api.github.com/users/gopherbot/received_events","type":"User","site_admin":false},"created_at":"2018-05-15T16:33:45Z","updated_at":"2018-05-15T16:33:45Z","author_association":"NONE","body":"This PR (HEAD: 9d87dc6583add279993e6a07f006005cfc74c646) has been imported to Gerrit for code review.\n\nPlease visit https://go-review.googlesource.com/#/c/oauth2/+/113255 to see it.\n\nTip: You can toggle comments from me using the `comments` slash command (e.g. `/comments off`)\nSee the [Wiki page](https://golang.org/wiki/GerritBot) for more info"}}
{"actor":{"display_login":"gopherbot"}}