feat: support check_suite webhook events

This commit is contained in:
RhenCloud 2026-08-03 06:58:47 +08:00
parent 7179a35457
commit fb9550b94d
No known key found for this signature in database
GPG key ID: A574A617378C4E0B
6 changed files with 115 additions and 2 deletions

View file

@ -44,6 +44,10 @@ function extractBranch(event: WebhookEvent): string | undefined {
const wf = event.payload.workflow_run as { head_branch?: string } | undefined;
return wf?.head_branch;
}
if (event.event === "check_suite") {
const suite = event.payload.check_suite as { head_branch?: string } | undefined;
return suite?.head_branch;
}
if (event.event === "commit_comment") {
const comment = event.payload.comment as { position?: number | null } | undefined;
if (comment?.position != null) {