Skip to content

OAuth providers

HubSpot

Set up HubSpot OAuth for CRM and marketing automation

Connect your users to HubSpot for CRM data, contact management, deal tracking, and marketing automation.

PropertyValue
Provider IDhubspot
CategoryPopular
PKCESupported
Token refreshAutomatic
Redirect URIShown in Developer Portal

Install and authenticate the HubSpot CLI

Install the HubSpot CLI (v7.6.0 or later) and authenticate with hs init or hs account auth. Apps are now created via the CLI from any standard HubSpot account — the legacy developer-account model was retired in March 2026.

Create a new project

Run hs project create and choose:

  • Distribution: Marketplace or restricted installation
  • Authentication: OAuth (for installation in multiple HubSpot accounts)

Configure OAuth settings

Edit the app’s top-level app-hsmeta.json file and add the Alter callback URL (from the Developer Portal) to the redirectUrls array. Add the required scopes under auth.requiredScopes. Then run hs project upload to deploy the app to HubSpot.

Get credentials

In the HubSpot account, go to Development > Projects, open the project, click the app name, and open the Auth tab. Copy the Client ID and Client secret.

Open the Developer Portal

Go to portal.alterauth.com and navigate to the application.

Add HubSpot provider

Go to OAuth Providers > Add Provider > HubSpot.

Enter credentials

  • Client ID: Paste your HubSpot Client ID
  • Client Secret: Paste your HubSpot Client secret

Select scopes

Choose the scopes the application needs.

Save

Click Save. The provider is now active.

ScopeDescription
crm.objects.contacts.readRead contact records
crm.objects.contacts.writeCreate, update, and delete contacts
crm.objects.companies.readRead company records
crm.objects.companies.writeCreate, update, and delete companies
crm.objects.deals.readRead deal records
crm.objects.deals.writeCreate, update, and delete deals
  • HubSpot enforces granular scopes — request only what the application needs.
  • Access tokens are short-lived (~30 minutes). Alter Vault handles automatic refresh using the refresh token.
  • See the HubSpot OAuth documentation for more details.