connect-hubspot-agent-cli
Install and connect HubSpot's Agent CLI so Claude Code can run bulk and administrative HubSpot operations directly from the terminal: JSONL bulk writes…
Skill by tomgranot
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/tomgranot-connect-hubspot-agent-cli
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: data, sales, productivity, agent-building
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/connect-hubspot-agent-cli
What's inside
- Skill name
connect-hubspot-agent-cli- Description
- Install and connect HubSpot's Agent CLI so Claude Code can run bulk and administrative HubSpot operations directly from the terminal: JSONL bulk writes, deletes, property and pipeline management, and workflow CRUD, with dry runs. Covers user versus service key mode, safe-use rules, and how the CLI fits beside MCP and this repo's scripts.
- License
- MIT
- Metadata
- author: tomgranot · version: 1.0 · category: audit-planning
- Instructions
- 161 lines in SKILL.md · view on GitHub
Before installing
- Instructions call the network
Files (1)
- SKILL.md
SKILL.md (first lines)
# Connect Claude Code to HubSpot via the Agent CLI HubSpot's Agent CLI is a command-line tool built for AI agents. Where the MCP server is for looking things up in conversation, the CLI is for doing administrative work: it reads and writes in bulk, deletes, manages properties and pipelines, and creates workflows. It is the most direct connection between Claude Code and a portal. ## Why This Matters Before the CLI, any HubSpot job that was too big for MCP needed a purpose-written script. That is still the right answer for work you repeat and need to audit. For the long tail of one-off administrative jobs (archive these 60 properties, re-label this association, upsert this file) a script is overhead, and the CLI fills the gap. **It is beta.** HubSpot states that commands, flags, and behavior may change without notice. Treat it as a power tool for supervised sessions, not as a dependency for anything scheduled. ## Where It Fits | | Agent CLI (this skill) | Remote MCP (`/connect-hubspot-mcp`) | REST scripts (scripted skills) | |---|---|---|---| | Status | Beta | Generally available | v3/v4 paths | | Delete and archive | Yes, guarded | No | Yes, guarded | | Workflows | List, get, create, update, delete | No | Create, export, restore | | Bulk input | JSONL on stdin | A few records at a time | Batches of 100 | | Audit trail | Local `history` log of destructive operations | None | CSV export before every mutation | | Abort threshold | None built in | Not applicable | Hard-coded per skill | | Use it for | One-off bulk and admin jobs, supervised | Lookups and spot-checks | Anything repeatable or destructive at scale | When a scripted skill exists for the job, prefer the skill. It was written with a threshold, an export, and a rollback note for that specific operation. Use the CLI when no skill covers the job, and apply the safe-use rules below yourself. ## Prerequisites - Claude Code, with permission to run shell commands - A HubSpot user whose permissions cover the work. The CLI is available on all HubSpot plans - Approval from a Super Admin if the portal restricts who can connect apps - On Claude Team or Enterprise, an admin may need to allowlist `api.hubapi.com` ## Execution Pattern ### Stage 1: Plan Decide which mode you need before installing: | Mode | How | Acts as | Use when | |------|-----|---------|----------| | User | `hubspot auth login` | You, with your HubSpot permissions | Almost always | | Admin | `HUBSPOT_ACCESS_TOKEN` set to a service key | The service key's scopes | Schema changes, association batch operations, and other calls that need account-level access | Start in user mode. It cannot exceed what you could do by hand in the UI. ### Stage 2: Execute 1. **Install.** Read the script before running it, as with any `curl | sh`: ```bash curl -fsSL https://api.hubapi.com/hub/cli/backend/hub-cli/latest/install.sh | sh ``` On Windows PowerShell: `irm https://api.hubapi.com/hub/cli/backend/hub-cli/latest/install.ps1 | iex` The binary is `hubspot`. It is separate from `hs`, HubSpot's developer CLI for building apps and CMS projects. 2. **Verify and sign in.** ```bash hubspot --version ``` ```bash hubspot auth login ``` The login opens a browser. Review the requested permissions and connect. 3. **Confirm which portal you are in.** ```bash hubspot whoami ``` Read the account name and ID back to the user and wait for them to confirm it is the intended portal. This matters most for anyone with access to more than one account. 4. **Optionally install HubSpot's own skills** for the CLI. They teach an agent the command surface and are complementary to this toolkit: ```bash npx skills add hubspot/agent-cli-skills ``` **Admin mode**, only when a command needs it: put a service key in the environment for that session and remove it afterward. ```bash export HUBSPOT_ACCESS_TOKEN=pat-na1-xxxxxxxx ``` ```bash unset HUBSPOT_ACCESS_TOKEN ``` This is the same variable this repo's scripts read from `.env`. If it is exported in your shell, the CLI silently runs in admin mode. Check `hubspot whoami` before any write. ### Stage 3: After Run a read and confirm the output matches the portal: ```bash hubspot owners list --format table ``` The owner names should be people the user recognizes. If they are not, you are in the wrong account: stop and sign in again. Before the first real write, run that command with `--dry-run` and read the preview together with the user, so the guard rails are familiar before they are needed. ## Command Surface | Group | Subcommands | |-------|-------------| | `objects` | `types`, `list`, `get`, `search`, `create`, `update`, `upsert`, `merge`, `delete` | | `properties` | `list`, `get`, `create`, `update`, `delete`, `batch-read`, `batch-create`, `batch-archive` | | `pipelines` | `list`, `get`, `create`, `update`, `delete`, plus `stages` variants | | `associations` | `list`, `create`, `delete`, batch variants, labels, limits | | `workflows` | `list`, `get`, `create`, `update`, `delete` | | `segments` (alias `lists`) | Segment and list management | | `schemas` | `list`, `get`, `create`, `update`, `delete` | | `owners` | `list` | | `views`, `reports`, `imports`, `query`, `sequences`, `marketing`, `conversations`, `analytics`, `buyer-intent` | See `hubspot help` |
From TomGranot/hubspot-admin-skills, MIT.
More from TomGranot/hubspot-admin-skills
- 0.675score
sandbox-self-test
tomgranot
Verify the entire toolkit against a disposable HubSpot developer test account or sandbox that you bring: seed synthetic fixtures, run every scripted skill's…
SkillAFreshness: A★ 77Claude Code +9 - 0.675score
hubspot-audit
tomgranot
Run a full, read-only HubSpot portal audit covering both the marketing and sales sides: database, deliverability, engagement, owners, pipelines, deal quality…
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
delete-no-email-contacts
tomgranot
Delete contacts with no email address from a HubSpot CRM instance.
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
suppress-global-unsubscribes
tomgranot
Identify and suppress globally unsubscribed contacts to ensure legal compliance and reduce billing.
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
new-contact-hygiene-workflow
tomgranot
Build a HubSpot workflow that auto-enriches and stages new contacts upon creation.
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
merge-duplicate-companies
tomgranot
Identify duplicate company records by domain and name, export audit CSVs for review, and guide merging.
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
bounce-monitoring-workflow
tomgranot
Build a workflow to protect sender reputation through automated bounce monitoring.
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
lifecycle-progression-workflow
tomgranot
Build workflows to automate contact progression through the sales funnel: Lead to MQL to SQL to Opportunity to Customer.
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
build-smart-lists
tomgranot
Create foundational segmented lists for marketing and sales operations via the Lists API, plus advanced UI-built segments: a master sendable list, ICP-based…
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
cleanup-deals
tomgranot
Find past-due, stale, incomplete, unexplained-loss, and likely test deals, then route each owner's flagged deals to them as one review task.
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
assign-unowned-contacts
tomgranot
Assign an owner to marketing contacts that have no owner.
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
create-icp-tiers
tomgranot
Classify companies into Ideal Customer Profile (ICP) tiers based on firmographic data (industry + employee count).
SkillAFreshness: A★ 77Claude Code +9
Signals
- Stars
- 77
- Forks
- 18
- Open issues
- 0
- Last commit (this folder)
- Oct 12, 2026 (16 days ago)
From GitHub (fetched Oct 24, 2026).
Details
- Version
- 1.0
- License
- MIT
- Website
- hubspot.granot.io
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from tomgranot
- 0.675score
hubspot-audit
tomgranot
Run a full, read-only HubSpot portal audit covering both the marketing and sales sides: database, deliverability, engagement, owners, pipelines, deal quality…
SkillAFreshness: A★ 77Claude Code +9 - 0.675score
sandbox-self-test
tomgranot
Verify the entire toolkit against a disposable HubSpot developer test account or sandbox that you bring: seed synthetic fixtures, run every scripted skill's…
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
merge-duplicate-companies
tomgranot
Identify duplicate company records by domain and name, export audit CSVs for review, and guide merging.
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
suppress-global-unsubscribes
tomgranot
Identify and suppress globally unsubscribed contacts to ensure legal compliance and reduce billing.
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
assign-unowned-contacts
tomgranot
Assign an owner to marketing contacts that have no owner.
SkillAFreshness: A★ 77Claude Code +9 - 0.672score
lifecycle-progression-workflow
tomgranot
Build workflows to automate contact progression through the sales funnel: Lead to MQL to SQL to Opportunity to Customer.
SkillAFreshness: A★ 77Claude Code +9
Cite this page
connect-hubspot-agent-cli skill. Agent Mart. https://agentmart.dev/skills/tomgranot-connect-hubspot-agent-cli (last updated 2026-10-24)