How to Build a Claude Code Sales Agent in 2026 (Step-by-Step)
By Kushal Magar · April 25, 2026 · 15 min read
Key Takeaway
A Claude Code sales agent automates the full outbound loop — prospect research, personalized email generation, CRM updates, and follow-up sequences — at a fraction of the cost of AI SDR tools. The key is pairing Claude Code's reasoning with SyncGTM's verified enrichment data pipeline so the agent always has accurate prospect context to work with.
In 2026, the most productive sales teams are not hiring more SDRs. They are building Claude Code sales agents — autonomous pipelines that research prospects, write personalized emails, update the CRM, and manage follow-up sequences without anyone babysitting each step.
This guide shows you exactly how to build one. You will get the full architecture: prospect research via SyncGTM’s enrichment pipeline, AI-powered email personalization at scale, automated CRM writes, and multi-touch follow-up sequences. By the end, you will have a working claude code sales agent you own and can customize.
This is not a theoretical overview. Every step includes the actual prompt patterns, MCP tool connections, and skill files you need to deploy.
How do you build a Claude Code sales agent?
Install Claude Code, connect it to your CRM via MCP, wire SyncGTM as the enrichment data source, then define four skill files: prospect-research.skill, email-writer.skill, crm-updater.skill, and follow-up-sequencer.skill. The agent loops through these skills autonomously for each prospect in your target list, requiring no manual input between steps.
TL;DR
- Claude Code sales agents run four core tasks autonomously: prospect research, email personalization, CRM updates, and follow-up sequencing.
- SyncGTM is the data layer. Waterfall enrichment across 20+ providers gives the agent verified emails, phone numbers, and firmographics for every prospect.
- MCP connects Claude Code to your CRM. One registration gives live read/write access to HubSpot or Salesforce — no API wrappers, no middleware.
- Skills define the agent’s behavior. Each task is a
.skillfile Claude Code executes in sequence. - Running cost is $50–100/month for 500 prospects/week — 80–90% less than hosted AI SDR tools at comparable output.
- Claude Managed Agents (launched April 2026) are an alternative for always-on deployments, but Claude Code is more cost-effective for batch workflows.
What Is a Claude Code Sales Agent?
A Claude Code sales agent is an autonomous AI agent built on Anthropic’s Claude Code platform that executes end-to-end sales development tasks without human intervention at each step.
Unlike a chatbot that answers questions, a Claude Code agent takes action. It reads prospect data, reasons about what to write, calls external tools, writes to your CRM, and hands off to the next step in the sequence — all in one session.
The key components of a sales agent built on Claude Code are:
- Skills — reusable
.skillfiles that define what the agent does at each step (research, write, update, sequence) - MCP tools — live connections to HubSpot, Salesforce, Gmail, or Slack via the Model Context Protocol
- Enrichment pipeline — a data source like SyncGTM that gives the agent verified, up-to-date prospect information to work with
- Memory — context the agent carries across sessions (prospect history, email threads, CRM state)
For a broader view of how GTM teams are already using Claude Code for revenue workflows, see How GTM Teams Use Claude Code: 6 Workflows That Replace Manual Ops.
Why Build Your Own Instead of Buying an AI SDR
Building a Claude Code sales agent costs 85–95% less than buying a hosted AI SDR tool and gives you full control over the logic, data, and integrations.
Hosted AI SDR tools like Artisan (Ava), 11x (Alice), and Salesforge Agent Frank charge $2,000–$5,000/month for a fixed-function agent on top of generic LLM calls. They work. But they are rigid, expensive, and impossible to adapt to your ICP.
A Claude Code sales agent runs at $140–300/month for the same 2,000 prospects/month output. Here is the direct comparison:
| Dimension | AI SDR tools (Artisan, 11x) | Claude Code sales agent |
|---|---|---|
| Monthly cost (500 prospects/wk) | $2,000–$5,000 | $50–$100 |
| Customization | Limited (UI settings only) | Full (skill files, prompts, tools) |
| Data integration | Vendor’s built-in sources | Any MCP tool + SyncGTM waterfall |
| ICP signal tuning | Platform-defined signals | Your buying signals (hiring, tech, funding) |
| Setup time | 1–2 days | 1–2 weeks (initial build) |
| Vendor lock-in | High | None — you own everything |
For teams with a GTM engineer or technical founder, building the agent in-house is almost always the right call. For teams with no technical capacity, start with a hosted AI SDR tool and migrate when you have the bandwidth.
See also: 7 Best GTM Agent Platforms in 2026 if you want to compare hosted options before committing to a custom build.
Prerequisites
Before building, confirm you have the following in place:
- Claude Code installed:
npm install -g @anthropic-ai/claude-code - Anthropic API key — from console.anthropic.com, set as
ANTHROPIC_API_KEY - SyncGTM account — for waterfall prospect enrichment (verified emails, phone numbers, firmographics)
- CRM access — HubSpot or Salesforce with API access enabled
- Composio account — for managed MCP server connections to your CRM and Gmail (free tier available)
- Node.js 18+ and Python 3.9+ for helper scripts
If you are new to building Claude Code workflows for GTM, the 7 Best Claude Code GTM Skills guide covers the core skill patterns you will use throughout this build.
Step 1: Prospect Research with SyncGTM + Claude Code
Prospect research is the highest-leverage task to automate first. Every downstream step — personalization, CRM entry, follow-up — depends on having accurate data about each contact. Get this wrong and the agent produces generic emails that do not convert.
1a. Enrich your prospect list with SyncGTM
Start with a raw list of target companies or LinkedIn URLs. Feed it into SyncGTM’s waterfall enrichment workflow. SyncGTM runs each prospect through 20+ data providers in sequence — FullEnrich, FindyMail, Datagma, Apollo — returning the best verified data at the lowest credit cost.
The enriched output for each prospect includes:
- Verified business email (85%+ hit rate)
- Direct phone number
- Current job title and seniority
- LinkedIn profile URL
- Company headcount, industry, tech stack, funding stage
- Buying signals: recent hires, job postings, funding announcements, news
1b. Write the prospect-research skill
Create a file at skills/prospect-research.skill:
# prospect-research.skill
## Goal
For each prospect in the input CSV, read their SyncGTM enrichment data and
produce a structured prospect brief that the email-writer skill can use.
## Input
CSV with columns: first_name, last_name, email, company, title,
linkedin_url, headcount, tech_stack, recent_signals
## Output per prospect
{
"name": "First Last",
"company": "Acme Corp",
"title": "VP of Sales",
"pain_hypothesis": "one sentence about likely pain based on tech stack and signals",
"signal_hook": "the most relevant recent signal to reference in email",
"personalisation_angle": "specific angle for outreach based on company context"
}
## Rules
- Prioritize recent signals (job postings, funding, news) as the email hook
- pain_hypothesis must reference a specific tool or process visible in the data
- Never invent data not present in the enrichment output1c. Run the research skill
claude --skill skills/prospect-research.skill --input prospects-enriched.csv --output prospect-briefs.jsonClaude Code reads every row, applies the skill logic, and outputs a JSON array of prospect briefs. This file feeds directly into Step 2.
Step 2: AI-Powered Email Personalization at Scale
The email-writer skill takes each prospect brief from Step 1 and generates a personalized first-touch email. The goal is an email that reads like it was written by a rep who spent 10 minutes researching the prospect — not a mail merge.
The email-writer skill
Create skills/email-writer.skill:
# email-writer.skill
## Goal
Write a personalized cold email for each prospect using their brief.
## Input
Prospect brief JSON from prospect-research skill.
## Output
{
"subject": "concise subject under 50 chars referencing the signal hook",
"body": "3-paragraph email body, plain text",
"cta": "single low-friction CTA (15-min call, specific question)"
}
## Email structure
Para 1 (hook): Reference the specific signal or context from signal_hook.
Max 2 sentences. Do not mention your product.
Para 2 (pain + bridge): Name the pain_hypothesis. Connect it to how
SyncGTM solves it specifically. One concrete example or metric.
Para 3 (CTA): Single low-friction ask. Never ask for a demo on first touch.
Use: "Worth a 15-minute call?" or "Open to a quick example?"
## Rules
- Subject line: no emojis, no "Quick question", no "Following up"
- Never start with "I hope this finds you well"
- Maximum 120 words in the body
- Tone: direct, peer-to-peer, not vendor-to-buyerRun the email writer
claude --skill skills/email-writer.skill --input prospect-briefs.json --output emails-draft.jsonClaude Code generates one complete email object per prospect. At 50 prospects, this runs in under 3 minutes. Review a sample (5–10 emails) before sending to confirm tone and accuracy.
For teams that want to go deeper on email writing patterns, the guide to using AI to personalize cold emails in 2026 covers the prompting approaches that produce the highest reply rates.
Step 3: Automated CRM Updates
Once emails are drafted, the agent writes every prospect into your CRM — creating contact and deal records, logging the draft email as an activity, and setting the next follow-up task. No rep needs to touch the CRM until a prospect replies.
Connect Claude Code to your CRM via MCP
Register a HubSpot or Salesforce MCP server using Composio’s managed MCP layer:
# Register HubSpot MCP server
claude mcp add --transport http hubspot-composio "YOUR_COMPOSIO_MCP_URL"
# Verify connection
claude mcp listThe crm-updater skill
Create skills/crm-updater.skill:
# crm-updater.skill
## Goal
For each prospect in emails-draft.json, create or update CRM records
and log the outreach activity.
## Operations
1. Search CRM for existing contact by email address
2. If not found: create contact with all enriched fields
3. Create deal record linked to contact (stage: "Email Sent", pipeline: "Outbound")
4. Log activity: type "Email", outcome "Sent", body = email subject + preview
5. Create follow-up task: due 3 business days from today, owner = current user
6. Add tag "claude-agent-outreach" to contact for tracking
## CRM fields to populate
Contact: first_name, last_name, email, phone, title, company, linkedin_url
Company: name, industry, employee_count, tech_stack (custom field)
Deal: deal_name = "{company} — Outbound Q2 2026", amount = blank
## Error handling
If contact creation fails: log error to errors.log, skip to next prospectRun the CRM updater
claude --skill skills/crm-updater.skill --input emails-draft.json --mcp hubspot-composioClaude Code makes the MCP calls to create records and log activities. For 50 prospects, this typically completes in 4–6 minutes including rate limit pauses.
For a full breakdown of how CRM automation workflows reduce admin time across your revenue stack, see the guide to CRM automation workflows that eliminate busywork.
Step 4: Follow-Up Sequences That Run on Autopilot
Most replies come after the third or fourth touchpoint. A Claude Code sales agent handles the full follow-up sequence without requiring a rep to remember who needs a bump.
The follow-up sequence architecture
The agent runs on a scheduled basis (daily or every 2 days) and checks the CRM for contacts whose follow-up task is due. For each, it generates the appropriate touchpoint based on where they are in the sequence:
| Touch | Day | Channel | Angle |
|---|---|---|---|
| 1 | 0 | Signal hook + SyncGTM pitch | |
| 2 | 3 | Email reply | Add a relevant case study or data point |
| 3 | 7 | LinkedIn DM | Short note referencing shared context |
| 4 | 14 | Break-up email — permission to close |
The follow-up-sequencer skill
# follow-up-sequencer.skill
## Goal
Check CRM for contacts with overdue follow-up tasks. Generate and
queue the appropriate touchpoint for each contact based on their
sequence position.
## Steps
1. Query CRM for all contacts tagged "claude-agent-outreach" where
next follow-up task is due today or earlier
2. For each contact, determine sequence position (count past activities)
3. Read past email thread from CRM to avoid repetition
4. Generate the appropriate touchpoint (email or LinkedIn DM copy)
5. Queue the email via Gmail MCP (draft, don't send auto — requires human review)
6. Update CRM: log activity, create next follow-up task (+3 or +7 days)
## Human review gate
Always create drafts. Never send automatically.
Flag contacts with email opens (if tracking is available) as priority.Human review gate
Always set the follow-up sequencer to create email drafts, not send automatically. A 2-minute human review of each draft catches hallucinations, awkward phrasing, or context errors before they hit a real prospect’s inbox. The time saved on research and writing far exceeds the review time.
Step 5: Wire the Full SyncGTM Data Pipeline
The four skills above are connected by a master orchestrator script — a shell or Python file that runs them in sequence and passes outputs between steps.
The full pipeline flow
#!/bin/bash
# sales-agent-pipeline.sh
# 1. Export target prospects from CRM (or load from CSV)
echo "Loading prospect list..."
INPUT="targets.csv"
# 2. Enrich with SyncGTM (run via SyncGTM API or CSV upload)
echo "Enriching with SyncGTM waterfall..."
# SyncGTM enrichment returns: prospects-enriched.csv
ENRICHED="prospects-enriched.csv"
# 3. Run prospect research skill
echo "Running prospect research..."
claude --skill skills/prospect-research.skill --input $ENRICHED --output prospect-briefs.json
# 4. Generate personalized emails
echo "Writing personalized emails..."
claude --skill skills/email-writer.skill --input prospect-briefs.json --output emails-draft.json
# 5. Update CRM records
echo "Updating CRM..."
claude --skill skills/crm-updater.skill --input emails-draft.json --mcp hubspot-composio
echo "Pipeline complete. Review emails-draft.json before sending."Run this script weekly or when you load a new batch of targets. The full pipeline for 50 prospects takes roughly 15–25 minutes end-to-end including enrichment.
The follow-up sequencer runs on its own daily cron job, independent of the main pipeline:
# Add to crontab — runs every weekday at 7am
0 7 * * 1-5 claude --skill skills/follow-up-sequencer.skill --mcp hubspot-composioFor teams connecting SyncGTM directly to their GTM stack, the SyncGTM + OpenAI integration shows how to layer additional AI personalization on top of enriched prospect data.
Agent Architecture: Skills, Memory, and Tools
A production Claude Code sales agent needs more than four skill files. Here is the full architecture recommended for a team running 200+ prospects per week.
Directory structure
sales-agent/
├── skills/
│ ├── prospect-research.skill
│ ├── email-writer.skill
│ ├── crm-updater.skill
│ └── follow-up-sequencer.skill
├── prompts/
│ ├── icp-definition.md # Your ICP: company size, signals, exclusions
│ ├── brand-voice.md # Tone, vocabulary, sentences to avoid
│ └── objection-handlers.md # Common objections + approved responses
├── memory/
│ ├── sent-emails.jsonl # Log of all outreach for dedup
│ └── reply-history.jsonl # Tracked replies for context
├── scripts/
│ ├── sales-agent-pipeline.sh
│ └── enrichment-prep.py # Normalize SyncGTM CSV output
└── .env # ANTHROPIC_API_KEY, CRM credentialsMCP tools to register
| Tool | MCP server | Used in skill |
|---|---|---|
| HubSpot or Salesforce | Composio managed MCP | crm-updater, follow-up-sequencer |
| Gmail | Composio Gmail MCP | follow-up-sequencer (draft only) |
| Slack | Composio Slack MCP | Pipeline alerts (optional) |
| Web search | Brave Search MCP | prospect-research (news lookup) |
For the full list of GTM-ready MCP servers that work with Claude Code, see Top 7 GTM MCPs That Actually Work with Claude Code in 2026.
What It Costs to Run a Claude Code Sales Agent
Running a Claude Code sales agent for 2,000 prospects per month costs approximately $140–$300/month in total — compared to $2,000–$5,000/month for hosted AI SDR tools at the same volume. Token rates are based on Anthropic’s published API pricing.
| Cost component | Estimate (2,000 prospects/mo) |
|---|---|
| Claude API (Sonnet 4.5) | $40–$80 |
| SyncGTM enrichment credits | $60–$120 (varies by plan) |
| Composio MCP (CRM + Gmail) | $19–$49 (starter plan) |
| CRM plan (HubSpot Starter) | $20–$50 |
| Total (approx.) | $140–$300/month |
Compare that to Artisan (Ava) at $2,500–$5,000/month or 11x at similar rates for the same 2,000 prospects. The Claude Code agent is 85–95% cheaper — and fully customizable.
Token costs drop significantly if you use Claude Haiku for high-volume, structured tasks (like CRM field extraction) and reserve Sonnet for email writing where quality matters most.
Limitations and When to Use a Managed Agent Instead
A Claude Code sales agent is not the right tool for every team. Know the constraints before committing to the build.
- Requires technical setup: You need a developer or GTM engineer to build and maintain the skill files, MCP connections, and orchestration scripts. If your team has no technical capacity, start with a hosted AI SDR tool.
- No built-in sending infrastructure: Claude Code drafts emails but does not send them. You need a separate cold email tool (Instantly, Smartlead, Lemlist) for deliverability, warm-up, and inbox rotation.
- Batch-oriented, not real-time: Claude Code runs when you execute it. For always-on inbound response or real-time triggers (web visit, form fill), Claude Managed Agents (launched April 2026) are better suited — they run cloud-hosted sessions at $0.08/hour with 24/7 uptime.
- Hallucination risk on research: The agent can invent prospect details if the enrichment data is sparse. Always set the research skill to surface data gaps rather than fill them with inference.
- No multi-agent coordination out of the box: If you need agents talking to each other (e.g., a research agent routing to a writing agent routing to a review agent), that requires the agentic AI architecture that Claude Managed Agents’ multi-agent coordination feature supports.
Conclusion
A Claude Code sales agent is the highest-leverage automation a B2B sales team can build in 2026. For $140–300/month in total running costs, you get a system that researches prospects, writes personalized emails, updates your CRM, and manages follow-up sequences — autonomously and at scale.
The foundation is the data pipeline. Without verified, enriched prospect data, the agent produces generic outreach. With SyncGTM’s waterfall enrichment — pulling verified emails, phone numbers, and buying signals from 20+ providers — the agent has the context it needs to personalize at a level that actually converts.
Build the four core skills (prospect research, email writer, CRM updater, follow-up sequencer), wire the MCP tools, connect SyncGTM as the data layer, and you have a working agent by the end of the week. Review the email drafts before sending, monitor reply rates by sequence position, and iterate the skill prompts based on what converts.
Start with 50 prospects. Validate the output quality. Then scale to 500.
See also: Top 7 AI Outbound Tools That Actually Book Meetings in 2026 to see what sending infrastructure works best alongside a Claude Code agent.
