Back to Templates
Marketing & Content

HubSpot Lead Quality Analyzer

Analyzes lead sources, conversion rates, and lead quality in HubSpot. Identifies which campaigns and channels produce the highest quality leads, spots trends in lead scoring, and generates weekly marketing performance reports.

Toolkits Needed

You'll need access to these toolkits in your Arcade MCP Gateway:

Hubspot
GoogleSheets
Slack

Setup Guide

1

Sign up for Arcade

Create a free Arcade account to get access to MCP Gateway.

Create Arcade Account →
2

Create a new MCP Gateway

Navigate to MCP Gateway page in Arcade, then click Create MCP Gateway.

Provide a slug that becomes your MCP URL (this is what you'll configure in Agent Builder):

Example: If you choose slug my-agent, your MCP URL will be:
https://api.arcade.dev/mcp/my-agent
3

Select the specific tools you need

Arcade MCP Gateway gives you fine-grained control over exactly which tools your agent can access. Select these specific tools from the toolkits:

Hubspot.ListContacts
Hubspot.GetContactDataByKeywords
Hubspot.ListDeals
Hubspot.GetDealDataByKeywords
Hubspot.ListCompanies
Hubspot.GetCompanyDataByKeywords
GoogleSheets.GetSpreadsheet
GoogleSheets.UpdateCells
GoogleSheets.CreateSpreadsheet
Slack.SendMessage
Slack.ListConversations
Choose your tools in Arcade MCP Gateway

Why this matters: Instead of granting access to entire toolkits with hundreds of tools, you're selecting only the 11 specific tools this agent actually needs. This precision reduces risk and keeps your agent focused.

4

Create the gateway and copy your MCP URL

Click Create Gateway. Copy the MCP URL — this is all you need to connect to LangSmith!

Example MCP URL:
https://api.arcade.dev/mcp/my-agent

No tokens needed! Arcade uses OAuth for secure authentication — you'll sign in with your Arcade account in LangSmith.

5

Open LangSmith Agent Builder

This agent is pre-created in the LangSmith Agent Builder templates. Go to LangSmith, find this template, and start using it right away!

Open LangSmith Agent Builder →
Can't find this template? Click here for the system prompt

If you don't see this template in your account, you can create the agent manually. Copy this system prompt and paste it into the "System Prompt" field when creating a new agent:

Agent System Prompt
You are a HubSpot Lead Quality Analyzer that scores and prioritizes leads.

## Your Capabilities
- Access all HubSpot contact, company, and activity data
- Analyze engagement patterns
- Score leads based on behavior
- Update lead scores in HubSpot
- Alert on high-priority leads via Slack

## Workflow
1. **Pull Data** - Get contact and activity data from HubSpot
2. **Analyze** - Review engagement, company fit, behavior
3. **Score** - Calculate lead quality score
4. **Update** - Write scores back to HubSpot
5. **Prioritize** - Identify hottest leads
6. **Alert** - Notify sales of priority leads

## Example Interactions
**User:** "Analyze our new leads from this week"
**Agent:** I'll analyze all new leads from the past week...

**Lead Analysis (45 new leads):**
- Hot (Score 80+): 5 leads
- Warm (Score 50-79): 15 leads
- Cold (Score <50): 25 leads

**Top Priority Leads:**
1. John @ BigCorp - Score: 92 - Multiple page visits, downloaded whitepaper
2. Sarah @ TechStart - Score: 87 - Demo request, VP title

I've updated scores in HubSpot. Alert #sales about the hot leads?

## Guidelines
- Weight recent activity higher
- Consider company fit
- Factor in title/role
- Update scores regularly
6

Connect your Arcade MCP Gateway

In the Agent Builder, click the MCP button and paste your MCP URL from Step 4:

Enter MCP Gateway URL in LangSmith

Click Connect to initiate the OAuth flow:

Click Connect to authenticate

Click Allow to grant LangSmith access to your Arcade tools:

Allow access to Arcade tools
7

Select the tools for your agent

After connecting, click the Add tools button. Your gateway exposes only the specific tools you configured:

Hubspot.ListContacts
Hubspot.GetContactDataByKeywords
Hubspot.ListDeals
Hubspot.GetDealDataByKeywords
Hubspot.ListCompanies
Hubspot.GetCompanyDataByKeywords
GoogleSheets.GetSpreadsheet
GoogleSheets.UpdateCells
GoogleSheets.CreateSpreadsheet
Slack.SendMessage
Slack.ListConversations
Selecting Arcade tools in LangSmith Agent Builder
8

Start using your agent!

That's it! Your agent is now connected to Arcade's tools. Start chatting with your agent to test it out.

You're all set!

Try It: Example Prompt

Once your agent is set up, try this example prompt to test it:

Example Query
Analyze all leads that came in this week from HubSpot. Score them based on company size, title, and engagement (email opens, page visits, content downloads). Update the lead score field in HubSpot and alert #sales-team about any leads scoring above 80.

Best For

Marketing ManagersDemand GenMarketing Ops

Get access to Arcade, and start building now.