Skip to main content

Hubspot

HubSpot is a comprehensive customer relationship management (CRM) and inbound marketing platform that helps businesses manage customer interactions, sales pipelines, marketing campaigns, customer support, and content management. This integration provides access to critical HubSpot data across multiple business functions including sales, marketing, customer service, and website content.

CategoryOther
DirectionQuery source
Sign-inPrivate App Token
Query languagesSQLite
Tables8
Query templates56
Websitehubspot.com

Before you start​

Huntbase signs in to Hubspot with Private App Token. Create the credential in Hubspot first, then keep it to hand for the Connect step.

  1. In HubSpot, go to Development › Legacy apps, click Create legacy app, and select Private. You must be a super admin.
  2. On the Basic Info tab, enter a name for the app.
  3. On the Scopes tab, click Add new scope and select only the read scopes listed below for the data you want to query.
  4. Click Create app, then Continue creating.
  5. Open the app, go to the Auth tab, click Show token, and copy it.

Permissions:

  • crm.objects.contacts.read, crm.objects.companies.read, crm.objects.deals.read and crm.objects.owners.read
  • crm.schemas.contacts.read, crm.schemas.companies.read and crm.schemas.deals.read for custom properties
  • tickets, content, cms.domains.read and hubdb
  • settings.users.read and settings.users.teams.read
  • account-info.security.read for login and security activity
Watch out for
  • The token carries only the scopes you selected. A missing scope causes a permission error for that data, not an empty result.

For the vendor's own instructions, see HubSpot private app documentation.

tip

Use a dedicated, read-only credential for Huntbase where the product allows it. Huntbase only needs to read.

Connect Hubspot​

  1. Go to Connections and click New connection, or click New connection on the Hubspot product page.
  2. On Product, pick Hubspot and choose the Owner.
  3. On Details, give the connection a Name and, optionally, a Description.
  4. On Connect, fill in the settings and credentials described below.
  5. On Verify, review the summary and click Create & check.

For everything else on the setup page — saving a draft, I'll do this later, and what each check result means — see Connections.

Credentials​

The only Method is Private App Token. Enter a Credential label (for example Production), then fill in:

FieldRequiredNotes
Private App TokenYesSecret — not shown again after you save it.

Query it​

Once connected, Hubspot can serve these languages in a query tab, and Scout can use it when you ask in Auto:

LanguageUse it for
SQLiteSQL over the 8 tables listed below, alongside every other connected source.

Example: SQLite​

HubSpot Company Basic Info — Retrieve creation and modification dates of companies in a HubSpot account, including archive status and domain, to track changes over time.

select
id,
created_at,
archived,
domain,
updated_at
from
hubspot_company;

Hubspot ships with 56 query templates. Find them in Library › Queries — see Query templates.

Tables​

Hubspot adds 8 tables. Browse their columns from Schema in the query bar's ⋯ menu.

All 8 tables
TableContains
hubspot_blog_postList of HubSpot BlogPosts.
hubspot_companyList of HubSpot Companies.
hubspot_contactList of HubSpot Contacts.
hubspot_dealList of HubSpot Deals.
hubspot_domainList of HubSpot Domains.
hubspot_hub_dbList of HubSpot published HubDBs.
hubspot_ownerList of HubSpot Owners.
hubspot_ticketList of HubSpot Tickets.

Next steps​