Skip to main content

GitHub Bot

The Mastra GitHub bot receives GitHub webhook events and routes them through Code Assist workflows.

Supported Event Inputs​

The dispatcher handles:

  • issue_opened
  • issue_labeled
  • issue_comment_created
  • pr_comment_created
  • pr_review_comment_created
  • pr_review_submitted
  • pr_checks_completed
  • pull_request_closed
  • promotion_workflow_completed

Labels​

The bot manages these labels:

LabelMeaning
planningCode Assist is preparing a plan.
needs-answerThe planner needs clarification.
plan-readyThe final implementation plan is posted.
plan-errorPlanning failed.
implementation-readyTrusted actor approved implementation.
auto-merge-when-greenBot may auto-merge after checks pass.
implementingImplementation is active.
implementation-blockedBot stopped for human review.
pr-openDraft PR is open.

Trust Model​

Implementation starts only from trusted actors or approved autonomy policy. The service checks collaborator permission and ignores generated bot comments to avoid self-trigger loops.

PR Follow-Up Sources​

The PR follow-up workflow can be triggered by:

  • trusted PR comments;
  • review comments;
  • submitted reviews;
  • failed check events;
  • successful checks that may enable merge;
  • PR close events;
  • promotion workflow completion events.