Skip to content

Webhook-driven reindex on push (GitHub) #5

@webdevtodayjason

Description

@webdevtodayjason

Thread Assignment

Thread C (Codex)

Problem

Index goes stale after code changes. Manual re-indexing is error-prone and blocks agents from getting fresh symbol data.

Requirements

  • Add /webhook HTTP endpoint that accepts GitHub push events
  • Validate webhook signature (HMAC SHA-256 with configurable secret)
  • On valid push: trigger incremental reindex of the changed repo
  • Reindex runs async — webhook returns 202 immediately
  • Add reindex status tracking (in-progress, last-success, last-failure)
  • CLI argentmunch reindex <repo> for manual trigger
  • Rate limit: max 1 reindex per repo per 60 seconds

Acceptance Criteria

  1. Configure GitHub webhook → push to repo → index updates within 30 seconds
  2. Invalid webhook signature → 403, no reindex triggered
  3. Rapid pushes (5 in 10 seconds) → only 1 reindex executes (debounce/rate limit)
  4. argentmunch list shows last_reindexed_at timestamp per repo
  5. Reindex failure does not corrupt existing index (atomic swap)

Merge Gate

Execution Order

#5 in Sprint Slice 2 — after multi-repo indexing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    sprint:slice-2Sprint Slice 2 — Production Hardeningthread:FThread F — ArgentMunch multi-repo + webhook

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions