Automatically sync Jira issues to your local beads issue tracker via the Atlassian Rovo MCP server.
π Phase 2 Complete! Real MCP integration is now live with production-ready Jira API support!
π Real MCP Integration - Query actual Jira data using the official
@modelcontextprotocol/sdkπ Documentation Navigation
- π docs/REAL_MCP_INTEGRATION.md - MCP integration guide (NEW!)
- docs/ONBOARDING.md - New developer guide (START HERE!)
- docs/FIRST_DAY.txt - Printable cheat sheet for your first day
- INDEX.md - Complete documentation index (organized by category)
- docs/QUICKREF.md - Quick command reference
- ROADMAP.md - Development roadmap (Phase 2 complete!)
- README.md - Project overview (you are here)
This integration allows you to:
- β Query real Jira data via Atlassian Rovo MCP server (v3.3.0+)
- β Sync issues to your local beads database
- β
Automatically trigger syncs on
git pullvia git hooks - β Work offline with full Jira issue context
- β Enable AI agents to access Jira issues locally
- β Track discovered work alongside planned Jira issues
- β
Test MCP connectivity with
npm run test:mcp
π Real MCP Integration:
- Official
@modelcontextprotocol/sdkintegration - Production-ready Jira API queries
- Graceful fallback to example data
- Connection testing utility
- Comprehensive documentation
See docs/REAL_MCP_INTEGRATION.md for details.
| Requirement | Version | Installation |
|---|---|---|
| Node.js | 18.0+ | nodejs.org |
| Python | 3.7+ | Usually pre-installed on macOS/Linux |
| Beads | Latest | curl -fsSL https://raw.githubusercontent.com/steveyegge/beads/main/scripts/install.sh | bash |
| Git | Any | Usually pre-installed |
| Jira Cloud Access | - | Access to your organization's Jira |
| Atlassian Rovo MCP | - | For real data (see Setup) |
Run the interactive onboarding wizard (takes ~5 minutes):
npm run onboardThe wizard will:
- β Check all prerequisites (Node, Git, beads)
- β Initialize beads if needed
- β Collect your configuration (Jira project, component)
- β Install sync scripts and workflow helpers
- β Set up git hooks (optional)
- β Run a test sync with example data
- β Show you exactly what to do next
π See docs/ONBOARDING.md for the complete first-day guide
If you prefer manual setup:
# Run the installation script
./install.shThe installer will:
- Check for beads and initialize if needed
- Copy the sync script to
scripts/sync_jira_to_beads.py - Install workflow helpers (
bd-start-branch,bd-finish) - Optionally install a git post-merge hook
- Create a config file at
.jira-beads-config
Before syncing, test that your MCP connection is working:
# Test MCP connectivity and list available tools
npm run test:mcpThis will connect to the Atlassian MCP server and verify authentication.
If the connection test fails, authenticate with the MCP server:
# This will open a browser for OAuth authentication
npx -y mcp-remote@latest https://mcp.atlassian.com/v1/mcpKeep this terminal session running, or configure it in your IDE/client.
# Using npm (recommended)
npm run sync -- PROJ
npm run sync -- PROJ --component backend-api
# Or using run.js directly
node run sync PROJ
node run sync PROJ --component backend-apiIf you installed the git hook, the sync will run automatically when you:
git pull # Only on main/master branchStreamline your development with automated branch creation and PR creation:
# Start working - creates branch automatically
npm run start -- bd-a1b2
# Make changes, commit...
# Finish - creates PR automatically
npm run finish -- bd-a1b2Alternative: Use node run start bd-a1b2 or direct scripts.
See docs/WORKFLOW_HELPERS.md for details.
Jira Cloud
β
Atlassian Rovo MCP Server (OAuth authenticated)
β
sync_jira_to_beads.py (queries via MCP)
β
Local Beads Database (.beads/beads.db)
Jira fields are mapped to beads as follows:
| Jira Field | Beads Field | Notes |
|---|---|---|
| Summary | Title | Direct copy |
| Description | Description | Includes Jira key and status |
| Priority | Priority | Mapped: Highestβ0, Highβ1, Mediumβ2, Lowβ3, Lowestβ4 |
| Issue Type | Type | Mapped: Bugβbug, Taskβtask, Story/Featureβfeature, Epicβepic |
| Key | Label | Added as label for tracking (e.g., "PROJ-123") |
| Components | Label | Added as "component-{name}" label |
| - | Label | "jira-synced" label added to all synced issues |
- Create: Issues not in beads are created with Jira key as a label
- Update: Existing issues (matched by Jira key label) are updated with latest description and priority
- No Delete: Issues are never deleted from beads (even if closed/removed in Jira)
If you're using a different MCP server endpoint:
python3 scripts/sync_jira_to_beads.py PROJ \
--mcp-url https://custom-mcp.example.com/v1/mcpEdit sync_jira_to_beads.py to add custom JQL filters:
# In the query_jira_via_mcp method
jql_parts.append('labels = "backend"')
jql_parts.append('assignee = currentUser()')For periodic syncing (e.g., every hour):
# Add to crontab
0 * * * * cd /path/to/project && python3 scripts/sync_jira_to_beads.py PROJ --component backend-apiEdit this file to set default values:
# Jira-Beads Sync Configuration
JIRA_PROJECT_KEY="PROJ"
JIRA_COMPONENT="backend-api"
MCP_URL="https://mcp.atlassian.com/v1/mcp"Then source it in scripts:
source .jira-beads-config
python3 scripts/sync_jira_to_beads.py $JIRA_PROJECT_KEY --component $JIRA_COMPONENTThe post-merge hook is at .git/hooks/post-merge. Edit to customize:
# Change which branches trigger sync
if [[ "$CURRENT_BRANCH" != "main" && "$CURRENT_BRANCH" != "develop" ]]; then
# Skip sync
fi
# Change component filter
JIRA_COMPONENT="different-component"π‘ Quick fixes: See docs/QUICKREF.md
π Offline issues: See docs/guides/OFFLINE_BEHAVIOR.md
Cause: Beads is not installed or not in PATH
Solution:
curl -fsSL https://raw.githubusercontent.com/steveyegge/beads/main/scripts/install.sh | bash
# Restart your terminal or run: source ~/.bashrc # or ~/.zshrc
which bd # Should show the bd pathCause: MCP integration not implemented (expected behavior)
Current behavior:
- Script uses example data in testing mode
- Returns empty list when offline (safe)
To use real Jira data (requires implementation):
- Authenticate:
npx -y mcp-remote@0.1.13 https://mcp.atlassian.com/v1/mcp - Keep MCP session running
- Implement
_query_via_mcp_client()method in script - Use MCP client library (Anthropic MCP SDK)
Workaround for testing:
# Use example data explicitly
python3 scripts/sync_jira_to_beads.py PROJ --use-example-dataSee docs/guides/OFFLINE_BEHAVIOR.md for details on example data vs production usage.
Cause: Beads not initialized in current directory
Solution:
cd /path/to/project
bd initPossible causes:
- Offline/no network (expected - see docs/guides/OFFLINE_BEHAVIOR.md)
- Wrong project key
- Component doesn't exist
- No open issues in Jira
Debug steps:
# Check the JQL query being used
python3 scripts/sync_jira_to_beads.py PROJ --component backend-api
# Look for output:
# "π Querying Jira with JQL: project = PROJ AND component = 'backend-api' ..."
# Test this JQL directly in Jira web interface
# Go to Jira β Filters β Advanced search β Paste JQLCause: Hook not executable or wrong branch
Solution:
# Check hook exists
ls -la .git/hooks/post-merge
# Make executable
chmod +x .git/hooks/post-merge
# Test manually
.git/hooks/post-merge
# Check it only runs on main/master
git branch # Should show * main or * master- Check docs/QUICKREF.md for command syntax
- Review docs/EXAMPLE_WORKFLOW.md for usage patterns
- See docs/guides/OFFLINE_BEHAVIOR.md for network issues
- Check beads documentation: https://github.com/steveyegge/beads
π For detailed workflows: See docs/EXAMPLE_WORKFLOW.md
# Morning: Pull latest code - this automatically syncs Jira issues via git hook
git pull origin main
# Output:
# Updating a1b2c3d..e4f5g6h
# Fast-forward
# src/api/users.js | 45 ++++++++++++++++++++++++++++++++++++++++++
# 1 file changed, 45 insertions(+)
#
# Running Jira sync...
# ============================================================
# π Jira to Beads Sync
# ============================================================
# ...
# Created: 2
# Updated: 3
# Check ready work
bd ready
# Your AI agent works with beads issues
# Updates are tracked locally in beads
# Evening: Push your changes
git add .
git commit -m "Implemented feature"
git pushFor complete workflows including AI agent integration, see docs/EXAMPLE_WORKFLOW.md.
π For complete AI integration examples: See docs/EXAMPLE_WORKFLOW.md
The synced beads issues are perfect for AI coding agents. Here's a quick example:
# Agent queries available work
bd ready --json | jq '.[0]'
# Agent reads issue details
bd show bd-a1b2
# Agent sees Jira context in description:
# **Jira Issue:** [PROJ-234]
# **Status:** In Progress
# **Assignee:** Alice Johnson
#
# Sessions are not being properly garbage collected...
# Agent creates dependencies for discovered work
bd create "Add missing tests" -t task -p 2
bd dep add bd-new1 bd-a1b2 --type discovered-fromAdd to your AGENTS.md or .github/copilot-instructions.md:
## Issue Tracking
We use beads for issue tracking, which syncs from Jira.
Before starting work:
- Run `bd ready` to see available tasks
- Jira-synced issues are labeled with `jira-synced` and their Jira key
- Check issue descriptions for Jira metadata
When you discover new work related to a Jira issue:
- Create a new beads issue: `bd create "title" -t task -p 2`
- Link it: `bd dep add <new-issue> <jira-issue> --type discovered-from`For detailed AI agent workflows, see docs/EXAMPLE_WORKFLOW.md.
| File | Purpose |
|---|---|
sync_jira_to_beads.py |
Main synchronization script |
install.sh |
Interactive installation wizard |
INDEX.md |
Package overview and navigation |
README.md |
Complete setup guide (this file) |
docs/QUICKREF.md |
Quick command reference |
docs/EXAMPLE_WORKFLOW.md |
Real-world usage scenarios |
OFFLINE_BEHAVIOR.md |
Network failure handling |
For humans:
- Start with INDEX.md - Package overview
- Read this file (README.md) - Setup and architecture
- Check docs/QUICKREF.md - Command reference
- Review docs/EXAMPLE_WORKFLOW.md - Daily workflow
For AI agents:
- Read docs/QUICKREF.md - Command syntax
- Study docs/EXAMPLE_WORKFLOW.md - Integration patterns
- Reference this file - Field mappings and labels
For troubleshooting:
- Check docs/QUICKREF.md - Quick fixes
- See docs/guides/OFFLINE_BEHAVIOR.md - Network issues
- Review this file - Detailed troubleshooting
Potential improvements:
- Real MCP Integration - Implement actual Atlassian Rovo MCP client
- Bidirectional Sync - Update Jira from beads changes
- More Jira Fields - Sync labels, custom fields, attachments
- Conflict Resolution - Handle concurrent updates
- Multiple Projects - Sync from multiple Jira projects
- Web UI - Monitor sync status and conflicts
- Incremental Sync - Only sync changed issues
This is a working prototype designed to be extended:
- Fork/copy these files
- Modify the sync logic in
sync_jira_to_beads.py - Add custom field mappings
- Implement real MCP integration
- Share improvements!
See INDEX.md for architecture details.
- INDEX.md - Package overview and architecture
- docs/QUICKREF.md - Command reference
- docs/EXAMPLE_WORKFLOW.md - Usage scenarios
- docs/guides/OFFLINE_BEHAVIOR.md - Network handling
MIT - Same as beads
- Built on beads by @steveyegge
- Uses Atlassian Rovo MCP Server
- Inspired by the need for offline Jira access and AI agent integration
- Documentation follows Agentic AI SDLC best practices