agent-orchestrator/packages/plugins
Harsh Batheja 4fd8cac7f9 feat: add SCM webhook lifecycle triggers (#394)
* feat(core): add scm webhook contract

Defines a provider-agnostic SCM webhook contract in core types and
config so SCM plugins can verify and normalize inbound webhook events
without reshaping project config later.

* feat(scm): trigger lifecycle checks from github webhooks

Adds GitHub webhook verification and event parsing, exposes a web
webhook endpoint, and routes matching PR/branch events through the
existing lifecycle manager so CI and review reactions update immediately.

* fix(scm): verify github signatures with raw webhook bytes

Preserves the original webhook bytes alongside the decoded payload so
GitHub HMAC verification uses the exact request body while the route
continues to drive lifecycle checks through the existing manager.

* fix(web): wire scm webhook route into main branch services

Restores the main-branch service and route-test wiring while keeping the
new webhook route coverage and scoped lifecycle helper in place.

* fix(webhooks): use singleton lifecycle manager and fail closed on scm API errors

Reuses the existing services lifecycle manager for webhook-triggered checks
so reactions and state transitions don't replay from a fresh instance, and
restores fail-closed behavior for GitHub review comment fetch failures.

* fix(webhooks): tighten project matching and restore scm compatibility methods

Prevents repository-less webhook events from matching all projects, restores
GitHub SCM PR utility methods and CI status rollup fallback, and adds tests
covering the compatibility paths and safer project matching behavior.

* fix(webhooks): pre-check content length and continue on parse errors

Adds an early content-length guard against configured maxBodyBytes before
reading the body and changes candidate parse failures to fail-forward so
one malformed payload path does not abort other valid candidate handling.

* fix(scm-github): parse review-comment timestamps from comment payload

Use comment.updated_at/created_at for pull_request_review_comment webhook
timestamps so normalized events retain temporal data for comment events.

* fix(webhooks): apply early size guard only when all candidates are bounded

Uses the broadest candidate limit for pre-read content-length checks and
skips early rejection when any matching project has no configured limit,
while retaining per-candidate verification limits.

* fix(webhooks): normalize repo matching and skip terminal sessions

Match webhook repository names case-insensitively against configured project
repos and avoid lifecycle checks for terminal sessions when resolving
webhook-affected sessions.

* fix(webhooks): fail forward when lifecycle checks throw

* fix(scm-github): parse push webhook branch and sha

* refactor(scm-github): dedupe cli exec helper wrappers

* fix(scm-github): tighten exec helper type and comment timestamps

* fix(scm-github): prefer head_commit timestamp for push events

* fix(webhooks): tighten repository parsing and helper visibility

* fix(scm-github): ignore non-head refs for push branch

* chore: trigger bugbot rerun

* feat(scm-gitlab): add webhook verification and event parsing

* fix(webhooks): share parser utils and handle check_run branch

* fix(webhooks): ignore gitlab tag refs in ci branch mapping

* fix(scm-gitlab): harden token and tag ref handling

* chore(scm-gitlab): update webhook helpers around bugbot threads
2026-03-11 06:41:04 +00:00
..
agent-aider fix: handle permissions=skip correctly in codex plugin (#337) 2026-03-07 20:27:01 +05:30
agent-claude-code fix(agent-claude-code): detect cd-prefixed gh/git commands and use relative hook path 2026-03-08 10:42:45 +00:00
agent-codex fix(codex): harden gh wrapper resolution with explicit GH_PATH 2026-03-08 02:55:31 +05:30
agent-opencode fix: opencode lifecycle race hardening (#359) 2026-03-11 06:41:04 +00:00
notifier-composio feat: seamless onboarding with enhanced documentation (#66) 2026-02-16 22:22:13 +05:30
notifier-desktop feat: publish to npm under @composio scope (#32) 2026-02-15 04:28:57 +05:30
notifier-openclaw feat: lifecycle manager, backlog auto-claim, task decomposition, and verification gate (#365) 2026-03-11 06:41:03 +00:00
notifier-slack feat: seamless onboarding with enhanced documentation (#66) 2026-02-16 22:22:13 +05:30
notifier-webhook feat(ao): add OpenClaw notifier plugin for AO escalations 2026-03-11 06:41:03 +00:00
runtime-process feat: seamless onboarding with enhanced documentation (#66) 2026-02-16 22:22:13 +05:30
runtime-tmux feat: OpenCode session lifecycle and CLI controls (#315) 2026-03-08 09:55:44 +05:30
scm-github feat: add SCM webhook lifecycle triggers (#394) 2026-03-11 06:41:04 +00:00
scm-gitlab feat: add SCM webhook lifecycle triggers (#394) 2026-03-11 06:41:04 +00:00
terminal-iterm2 feat: publish to npm under @composio scope (#32) 2026-02-15 04:28:57 +05:30
terminal-web feat: publish to npm under @composio scope (#32) 2026-02-15 04:28:57 +05:30
tracker-github feat: lifecycle manager, backlog auto-claim, task decomposition, and verification gate (#365) 2026-03-11 06:41:03 +00:00
tracker-gitlab fix(gitlab): handle closed MR state and deduplicate glab helpers (#358) 2026-03-08 12:34:31 +05:30
tracker-linear feat: seamless onboarding with enhanced documentation (#66) 2026-02-16 22:22:13 +05:30
workspace-clone fix: destroy old runtime before restore, cleanup clone on failure (#109) 2026-02-19 01:35:49 +05:30
workspace-worktree feat: implement session restore for crashed/exited agents (#104) 2026-02-19 01:12:57 +05:30