@@ -76,6 +76,10 @@ type CommitCommentEvent struct {
76
76
Repo * Repository `json:"repository,omitempty"`
77
77
Sender * User `json:"sender,omitempty"`
78
78
Installation * Installation `json:"installation,omitempty"`
79
+
80
+ // The following field is only present when the webhook is triggered on
81
+ // a repository belonging to an organization.
82
+ Org * Organization `json:"organization,omitempty"`
79
83
}
80
84
81
85
// ContentReferenceEvent is triggered when the body or comment of an issue or
@@ -132,6 +136,10 @@ type DeleteEvent struct {
132
136
Repo * Repository `json:"repository,omitempty"`
133
137
Sender * User `json:"sender,omitempty"`
134
138
Installation * Installation `json:"installation,omitempty"`
139
+
140
+ // The following field is only present when the webhook is triggered on
141
+ // a repository belonging to an organization.
142
+ Org * Organization `json:"organization,omitempty"`
135
143
}
136
144
137
145
// DependabotAlertEvent is triggered when there is activity relating to Dependabot alerts.
@@ -192,6 +200,10 @@ type DeploymentEvent struct {
192
200
// The following fields are only populated by Webhook events.
193
201
Sender * User `json:"sender,omitempty"`
194
202
Installation * Installation `json:"installation,omitempty"`
203
+
204
+ // The following field is only present when the webhook is triggered on
205
+ // a repository belonging to an organization.
206
+ Org * Organization `json:"organization,omitempty"`
195
207
}
196
208
197
209
// DeploymentProtectionRuleEvent represents a deployment protection rule event.
@@ -227,6 +239,10 @@ type DeploymentStatusEvent struct {
227
239
// The following fields are only populated by Webhook events.
228
240
Sender * User `json:"sender,omitempty"`
229
241
Installation * Installation `json:"installation,omitempty"`
242
+
243
+ // The following field is only present when the webhook is triggered on
244
+ // a repository belonging to an organization.
245
+ Org * Organization `json:"organization,omitempty"`
230
246
}
231
247
232
248
// DiscussionCommentEvent represents a webhook event for a comment on discussion.
@@ -363,6 +379,10 @@ type GollumEvent struct {
363
379
Repo * Repository `json:"repository,omitempty"`
364
380
Sender * User `json:"sender,omitempty"`
365
381
Installation * Installation `json:"installation,omitempty"`
382
+
383
+ // The following field is only present when the webhook is triggered on
384
+ // a repository belonging to an organization.
385
+ Org * Organization `json:"organization,omitempty"`
366
386
}
367
387
368
388
// EditChange represents the changes when an issue, pull request, comment,
@@ -510,6 +530,10 @@ type InstallationEvent struct {
510
530
Sender * User `json:"sender,omitempty"`
511
531
Installation * Installation `json:"installation,omitempty"`
512
532
Requester * User `json:"requester,omitempty"`
533
+
534
+ // The following field is only present when the webhook is triggered on
535
+ // a repository belonging to an organization.
536
+ Org * Organization `json:"organization,omitempty"`
513
537
}
514
538
515
539
// InstallationRepositoriesEvent is triggered when a repository is added or
@@ -524,6 +548,10 @@ type InstallationRepositoriesEvent struct {
524
548
RepositorySelection * string `json:"repository_selection,omitempty"`
525
549
Sender * User `json:"sender,omitempty"`
526
550
Installation * Installation `json:"installation,omitempty"`
551
+
552
+ // The following field is only present when the webhook is triggered on
553
+ // a repository belonging to an organization.
554
+ Org * Organization `json:"organization,omitempty"`
527
555
}
528
556
529
557
// InstallationLoginChange represents a change in login on an installation.
@@ -603,6 +631,10 @@ type IssuesEvent struct {
603
631
Sender * User `json:"sender,omitempty"`
604
632
Installation * Installation `json:"installation,omitempty"`
605
633
Milestone * Milestone `json:"milestone,omitempty"`
634
+
635
+ // The following field is only present when the webhook is triggered on
636
+ // a repository belonging to an organization.
637
+ Org * Organization `json:"organization,omitempty"`
606
638
}
607
639
608
640
// LabelEvent is triggered when a repository's label is created, edited, or deleted.
@@ -639,6 +671,10 @@ type MarketplacePurchaseEvent struct {
639
671
PreviousMarketplacePurchase * MarketplacePurchase `json:"previous_marketplace_purchase,omitempty"`
640
672
Sender * User `json:"sender,omitempty"`
641
673
Installation * Installation `json:"installation,omitempty"`
674
+
675
+ // The following field is only present when the webhook is triggered on
676
+ // a repository belonging to an organization.
677
+ Org * Organization `json:"organization,omitempty"`
642
678
}
643
679
644
680
// MemberEvent is triggered when a user is added as a collaborator to a repository.
@@ -654,6 +690,10 @@ type MemberEvent struct {
654
690
Repo * Repository `json:"repository,omitempty"`
655
691
Sender * User `json:"sender,omitempty"`
656
692
Installation * Installation `json:"installation,omitempty"`
693
+
694
+ // The following field is only present when the webhook is triggered on
695
+ // a repository belonging to an organization.
696
+ Org * Organization `json:"organization,omitempty"`
657
697
}
658
698
659
699
// MembershipEvent is triggered when a user is added or removed from a team.
@@ -825,6 +865,10 @@ type PageBuildEvent struct {
825
865
Repo * Repository `json:"repository,omitempty"`
826
866
Sender * User `json:"sender,omitempty"`
827
867
Installation * Installation `json:"installation,omitempty"`
868
+
869
+ // The following field is only present when the webhook is triggered on
870
+ // a repository belonging to an organization.
871
+ Org * Organization `json:"organization,omitempty"`
828
872
}
829
873
830
874
// PersonalAccessTokenRequestEvent occurs when there is activity relating to a
@@ -885,6 +929,10 @@ type PersonalAccessTokenRequest struct {
885
929
886
930
// Date and time when the associated fine-grained personal access token was last used for authentication.
887
931
TokenLastUsedAt * Timestamp `json:"token_last_used_at,omitempty"`
932
+
933
+ // The following field is only present when the webhook is triggered on
934
+ // a repository belonging to an organization.
935
+ Org * Organization `json:"organization,omitempty"`
888
936
}
889
937
890
938
// PersonalAccessTokenPermissions represents the original or newly requested
@@ -1044,6 +1092,10 @@ type PublicEvent struct {
1044
1092
Repo * Repository `json:"repository,omitempty"`
1045
1093
Sender * User `json:"sender,omitempty"`
1046
1094
Installation * Installation `json:"installation,omitempty"`
1095
+
1096
+ // The following field is only present when the webhook is triggered on
1097
+ // a repository belonging to an organization.
1098
+ Org * Organization `json:"organization,omitempty"`
1047
1099
}
1048
1100
1049
1101
// PullRequestEvent is triggered when a pull request is assigned, unassigned, labeled,
@@ -1129,6 +1181,10 @@ type PullRequestReviewCommentEvent struct {
1129
1181
Repo * Repository `json:"repository,omitempty"`
1130
1182
Sender * User `json:"sender,omitempty"`
1131
1183
Installation * Installation `json:"installation,omitempty"`
1184
+
1185
+ // The following field is only present when the webhook is triggered on
1186
+ // a repository belonging to an organization.
1187
+ Org * Organization `json:"organization,omitempty"`
1132
1188
}
1133
1189
1134
1190
// PullRequestReviewThreadEvent is triggered when a comment made as part of a
@@ -1147,6 +1203,10 @@ type PullRequestReviewThreadEvent struct {
1147
1203
Repo * Repository `json:"repository,omitempty"`
1148
1204
Sender * User `json:"sender,omitempty"`
1149
1205
Installation * Installation `json:"installation,omitempty"`
1206
+
1207
+ // The following field is only present when the webhook is triggered on
1208
+ // a repository belonging to an organization.
1209
+ Org * Organization `json:"organization,omitempty"`
1150
1210
}
1151
1211
1152
1212
// PullRequestTargetEvent is triggered when a pull request is assigned, unassigned, labeled,
@@ -1315,6 +1375,10 @@ type ReleaseEvent struct {
1315
1375
Repo * Repository `json:"repository,omitempty"`
1316
1376
Sender * User `json:"sender,omitempty"`
1317
1377
Installation * Installation `json:"installation,omitempty"`
1378
+
1379
+ // The following field is only present when the webhook is triggered on
1380
+ // a repository belonging to an organization.
1381
+ Org * Organization `json:"organization,omitempty"`
1318
1382
}
1319
1383
1320
1384
// RepositoryEvent is triggered when a repository is created, archived, unarchived,
@@ -1385,6 +1449,10 @@ type RepositoryVulnerabilityAlertEvent struct {
1385
1449
1386
1450
// The user that triggered the event.
1387
1451
Sender * User `json:"sender,omitempty"`
1452
+
1453
+ // The following field is only present when the webhook is triggered on
1454
+ // a repository belonging to an organization.
1455
+ Org * Organization `json:"organization,omitempty"`
1388
1456
}
1389
1457
1390
1458
// RepositoryVulnerabilityAlert represents a repository security alert.
@@ -1491,6 +1559,10 @@ type StatusEvent struct {
1491
1559
Repo * Repository `json:"repository,omitempty"`
1492
1560
Sender * User `json:"sender,omitempty"`
1493
1561
Installation * Installation `json:"installation,omitempty"`
1562
+
1563
+ // The following field is only present when the webhook is triggered on
1564
+ // a repository belonging to an organization.
1565
+ Org * Organization `json:"organization,omitempty"`
1494
1566
}
1495
1567
1496
1568
// TeamEvent is triggered when an organization's team is created, modified or deleted.
@@ -1561,6 +1633,10 @@ type WatchEvent struct {
1561
1633
Repo * Repository `json:"repository,omitempty"`
1562
1634
Sender * User `json:"sender,omitempty"`
1563
1635
Installation * Installation `json:"installation,omitempty"`
1636
+
1637
+ // The following field is only present when the webhook is triggered on
1638
+ // a repository belonging to an organization.
1639
+ Org * Organization `json:"organization,omitempty"`
1564
1640
}
1565
1641
1566
1642
// WorkflowDispatchEvent is triggered when someone triggers a workflow run on GitHub or
0 commit comments