Your AI intern for automatically implementing JIRA tasks using Claude. Supports both single task processing and batch processing of multiple tasks through JQL queries or explicit task lists. Pulls task details and feeds them to Claude for implementation with full automation of the development workflow.
Install globally via npm to use from any directory:
# Install globally
npm install -g claude-intern
# Or use directly without installing
npx claude-intern PROJ-123For development or contributing to the project:
- Install Bun (if not already installed):
curl -fsSL https://bun.sh/install | bash- Clone and install dependencies:
git clone https://github.com/danii1/claude-intern.git
cd claude-intern
bun install- (Optional) Install development version globally:
bun run install-globalThe easiest way to set up claude-intern for your project is using the init command:
# Initialize project-specific configuration
claude-intern initThis creates a .claude-intern folder in your current project with:
.env- Your project-specific configuration file with JIRA credentials.env.sample- Template with all configuration optionssettings.json- Per-project settings (PR status transitions, etc.)
Automatic .gitignore Protection: The init command automatically adds .claude-intern/.env to your .gitignore file (or creates one if it doesn't exist) to prevent accidentally committing credentials to version control.
After running init:
- Edit
.claude-intern/.envwith your JIRA credentials - (Optional) Edit
.claude-intern/settings.jsonto configure per-project PR status transitions
The tool searches for .env files in the following order:
- Custom path (if specified with
--env-file) - Project-specific (
.claude-intern/.env- recommended) - Current working directory (
.env) - User home directory (
~/.env) - Tool installation directory
Configuration options:
# Option 1: Project-specific (recommended)
claude-intern init # Creates .claude-intern/.env
# Option 2: Current directory
cp .env.sample .env
# Option 3: Global configuration
cp .env.sample ~/.env
# Option 4: Custom location
claude-intern PROJ-123 --env-file /path/to/custom.envUpdate your .env file with your JIRA details:
JIRA_BASE_URL: Your JIRA instance URL (e.g., https://yourcompany.atlassian.net)JIRA_EMAIL: Your JIRA email addressJIRA_API_TOKEN: Your JIRA API token (create one at https://id.atlassian.com/manage-profile/security/api-tokens)
Optional PR integration:
GITHUB_TOKEN: GitHub personal access token for creating pull requestsBITBUCKET_TOKEN: Bitbucket app password for creating pull requests
The .env.sample file includes helpful comments and optional configuration options.
Note: JIRA PR status transitions are now configured per-project in settings.json (see below).
The .claude-intern/settings.json file allows you to configure project-specific behavior:
{
"projects": {
"PROJ": {
"prStatus": "In Review"
},
"ABC": {
"prStatus": "Code Review"
}
}
}Configuration options:
prStatus: JIRA status to transition to after PR creation for a specific project- Each project key can have its own status workflow
- If not configured, no status transition will occur
Example: If you work with multiple JIRA projects that have different workflows (e.g., "PROJ" uses "In Review" but "ABC" uses "Code Review"), configure each project's status in settings.json.
# Global installation usage (recommended)
claude-intern TASK-123
# Or use with npx (no installation needed)
npx claude-intern TASK-123
# Skip Claude and just fetch/format the task
claude-intern TASK-123 --no-claude
# Skip git branch creation
claude-intern TASK-123 --no-git
# Use custom .env file
claude-intern TASK-123 --env-file /path/to/custom.env
# Specify custom output file
claude-intern TASK-123 -o my-task.md
# Verbose output for debugging
claude-intern TASK-123 -v
# Custom Claude CLI path
claude-intern TASK-123 --claude-path /path/to/claude
# Increase max turns for complex tasks
claude-intern TASK-123 --max-turns 50
# Skip automatic commit after Claude completes
claude-intern TASK-123 --no-auto-commit
# Create pull request after implementation
claude-intern TASK-123 --create-pr
# Create pull request targeting specific branch
claude-intern TASK-123 --create-pr --pr-target-branch develop
# Testing options - skip ALL JIRA comments (feasibility + implementation)
claude-intern TASK-123 --skip-jira-comments
# Local testing without PR (commits stay local, no push to remote)
# Simply omit --create-pr to skip pushing to remote
claude-intern TASK-123 --skip-jira-comments# Run with Bun during development
bun start TASK-123
# Development mode (same as start)
bun run dev TASK-123
# All options work with bun as well (note the -- separator)
bun start TASK-123 -- --no-claude --verbose# Process multiple specific tasks
claude-intern PROJ-123 PROJ-124 PROJ-125
# Process tasks matching JQL query
claude-intern --jql "project = PROJ AND status = 'To Do'"
# Complex JQL with custom fields and conditions
claude-intern --jql "project = \"My Project\" AND cf[10016] <= 3 AND labels IN (FrontEnd, MobileApp)"
# Batch process with PR creation
claude-intern --jql "assignee = currentUser() AND status = 'To Do'" --create-pr
# High-complexity batch processing with extended turns
claude-intern --jql "labels = 'refactoring' AND type = Story" --max-turns 500 --create-pr
# Batch process with skipped clarity checks for faster processing
claude-intern PROJ-101 PROJ-102 PROJ-103 --skip-clarity-check --create-pr# Process multiple tasks with Bun
bun start PROJ-123 PROJ-124 PROJ-125
# JQL queries (note -- separator for options)
bun start -- --jql "project = PROJ AND status = 'To Do'"
bun start -- --jql "assignee = currentUser()" --create-pr# Fetch JIRA task and run Claude automatically
claude-intern PROJ-456
# Just fetch and format (useful for reviewing before Claude runs)
claude-intern PROJ-456 --no-claude
# Then manually run Claude with the formatted output
claude -p --dangerously-skip-permissions --max-turns 10 < task-details.md
# Advanced batch scenarios
claude-intern --jql "\"Epic Link\" = PROJ-100" --create-pr
claude-intern --jql "sprint in openSprints() AND assignee = currentUser()" --max-turns 500You can set up automated task processing using cron jobs. This is useful for continuously picking up new tasks labeled for the intern to work on:
# Example: Process tasks labeled "Intern" in open sprints every 10 minutes
# Add to crontab (run: crontab -e)
*/10 * * * * cd /path/to/your/project && claude-intern --jql 'statusCategory = "To Do" AND sprint in openSprints() AND labels IN (Intern) ORDER BY created DESC' --max-turns 500 --create-pr --pr-target-branch master >> /tmp/claude-intern-cron.log 2>&1
# Example: Process assigned tasks every hour
0 * * * * cd /path/to/your/project && claude-intern --jql 'assignee = currentUser() AND status = "To Do" AND labels IN (AutoImpl)' --create-pr >> /tmp/claude-intern-cron.log 2>&1
# Example: Process high-priority bugs twice daily
0 9,17 * * * cd /path/to/your/project && claude-intern --jql 'type = Bug AND priority = High AND status = "To Do" AND labels IN (Intern)' --max-turns 300 --create-pr >> /tmp/claude-intern-cron.log 2>&1Important notes for cron setup:
- Always change to your project directory (
cd /path/to/your/project) to ensure the correct.claude-intern/.envis loaded - Use absolute paths or ensure PATH includes
claude-internandclaudebinaries - Redirect output to a log file for monitoring (
>> /tmp/claude-intern-cron.log 2>&1) - Use the
ORDER BY created DESCclause to process newest tasks first - Consider using labels (e.g.,
labels = "Intern") to mark tasks for automated processing - Test your JQL query manually before adding to cron to ensure it returns the expected tasks
- Monitor the log file regularly to ensure the cron job is running successfully
-
Fetches the JIRA task details including:
- Task description
- Custom fields (including links to Figma, external docs, etc.)
- Comments and discussion
-
Formats the information for Claude
-
Creates a feature branch named
feature/task-id(e.g.,feature/proj-123) -
Runs optional feasibility assessment to validate task clarity (skippable with
--skip-clarity-check)- Posts assessment results to JIRA (skippable with
--skip-jira-comments) - Saves assessment results for debugging:
{output-dir}/{task-key}/feasibility-assessment.md(formatted results with JSON){output-dir}/{task-key}/feasibility-assessment-failed.txt(raw output on parse failure)
- Posts assessment results to JIRA (skippable with
-
Runs
claude -pwith enhanced permissions and extended conversation limits for automatic implementation -
Saves Claude's implementation summary to local files for analysis:
{output-dir}/{task-key}/implementation-summary.md(successful){output-dir}/{task-key}/implementation-summary-incomplete.md(incomplete/failed)
-
Automatically commits all changes with a descriptive commit message after Claude completes successfully
-
Pushes the feature branch to remote repository (when creating PRs)
-
Optionally creates pull requests on GitHub or Bitbucket with detailed implementation summaries
-
Posts implementation results back to JIRA as comments (skippable with
--skip-jira-comments)- Includes feasibility assessment results
- Includes implementation summary
- Bun runtime
- JIRA API access
- Claude CLI installed and configured
- Git (for automatic branch creation)
- Install globally:
npm install -g claude-intern - Initialize your project:
claude-intern init - Configure your JIRA credentials in
.claude-intern/.env - Run from any directory:
claude-intern PROJ-123
Alternative: For global configuration across all projects, place .env in your home directory (~/.env)
See USAGE.md for detailed usage scenarios and troubleshooting.
See GLOBAL_USAGE.md for quick reference on global installation.
See ENV_SETUP.md for comprehensive environment configuration guide.
- ✅ Full TypeScript Support - Type-safe development with comprehensive interfaces
- ✅ JIRA API Integration - Connects to any JIRA instance with proper authentication
- ✅ Smart Link Detection - Automatically finds Figma, GitHub, Confluence links in custom fields
- ✅ Rich Text Processing - Handles JIRA's Atlassian Document Format with proper conversion
- ✅ HTML to Markdown Conversion - Converts JIRA's rendered HTML descriptions to clean markdown format
- ✅ Working Attachment Links - Converts relative JIRA attachment URLs to clickable full URLs
- ✅ Comment Threading - Includes all task discussions and updates
- ✅ Multiple Task Support - Process multiple tasks with explicit task keys
- ✅ JQL Query Integration - Use JIRA Query Language for dynamic task selection
- ✅ Complex JQL Support - Custom fields, arrays, operators, and advanced conditions
- ✅ Error Isolation - Failed tasks don't stop processing of remaining work
- ✅ Progress Tracking - Real-time progress indicators for batch operations
- ✅ Dynamic File Naming - Unique output files prevent conflicts during batch processing
- ✅ Claude Integration - Automatically runs
claude -pwith formatted context - ✅ Real-time Output - All Claude output is visible in real-time during execution
- ✅ CLI Interface - Easy-to-use command line tool with comprehensive options
- ✅ Git Integration - Automatically creates feature branches for each task
- ✅ Auto-Commit - Commits changes automatically after Claude completes successfully
- ✅ Pull Request Creation - Automatically creates PRs on GitHub or Bitbucket with implementation details
- ✅ Smart Repository Detection - Automatically detects GitHub/Bitbucket and workspace from git remote
- ✅ Error Handling - Robust error handling and validation
- ✅ Configurable - Flexible options for output and Claude path