pex

HubSpot

The HubSpot connector imports deal pipeline data, contact information, and revenue figures from your HubSpot CRM. This is essential for B2B teams that need to connect marketing activity to actual closed deals.

Authentication

HubSpot uses OAuth 2.0. Apex requests read-only scopes for deals, contacts, and deal schemas.

Click Connect on the Sensors page

Find the HubSpot card and click Connect. You'll be redirected to HubSpot's authorization screen.

Select your HubSpot portal

If you have access to multiple HubSpot portals, select the one you want to connect.

Authorize access

Grant Apex permission to read deals, contacts, and deal schemas. Apex never creates or modifies records in HubSpot.

OAuth Scopes

ScopePurpose
crm.objects.deals.readRead deal records (amount, stage, close date)
crm.objects.contacts.readRead contact records (email for identity resolution)
crm.schemas.deals.readRead deal pipeline and stage definitions

Data Synced

Each sync paginates through your HubSpot deals and pulls:

DataDescription
DealsAmount, deal stage, close date, deal name
Contact associationsEmail address of the primary contact on each deal
Pipeline dataWhich pipeline and stage each deal belongs to

For each deal, Apex also resolves the associated contact to get their email address. This enables identity stitching — linking anonymous website visitors to known CRM contacts.

How Apex Uses This Data

  • Revenue attribution — Match closed deals back to the marketing channels that generated the lead, using email-based identity resolution
  • Pipeline visibility — See deal volume and value by stage in the dashboard
  • Experiment impact — Measure whether an experiment affected downstream deal creation or close rates, not just form submissions
  • Lead quality scoring — Combine HubSpot deal data with ad platform data to calculate true cost per qualified lead

Info

HubSpot's identity resolution works best when your forms capture email addresses. Apex matches the HubSpot contact email to the visitor who originally submitted the form via the tracking snippet.

Webhook Support

In addition to scheduled syncs, Apex can receive HubSpot webhooks for real-time updates. When a deal is created or moves to a new stage, the webhook processor:

  1. Validates the webhook signature
  2. Deduplicates the event
  3. Updates the local deal record
  4. Triggers revenue matching if the deal has a contact email

Tip

Webhooks are optional but recommended for B2B teams where deal stage changes matter for attribution timing.

Troubleshooting

IssueCauseFix
No deals returnedToken expired or revokedRe-authorize from the Sensors page
Missing contact emailsDeals lack contact associationsEnsure deals in HubSpot have associated contacts
"403 Forbidden" on syncInsufficient scopesDisconnect and reconnect to re-request scopes

Next Steps