How to integrate Gleap MCP with Google ADK

This guide walks you through connecting Gleap to Google ADK using the Composio tool router. By the end, you'll have a working Gleap agent that can archive resolved support tickets from last week, send a chat message to follow up on feedback, list all articles in the onboarding collection through natural language commands. This guide will help you understand how to give your Google ADK agent real control over a Gleap account through Composio's Gleap MCP server. Before we dive in, let's take a quick look at the key ideas and tools involved.

Gleap logoGleap
Api Key

Gleap is an all-in-one customer feedback tool for apps and websites. It helps you understand user pain points and improve software through direct, actionable insights.

179 Tools

Introduction

This guide walks you through connecting Gleap to Google ADK using the Composio tool router. By the end, you'll have a working Gleap agent that can archive resolved support tickets from last week, send a chat message to follow up on feedback, list all articles in the onboarding collection through natural language commands.

This guide will help you understand how to give your Google ADK agent real control over a Gleap account through Composio's Gleap MCP server.

Before we dive in, let's take a quick look at the key ideas and tools involved.

Also integrate Gleap with

TL;DR

Here's what you'll learn:
  • Get a Gleap account set up and connected to Composio
  • Install the Google ADK and Composio packages
  • Create a Composio Tool Router session for Gleap
  • Build an agent that connects to Gleap through MCP
  • Interact with Gleap using natural language

What is Google ADK?

Google ADK (Agents Development Kit) is Google's framework for building AI agents powered by Gemini models. It provides tools for creating agents that can use external services through the Model Context Protocol.

Key features include:

  • Gemini Integration: Native support for Google's Gemini models
  • MCP Toolset: Built-in support for Model Context Protocol tools
  • Streamable HTTP: Connect to external services through streamable HTTP
  • CLI and Web UI: Run agents via command line or web interface

What is the Gleap MCP server, and what's possible with it?

The Gleap MCP server is an implementation of the Model Context Protocol that connects your AI agent and assistants like Claude, Cursor, etc directly to your Gleap account. It provides structured and secure access to your customer feedback data, so your agent can perform actions like managing support tickets, communicating with users, organizing help center content, and handling team workflows on your behalf.

  • Ticket creation and management: Instantly create new support tickets, archive resolved issues, or retrieve existing tickets to streamline customer support workflows.
  • Chat and user communication: Allow your agent to send new chat messages or fetch entire chat histories, making it easy to keep conversations going with users.
  • Help center organization: Create collections or retrieve articles in your help center, enabling your agent to help manage and organize your knowledge base content efficiently.
  • Team and user administration: Add new teams for ticket assignment or remove users from projects, so you can stay on top of team management tasks without lifting a finger.
  • Checklist and engagement tracking: Fetch detailed checklists to monitor user engagement or onboarding progress, giving your agent context to provide personalized support.

What is the Composio tool router, and how does it fit here?

What is Composio SDK?

Composio's Composio SDK helps agents find the right tools for a task at runtime. You can plug in multiple toolkits (like Gmail, HubSpot, and GitHub), and the agent will identify the relevant app and action to complete multi-step workflows. This can reduce token usage and improve the reliability of tool calls. Read more here: Getting started with Composio SDK

The tool router generates a secure MCP URL that your agents can access to perform actions.

How the Composio SDK works

The Composio SDK follows a three-phase workflow:

  1. Discovery: Searches for tools matching your task and returns relevant toolkits with their details.
  2. Authentication: Checks for active connections. If missing, creates an auth config and returns a connection URL via Auth Link.
  3. Execution: Executes the action using the authenticated connection.

Step-by-step Guide

Step by step09 STEPS
1

Prerequisites

Before starting, make sure you have:
  • A Google API key for Gemini models
  • A Composio account and API key
  • Python 3.9 or later installed
  • Basic familiarity with Python
2

Getting API Keys for Google and Composio

Google API Key
  • Go to Google AI Studio and create an API key.
  • Copy the key and keep it safe. You will put this in GOOGLE_API_KEY.
Composio API Key and User ID
  • Log in to the Composio dashboard.
  • Go to Settings → API Keys and copy your Composio API key. Use this for COMPOSIO_API_KEY.
  • Decide on a stable user identifier to scope sessions, often your email or a user ID. Use this for COMPOSIO_USER_ID.
3

Install dependencies

bash
pip install google-adk composio python-dotenv

Inside your virtual environment, install the required packages.

What's happening:

  • google-adk is Google's Agents Development Kit
  • composio connects your agent to Gleap via MCP
  • python-dotenv loads environment variables
4

Set up ADK project

bash
adk create my_agent

Set up a new Google ADK project.

What's happening:

  • This creates an agent folder with a root agent file and .env file
5

Set environment variables

bash
GOOGLE_API_KEY=your-google-api-key
COMPOSIO_API_KEY=your-composio-api-key
COMPOSIO_USER_ID=your-user-id-or-email

Save all your credentials in the .env file.

What's happening:

  • GOOGLE_API_KEY authenticates with Google's Gemini models
  • COMPOSIO_API_KEY authenticates with Composio
  • COMPOSIO_USER_ID identifies the user for session management
6

Import modules and validate environment

python
import os
import warnings

from composio import Composio
from dotenv import load_dotenv
from google.adk.agents.llm_agent import Agent
from google.adk.tools.mcp_tool.mcp_session_manager import StreamableHTTPConnectionParams
from google.adk.tools.mcp_tool.mcp_toolset import McpToolset

load_dotenv()

warnings.filterwarnings("ignore", message=".*BaseAuthenticatedTool.*")

GOOGLE_API_KEY = os.getenv("GOOGLE_API_KEY")
COMPOSIO_API_KEY = os.getenv("COMPOSIO_API_KEY")
COMPOSIO_USER_ID = os.getenv("COMPOSIO_USER_ID")

if not GOOGLE_API_KEY:
    raise ValueError("GOOGLE_API_KEY is not set in the environment.")
if not COMPOSIO_API_KEY:
    raise ValueError("COMPOSIO_API_KEY is not set in the environment.")
if not COMPOSIO_USER_ID:
    raise ValueError("COMPOSIO_USER_ID is not set in the environment.")
What's happening:
  • os reads environment variables
  • Composio is the main Composio SDK client
  • GoogleProvider declares that you are using Google ADK as the agent runtime
  • Agent is the Google ADK LLM agent class
  • McpToolset lets the ADK agent call MCP tools over HTTP
7

Create Composio client and Tool Router session

python
composio_client = Composio(api_key=COMPOSIO_API_KEY)

composio_session = composio_client.create(
    user_id=COMPOSIO_USER_ID,
    toolkits=["gleap"],
)

COMPOSIO_MCP_URL = composio_session.mcp.url,
print(f"Composio MCP URL: {COMPOSIO_MCP_URL}")
What's happening:
  • Authenticates to Composio with your API key
  • Declares Google ADK as the provider
  • Spins up a short-lived MCP endpoint for your user and selected toolkit
  • Stores the MCP HTTP URL for the ADK MCP integration
8

Set up the McpToolset and create the Agent

python
composio_toolset = McpToolset(
    connection_params=StreamableHTTPConnectionParams(
        url=COMPOSIO_MCP_URL,
        headers={"x-api-key": COMPOSIO_API_KEY}
    )
)

root_agent = Agent(
    model="gemini-2.5-flash",
    name="composio_agent",
    description="An agent that uses Composio tools to perform actions.",
    instruction=(
        "You are a helpful assistant connected to Composio. "
        "You have the following tools available: "
        "COMPOSIO_SEARCH_TOOLS, COMPOSIO_MULTI_EXECUTE_TOOL, "
        "COMPOSIO_MANAGE_CONNECTIONS, COMPOSIO_REMOTE_BASH_TOOL, COMPOSIO_REMOTE_WORKBENCH. "
        "Use these tools to help users with Gleap operations."
    ),
    tools=[composio_toolset],
)

print("\nAgent setup complete. You can now run this agent directly ;)")
What's happening:
  • Connects the ADK agent to the Composio MCP endpoint through McpToolset
  • Uses Gemini as the model powering the agent
  • Lists exact tool names in instruction to reduce misnamed tool calls
9

Run the agent

bash
# Run in CLI mode
adk run my_agent

# Or run in web UI mode
adk web

Execute the agent from the project root. The web command opens a web portal where you can chat with the agent.

What's happening:

  • adk run runs the agent in CLI mode
  • adk web . opens a web UI for interactive testing

Complete Code

Here's the complete code to get you started with Gleap and Google ADK:

python
import os
import warnings

from composio import Composio
from composio_google import GoogleProvider
from dotenv import load_dotenv
from google.adk.agents.llm_agent import Agent
from google.adk.tools.mcp_tool.mcp_session_manager import StreamableHTTPConnectionParams
from google.adk.tools.mcp_tool.mcp_toolset import McpToolset

load_dotenv()
warnings.filterwarnings("ignore", message=".*BaseAuthenticatedTool.*")

GOOGLE_API_KEY = os.getenv("GOOGLE_API_KEY")
COMPOSIO_API_KEY = os.getenv("COMPOSIO_API_KEY")
COMPOSIO_USER_ID = os.getenv("COMPOSIO_USER_ID")

if not GOOGLE_API_KEY:
    raise ValueError("GOOGLE_API_KEY is not set in the environment.")
if not COMPOSIO_API_KEY:
    raise ValueError("COMPOSIO_API_KEY is not set in the environment.")
if not COMPOSIO_USER_ID:
    raise ValueError("COMPOSIO_USER_ID is not set in the environment.")

composio_client = Composio(api_key=COMPOSIO_API_KEY, provider=GoogleProvider())

composio_session = composio_client.create(
    user_id=COMPOSIO_USER_ID,
    toolkits=["gleap"],
)

COMPOSIO_MCP_URL = composio_session.mcp.url


composio_toolset = McpToolset(
    connection_params=StreamableHTTPConnectionParams(
        url=COMPOSIO_MCP_URL,
        headers={"x-api-key": COMPOSIO_API_KEY}
    )
)

root_agent = Agent(
    model="gemini-2.5-flash",
    name="composio_agent",
    description="An agent that uses Composio tools to perform actions.",
    instruction=(
        "You are a helpful assistant connected to Composio. "
        "You have the following tools available: "
        "COMPOSIO_SEARCH_TOOLS, COMPOSIO_MULTI_EXECUTE_TOOL, "
        "COMPOSIO_MANAGE_CONNECTIONS, COMPOSIO_REMOTE_BASH_TOOL, COMPOSIO_REMOTE_WORKBENCH. "
        "Use these tools to help users with Gleap operations."
    ),  
    tools=[composio_toolset],
)

print("\nAgent setup complete. You can now run this agent directly ;)")

Conclusion

You've successfully integrated Gleap with the Google ADK through Composio's MCP Tool Router. Your agent can now interact with Gleap using natural language commands.

Key takeaways:

  • The Tool Router approach dynamically routes requests to the appropriate Gleap tools
  • Environment variables keep your credentials secure and separate from code
  • Clear agent instructions reduce tool calling errors
  • The ADK web UI provides an interactive interface for testing and development

You can extend this setup by adding more toolkits to the toolkits array in your session configuration.

TOOLS

Supported Tools

Every Gleap action and event your agent gets out of the box.

Archive All Tickets

Tool to archive all tickets matching specific type and status criteria.

Archive a Ticket

Tool to archive a ticket.

Clone Engagement

Tool to clone an existing engagement.

Create a Collection

Tool to create a help center collection.

Create AI Content

Tool to create or update AI content in Gleap's knowledge base.

Create a new chat message

Creates a new chat message in a Gleap chat session.

Create a new session

Create a new user session in Gleap and associate it with a project.

Create a new team

Tool to create a new team.

Create a new ticket

Create a new support ticket in Gleap with detailed information including title, description, type, priority, status, tags, and attachments.

Create Engagement Banner

Tool to create a new engagement banner in Gleap.

Create Engagement Checklist

Tool to create a new engagement checklist.

Create Engagement Cobrowse

Tool to create a new cobrowse product tour.

Create Engagement Email

Tool to create a new engagement email in Gleap.

Create Engagement Modal

Tool to create a new engagement modal in Gleap.

Create Engagement Product Tour

Tool to create a new product tour in Gleap.

Create Engagement Push Notification

Tool to create a new push notification in Gleap.

Create Engagement Tooltip

Tool to create a new engagement tooltip in Gleap.

Create feedback item

Tool to manually create a feedback item (bug) in a Gleap project.

Create Help Center Redirect

Tool to create a new redirect for help center URLs.

Create Message Template

Tool to create a new message template in Gleap.

Create new conversation with session

Create a new conversation with a session in Gleap.

Create QA Snippet

Tool to create a QA snippet (question-answer pair) in Gleap.

Create Tracker Ticket

Tool to create a tracker ticket in Gleap.

Delete AI Content

Tool to delete AI content by content ID.

Delete AI Content Batch

Tool to delete all AI content by batchId.

Delete a User from a Project

Removes a user (team member) from a Gleap project, revoking their access.

Delete Bugs

Tool to delete a bug/ticket by ID.

Delete Engagement Banner

Tool to delete an engagement banner.

Delete Engagement Chat Message

Deletes an engagement chat message from Gleap by its ID.

Delete Engagement Checklist

Tool to delete an engagement checklist by its ID.

Delete Engagement Cobrowse

Tool to delete a cobrowse product tour by its ID.

Delete Engagement Email

Tool to delete an engagement email by its ID.

Delete Engagement Modal

Tool to delete an engagement modal from a Gleap project.

Delete Engagement News

Tool to delete an engagement news article.

Delete Engagement Product Tour

Tool to delete an engagement product tour by its ID.

Delete Engagement Push Notification

Tool to delete an engagement push notification by its ID.

Delete Engagement Surveys

Tool to delete an engagement survey.

Delete Engagement Tooltips

Tool to delete an engagement tooltip.

Delete Engagement WhatsApp Message

Tool to delete an engagement WhatsApp message by its ID.

Delete Help Center Collection

Tool to delete a help center collection by ID.

Delete Help Center Redirect

Tool to delete a help center redirect.

Delete Message

Tool to delete a message (comment) from a bug or ticket.

Delete Message Template

Tool to delete a message template.

Delete Old AI Content Batches

Delete all AI content batches except the current batch.

Delete QA Answer

Tool to delete a QA answer (snippet) from a Gleap project.

Delete project session

Tool to delete a session from a Gleap project.

Delete session

Tool to delete a session by ID.

Delete Team

Tool to delete a team by ID.

Delete Ticket

Tool to delete a ticket by ID.

Export sessions

Tool to export sessions for the authenticated project in CSV format.

Export Statistics Lists

Tool to export statistics list data as CSV from Gleap.

Generate ticket draft reply

Tool to generate an AI-powered draft reply for a ticket.

Generate tracker ticket data

Tool to generate AI-powered tracker ticket data from an existing ticket.

Get a Checklist

Tool to retrieve a specific engagement checklist by its ID.

Get a Collection

Tool to retrieve a help center collection by ID.

Get AI content

Tool to retrieve AI content by its content ID.

Get all articles

Tool to retrieve articles in a help center collection.

Get all chat messages

Retrieves all engagement chat messages from the current Gleap project.

Get All Collections

Retrieves all help center collections for the authenticated project.

Get All Invitations for a Project

Retrieves all pending invitations for a project.

Get all sessions

Retrieves all user sessions for the authenticated project.

Get All Teams

Tool to retrieve all teams.

Get All Tickets

Retrieve tickets from a Gleap project with optional filtering, sorting, and pagination.

Get All Users for a Project

Tool to retrieve all users for a project.

Get a ticket

Retrieves complete details for a specific ticket by its ID.

Get current user

Retrieves the authenticated user's profile including email, name, user type, availability status, notification preferences, and 2FA settings.

Get engagement activities count

Tool to retrieve the count of activities for a specific engagement.

Get engagement banner

Tool to retrieve an engagement banner by its ID.

Get Engagement Banners

Tool to retrieve all engagement banners from a Gleap project.

Get engagement chat message

Retrieves a specific engagement chat message by its ID.

Get Engagement Checklists

Tool to retrieve all engagement checklists for a project.

Get Engagement Cobrowse

Retrieves all cobrowse product tours for the authenticated project.

Get engagement cobrowse by ID

Tool to retrieve a specific cobrowse product tour by its ID.

Get engagement email

Retrieves a specific engagement email by its ID.

Get Engagement Emails

Tool to retrieve all engagement emails from a Gleap project.

Get engagement modal

Tool to retrieve an engagement modal by its ID.

Get Engagement Modals

Tool to retrieve all engagement modals from a Gleap project.

Get Engagement News

Tool to retrieve all engagement news articles from a Gleap project.

Get engagement news article

Retrieves a specific engagement news article by its ID.

Get a Product Tour

Tool to retrieve a specific engagement product tour by its ID.

Get Engagement Product Tours

Tool to retrieve all engagement product tours for a project.

Get engagement push notification

Retrieves a specific engagement push notification by its ID.

Get Engagement Push Notifications

Tool to retrieve all engagement push notifications from a Gleap project.

Get Engagements Activities

Tool to retrieve all activities for a specific engagement.

Get engagement recipients

Tool to find and retrieve recipients for a specific engagement.

Get engagement statistics

Tool to retrieve statistics for a specific engagement.

Get Engagement Survey

Tool to retrieve a survey by its ID.

Get Engagement Surveys

Tool to retrieve all engagement surveys from a Gleap project.

Get Survey Responses

Tool to retrieve all survey responses for a specific survey.

Get Engagement Survey Response Samples

Tool to retrieve survey response samples for a specific engagement survey.

Summarize Survey Responses

Tool to retrieve an AI-generated summary of survey responses.

Get Engagement Tooltip by ID

Tool to retrieve a specific engagement tooltip by its ID.

Get Engagement Tooltips

Tool to retrieve all engagement tooltips for the authenticated project.

Get engagement WhatsApp message

Retrieves a specific engagement WhatsApp message by its ID.

Get Help Center Sources

Retrieves all configured help center sources (knowledge base content sources) for the project.

Get Invitations

Retrieves all invitations for the authenticated user.

Get message template

Retrieves a specific message template by its ID from a Gleap project.

Get Message Templates

Retrieve all message templates for the authenticated project.

Get notification ticket

Retrieves detailed information about a Gleap ticket using its notification share token.

Get project

Retrieves complete details for a specific project by its ID.

Get Projects

Retrieves all projects accessible to the authenticated user.

Get archived bugs

Tool to retrieve archived bugs for a specific project.

Get Projects Help Center Collections

Tool to get all help center collections for a project.

Get project sessions

Tool to retrieve all sessions for a specific project.

Get Projects Tickets

Tool to retrieve all tickets from a specific Gleap project.

Get project users

Tool to get project users by project ID.

Get a session

Retrieves detailed information for a specific session by its ID.

Get session activities

Retrieves all activities for a specific session by session ID.

Get session Chargebee info

Tool to retrieve Chargebee billing information for a specific session.

Get Session Checklists

Retrieve all engagement checklists associated with a user session in Gleap.

Get session events by ID

Tool to retrieve all streamed events for a specific session by its ID.

Get session LemonSqueezy info

Tool to retrieve LemonSqueezy subscription and payment information for a specific session.

Get Session Shopify Info

Retrieve Shopify information associated with a user session in Gleap.

Get Shared Help Center Answer

Retrieves an answer to a question from the shared help center knowledge base.

Get email client bounce statistics

Tool to retrieve email client bounce statistics from Gleap.

Get Email Client Usage Statistics

Tool to retrieve email client usage statistics from Gleap.

Get email overview statistics

Tool to retrieve email overview statistics from Gleap.

Get statistics facts

Tool to retrieve fact data for various statistics from Gleap.

Get Statistics Heatmap

Retrieve heatmap data for activity patterns in Gleap.

Get Statistics Lists

Tool to retrieve statistics list data from Gleap.

Get Statistics Raw Data

Tool to retrieve raw statistics data from Gleap.

Get Tickets By Session Query

Find tickets by session query parameters such as email, userId, phone, or custom data.

Get Tickets Export

Export tickets from Gleap project with optional filtering and sorting.

Get Tickets Export Fields

Retrieve available fields for ticket export from Gleap.

Search Tickets by Term

Search for tickets using a text search term in Gleap.

Get Tickets Count

Tool to get the total count of tickets in a Gleap project.

Get current user's permissions

Tool to retrieve the current user's role permissions.

Get users unified inbox

Retrieves tickets from the unified inbox for the authenticated user.

Get users unified inbox ticket

Retrieves complete details for a specific ticket from the unified inbox by its ID.

Identify or update user

Identify or update a user's information in Gleap.

Import session

Import user sessions into Gleap for tracking and analytics.

Import sessions from Intercom

Import user sessions from Intercom into Gleap.

Indicate user typing

Tool to indicate that a user is typing in a ticket conversation.

Indicate user viewing

Tool to indicate that a user is viewing a ticket.

Link a Ticket

Tool to link a ticket.

Mark Survey Responses as Read

Tool to mark all survey responses as read for a given survey.

Merge tickets

Tool to merge multiple tickets into a single target ticket in Gleap.

Post a comment on a bug

Tool to post a comment/message on a bug or ticket in Gleap.

Create Engagement News Article

Tool to create a new engagement news article in Gleap.

Create Engagement Survey

Tool to create a new survey in Gleap.

Create WhatsApp Engagement Message

Tool to create a new WhatsApp message in Gleap for user engagement.

Reassign all tickets to user

Tool to reassign all tickets to the authenticated user.

Resubscribe a Session

Tool to resubscribe a session.

Search for sessions

Search for sessions in Gleap using various filter criteria.

Search messages

Search messages in Gleap by search term.

Search sessions by index

Search for sessions in a project using the session search index.

Send Engagement Email Preview

Tool to send a preview of an engagement email to specified email addresses.

Send ticket transcript

Tool to send ticket conversation transcript to multiple email addresses.

Snooze a Ticket

Tool to snooze a ticket for a specified duration.

Suggest FAQ from message

Tool to suggest a FAQ from a message.

Toggle Collection Publish Status

Tool to toggle the publish status of a help center collection.

Track events

Track custom user events in Gleap for analytics and user behavior monitoring.

Unarchive a Ticket

Tool to unarchive a ticket.

Unlink a Ticket

Tool to unlink a ticket.

Unsubscribe sessions

Tool to unsubscribe one or more user sessions from communications.

Update AI Content by Content ID

Tool to update AI content by content ID.

Update a team

Tool to update an existing team.

Update a ticket

Tool to update an existing ticket/bug in Gleap.

Update a User for a Project

Tool to update a user’s role in a project.

Update Chat Message

Updates an existing chat message in Gleap by its ID.

Update a Checklist

Tool to update an engagement checklist by its ID.

Update Engagement Banner

Tool to update an engagement banner.

Update Engagement Cobrowse

Tool to update an existing cobrowse product tour.

Update Engagement Email

Tool to update an existing engagement email.

Update Engagement Modal

Tool to update an existing engagement modal.

Update Engagement News

Tool to update an engagement news article.

Update Engagement Product Tour

Tool to update an existing product tour.

Update Engagement Push Notification

Tool to update an existing push notification.

Update Engagement Survey

Tool to update an existing engagement survey in Gleap.

Update Engagement Tooltips

Tool to update an engagement tooltip.

Update Engagement WhatsApp Message

Tool to update an existing engagement WhatsApp message.

Update Helpcenter Collection

Tool to update a help center collection.

Update help center redirect

Tool to update an existing help center redirect.

Update message template

Tool to update an existing message template in Gleap.

Update project

Tool to update a Gleap project's configuration including name, description, notification settings, and feedback tags.

Update QA Answer

Updates an existing QA answer/snippet in Gleap.

Update a session

Tool to update an existing session in Gleap.

Update user

Tool to update a user's profile information including name, availability, profile image, onboarding status, and notification settings.

Vote for ticket

Tool to vote for a ticket in Gleap.

FAQ

Frequently asked questions

With a standalone Gleap MCP server, the agents and LLMs can only access a fixed set of Gleap tools tied to that server. However, with the Composio Tool Router, agents can dynamically load tools from Gleap and many other apps based on the task at hand, all through a single MCP endpoint.

Yes, you can. Google ADK fully supports MCP integration. You get structured tool calling, message history handling, and model orchestration while Tool Router takes care of discovering and serving the right Gleap tools.

Yes, absolutely. You can configure which Gleap scopes and actions are allowed when connecting your account to Composio. You can also bring your own OAuth credentials or API configuration so you keep full control over what the agent can do.

All sensitive data such as tokens, keys, and configuration is fully encrypted at rest and in transit. Composio is SOC 2 Type 2 compliant and follows strict security practices so your Gleap data and credentials are handled as safely as possible.

Start with Gleap.It takes 30 seconds.

Managed auth, hosted MCP servers, and every Gleap tool your agent needs.Free to start.

Start building