# Hubspot CLI

Hubspot resources through the cmdhub CLI.

## Install

```bash
cmdhub get hubspot
```

## Authentication

oauth

## Agent-Readable Catalog

- Machine-readable command catalog: `/cli/hubspot/catalog.json`
- Stable command anchors use the `cmd-...` IDs listed under each command.
- Inspect this catalog before planning tool use for command paths, examples, flags, mutation markers, and dry-run support.

## Overview

```bash
# Inspect auth state and available command schemas
hubspot auth status --json
hubspot schema
```

## CLI Overview

Authenticated HubSpot CRM work from the terminal

Authenticated HubSpot CRM work for contacts, companies, deals, tickets, notes, associations, owners, pipelines, and properties.

Start here:
  hubspot auth status
  hubspot contact search --query "<text>"
  hubspot contact get ct1 --view full

CRM records:
  contact, company, deal, ticket, note
CRM metadata:
  owner, pipeline, property
Relationships and cleanup:
  association, cleanup
Shared commands:
  auth, profile, doctor, capabilities, schema, resolve, version

Safety:
  Deletes, association removal, and cleanup require --dry-run or --yes. Human output uses local refs; JSON and JSONL preserve exact HubSpot IDs, URLs, and cursors.

## Generated Coverage

- Command groups: `18`
- Total documented command nodes: `87`
- Live examples: `3`
- Lifecycle surfaces: `auth`, `doctor`, `capabilities`, `schema`, `resolve`, `version`
- Machine-readable output: `--json`, `--jsonl`
- Human views: `summary`, `full`

## Auth Contract

- Auth mode: oauth
- Standard commands: `auth login`, `auth logout`, `auth refresh`, `auth status`, `auth whoami`
- `auth status --json` reports `tool`, `profile`, `provider`, `authenticated`, and `suggested_next_step`.
- `auth whoami --json` is the stable way to answer identity questions.

## Agent Safety Notes

- Discovery commands such as `list`, `search`, `get`, `resolve`, `schema`, `doctor`, `capabilities`, `status`, and `whoami` are the safest commands to run first.
- Treat commands marked as mutating as state-changing local or provider operations.
- Mutating command paths: `hubspot association add`, `hubspot association remove`, `hubspot auth login`, `hubspot auth logout`, `hubspot auth refresh`, `hubspot company create`, `hubspot company delete`, `hubspot company update`, `hubspot contact create`, `hubspot contact delete`, `hubspot contact update`, `hubspot deal create`, `hubspot deal delete`, `hubspot deal update`, `hubspot note create`, `hubspot note delete`, `hubspot note pin`, `hubspot note unpin`, `hubspot note update`, `hubspot profile create`, `hubspot profile delete`, `hubspot profile use`, `hubspot ticket create`, `hubspot ticket delete`, `hubspot ticket update`
- Commands with `--dry-run`: `hubspot association remove`, `hubspot company delete`, `hubspot contact delete`, `hubspot deal delete`, `hubspot note delete`, `hubspot ticket delete`

## Global Flags

- `--json` (bool): Emit JSON machine output
- `--jsonl` (bool): Emit JSONL records for piping
- `--output` (string): Compatibility output mode: json|jsonl. Prefer --json or --jsonl
- `--view` (string): View mode: summary|full Default: `summary`.
- `--profile` (string): Config/auth profile Default: `default`.
- `--config` (string): Config path override
- `--quiet` (bool): Suppress non-essential diagnostics
- `--debug` (bool): Enable debug diagnostics
- `--limit` (int): Maximum items to emit Default: `50`.
- `--page-size` (int): Requested upstream page size Default: `50`.
- `--cursor` (string): Continuation cursor
- `--no-paginate` (bool): Fetch only one page
- `--version` (bool): Print version information

## Command Reference

### `hubspot association`

- Anchor: `cmd-hubspot-association`
- Mutates state: `no`
- Supports dry run: `no`

Manage exact HubSpot CRM associations

Manage relationships between exact HubSpot CRM records.

Workflow:
  find both records, inspect association types when needed, add an exact relationship, or preview removal before confirming.

Selectors and filters:
  --from and --to use object:ref selectors such as contact:ct1 and company:co1. types uses --from <object> --to <object>.

Output:
  Human output uses local CRM refs. JSON and JSONL preserve exact HubSpot IDs and association type IDs.

Safety:
  association remove requires --dry-run or --yes. Records are not deleted when an association is removed.

Example:

```bash
hubspot association types --from contact --to company
  hubspot association add --from contact:ct1 --to company:co1 --label "Decision maker"
  hubspot association remove --from contact:ct1 --to company:co1 --dry-run
```

#### `hubspot association add`

- Anchor: `cmd-hubspot-association-add`
- Mutates state: `yes`
- Supports dry run: `no`

Associate two exact HubSpot CRM records

Example:

```bash
hubspot association add --from contact:ct1 --to company:co1
hubspot association add --help
hubspot association types --from contact --to company
```

Flags:

- `--from` (string): Source object type or object:ref, such as contact or contact:ct1
- `--label` (string): Association type ID from association types; omitted uses HubSpot default for the pair
- `--to` (string): Target object type or object:ref, such as company or company:co1

#### `hubspot association list`

- Anchor: `cmd-hubspot-association-list`
- Mutates state: `no`
- Supports dry run: `no`

List HubSpot associations from an exact record

Example:

```bash
hubspot association list
hubspot association list --from contact:ct1 --to company
hubspot contact search --query ada
```

Flags:

- `--from` (string): Source object type or object:ref, such as contact or contact:ct1
- `--to` (string): Target object type or object:ref, such as company or company:co1

#### `hubspot association remove`

- Anchor: `cmd-hubspot-association-remove`
- Mutates state: `yes`
- Supports dry run: `yes`

Remove an exact HubSpot CRM association

Example:

```bash
hubspot association remove --from contact:ct1 --to company:co1 --dry-run
hubspot association remove --from contact:ct1 --to company:co1 --yes
hubspot association remove --help
hubspot association remove a1 --dry-run
```

Flags:

- `--dry-run` (bool): Preview the exact association removal without mutating HubSpot
- `--from` (string): Source object type or object:ref, such as contact or contact:ct1
- `--to` (string): Target object type or object:ref, such as company or company:co1
- `--yes` (bool): Confirm removal of the exact association

#### `hubspot association types`

- Anchor: `cmd-hubspot-association-types`
- Mutates state: `no`
- Supports dry run: `no`

List HubSpot association labels

Example:

```bash
hubspot association types
hubspot association types --from contact --to company
```

Flags:

- `--from` (string): Source object type or object:ref, such as contact or contact:ct1
- `--to` (string): Target object type or object:ref, such as company or company:co1

### `hubspot auth`

- Anchor: `cmd-hubspot-auth`
- Mutates state: `no`
- Supports dry run: `no`

Manage HubSpot authentication

Example:

```bash
hubspot auth --help
```

#### `hubspot auth login`

- Anchor: `cmd-hubspot-auth-login`
- Mutates state: `yes`
- Supports dry run: `no`

Authenticate with a HubSpot OAuth grant

Starts HubSpot OAuth login for a HubSpot OAuth access token and refresh token through the cmdhub website broker. Normal users do not need a HubSpot OAuth client ID or client secret.

Example:

```bash
hubspot auth login
hubspot auth login --help
hubspot auth status
```

#### `hubspot auth logout`

- Anchor: `cmd-hubspot-auth-logout`
- Mutates state: `yes`
- Supports dry run: `no`

Remove stored HubSpot OAuth credentials

Deletes the selected profile's HubSpot OAuth access token and refresh token from the shared credential backend.

Example:

```bash
hubspot auth login
hubspot auth logout
hubspot auth logout --help
```

#### `hubspot auth refresh`

- Anchor: `cmd-hubspot-auth-refresh`
- Mutates state: `yes`
- Supports dry run: `no`

Refresh the stored HubSpot OAuth access token

Refreshes the selected profile's HubSpot OAuth access token using maintainer OAuth app credentials when configured; otherwise rerun hubspot auth login to renew through the broker.

Example:

```bash
hubspot auth refresh
hubspot auth refresh --help
hubspot auth status
```

#### `hubspot auth status`

- Anchor: `cmd-hubspot-auth-status`
- Mutates state: `no`
- Supports dry run: `no`

Show HubSpot OAuth auth status

Reports whether the selected profile has a stored HubSpot OAuth access token and refresh token, whether the access token is valid, and whether required HubSpot OAuth scopes are present.

Example:

```bash
hubspot auth status
hubspot auth status --help
hubspot auth status --json
```

#### `hubspot auth whoami`

- Anchor: `cmd-hubspot-auth-whoami`
- Mutates state: `no`
- Supports dry run: `no`

Show the current HubSpot user and portal

Verifies the stored HubSpot OAuth access token and shows the configured HubSpot user and portal.

Example:

```bash
hubspot auth whoami
hubspot auth whoami --help
hubspot auth whoami --json
```

### `hubspot capabilities`

- Anchor: `cmd-hubspot-capabilities`
- Mutates state: `no`
- Supports dry run: `no`

Describe capabilities

Example:

```bash
hubspot capabilities --help
```

Flags:

- `--section` (string): Show one capability section: scopes, schemas, or commands

### `hubspot cleanup`

- Anchor: `cmd-hubspot-cleanup`
- Mutates state: `no`
- Supports dry run: `no`

Plan, run, and verify bounded cleanup of disposable HubSpot CRM data

Plan, run, and verify bounded cleanup of disposable cmdhub HubSpot CRM data.

Workflow:
  create a cleanup manifest from a cmdhub-* token, review the manifest, run deletion with --yes, then verify the token is gone.

Selectors and filters:
  --token must start with cmdhub- or cmdhub-eval-. --objects bounds cleanup to contacts, companies, deals, tickets, and notes.
  --manifest selects the generated cleanup manifest for run and verify.

Output:
  Human output summarizes the manifest, refs, deleted records, and verification status. JSON preserves exact HubSpot IDs and URLs.

Safety:
  cleanup run requires --yes and only operates on records selected by a bounded manifest.

Example:

```bash
hubspot cleanup plan --token cmdhub-eval-20260607 --objects contacts,companies,deals,tickets,notes
  hubspot cleanup run --manifest lifecycle/live/cleanup-cmdhub-eval-20260607.json --yes
  hubspot cleanup verify --token cmdhub-eval-20260607
```

#### `hubspot cleanup plan`

- Anchor: `cmd-hubspot-cleanup-plan`
- Mutates state: `no`
- Supports dry run: `no`

Preview disposable cmdhub CRM records and write a cleanup manifest

Example:

```bash
hubspot cleanup plan
hubspot cleanup plan --token cmdhub-eval-20260607 --objects contacts,companies
```

Flags:

- `--manifest` (string): Cleanup manifest path; defaults under apps/hubspot-cli/lifecycle/live
- `--objects` (string): Comma-separated object set: contacts, companies, deals, tickets, notes
- `--token` (string): Disposable cmdhub-* token to search for

#### `hubspot cleanup run`

- Anchor: `cmd-hubspot-cleanup-run`
- Mutates state: `no`
- Supports dry run: `no`

Delete only records listed in a cleanup manifest

Example:

```bash
hubspot cleanup run --help
hubspot cleanup run --manifest apps/hubspot-cli/lifecycle/live/cleanup-cmdhub-eval-20260607.json --yes
```

Flags:

- `--manifest` (string): Cleanup manifest path from cleanup plan
- `--yes` (bool): Confirm deletion of only records listed in the manifest

#### `hubspot cleanup verify`

- Anchor: `cmd-hubspot-cleanup-verify`
- Mutates state: `no`
- Supports dry run: `no`

Verify disposable cmdhub CRM records are gone

Example:

```bash
hubspot cleanup verify
hubspot cleanup verify --token cmdhub-eval-20260607 --objects contacts,companies
```

Flags:

- `--manifest` (string): Cleanup manifest path to verify
- `--objects` (string): Comma-separated object set: contacts, companies, deals, tickets, notes
- `--token` (string): Disposable cmdhub-* token to search for

### `hubspot company`

- Anchor: `cmd-hubspot-company`
- Mutates state: `no`
- Supports dry run: `no`

Work with HubSpot company records

Work with HubSpot company records.

Actions:
  list, search, get, create, update, upsert, delete, restore

Workflow:
  search or list records, inspect the selected local ref, then run exact create, update, move, delete, or restore commands.

Selectors and filters:
  get, update, delete, and restore accept local refs like co1, HubSpot record IDs, and exact unique values when available.
  Useful filters include --query, --owner, --created-after, --updated-after, --archived, and --property name=value.
  company records commonly use --domain as their unique selector.

Output:
  Human output uses local refs and hides long HubSpot IDs. Use --json or --jsonl for exact IDs, URLs, properties, cursors, and associations.

Safety:
  delete requires --dry-run or --yes. Use restore for records recoverable from the HubSpot recycle bin.

Example:

```bash
hubspot company search --query cmdhub --limit 5
  hubspot company get co1 --view full
  hubspot company create --name "Cmdhub Eval" --domain example.invalid
  hubspot company search --query cmdhub --limit 5
  hubspot company update co1 --property lifecyclestage=customer
  hubspot company delete co1 --dry-run
```

#### `hubspot company create`

- Anchor: `cmd-hubspot-company-create`
- Mutates state: `yes`
- Supports dry run: `no`

Create a HubSpot company

Example:

```bash
hubspot company create --help
hubspot company create --name "Cmdhub Eval" --domain example.invalid
```

Flags:

- `--city` (string): Company city
- `--country` (string): Company country
- `--domain` (string): Company domain
- `--industry` (string): Company industry
- `--lifecycle-stage` (string): Company lifecycle stage
- `--name` (string): Company name
- `--owner` (string): HubSpot owner ID or ref
- `--property` (stringArray): Additional HubSpot property as name=value

#### `hubspot company delete`

- Anchor: `cmd-hubspot-company-delete`
- Mutates state: `yes`
- Supports dry run: `yes`

Delete an exact HubSpot company

Example:

```bash
hubspot company delete --help
hubspot company delete co1 --dry-run
hubspot company delete co1 --yes
hubspot company search --query cmdhub-eval --limit 5
```

Flags:

- `--dry-run` (bool): Preview the exact delete without mutating HubSpot
- `--yes` (bool): Confirm deletion of the exact displayed record

#### `hubspot company get`

- Anchor: `cmd-hubspot-company-get`
- Mutates state: `no`
- Supports dry run: `no`

Inspect a HubSpot company

Example:

```bash
hubspot company get
hubspot company get co1 --view full
hubspot company search --query cmdhub --limit 5
```

#### `hubspot company list`

- Anchor: `cmd-hubspot-company-list`
- Mutates state: `no`
- Supports dry run: `no`

List HubSpot companies

Example:

```bash
hubspot company get co1 --view full
hubspot company list
hubspot company list --limit 10
```

Flags:

- `--archived` (string): Archived filter: true or false
- `--city` (string): Filter by company city
- `--country` (string): Filter by company country
- `--created-after` (string): Only records created after YYYY-MM-DD or RFC3339
- `--domain` (string): Filter by company domain
- `--filter` (stringArray): Property filter as name=value, name:OP:value, or "name OP value"
- `--industry` (string): Filter by company industry
- `--lifecycle-stage` (string): Filter by company lifecycle stage
- `--name` (string): Filter by company name
- `--owner` (string): HubSpot owner ID, owner ref, email, or name
- `--property` (stringArray): Additional exact property filter as name=value
- `--updated-after` (string): Only records updated after YYYY-MM-DD or RFC3339

#### `hubspot company restore`

- Anchor: `cmd-hubspot-company-restore`
- Mutates state: `no`
- Supports dry run: `no`

Restore a HubSpot company from recycle bin

Example:

```bash
hubspot company restore --help
hubspot company restore co1
```

#### `hubspot company search`

- Anchor: `cmd-hubspot-company-search`
- Mutates state: `no`
- Supports dry run: `no`

Search HubSpot companies

Example:

```bash
hubspot company get co1 --view full
hubspot company search
hubspot company search --query cmdhub --limit 5
hubspot company search --query example --limit 5
```

Flags:

- `--archived` (string): Archived filter: true or false
- `--city` (string): Filter by company city
- `--country` (string): Filter by company country
- `--created-after` (string): Only records created after YYYY-MM-DD or RFC3339
- `--domain` (string): Filter by company domain
- `--filter` (stringArray): Property filter as name=value, name:OP:value, or "name OP value"
- `--industry` (string): Filter by company industry
- `--lifecycle-stage` (string): Filter by company lifecycle stage
- `--name` (string): Filter by company name
- `--owner` (string): HubSpot owner ID, owner ref, email, or name
- `--property` (stringArray): Additional exact property filter as name=value
- `--query` (string): Text to search across HubSpot default searchable properties
- `--sort` (stringArray): Sort as property:asc or property:desc
- `--updated-after` (string): Only records updated after YYYY-MM-DD or RFC3339

#### `hubspot company update`

- Anchor: `cmd-hubspot-company-update`
- Mutates state: `yes`
- Supports dry run: `no`

Update an exact HubSpot company

Example:

```bash
hubspot company search --query cmdhub --limit 5
hubspot company update --help
hubspot company update co1 --property lifecyclestage=customer
```

Flags:

- `--city` (string): Company city
- `--country` (string): Company country
- `--domain` (string): Company domain
- `--industry` (string): Company industry
- `--lifecycle-stage` (string): Company lifecycle stage
- `--name` (string): Company name
- `--owner` (string): HubSpot owner ID or ref
- `--property` (stringArray): HubSpot property update as name=value

#### `hubspot company upsert`

- Anchor: `cmd-hubspot-company-upsert`
- Mutates state: `no`
- Supports dry run: `no`

Create or update a HubSpot company by domain

Example:

```bash
hubspot company upsert --domain cmdhub-eval@example.invalid --property lifecyclestage=customer
hubspot company upsert --domain example.invalid --name "Cmdhub Eval"
hubspot company upsert --help
```

Flags:

- `--city` (string): Company city
- `--country` (string): Company country
- `--domain` (string): Company domain
- `--industry` (string): Company industry
- `--lifecycle-stage` (string): Company lifecycle stage
- `--name` (string): Company name
- `--owner` (string): HubSpot owner ID or ref
- `--property` (stringArray): Additional HubSpot property as name=value

### `hubspot config`

- Anchor: `cmd-hubspot-config`
- Mutates state: `no`
- Supports dry run: `no`

Inspect local configuration

Example:

```bash
hubspot config --help
```

#### `hubspot config explain`

- Anchor: `cmd-hubspot-config-explain`
- Mutates state: `no`
- Supports dry run: `no`

Explain resolved configuration

Example:

```bash
hubspot config explain --help
```

### `hubspot contact`

- Anchor: `cmd-hubspot-contact`
- Mutates state: `no`
- Supports dry run: `no`

Work with HubSpot contact records

Work with HubSpot contact records.

Actions:
  list, search, get, create, update, upsert, delete, restore

Workflow:
  search or list records, inspect the selected local ref, then run exact create, update, move, delete, or restore commands.

Selectors and filters:
  get, update, delete, and restore accept local refs like ct1, HubSpot record IDs, and exact unique values when available.
  Useful filters include --query, --owner, --created-after, --updated-after, --archived, and --property name=value.
  contact records commonly use --email as their unique selector.

Output:
  Human output uses local refs and hides long HubSpot IDs. Use --json or --jsonl for exact IDs, URLs, properties, cursors, and associations.

Safety:
  delete requires --dry-run or --yes. Use restore for records recoverable from the HubSpot recycle bin.

Example:

```bash
hubspot contact search --query cmdhub --limit 5
  hubspot contact get ct1 --view full
  hubspot contact create --email cmdhub-eval@example.com --first-name Cmdhub --last-name Eval
  hubspot contact search --query cmdhub --limit 5
  hubspot contact update ct1 --lifecycle-stage customer
  hubspot contact delete ct1 --dry-run
```

#### `hubspot contact create`

- Anchor: `cmd-hubspot-contact-create`
- Mutates state: `yes`
- Supports dry run: `no`

Create a HubSpot contact

Example:

```bash
hubspot contact create --email cmdhub-eval@example.com --first-name Cmdhub
hubspot contact create --email cmdhub-eval@example.com --first-name Cmdhub --last-name Eval
hubspot contact create --help
```

Flags:

- `--email` (string): Contact email
- `--first-name` (string): Contact first name
- `--last-name` (string): Contact last name
- `--lifecycle-stage` (string): Contact lifecycle stage
- `--owner` (string): HubSpot owner ID or ref
- `--phone` (string): Contact phone number
- `--property` (stringArray): Additional HubSpot property as name=value

#### `hubspot contact delete`

- Anchor: `cmd-hubspot-contact-delete`
- Mutates state: `yes`
- Supports dry run: `yes`

Delete an exact HubSpot contact

Example:

```bash
hubspot contact delete --help
hubspot contact delete ct1 --dry-run
hubspot contact delete ct1 --yes
hubspot contact search --query cmdhub-eval --limit 5
```

Flags:

- `--dry-run` (bool): Preview the exact delete without mutating HubSpot
- `--yes` (bool): Confirm deletion of the exact displayed record

#### `hubspot contact get`

- Anchor: `cmd-hubspot-contact-get`
- Mutates state: `no`
- Supports dry run: `no`

Inspect a HubSpot contact

Example:

```bash
hubspot contact get
hubspot contact get ct1 --view full
hubspot contact search --query cmdhub --limit 5
```

#### `hubspot contact list`

- Anchor: `cmd-hubspot-contact-list`
- Mutates state: `no`
- Supports dry run: `no`

List HubSpot contacts

Example:

```bash
hubspot contact get ct1 --view full
hubspot contact list
hubspot contact list --limit 10
```

Flags:

- `--archived` (string): Archived filter: true or false
- `--created-after` (string): Only records created after YYYY-MM-DD or RFC3339
- `--email` (string): Filter by contact email
- `--filter` (stringArray): Property filter as name=value, name:OP:value, or "name OP value"
- `--first-name` (string): Filter by contact first name
- `--last-name` (string): Filter by contact last name
- `--lifecycle-stage` (string): Filter by contact lifecycle stage
- `--owner` (string): HubSpot owner ID, owner ref, email, or name
- `--phone` (string): Filter by contact phone
- `--property` (stringArray): Additional exact property filter as name=value
- `--updated-after` (string): Only records updated after YYYY-MM-DD or RFC3339

#### `hubspot contact restore`

- Anchor: `cmd-hubspot-contact-restore`
- Mutates state: `no`
- Supports dry run: `no`

Restore a HubSpot contact from recycle bin

Example:

```bash
hubspot contact restore --help
hubspot contact restore ct1
```

#### `hubspot contact search`

- Anchor: `cmd-hubspot-contact-search`
- Mutates state: `no`
- Supports dry run: `no`

Search HubSpot contacts

Example:

```bash
hubspot contact get ct1 --view full
hubspot contact search
hubspot contact search --query alice --limit 5
hubspot contact search --query cmdhub --limit 5
```

Flags:

- `--archived` (string): Archived filter: true or false
- `--created-after` (string): Only records created after YYYY-MM-DD or RFC3339
- `--email` (string): Filter by contact email
- `--filter` (stringArray): Property filter as name=value, name:OP:value, or "name OP value"
- `--first-name` (string): Filter by contact first name
- `--last-name` (string): Filter by contact last name
- `--lifecycle-stage` (string): Filter by contact lifecycle stage
- `--owner` (string): HubSpot owner ID, owner ref, email, or name
- `--phone` (string): Filter by contact phone
- `--property` (stringArray): Additional exact property filter as name=value
- `--query` (string): Text to search across HubSpot default searchable properties
- `--sort` (stringArray): Sort as property:asc or property:desc
- `--updated-after` (string): Only records updated after YYYY-MM-DD or RFC3339

#### `hubspot contact update`

- Anchor: `cmd-hubspot-contact-update`
- Mutates state: `yes`
- Supports dry run: `no`

Update an exact HubSpot contact

Example:

```bash
hubspot contact search --query cmdhub --limit 5
hubspot contact update --help
hubspot contact update ct1 --lifecycle-stage customer
```

Flags:

- `--email` (string): Contact email
- `--first-name` (string): Contact first name
- `--last-name` (string): Contact last name
- `--lifecycle-stage` (string): Contact lifecycle stage
- `--owner` (string): HubSpot owner ID or ref
- `--phone` (string): Contact phone number
- `--property` (stringArray): HubSpot property update as name=value

#### `hubspot contact upsert`

- Anchor: `cmd-hubspot-contact-upsert`
- Mutates state: `no`
- Supports dry run: `no`

Create or update a HubSpot contact by email

Example:

```bash
hubspot contact upsert --email cmdhub-eval@example.com --first-name Cmdhub
hubspot contact upsert --email cmdhub-eval@example.invalid --property lifecyclestage=customer
hubspot contact upsert --help
```

Flags:

- `--email` (string): Contact email
- `--first-name` (string): Contact first name
- `--last-name` (string): Contact last name
- `--lifecycle-stage` (string): Contact lifecycle stage
- `--owner` (string): HubSpot owner ID or ref
- `--phone` (string): Contact phone number
- `--property` (stringArray): Additional HubSpot property as name=value

### `hubspot deal`

- Anchor: `cmd-hubspot-deal`
- Mutates state: `no`
- Supports dry run: `no`

Work with HubSpot deal records

Work with HubSpot deal records.

Actions:
  list, search, get, create, update, move, delete, restore

Workflow:
  search or list records, inspect the selected local ref, then run exact create, update, move, delete, or restore commands.

Selectors and filters:
  get, update, delete, and restore accept local refs like d1, HubSpot record IDs, and exact unique values when available.
  Useful filters include --query, --owner, --created-after, --updated-after, --archived, and --property name=value.
  deal records commonly use --name as their unique selector.

Output:
  Human output uses local refs and hides long HubSpot IDs. Use --json or --jsonl for exact IDs, URLs, properties, cursors, and associations.

Safety:
  delete requires --dry-run or --yes. Use restore for records recoverable from the HubSpot recycle bin.

Example:

```bash
hubspot deal search --query cmdhub --limit 5
  hubspot deal get d1 --view full
  hubspot deal create --name "Cmdhub Eval Renewal" --amount 1000 --stage appointmentscheduled
  hubspot deal search --query cmdhub --limit 5
  hubspot deal update d1 --amount 2500
  hubspot deal move d1 --stage s2
  hubspot deal delete d1 --dry-run
```

#### `hubspot deal create`

- Anchor: `cmd-hubspot-deal-create`
- Mutates state: `yes`
- Supports dry run: `no`

Create a HubSpot deal

Example:

```bash
hubspot deal create --help
hubspot deal create --name "Cmdhub Eval Renewal" --amount 1000 --stage appointmentscheduled
```

Flags:

- `--amount` (string): Deal amount
- `--close-date` (string): Deal close date
- `--company` (string): Company ref or ID to associate after create
- `--contact` (string): Contact ref or ID to associate after create
- `--name` (string): Deal name
- `--owner` (string): HubSpot owner ID or ref
- `--pipeline` (string): Deal pipeline ID or ref
- `--property` (stringArray): Additional HubSpot property as name=value
- `--stage` (string): Deal stage ID or ref

#### `hubspot deal delete`

- Anchor: `cmd-hubspot-deal-delete`
- Mutates state: `yes`
- Supports dry run: `yes`

Delete an exact HubSpot deal

Example:

```bash
hubspot deal delete --help
hubspot deal delete d1 --dry-run
hubspot deal delete d1 --yes
hubspot deal search --query cmdhub-eval --limit 5
```

Flags:

- `--dry-run` (bool): Preview the exact delete without mutating HubSpot
- `--yes` (bool): Confirm deletion of the exact displayed record

#### `hubspot deal get`

- Anchor: `cmd-hubspot-deal-get`
- Mutates state: `no`
- Supports dry run: `no`

Inspect a HubSpot deal

Example:

```bash
hubspot deal get
hubspot deal get d1 --view full
hubspot deal search --query cmdhub --limit 5
```

#### `hubspot deal list`

- Anchor: `cmd-hubspot-deal-list`
- Mutates state: `no`
- Supports dry run: `no`

List HubSpot deals

Example:

```bash
hubspot deal get d1 --view full
hubspot deal list
hubspot deal list --limit 10
```

Flags:

- `--amount` (string): Filter by deal amount
- `--archived` (string): Archived filter: true or false
- `--close-date` (string): Filter by deal close date
- `--company` (string): Filter by associated company ref or ID
- `--contact` (string): Filter by associated contact ref or ID
- `--created-after` (string): Only records created after YYYY-MM-DD or RFC3339
- `--filter` (stringArray): Property filter as name=value, name:OP:value, or "name OP value"
- `--name` (string): Filter by deal name
- `--owner` (string): HubSpot owner ID, owner ref, email, or name
- `--pipeline` (string): Filter by deal pipeline ID or ref
- `--property` (stringArray): Additional exact property filter as name=value
- `--stage` (string): Filter by deal stage ID, ref, or label
- `--updated-after` (string): Only records updated after YYYY-MM-DD or RFC3339

#### `hubspot deal move`

- Anchor: `cmd-hubspot-deal-move`
- Mutates state: `no`
- Supports dry run: `no`

Move a HubSpot deal to another stage

Move a HubSpot deal only after validating the requested stage against HubSpot pipeline metadata. Stage accepts a displayed stage ref from `hubspot pipeline get p1 --object deal`, an exact stage ID, or an unambiguous stage label. Use --pipeline when labels are ambiguous across pipelines.

Example:

```bash
hubspot deal move --help
hubspot deal move d1 --stage s2
hubspot pipeline list --object deal
```

Flags:

- `--pipeline` (string): Pipeline ref or pipeline ID
- `--stage` (string): Stage ref, stage ID, or stage label

#### `hubspot deal restore`

- Anchor: `cmd-hubspot-deal-restore`
- Mutates state: `no`
- Supports dry run: `no`

Restore a HubSpot deal from recycle bin

Example:

```bash
hubspot deal restore --help
hubspot deal restore d1
```

#### `hubspot deal search`

- Anchor: `cmd-hubspot-deal-search`
- Mutates state: `no`
- Supports dry run: `no`

Search HubSpot deals

Example:

```bash
hubspot deal get d1 --view full
hubspot deal search
hubspot deal search --query cmdhub --limit 5
```

Flags:

- `--amount` (string): Filter by deal amount
- `--archived` (string): Archived filter: true or false
- `--close-date` (string): Filter by deal close date
- `--company` (string): Filter by associated company ref or ID
- `--contact` (string): Filter by associated contact ref or ID
- `--created-after` (string): Only records created after YYYY-MM-DD or RFC3339
- `--filter` (stringArray): Property filter as name=value, name:OP:value, or "name OP value"
- `--name` (string): Filter by deal name
- `--owner` (string): HubSpot owner ID, owner ref, email, or name
- `--pipeline` (string): Filter by deal pipeline ID or ref
- `--property` (stringArray): Additional exact property filter as name=value
- `--query` (string): Text to search across HubSpot default searchable properties
- `--sort` (stringArray): Sort as property:asc or property:desc
- `--stage` (string): Filter by deal stage ID, ref, or label
- `--updated-after` (string): Only records updated after YYYY-MM-DD or RFC3339

#### `hubspot deal update`

- Anchor: `cmd-hubspot-deal-update`
- Mutates state: `yes`
- Supports dry run: `no`

Update an exact HubSpot deal

Example:

```bash
hubspot deal search --query cmdhub --limit 5
hubspot deal update --help
hubspot deal update d1 --amount 2500
```

Flags:

- `--amount` (string): Deal amount
- `--close-date` (string): Deal close date
- `--company` (string): Company ref or ID to associate after create
- `--contact` (string): Contact ref or ID to associate after create
- `--name` (string): Deal name
- `--owner` (string): HubSpot owner ID or ref
- `--pipeline` (string): Deal pipeline ID or ref
- `--property` (stringArray): HubSpot property update as name=value
- `--stage` (string): Deal stage ID or ref

### `hubspot doctor`

- Anchor: `cmd-hubspot-doctor`
- Mutates state: `no`
- Supports dry run: `no`

Run diagnostics

Example:

```bash
hubspot doctor --help
```

### `hubspot note`

- Anchor: `cmd-hubspot-note`
- Mutates state: `no`
- Supports dry run: `no`

Work with HubSpot CRM notes

Work with HubSpot notes attached to exact CRM records.

Workflow:
  find the target contact, company, deal, or ticket; create or list notes with --on <object:ref>; then inspect or update the note by local ref.

Selectors and filters:
  --on accepts contact:ct1, company:co1, deal:d1, or ticket:tk1. create accepts --body or --body-file.
  list and search accept created/updated filters and pagination flags.

Output:
  Human output uses note refs n1 and CRM refs. JSON and JSONL preserve exact note IDs and associations.

Safety:
  delete requires --dry-run or --yes. Pin and unpin require an exact target record.

Example:

```bash
hubspot note create --on deal:d1 --body "Customer asked for renewal quote."
  hubspot note list --on deal:d1
  hubspot note get n1 --view full
  hubspot note delete n1 --dry-run
```

#### `hubspot note create`

- Anchor: `cmd-hubspot-note-create`
- Mutates state: `yes`
- Supports dry run: `no`

Create a HubSpot CRM note

Create a HubSpot CRM note on one exact record. Prefer --on <object:ref>, such as --on deal:d1, after listing or searching the target record. Use --body for short text or --body-file for a local UTF-8 note body.

Example:

```bash
hubspot contact search --query cmdhub --limit 5
hubspot note create --help
hubspot note create --on contact:ct1 --body "Left voicemail."
hubspot note create --on deal:d1 --body-file note.txt
```

Flags:

- `--body` (string): Note body
- `--body-file` (string): Read note body from a local UTF-8 file
- `--company` (string): Company ref or ID to associate
- `--contact` (string): Contact ref or ID to associate
- `--deal` (string): Deal ref or ID to associate
- `--on` (string): Target record as object:ref, such as deal:d1
- `--ticket` (string): Ticket ref or ID to associate

#### `hubspot note delete`

- Anchor: `cmd-hubspot-note-delete`
- Mutates state: `yes`
- Supports dry run: `yes`

Delete an exact HubSpot CRM note

Example:

```bash
hubspot note delete --help
hubspot note delete n1 --dry-run
hubspot note delete n1 --yes
```

Flags:

- `--dry-run` (bool): Preview the exact note deletion without mutating HubSpot
- `--yes` (bool): Confirm deletion of the exact displayed note

#### `hubspot note get`

- Anchor: `cmd-hubspot-note-get`
- Mutates state: `no`
- Supports dry run: `no`

Inspect a HubSpot CRM note

Example:

```bash
hubspot note get
hubspot note get n1 --view full
```

#### `hubspot note list`

- Anchor: `cmd-hubspot-note-list`
- Mutates state: `no`
- Supports dry run: `no`

List HubSpot CRM notes

Example:

```bash
hubspot note list
hubspot note list --on deal:d1
```

Flags:

- `--created-after` (string): Only records created after YYYY-MM-DD or RFC3339
- `--on` (string): Target record as object:ref, such as deal:d1

#### `hubspot note pin`

- Anchor: `cmd-hubspot-note-pin`
- Mutates state: `yes`
- Supports dry run: `no`

Pin a HubSpot CRM note on a record

Example:

```bash
hubspot note pin --help
hubspot note pin n1 --on deal:d1
```

Flags:

- `--on` (string): Target record as object:ref, such as deal:d1

#### `hubspot note search`

- Anchor: `cmd-hubspot-note-search`
- Mutates state: `no`
- Supports dry run: `no`

Search HubSpot CRM notes

Example:

```bash
hubspot note search
hubspot note search --query renewal --limit 5
```

Flags:

- `--created-after` (string): Only records created after YYYY-MM-DD or RFC3339
- `--on` (string): Target record as object:ref, such as deal:d1
- `--query` (string): Text to search note bodies
- `--sort` (stringArray): Sort as property:asc or property:desc

#### `hubspot note unpin`

- Anchor: `cmd-hubspot-note-unpin`
- Mutates state: `yes`
- Supports dry run: `no`

Unpin a HubSpot CRM note from a record

Example:

```bash
hubspot note unpin --help
hubspot note unpin n1 --on deal:d1
```

Flags:

- `--on` (string): Target record as object:ref, such as deal:d1

#### `hubspot note update`

- Anchor: `cmd-hubspot-note-update`
- Mutates state: `yes`
- Supports dry run: `no`

Update an exact HubSpot CRM note

Example:

```bash
hubspot note update --help
hubspot note update n1 --body "Updated context."
```

Flags:

- `--body` (string): Updated note body
- `--property` (stringArray): HubSpot note property update as name=value

### `hubspot owner`

- Anchor: `cmd-hubspot-owner`
- Mutates state: `no`
- Supports dry run: `no`

Discover HubSpot owners

Discover assignable HubSpot CRM owners before create or update commands.

Workflow:
  list or search owners, then use displayed owner refs such as o1 with --owner on CRM record commands.

Selectors and filters:
  owner get accepts an owner ref, owner ID, email, or exact name. owner search accepts --query for names and email addresses.

Output:
  Human output uses owner refs o1. JSON and JSONL preserve exact HubSpot owner IDs.

Safety:
  Read-only metadata. The HubSpot owner ID is the assignment value, not userId.

Example:

```bash
hubspot owner search --query ada@example.com
  hubspot owner get o1
  hubspot contact update ct1 --owner o1
```

#### `hubspot owner get`

- Anchor: `cmd-hubspot-owner-get`
- Mutates state: `no`
- Supports dry run: `no`

Inspect a HubSpot owner

Example:

```bash
hubspot owner get
hubspot owner get o1
```

#### `hubspot owner list`

- Anchor: `cmd-hubspot-owner-list`
- Mutates state: `no`
- Supports dry run: `no`

List HubSpot owners

Example:

```bash
hubspot owner list
hubspot owner list --json
```

#### `hubspot owner search`

- Anchor: `cmd-hubspot-owner-search`
- Mutates state: `no`
- Supports dry run: `no`

Search HubSpot owners

Example:

```bash
hubspot owner search
hubspot owner search --query ada
```

Flags:

- `--query` (string): Text to match owner name or email

### `hubspot pipeline`

- Anchor: `cmd-hubspot-pipeline`
- Mutates state: `no`
- Supports dry run: `no`

Discover HubSpot deal and ticket pipelines

Discover read-only HubSpot deal and ticket pipeline metadata before moving records.

Workflow:
  list pipelines for the object, inspect one pipeline, then use displayed stage refs with deal move or ticket move.

Selectors and filters:
  pipeline get accepts a local pipeline ref such as p1, a HubSpot pipeline ID, or an exact pipeline label.
  --object selects deal or ticket pipelines.

Output:
  Human output uses pipeline refs p1 and stage refs s1. JSON and JSONL preserve exact HubSpot IDs.

Safety:
  Pipeline and stage administration is out of scope; this command only reads metadata.

Example:

```bash
hubspot pipeline list --object deal
  hubspot pipeline get p1 --object deal
  hubspot deal move d1 --stage s2
  hubspot pipeline stage get s2 --object deal --pipeline p1
```

#### `hubspot pipeline get`

- Anchor: `cmd-hubspot-pipeline-get`
- Mutates state: `no`
- Supports dry run: `no`

Inspect a HubSpot pipeline and cache stages

Example:

```bash
hubspot pipeline get
hubspot pipeline get p1 --view full
hubspot pipeline list --object deal
```

Flags:

- `--object` (string): Pipeline object: deal or ticket Default: `deal`.

#### `hubspot pipeline list`

- Anchor: `cmd-hubspot-pipeline-list`
- Mutates state: `no`
- Supports dry run: `no`

List HubSpot pipelines

Example:

```bash
hubspot pipeline get p1
hubspot pipeline list
hubspot pipeline list --object deal
```

Flags:

- `--object` (string): Pipeline object: deal or ticket Default: `deal`.

#### `hubspot pipeline stage`

- Anchor: `cmd-hubspot-pipeline-stage`
- Mutates state: `no`
- Supports dry run: `no`

Discover HubSpot pipeline stages

Discover valid stage refs for deal and ticket move commands.

Workflow:
  inspect a pipeline with hubspot pipeline get p1, then use the stage refs with deal move or ticket move.

Selectors and filters:
  stage get accepts a stage ref such as s1, a HubSpot stage ID, or an exact stage label.
  --pipeline accepts a pipeline ref, ID, or label. --object selects deal or ticket.

Output:
  Human output uses stage refs s1. JSON and JSONL preserve exact HubSpot IDs.

Example:

```bash
hubspot pipeline stage list --object deal --pipeline p1
  hubspot pipeline stage get s1 --object deal --pipeline p1
  hubspot deal move d1 --stage s1
```

##### `hubspot pipeline stage get`

- Anchor: `cmd-hubspot-pipeline-stage-get`
- Mutates state: `no`
- Supports dry run: `no`

Inspect a HubSpot pipeline stage

Example:

```bash
hubspot pipeline stage get
hubspot pipeline stage get s1 --object deal --pipeline p1
```

Flags:

- `--object` (string): Pipeline object: deal or ticket Default: `deal`.
- `--pipeline` (string): Pipeline ref, ID, or label

##### `hubspot pipeline stage list`

- Anchor: `cmd-hubspot-pipeline-stage-list`
- Mutates state: `no`
- Supports dry run: `no`

List HubSpot pipeline stages

Example:

```bash
hubspot pipeline stage list
hubspot pipeline stage list --object deal --pipeline p1
```

Flags:

- `--object` (string): Pipeline object: deal or ticket Default: `deal`.
- `--pipeline` (string): Pipeline ref, ID, or label

### `hubspot profile`

- Anchor: `cmd-hubspot-profile`
- Mutates state: `no`
- Supports dry run: `no`

Manage provider profiles

Example:

```bash
hubspot profile --help
```

#### `hubspot profile create`

- Anchor: `cmd-hubspot-profile-create`
- Mutates state: `yes`
- Supports dry run: `no`

Create an unauthenticated provider profile

Example:

```bash
hubspot profile create --help
```

#### `hubspot profile delete`

- Anchor: `cmd-hubspot-profile-delete`
- Mutates state: `yes`
- Supports dry run: `no`

Delete a local provider profile

Example:

```bash
hubspot profile delete --help
```

#### `hubspot profile list`

- Anchor: `cmd-hubspot-profile-list`
- Mutates state: `no`
- Supports dry run: `no`

List provider profiles

Example:

```bash
hubspot profile list --help
```

#### `hubspot profile rename`

- Anchor: `cmd-hubspot-profile-rename`
- Mutates state: `no`
- Supports dry run: `no`

Rename a local provider profile

Example:

```bash
hubspot profile rename --help
```

#### `hubspot profile use`

- Anchor: `cmd-hubspot-profile-use`
- Mutates state: `yes`
- Supports dry run: `no`

Set the default provider profile

Example:

```bash
hubspot profile use --help
```

### `hubspot property`

- Anchor: `cmd-hubspot-property`
- Mutates state: `no`
- Supports dry run: `no`

Discover HubSpot CRM properties

Discover valid HubSpot property internal names, field types, and option values.

Workflow:
  search properties for an object, inspect a property, then use --property name=value on create, update, list, or search commands.

Selectors and filters:
  property get accepts a property ref such as pr1, an internal property name, or an exact label.
  --object selects contact, company, deal, ticket, or note.

Output:
  Human output uses property refs pr1 and internal names. JSON and JSONL preserve full property metadata.

Safety:
  Read-only metadata. Read-only properties are shown so agents avoid invalid update attempts.

Example:

```bash
hubspot property search --object contact --query lifecycle
  hubspot property get pr1 --object contact
  hubspot contact update ct1 --property lifecyclestage=customer
```

#### `hubspot property get`

- Anchor: `cmd-hubspot-property-get`
- Mutates state: `no`
- Supports dry run: `no`

Inspect a HubSpot property

Example:

```bash
hubspot property get
hubspot property get pr1 --view full
hubspot property search --object contact --query lifecycle
```

Flags:

- `--object` (string): CRM object: contact, company, deal, or ticket Default: `contact`.

#### `hubspot property list`

- Anchor: `cmd-hubspot-property-list`
- Mutates state: `no`
- Supports dry run: `no`

List HubSpot properties

Example:

```bash
hubspot property get pr1 --object contact
hubspot property list
hubspot property list --object contact
```

Flags:

- `--object` (string): CRM object: contact, company, deal, or ticket Default: `contact`.

#### `hubspot property search`

- Anchor: `cmd-hubspot-property-search`
- Mutates state: `no`
- Supports dry run: `no`

Search HubSpot properties

Example:

```bash
hubspot property get pr1 --object contact
hubspot property search
hubspot property search --object contact --query lifecycle
```

Flags:

- `--object` (string): CRM object: contact, company, deal, or ticket Default: `contact`.
- `--query` (string): Text to match against property label, name, or description

### `hubspot resolve`

- Anchor: `cmd-hubspot-resolve`
- Mutates state: `no`
- Supports dry run: `no`

Resolve a local ref, short id, or URL alias

Example:

```bash
hubspot resolve --help
hubspot resolve <ref>
```

### `hubspot schema`

- Anchor: `cmd-hubspot-schema`
- Mutates state: `no`
- Supports dry run: `no`

Emit schema hints

Example:

```bash
hubspot schema --help
```

Flags:

- `--in` (bool): Show input schema
- `--input` (bool): Show input schema
- `--out` (bool): Show output schema

### `hubspot ticket`

- Anchor: `cmd-hubspot-ticket`
- Mutates state: `no`
- Supports dry run: `no`

Work with HubSpot ticket records

Work with HubSpot ticket records.

Actions:
  list, search, get, create, update, move, delete, restore

Workflow:
  search or list records, inspect the selected local ref, then run exact create, update, move, delete, or restore commands.

Selectors and filters:
  get, update, delete, and restore accept local refs like tk1, HubSpot record IDs, and exact unique values when available.
  Useful filters include --query, --owner, --created-after, --updated-after, --archived, and --property name=value.
  ticket records commonly use --subject as their unique selector.

Output:
  Human output uses local refs and hides long HubSpot IDs. Use --json or --jsonl for exact IDs, URLs, properties, cursors, and associations.

Safety:
  delete requires --dry-run or --yes. Use restore for records recoverable from the HubSpot recycle bin.

Example:

```bash
hubspot ticket search --query cmdhub --limit 5
  hubspot ticket get tk1 --view full
  hubspot ticket create --subject "Cmdhub Eval Ticket" --priority LOW
  hubspot ticket search --query cmdhub --limit 5
  hubspot ticket update tk1 --priority HIGH
  hubspot ticket move tk1 --stage s2
  hubspot ticket delete tk1 --dry-run
```

#### `hubspot ticket create`

- Anchor: `cmd-hubspot-ticket-create`
- Mutates state: `yes`
- Supports dry run: `no`

Create a HubSpot ticket

Example:

```bash
hubspot ticket create --help
hubspot ticket create --subject "Cmdhub Eval Ticket" --priority LOW
```

Flags:

- `--company` (string): Company ref or ID to associate after create
- `--contact` (string): Contact ref or ID to associate after create
- `--content` (string): Ticket content
- `--owner` (string): HubSpot owner ID or ref
- `--pipeline` (string): Ticket pipeline ID or ref
- `--priority` (string): Ticket priority
- `--property` (stringArray): Additional HubSpot property as name=value
- `--stage` (string): Ticket stage ID or ref
- `--subject` (string): Ticket subject

#### `hubspot ticket delete`

- Anchor: `cmd-hubspot-ticket-delete`
- Mutates state: `yes`
- Supports dry run: `yes`

Delete an exact HubSpot ticket

Example:

```bash
hubspot ticket delete --help
hubspot ticket delete tk1 --dry-run
hubspot ticket delete tk1 --yes
hubspot ticket search --query cmdhub-eval --limit 5
```

Flags:

- `--dry-run` (bool): Preview the exact delete without mutating HubSpot
- `--yes` (bool): Confirm deletion of the exact displayed record

#### `hubspot ticket get`

- Anchor: `cmd-hubspot-ticket-get`
- Mutates state: `no`
- Supports dry run: `no`

Inspect a HubSpot ticket

Example:

```bash
hubspot ticket get
hubspot ticket get tk1 --view full
hubspot ticket search --query cmdhub --limit 5
```

#### `hubspot ticket list`

- Anchor: `cmd-hubspot-ticket-list`
- Mutates state: `no`
- Supports dry run: `no`

List HubSpot tickets

Example:

```bash
hubspot ticket get tk1 --view full
hubspot ticket list
hubspot ticket list --limit 10
```

Flags:

- `--archived` (string): Archived filter: true or false
- `--company` (string): Filter by associated company ref or ID
- `--contact` (string): Filter by associated contact ref or ID
- `--created-after` (string): Only records created after YYYY-MM-DD or RFC3339
- `--filter` (stringArray): Property filter as name=value, name:OP:value, or "name OP value"
- `--owner` (string): HubSpot owner ID, owner ref, email, or name
- `--pipeline` (string): Filter by ticket pipeline ID or ref
- `--priority` (string): Filter by ticket priority
- `--property` (stringArray): Additional exact property filter as name=value
- `--stage` (string): Filter by ticket stage ID, ref, or label
- `--subject` (string): Filter by ticket subject
- `--updated-after` (string): Only records updated after YYYY-MM-DD or RFC3339

#### `hubspot ticket move`

- Anchor: `cmd-hubspot-ticket-move`
- Mutates state: `no`
- Supports dry run: `no`

Move a HubSpot ticket to another stage

Move a HubSpot ticket only after validating the requested stage against HubSpot ticket pipeline metadata. Stage accepts a displayed stage ref from `hubspot pipeline get p1 --object ticket`, an exact stage ID, or an unambiguous stage label. Use --pipeline when labels are ambiguous across pipelines.

Example:

```bash
hubspot pipeline list --object ticket
hubspot ticket move --help
hubspot ticket move tk1 --stage s2
```

Flags:

- `--pipeline` (string): Pipeline ref or pipeline ID
- `--stage` (string): Stage ref, stage ID, or stage label

#### `hubspot ticket restore`

- Anchor: `cmd-hubspot-ticket-restore`
- Mutates state: `no`
- Supports dry run: `no`

Restore a HubSpot ticket from recycle bin

Example:

```bash
hubspot ticket restore --help
hubspot ticket restore tk1
```

#### `hubspot ticket search`

- Anchor: `cmd-hubspot-ticket-search`
- Mutates state: `no`
- Supports dry run: `no`

Search HubSpot tickets

Example:

```bash
hubspot ticket get tk1 --view full
hubspot ticket search
hubspot ticket search --query cmdhub --limit 5
```

Flags:

- `--archived` (string): Archived filter: true or false
- `--company` (string): Filter by associated company ref or ID
- `--contact` (string): Filter by associated contact ref or ID
- `--created-after` (string): Only records created after YYYY-MM-DD or RFC3339
- `--filter` (stringArray): Property filter as name=value, name:OP:value, or "name OP value"
- `--owner` (string): HubSpot owner ID, owner ref, email, or name
- `--pipeline` (string): Filter by ticket pipeline ID or ref
- `--priority` (string): Filter by ticket priority
- `--property` (stringArray): Additional exact property filter as name=value
- `--query` (string): Text to search across HubSpot default searchable properties
- `--sort` (stringArray): Sort as property:asc or property:desc
- `--stage` (string): Filter by ticket stage ID, ref, or label
- `--subject` (string): Filter by ticket subject
- `--updated-after` (string): Only records updated after YYYY-MM-DD or RFC3339

#### `hubspot ticket update`

- Anchor: `cmd-hubspot-ticket-update`
- Mutates state: `yes`
- Supports dry run: `no`

Update an exact HubSpot ticket

Example:

```bash
hubspot ticket search --query cmdhub --limit 5
hubspot ticket update --help
hubspot ticket update tk1 --priority HIGH
```

Flags:

- `--company` (string): Company ref or ID to associate after create
- `--contact` (string): Contact ref or ID to associate after create
- `--content` (string): Ticket content
- `--owner` (string): HubSpot owner ID or ref
- `--pipeline` (string): Ticket pipeline ID or ref
- `--priority` (string): Ticket priority
- `--property` (stringArray): HubSpot property update as name=value
- `--stage` (string): Ticket stage ID or ref
- `--subject` (string): Ticket subject

### `hubspot version`

- Anchor: `cmd-hubspot-version`
- Mutates state: `no`
- Supports dry run: `no`

Show version information

Example:

```bash
hubspot version --help
```

## Live Examples

### Auth

#### Show auth status

Shows the current auth state and next step.

_Example metadata: provider state: local._

```bash
hubspot auth status
```

```text
Authenticated as kestrelphilip@gmail.com
Profile: kestrelphilip@gmail.com

Next steps:
- Find contacts:      hubspot contact search --query <text> --limit 5
- Find companies:     hubspot company search --query <text> --limit 5
- Discover pipelines: hubspot pipeline list --object deal
- Plan cleanup:       hubspot cleanup plan --token cmdhub-eval-<run> --objects contacts
```

### Lifecycle

#### Show capabilities

Lists command surfaces and output modes.

_Example metadata: provider state: local._

```bash
hubspot capabilities
```

```text
hubspot capabilities
Resources: association, auth, capabilities, cleanup, company, config, contact, deal, doctor, note, owner, pipeline, profile, property, resolve, schema, ticket, version
Machine output: --json, --jsonl

Next steps:
- Schema:        hubspot schema
- Contract:      hubspot capabilities --json
- Help:          hubspot --help
- Find contacts: hubspot contact search --query <text> --limit 5
```

### Schemas

#### Show schema overview

Lists available schemas.

_Example metadata: provider state: local._

```bash
hubspot schema
```

```text
hubspot schemas
COMMAND                DIR
association.add        input
association.add        output
association.list       input
association.list       output
association.remove     input
association.remove     output
association.types      input
association.types      output
auth.status            output
auth.whoami            output
capabilities.describe  output
cleanup.plan           input
cleanup.plan           output
cleanup.run            input
cleanup.run            output
cleanup.verify         input
cleanup.verify         output
company.create         input
company.create         output
company.delete         input
company.delete         output
company.get            input
company.get            output
company.list           input
company.list           output
company.search         input
company.search         output
company.update         input
company.update         output
contact.create         input
contact.create         output
contact.delete         input
contact.delete         output
contact.get            input
contact.get            output
contact.list           input
contact.list           output
contact.search         input
contact.search         output
contact.update         input
contact.update         output
deal.create            input
deal.create            output
deal.delete            input
deal.delete            output
deal.get               input
deal.get               output
deal.list              input
deal.list              output
deal.move              input
deal.move              output
deal.search            input
deal.search            output
deal.update            input
deal.update            output
doctor.run             output
note.create            input
note.create            output
note.delete            input
note.delete            output
note.get               input
note.get               output
note.update            input
note.update            output
owner.list             output
pipeline.get           input
pipeline.get           output
pipeline.list          input
pipeline.list          output
property.get           input
property.get           output
property.list          input
property.list          output
property.search        input
property.search        output
resolve.get            output
ticket.create          input
ticket.create          output
ticket.delete          input
ticket.delete          output
ticket.get             input
ticket.get             output
ticket.list            input
ticket.list            output
ticket.move            input
ticket.move            output
ticket.search          input
ticket.search          output
ticket.update          input
ticket.update          output
version.get            output

Next steps:
- Find contacts:      hubspot contact search --query <text> --limit 5
- Find companies:     hubspot company search --query <text> --limit 5
- Discover pipelines: hubspot pipeline list --object deal
- Plan cleanup:       hubspot cleanup plan --token cmdhub-eval-<run> --objects contacts
```
