docs/guides/github-mcp-continue-cookbook.mdx
import { OSAutoDetect } from '/snippets/OSAutoDetect.jsx' import CLIInstall from '/snippets/cli-install.mdx'
<OSAutoDetect /> <Card title="What You'll Build" icon="github"> A GitHub workflow assistant that uses Continue with the GitHub MCP to: - List, filter, and summarize open issues - Review and summarize recently merged PRs - Post comments with AI-generated summaries or checklists - Automate routine GitHub maintenance with headless CLI runs </Card>Before starting, ensure you have:
repo:readpublic_repo for public repos or repo for private reposFor all options, first: <Steps> <Step title="Install Continue CLI"> <CLIInstall /> </Step>
<Step title="Configure GitHub Token"> Add your `GITHUB_TOKEN` to your [Continue Mission Control agent's environment variables](https://continue.dev/settings). </Step> </Steps> <Warning> To use agents in headless mode, you need a [Continue API key](https://continue.dev/settings/api-keys). For write actions (e.g., posting comments), your token must include the relevant GitHub scopes. </Warning>After ensuring you meet the Prerequisites above, you have two paths to get started:
<Tabs> <Tab title="⚡ Quick Start (Recommended)"> <Steps> <Step title="Install GitHub MCP via Continue Mission Control"> Visit the [GitHub Project Manager Agent](https://continue.dev/continuedev/github-project-manager-agent) on Continue Mission Control and click **Install** to add it to your agent. The listing provides a pre-configured MCP block; add your `GITHUB_TOKEN` in Hub.
</Step>
<Step title="Launch the Agent">
From your repo root:
```bash
cn --agent continuedev/github-project-manager-agent
```
Now try: "List my open issues labeled bug and summarize priorities."
</Step>
</Steps>
<Info>
You can also attach an MCP to a one-off session: `cn --mcp anthropic/github-mcp`.
</Info>
<Step title="Add GitHub MCP">
Install from Hub (recommended) or add YAML manually. Minimal YAML example:
```yaml title="config.yaml"
name: My Config
version: 0.0.1
schema: v1
mcpServers:
- name: GitHub MCP
command: npx
args:
- "-y"
- "@modelcontextprotocol/server-github"
env:
GITHUB_TOKEN: ${env:GITHUB_TOKEN}
connectionTimeout: 30
```
Notes:
- The exact `command`/`args` may differ based on the MCP you choose on Hub. Hub templates prefill these for you.
- Provide `GITHUB_TOKEN` via environment or Hub secrets.
</Step>
<Step title="Test the Connection">
Launch Continue and ask:
```
List the 5 most recently updated open issues in this repository.
```
</Step>
</Steps>
The agent will automatically detect and use your configuration along with the GitHub MCP for issue and PR operations.
Use natural language to explore, triage, and act on open issues. The agent calls GitHub MCP tools under the hood.
<Info> **Where to run these workflows:** - **IDE Extensions**: Use Continue in VS Code, JetBrains, or other supported IDEs - **Terminal (TUI mode)**: Run `cn` to enter interactive mode, then type your prompts - **CLI (headless mode)**: Use `cn -p "your prompt" --auto` for automationTo run any of the example prompts below in headless mode, use cn -p "prompt"
</Info>
Prompt:
List the 20 most recently updated open issues in this repo.
Cluster by label and severity. Summarize top priorities.
Prompt:
Show open issues labeled bug or security, assigned to @me.
Summarize blockers and suggest next steps.
Prompt:
Find the issue with the most engagement (comments, reactions) in the last 30 days.
Come up with a triage plan and draft a comment with:
- current hypothesis
- next 2 steps
- owner and ETA
Then post the comment.
Prompt:
Find open issues with no activity in the last 30 days.
Suggest action (close, needs-repro, or prioritize) and draft comments.
Analyze recently merged PRs for change awareness, release notes, and quality signals.
Prompt:
List PRs merged in the last 7 days.
Group by area (label or path). Summarize impact and notable changes.
Prompt:
Generate release notes for PRs merged since tag v1.2.0.
Use keep-a-changelog sections and include PR numbers/authors.
Prompt:
Find the last merged PR with a significant amount of comments.
Summarize the conversation, including goal, key changes,
risk areas, and any follow-ups.
Run headless commands on a schedule or in PRs to keep teams informed.
Repository Settings → Secrets and variables → Actions:
CONTINUE_API_KEY: From continue.dev/settings/api-keysGITHUB_TOKEN: A token with permissions to read issues/PRs and post commentsCreate .github/workflows/github-mcp-reports.yml:
name: GitHub MCP Reports
on:
schedule:
- cron: "0 13 * * 1" # Mondays 13:00 UTC
workflow_dispatch:
pull_request:
types: [opened, synchronize]
jobs:
report:
runs-on: ubuntu-latest
env:
CONTINUE_API_KEY: ${{ secrets.CONTINUE_API_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "18"
- name: Install Continue CLI
run: npm i -g @continuedev/cli
- name: Weekly Issue Triage Summary
if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
run: |
cn --agent continuedev/github-project-manager-agent \
-p "List open issues updated in the last 14 days. Group by label and priority. Propose top 5 actions and include issue links." \
--auto > issue_summary.txt
- name: Post PR Context Comment
if: github.event_name == 'pull_request'
env:
PR_NUMBER: ${{ github.event.pull_request.number }}
run: |
REPORT=$( cn --agent continuedev/github-project-manager-agent \
-p "Summarize the context for PR #${PR_NUMBER}: related open issues, risk areas, and test suggestions. Keep under 200 words." \
--auto)
gh pr comment ${PR_NUMBER} --body "$REPORT"
GITHUB_TOKEN is set and has the required scopes. Try a minimal test: “List 3 open issues in this repo”.public_repo (public) or repo (private) to write comments.connectionTimeout or verify the command/args from Mission Control listing.After completing this guide, you have a complete AI-powered GitHub workflow system that: