Click on "Install 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 Servercreate a pull request to update the API documentation in my main repo"
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 Model Context Protocol (MCP) server for the Google Jules API. This server enables LLM applications to interact with Jules - Google's AI coding assistant - to create sessions, send messages, and manage coding tasks programmatically.
Features
List Sources: Browse available GitHub repositories connected to Jules
Create Sessions: Start new coding tasks with Jules
Send Messages: Communicate with Jules during active sessions
Approve Plans: Approve Jules's proposed plans before execution
List Activities: View the work history and conversation for a session
Create Pull Requests: Convenience tool to create sessions that result in PRs
Prerequisites
Python 3.10+
A Jules API key (generate one from the Jules Settings page)
GitHub repositories installed in Jules
Installation
Using uv (Recommended)
Using pip
Configuration
Set the JULES_API_KEY environment variable with your API key:
Usage
Running Standalone
MCP Configuration
Add this server to your MCP client configuration. Below are examples for different setups.
Claude Desktop / Claude Code
Add to your mcp.json or claude_desktop_config.json:
Alternative (without uv)
Available Tools
list_sources
List available GitHub repositories that Jules can work with.
Parameters:
page_size(int, optional): Number of sources to return (1-100, default 30)page_token(str, optional): Pagination token
get_source
Get details about a specific source repository.
Parameters:
source_name(str, required): Resource name (e.g., "sources/github/owner/repo")
list_sessions
List Jules sessions (coding tasks).
Parameters:
page_size(int, optional): Number of sessions to return (1-100, default 30)page_token(str, optional): Pagination tokenactive_only(bool, optional): Filter to only show active sessions
get_session
Get details about a specific session.
Parameters:
session_name(str, required): Resource name (e.g., "sessions/abc123")
create_session
Create a new Jules session to work on a coding task.
Parameters:
prompt(str, required): The coding task descriptionsource(str, required): Resource name of the repositorybranch(str, optional): Branch to usetitle(str, optional): Session titlerequire_plan_approval(bool, optional): Wait for plan approval before executing
send_message
Send a follow-up message to an active session.
Parameters:
session_name(str, required): Resource name of the sessionmessage(str, required): Message to send
approve_plan
Approve Jules's plan for a session in AWAITING_PLAN_APPROVAL state.
Parameters:
session_name(str, required): Resource name of the session
list_activities
List activities (work history) for a session.
Parameters:
session_name(str, required): Resource name of the sessionpage_size(int, optional): Number of activities to return (1-100, default 50)page_token(str, optional): Pagination token
create_pull_request
Create a session that will result in a pull request.
Parameters:
prompt(str, required): Description of changes to makesource(str, required): Resource name of the repositorybranch(str, optional): Base branch for the PRtitle(str, optional): Title for the session/PR
Session States
Sessions progress through these states:
QUEUED- Session is waiting to startPLANNING- Jules is creating a planAWAITING_PLAN_APPROVAL- Waiting for user to approve the planAWAITING_USER_FEEDBACK- Waiting for user inputIN_PROGRESS- Jules is working on the taskPAUSED- Session is pausedFAILED- Session failedCOMPLETED- Session completed successfully
Example Workflow
List available repositories:
Use the list_sources tool to see which repos are availableCreate a coding task:
Use create_session with: - prompt: "Add a dark mode toggle to the settings page" - source: "sources/github/myorg/myrepo"Monitor progress:
Use get_session to check the session state Use list_activities to see what Jules is doingInteract with Jules:
Use send_message if Jules needs clarification Use approve_plan if plan approval is requiredGet the result:
Once session is COMPLETED, check the outputs field for PR URL
API Reference
This server wraps the Google Jules API (v1alpha).
License
MIT