Start a flow from GitHub events
GitHub triggers start a flow when something happens in a connected GitHub repository, such as a merged pull request or a failed check suite. The flow then starts an agent run, for example to review the change, write release notes, or investigate a failing build.
Before you start
Connect GitHub to your organization and make the repository available to your workspace. Helpin receives events through the GitHub App.
Create the agent that the flow should run.
You need permission to edit flows in the workspace.
Available GitHub triggers
Trigger in the composer | Starts the flow when | Filters |
|---|---|---|
GitHub push arrives | Commits are pushed | Repository, branch |
GitHub pull request opens | A pull request is opened | Repository, base branch |
GitHub pull request merges | A pull request is merged | Repository, base branch |
GitHub pull request closes without merging | A pull request is closed without being merged | Repository, base branch |
GitHub review is requested | A review is requested on a pull request | Repository, base branch |
GitHub release publishes | A release is published | Repository, tag |
GitHub check suite completes | A check suite finishes | Repository, branch, conclusion |
The conclusion filter accepts success, failure, cancelled, timed out, or any.
Create a GitHub flow
Go to Automation → Flows and create a flow. Pick a template or choose Build a custom flow.
Enter a Flow name.
In the When row, choose a trigger from GitHub events.
Set the filters. Choose a repository after repository is, or leave it empty to match any repository, and fill in the branch, base branch, tag, or conclusion as needed. Each flow needs at least one filter.
Optionally, add a Semantic condition.
In the then row, Start an agent run is selected. Choose the agent after using.
In the on row, choose where the agent should run, such as a specific repository, task, or epic, or this workspace.
Optionally, open + branch overrides to set the branch the agent checks out and the branch it works on.
Select Create flow.
Choose where the agent runs
For push, pull request, review, and check suite triggers, you must choose a specific target. The composer shows “Choose where the agent should run” until you do. For GitHub release publishes, you can also keep whatever triggered it.
In branch overrides, use {base_branch} for the default base branch and {task_branch} for the agent's working branch.
Things to know
A tag filter must match the release tag exactly, for example
v1.0.0.Pre-releases don't start release flows created in the composer.
GitHub triggers can only start an agent run. To move tasks or merge branches, use a workflow trigger instead.
To check whether a flow ran, open the flow and review Recent runs, or go to Automation → Activity.
Related
Was this article helpful?