summaryrefslogtreecommitdiff
path: root/internal/cli
diff options
context:
space:
mode:
authorClaudomator Agent <agent@claudomator>2026-03-16 05:08:00 +0000
committerClaudomator Agent <agent@claudomator>2026-03-16 05:08:00 +0000
commitc2aa026f6ce1c9e216b99d74f294fc133d5fcddd (patch)
tree2fdbc85367b92e5ba0d5cd9b789f4f4cf34aad61 /internal/cli
parentd75a231d8865d9b14fbe3d608c9aa1bffb7ed386 (diff)
feat: add GitHub webhook endpoint for automatic CI failure task creation
Adds POST /api/webhooks/github that receives check_run and workflow_run events and creates a Claudomator task to investigate and fix the failure. - Config: new webhook_secret and [[projects]] fields in config.toml - HMAC-SHA256 validation when webhook_secret is configured - Ignores non-failure events (success, skipped, etc.) with 204 - Matches repo name to configured project dirs (case-insensitive) - Falls back to single project when no name match found - 11 new tests covering all acceptance criteria Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'internal/cli')
-rw-r--r--internal/cli/serve.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/internal/cli/serve.go b/internal/cli/serve.go
index f22ea95..94f0c5d 100644
--- a/internal/cli/serve.go
+++ b/internal/cli/serve.go
@@ -87,6 +87,7 @@ func serve(addr string) error {
if cfg.WorkspaceRoot != "" {
srv.SetWorkspaceRoot(cfg.WorkspaceRoot)
}
+ srv.SetGitHubWebhookConfig(cfg.WebhookSecret, cfg.Projects)
// Register scripts.
wd, _ := os.Getwd()