Directory Compare FCRS-1.0 /llms.txt
← Back to Directory

HubSpot CLI

$ hs Official Med Risk
HubSpot · Workspace & SaaS · Apache-2.0 · macos / linux / windows

HubSpot CLI (hs) connects local developer workflows to HubSpot CMS Hub themes, serverless functions, and developer projects. It supports multiple named accounts and sandboxes via hubspot.config.yml, though many commands target human terminal output rather than strict JSON.

FCRS-1.0 Score
79 /100
Good
Medium Confidence
Zero-Friction Install
npm install -g @hubspot/cli
CLI vs MCP Decision Hybrid (CLI + MCP)

Use hs CLI for HubSpot CMS file sync and hs project builds/deploys; use HubSpot MCP for conversational CRM object search and deal/contact inspection.

Agent-Readiness Checklist

— JSON Output
— Field Filtering
✓ Non-Interactive
— Dry-Run
— Read-Only Mode
— NO_COLOR Clean
✓ Self-Describing
— Official SKILL.md

Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.

FCRS-1.0 6-Dimension Breakdown

Agent-Readiness 18 / 25

Supports --account and CI env vars, but lacks universal --json output across cms and project subcommands.

  • Human-formatted logs/tables are the default output
  • Init and auth flows default to interactive prompts unless env vars are configured
Trust & Safety 19 / 25

Explicit --account selection and personal access keys isolate portals, though cms delete is destructive.

  • Named account profiles in hubspot.config.yml separate sandbox vs prod
  • Environment-variable auth avoids storing keys in repo files
Setup & Portability 13 / 15

Standard Node.js package installable globally or via npx @hubspot/cli across all major OSes.

  • Published on npm as @hubspot/cli
Utility & Efficiency 12 / 15

Solid for HubSpot CMS themes and projects, though CRM object CRUD is outside its scope.

  • Focused on CMS Hub assets, HubDB, and Developer Projects
Maintenance & Lineage 9 / 10

Official HubSpot tool (HubSpot/hubspot-cli) actively maintained under Apache-2.0.

  • Official HubSpot GitHub repository
Docs & Verifiability 8 / 10

Well-documented CMS and Developer Projects CLI guides in HubSpot Developer Docs.

  • Official reference on developers.hubspot.com

Security, Auth & Guardrails

Auth Modes
Env API Key Config File
Credential Storage

Stores personal access keys and portal IDs in hubspot.config.yml or reads HUBSPOT_PERSONAL_ACCESS_KEY / HUBSPOT_PORTAL_ID environment variables.

Side Effects
Read-Only Local Write Remote Write Destructive
Cost & Quotas

CLI is free (Apache-2.0); HubSpot Developer Sandbox accounts are free for testing.

Copyable Guardrail for CLAUDE.md / AGENTS.md
# HubSpot CLI Agent Rules
- Always pass `--account=<sandbox>` explicitly so operations never default to a production portal.
- Never run `hs cms delete` or `hs filemanager delete` without explicit human confirmation.
- Keep `hubspot.config.yml` out of version control and prefer `HUBSPOT_PERSONAL_ACCESS_KEY` in CI.

Agent-Ready Command Recipes

Safe Read-Only Queries

List configured HubSpot accounts
hs account list

Displays configured portal IDs, account names, and default account settings from hubspot.config.yml.

List CMS files in a sandbox portal
hs cms list --account=sandbox

Lists remote Design Manager paths inside the named sandbox account without modifying files.

Controlled Writes & Previews

Upload project build to sandbox
hs project upload --account=sandbox

Uploads a HubSpot Developer Project to the designated sandbox portal for preview.

Strengths for Agents

  • + Multi-account configuration (--account) makes targeting HubSpot developer sandboxes straightforward.
  • + Clean CI support via HUBSPOT_PERSONAL_ACCESS_KEY and HUBSPOT_PORTAL_ID.
  • + Direct integration with HubSpot Developer Projects and CMS Design Manager.

Caveats & Pitfalls

  • ! Lacks universal --json output across most subcommands, requiring text parsing by agents.
  • ! Scoped to CMS/developer projects rather than general CRM contact or deal queries.

Tested Agent Hosts

Claude Code Codex CLI Gemini CLI