@@ -28,43 +28,44 @@ type Event string
28
28
29
29
// GitHub hook types
30
30
const (
31
- CheckRunEvent Event = "check_run"
32
- CheckSuiteEvent Event = "check_suite"
33
- CommitCommentEvent Event = "commit_comment"
34
- CreateEvent Event = "create"
35
- DeleteEvent Event = "delete"
36
- DeploymentEvent Event = "deployment"
37
- DeploymentStatusEvent Event = "deployment_status"
38
- ForkEvent Event = "fork"
39
- GollumEvent Event = "gollum"
40
- InstallationEvent Event = "installation"
41
- InstallationRepositoriesEvent Event = "installation_repositories"
42
- IntegrationInstallationEvent Event = "integration_installation"
43
- IssueCommentEvent Event = "issue_comment"
44
- IssuesEvent Event = "issues"
45
- LabelEvent Event = "label"
46
- MemberEvent Event = "member"
47
- MembershipEvent Event = "membership"
48
- MilestoneEvent Event = "milestone"
49
- OrganizationEvent Event = "organization"
50
- OrgBlockEvent Event = "org_block"
51
- PageBuildEvent Event = "page_build"
52
- PingEvent Event = "ping"
53
- ProjectCardEvent Event = "project_card"
54
- ProjectColumnEvent Event = "project_column"
55
- ProjectEvent Event = "project"
56
- PublicEvent Event = "public"
57
- PullRequestEvent Event = "pull_request"
58
- PullRequestReviewEvent Event = "pull_request_review"
59
- PullRequestReviewCommentEvent Event = "pull_request_review_comment"
60
- PushEvent Event = "push"
61
- ReleaseEvent Event = "release"
62
- RepositoryEvent Event = "repository"
63
- SecurityAdvisoryEvent Event = "security_advisory"
64
- StatusEvent Event = "status"
65
- TeamEvent Event = "team"
66
- TeamAddEvent Event = "team_add"
67
- WatchEvent Event = "watch"
31
+ CheckRunEvent Event = "check_run"
32
+ CheckSuiteEvent Event = "check_suite"
33
+ CommitCommentEvent Event = "commit_comment"
34
+ CreateEvent Event = "create"
35
+ DeleteEvent Event = "delete"
36
+ DeploymentEvent Event = "deployment"
37
+ DeploymentStatusEvent Event = "deployment_status"
38
+ ForkEvent Event = "fork"
39
+ GollumEvent Event = "gollum"
40
+ InstallationEvent Event = "installation"
41
+ InstallationRepositoriesEvent Event = "installation_repositories"
42
+ IntegrationInstallationEvent Event = "integration_installation"
43
+ IssueCommentEvent Event = "issue_comment"
44
+ IssuesEvent Event = "issues"
45
+ LabelEvent Event = "label"
46
+ MemberEvent Event = "member"
47
+ MembershipEvent Event = "membership"
48
+ MilestoneEvent Event = "milestone"
49
+ OrganizationEvent Event = "organization"
50
+ OrgBlockEvent Event = "org_block"
51
+ PageBuildEvent Event = "page_build"
52
+ PingEvent Event = "ping"
53
+ ProjectCardEvent Event = "project_card"
54
+ ProjectColumnEvent Event = "project_column"
55
+ ProjectEvent Event = "project"
56
+ PublicEvent Event = "public"
57
+ PullRequestEvent Event = "pull_request"
58
+ PullRequestReviewEvent Event = "pull_request_review"
59
+ PullRequestReviewCommentEvent Event = "pull_request_review_comment"
60
+ PushEvent Event = "push"
61
+ ReleaseEvent Event = "release"
62
+ RepositoryEvent Event = "repository"
63
+ RepositoryVulnerabilityAlertEvent Event = "repository_vulnerability_alert"
64
+ SecurityAdvisoryEvent Event = "security_advisory"
65
+ StatusEvent Event = "status"
66
+ TeamEvent Event = "team"
67
+ TeamAddEvent Event = "team_add"
68
+ WatchEvent Event = "watch"
68
69
)
69
70
70
71
// EventSubtype defines a GitHub Hook Event subtype
@@ -289,6 +290,10 @@ func (hook Webhook) Parse(r *http.Request, events ...Event) (interface{}, error)
289
290
var pl RepositoryPayload
290
291
err = json .Unmarshal ([]byte (payload ), & pl )
291
292
return pl , err
293
+ case RepositoryVulnerabilityAlertEvent :
294
+ var pl RepositoryVulnerabilityAlertPayload
295
+ err = json .Unmarshal ([]byte (payload ), & pl )
296
+ return pl , err
292
297
case SecurityAdvisoryEvent :
293
298
var pl SecurityAdvisoryPayload
294
299
err = json .Unmarshal ([]byte (payload ), & pl )
0 commit comments