Jules MCP Server
Integrates with GitHub repositories through Jules to automate code modifications, create pull requests, and manage repository maintenance tasks like dependency updates and security audits.
Enables autonomous coding tasks through the Google Jules API, allowing creation and scheduling of coding sessions, task management, plan approval workflows, and monitoring of code generation progress in connected GitHub repositories.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Jules MCP Server add error handling to the login function in my-app-backend"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Jules MCP Server
A production-ready Model Context Protocol (MCP) server for the Google Jules API, enabling autonomous coding tasks and scheduling directly from AI assistants like Claude.
⚠️ DISCLAIMER: This is an independent, open-source project and is NOT officially created, maintained, or endorsed by Google. This server is a community-driven integration with the public Jules API. Use at your own risk. For official Jules documentation, visit jules.google.
🌟 Star This Repository
If you find this useful, please star ⭐ the repository to help others discover it!
Related MCP server: Jules MCP Server
Overview
This MCP server bridges the Google Jules coding agent with AI assistants, allowing you to:
Create coding tasks - Delegate bug fixes, refactoring, tests, and features to Jules
Schedule recurring tasks - Set up automated weekly/daily maintenance (dependency updates, security audits, etc.)
Monitor progress - Track session states and review generated plans
Approve plans - Human-in-the-loop control before code changes
Manage workflows - Send feedback and iterate on Jules's work
Architecture: The "Thick Server" Pattern
Since the Jules API v1alpha is stateless (no native scheduling endpoints), this server implements a local scheduling engine:
Persistent Storage: Schedules stored in
~/.jules-mcp/schedules.jsonCron Engine: Uses
node-schedulefor reliable task executionSurvives Restarts: Schedules are rehydrated on server startup
Autonomous Execution: Scheduled tasks run even without active IDE sessions
Installation
Prerequisites
Node.js 18.0.0 or higher
Jules API Key - Generate at jules.google/settings
GitHub Repositories - Connect repos to Jules via the web UI first
Setup
# Clone or download this repository
cd jules-mcp
# Install dependencies
npm install
# Build TypeScript
npm run build
# Set your API key
export JULES_API_KEY="your-key-here"
# Test the server
npm startQuick smoke test (MCP stdio)
After building and setting JULES_API_KEY, you can validate the server end-to-end:
npm run mcp:smokeExpected output (with a valid key):
Lists 6 tools, 5 prompts, and the 4 core resources
Attempts to read a fake session ID and reports a Jules 404 (proves real API calls work)
Attempts a tool call with dummy data and reports the API error without crashing
Global Installation (Recommended)
# Install globally
npm install -g
# Now available as: jules-mcp
jules-mcpConfiguration
Environment Variables
Create a .env file or set these in your shell:
# Required
JULES_API_KEY=your_jules_api_key_here
# Optional - Security allowlist (comma-separated repo names)
# If set, only these repos can be modified
JULES_ALLOWED_REPOS=owner/repo1,owner/repo2
# Optional - Default branch
JULES_DEFAULT_BRANCH=mainClaude Desktop Configuration
Add to your claude_desktop_config.json:
{
"mcpServers": {
"jules": {
"command": "node",
"args": ["/path/to/jules-mcp/dist/index.js"],
"env": {
"JULES_API_KEY": "your-key-here"
}
}
}
}On macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
On Windows: %APPDATA%/Claude/claude_desktop_config.json
VS Code / Cursor Configuration
For Cursor or VS Code with MCP support:
{
"mcp.servers": {
"jules": {
"command": "jules-mcp",
"env": {
"JULES_API_KEY": "your-key-here"
}
}
}
}Usage
Once configured, your AI assistant can use Jules through natural language:
Creating Immediate Tasks
"Use Jules to add unit tests for the authentication module in my-app-backend repository"The assistant will:
Check
jules://sourcesto find the repositoryCall
create_coding_tasktool with appropriate promptReturn the session ID for monitoring
Scheduling Recurring Tasks
"Schedule Jules to update dependencies every Monday at 9 AM in my-app-backend"The assistant will:
Call
schedule_recurring_taskwith cron"0 9 * * 1"Save the schedule to
~/.jules-mcp/schedules.jsonConfirm the next execution time
Monitoring Progress
"Check the status of Jules session abc123"The assistant will:
Call
get_session_statusor readjules://sessions/abc123/fullShow current state (PLANNING, IN_PROGRESS, COMPLETED, etc.)
Provide next steps based on state
Reviewing and Approving Plans
"Show me Jules's plan for session abc123 and approve it"The assistant will:
Read
jules://sessions/abc123/fullto get the planDisplay the plan steps to you
Call
manage_sessionwithaction=approve_planafter your confirmation
Available Resources
Resources are read-only context that the AI can access:
URI | Description |
| Connected GitHub repositories |
| Recent Jules sessions |
| Complete session details with activities |
| Active scheduled tasks |
| Execution history |
Available Tools
Tools are actions the AI can execute:
create_coding_task
Creates an immediate Jules coding session.
Parameters:
prompt(required) - Natural language task instructionsource(required) - Repository (format:sources/github/owner/repo)branch(optional) - Target branch (default:main)auto_create_pr(optional) - Auto-create PR (default:true)require_plan_approval(optional) - Pause for review (default:false)title(optional) - Session title
Returns: Session ID and monitoring URL
manage_session
Manage active sessions (approve plans, send feedback).
Parameters:
session_id(required)action(required) -"approve_plan"or"send_message"message(optional) - Required forsend_message
get_session_status
Check session status and get next steps.
Parameters:
session_id(required)
schedule_recurring_task
Schedule a task to run on a cron schedule.
Parameters:
task_name(required) - Unique schedule identifiercron_expression(required) - Standard cron formatprompt(required) - Task instructionsource(required) - Repository resource namebranch,auto_create_pr,require_plan_approval,timezone(optional)
Cron Examples:
"0 9 * * 1"- Every Monday at 9 AM"0 2 * * *"- Every day at 2 AM"0 0 1 * *"- First day of each month at midnight
list_schedules
List all active scheduled tasks with next run times.
delete_schedule
Remove a scheduled task.
Parameters:
task_name(required)
Available Prompts
Prompts are templates that guide best practices:
refactor_module- Guided refactoring workflowsetup_weekly_maintenance- Automated maintenance setupaudit_security- Comprehensive security auditfix_failing_tests- Test failure resolutionupdate_dependencies- Dependency update with breaking change handling
Security Considerations
API Key Security
Never commit your
JULES_API_KEYto version controlStore in environment variables or secure secrets manager
The API key grants write access to connected repositories
Repository Allowlist
Use JULES_ALLOWED_REPOS to restrict which repositories can be modified:
export JULES_ALLOWED_REPOS="myorg/safe-repo,myorg/test-repo"This prevents accidental modifications to production or sensitive repos.
Plan Approval Workflow
For critical repositories, always set require_plan_approval: true:
"Create a task but require plan approval before any code changes"This ensures human review before Jules modifies code.
Audit Logging
All scheduled task executions are logged to jules://schedules/history. Review this regularly to audit autonomous activities.
Troubleshooting
"JULES_API_KEY environment variable is required"
Set your API key:
export JULES_API_KEY="your-key-here""Repository not found" error
Check
jules://sourcesresource to see connected reposEnsure the GitHub app is installed on the repository
Use the exact resource name format:
sources/github/owner/repo
Schedules not persisting
Check that ~/.jules-mcp/schedules.json exists and is writable.
TypeScript compilation errors
npm run typecheckDevelopment
Project Structure
src/
types/ # TypeScript type definitions
jules-api.ts # Jules API types
schedule.ts # Schedule types
api/ # API client layer
jules-client.ts
storage/ # Persistence layer
schedule-store.ts
scheduler/ # Cron engine
cron-engine.ts
mcp/ # MCP protocol layer
resources.ts # Resources implementation
tools.ts # Tools implementation
prompts.ts # Prompt templates
index.ts # Main entry pointBuild Commands
npm run build # Compile TypeScript
npm run dev # Development mode with tsx
npm run typecheck # Type checking onlyAPI Endpoints Covered
This server provides complete coverage of the Jules v1alpha API:
Endpoint | Method | MCP Mapping |
| GET | Resource: |
| GET | Included in full session resource |
| POST | Tool: |
| GET | Resource: |
| GET | Tool: |
| POST | Tool: |
| POST | Tool: |
| GET | Resource: |
Additional Capabilities (Beyond API)
Local scheduling - Cron-based task execution
Schedule persistence - Survives server restarts
Execution history - Audit trail for scheduled tasks
Future Roadmap
When Jules API adds native scheduling:
The
schedule_recurring_tasktool will migrate from local cron to API callsExisting local schedules can be migrated automatically
The MCP tool interface remains unchanged for backward compatibility
Resources
Jules API Documentation: https://developers.google.com/jules/api
Jules Web Interface: https://jules.google
Model Context Protocol: https://modelcontextprotocol.io
MCP TypeScript SDK: https://github.com/modelcontextprotocol/typescript-sdk
License
MIT
Contributing
This is an open-source implementation. Contributions welcome for:
Additional prompt templates
Enhanced error handling
Webhook support (when Jules API adds it)
Advanced scheduling features (conditional execution, dependency chains)
Available Tools
6 toolscreate_coding_taskA
Creates a new Jules coding session. Returns immediately with a session ID. Monitor progress via jules://sessions/{id}/full resource.
Inputs: prompt (required), source (required), branch, auto_create_pr, +2 more.
delete_scheduleC
Delete a scheduled task by name
Inputs: task_name (required).
get_session_statusC
Get the current status and state of a Jules session
Inputs: session_id (required).
list_schedulesB
List all locally-managed scheduled tasks
Inputs: no named parameters.
manage_sessionC
Manage an active Jules session: approve plans or send feedback
Inputs: session_id (required), action (required), message.
schedule_recurring_taskC
Schedule a Jules task to run automatically on a cron schedule. The server manages execution even when offline.
Inputs: task_name (required), cron_expression (required), prompt (required), source (required), +4 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 6 tools
Each tool has a clearly distinct purpose with no overlap: create_coding_task initiates sessions, get_session_status monitors them, manage_session controls them, while list_schedules, schedule_recurring_task, and delete_schedule handle scheduling separately. The descriptions reinforce these boundaries, making misselection unlikely.
The tools follow a consistent verb_noun pattern with snake_case throughout, such as create_coding_task and list_schedules. However, manage_session deviates slightly by using a more generic verb compared to the others, but overall the naming is predictable and readable.
With 6 tools, the server is well-scoped for managing Jules coding sessions and scheduled tasks. Each tool earns its place by covering distinct aspects like creation, monitoring, management, and scheduling, without being overly sparse or bloated.
The tool set provides solid coverage for session lifecycle (create, status, manage) and scheduling (list, create, delete), with no dead ends. A minor gap exists in lacking a direct tool to list or delete sessions, but agents can infer status from get_session_status and deletion might be handled implicitly.
Maintenance
Related MCP Connectors
Connect AI assistants to GitHub - manage repos, issues, PRs, and workflows through natural language.
Schedule tasks for later from your AI agent: reminders, delayed webhooks, recurring jobs.
Hand tasks, bugs and finished work to AI coding agents, and get back a write-up with evidence.
Assign Linear, Jira or GitHub issues to an AI coding agent team that plans, builds, reviews, tests.
Related MCP Servers
- -licenseAqualityNot gradedmaintenanceEnables automation of Google Jules AI coding assistant through task creation, code review automation, repository management, and AI-powered development workflows. Supports multiple session modes including cloud deployment with persistent authentication.13-
- AlicenseNot gradedqualityDmaintenanceConnects AI coding assistants to the Jules API for autonomous coding sessions. Enables creating and managing coding sessions, GitHub integration, plan approval workflows, and real-time activity tracking directly from your IDE.10 npm6MIT
- AlicenseBqualityBmaintenanceIntegrates Google's Jules coding agent with AI assistants to delegate autonomous coding tasks like bug fixes, refactoring, and tests, with support for scheduling recurring maintenance tasks and human-in-the-loop plan approval.629MIT
- FlicenseAqualityDmaintenanceEnables LLM applications to interact with Google's Jules AI coding assistant to manage repositories, coding sessions, and pull requests. It allows users to programmatically create tasks, approve plans, and communicate with the assistant during active coding sessions.9-