The HubSpot Agent CLI is a command-line tool that lets an AI agent read and change your HubSpot data from outside HubSpot, in Claude Code, Claude Cowork or Codex. It is built for unattended work: repetitive, bulk and scheduled jobs that a person would otherwise ask for in chat every week. It is still in beta in November 2026. Start it on read-only reports, sign in with OAuth so it acts with your own permissions, and run every write with --dry-run first.
--dry-run. Use it every time, and test destructive jobs in a sandbox.It is a single program, with no other software to install, that an AI agent runs from a terminal to work with your HubSpot account. HubSpot describes it as bringing HubSpot data into the environments where operations teams build their own automations, naming Codex, Claude Cowork and Claude Code. The agent discovers what it can do by calling --help at any level of the command tree, so nobody has to teach it the commands one by one.
What it can reach is broad. The object commands list, get, search, create, update, merge, upsert and delete contacts, companies, deals, tickets and custom objects. Other commands cover associations, pipelines, properties, owners, workflows, saved views, activities and call transcripts, reports, segments, conversations, sequences, imports, analytics, marketing forms and buyer intent. Bulk work runs by piping the results of one command into another, for example a search into an update.
HubSpot also publishes Agent CLI Skills, installed with npx skills add hubspot/agent-cli-skills. They give the agent ready instructions for jobs such as bulk operations, data-quality checks and record lookup.
The difference is who is watching. HubSpot positions its AI connectors for work where a person is talking to an agent: questions, analysis, campaign results. The Agent CLI is for work that happens in the background and is ready when you need it. Breeze agents run inside HubSpot on HubSpot's own infrastructure.
A workflow is different again. It follows a fixed path you build in advance: when a field changes, do this. An agent is told the outcome you want, such as "find the open deals that look stuck and tell me why", and works out the steps, including reading notes and activity that no workflow condition can interpret.
HubSpot's own framing is a useful test: take the questions you keep asking an assistant in chat, and the tasks you keep completing by hand, and automate those. If a job needs judgment every single time, keep a person in the conversation. If the same request comes up every Monday, it is a candidate for the Agent CLI.
The default sign-in, hubspot auth login, opens a browser and creates a token tied to that user's permissions. The agent then sees and changes only what that person could in the HubSpot interface, and its changes are recorded under that user. Some operations, including certain schema, relationship, activity and destructive actions, are not available with OAuth alone and need a service key.
A service key, set in the HUBSPOT_ACCESS_TOKEN variable, takes precedence over OAuth. HubSpot's documentation calls this admin mode: broader permissions and no per-user audit trail. Decide in advance which jobs justify a service key, give the key only the scopes those jobs need, and store it where only the agent's environment can read it.
Super Admins can control access through App Governance, under Settings > Integrations > Connected Apps > Approved apps, and users without install rights can request approval there. In Claude Team or Enterprise, an organization owner must also add api.hubapi.com to the allowed domains before the CLI can install or run in Cowork.
Write down which objects and properties each job may write to. A weekly report needs no write access at all. A clean-up job that sets one property on contacts needs that one property and nothing else. This list becomes the scope of the service key, if you use one, and the checklist for reviewing what the agent did.
Every scheduled job needs a named reader. A data-quality list nobody opens costs the same to run as one that gets acted on, and HubSpot's documentation does not mention usage limits for the CLI itself, so the discipline has to come from you.
Start with jobs that only read and report. They carry almost no risk, and they show quickly whether your data is clean enough to trust an agent with anything more. HubSpot's announcement uses the same three kinds of example.
Only after these run cleanly for a few weeks should the agent write. A good first write job is narrow and reversible, such as setting a single custom property on contacts that match a search.
For example, take a portal where marketing wants a Data review status property set to Needs owner on every contact with a lifecycle stage of Marketing qualified lead and no contact owner. The job runs every weekday at 7am in Cowork and goes in this order:
--dry-run and saves the preview, which shows each record and the value it would set.--dry-run, then searches again and reports how many records now carry the value.To check it, open a saved view of contacts where Data review status is Needs owner and compare the count with the agent's report. To roll it back, the same search piped into an update can clear the property, and because the job touches one custom property only, nothing else needs restoring. That is why the first write job should never merge or delete: merge folds a secondary record into a primary and deletes the secondary, and HubSpot's own documentation warns that write operations can permanently delete live data.
--dry-run and a record-count limit before every write, and the saved preview is kept with the run log.We use AI agents against HubSpot every day, including in our own portal, and the pattern holds: the agent is only as useful as the data it reads. So we follow the same order with every client. First the reports, which show where the data model is weak. Then the fixes to that data model, done by people. Only then narrow write jobs, each with a dry run, a record limit and a named reader.
We also keep OAuth as the default and treat a service key like a shared admin password: issued for a stated job, scoped to it, and reviewed when the job changes. The teams that get the most from the Agent CLI will not be the ones running the most jobs. They will be the ones whose portals are clean enough that a Monday report leads straight to action.
If you want a second opinion on whether your HubSpot is ready for an agent, book a 30-minute portal audit and we will go through your data model, permissions and the first jobs worth automating.
Not yet. As of November 2026 HubSpot's developer documentation still lists it as beta, and using it means accepting HubSpot's Developer Terms and Developer Beta Terms.
HubSpot names Codex, Claude Cowork and Claude Code. It installs with one command on macOS, Linux or Windows PowerShell, and an agent can install it in its own workspace.
Not when it signs in with OAuth. The token is scoped to the signed-in user's permissions, so the agent can do what that user can do in HubSpot and no more. A service key can reach further, which is why it should be reserved for jobs that need it.
Only partly, so plan for it. Property updates can be reversed by running a corrected update on the same records, which is easy when the job wrote one custom property. Merges and deletions are much harder to undo, so keep them out of automated jobs and test them in a sandbox.
Someone technical should set up the sign-in, the allowed domains and the job instructions once. After that, the jobs are written in plain language, and the agent works out the commands.