HubSpot Module Basics - Setup
  • Updated on 26 Jul 2017
  • 4 minutes to read
  • Print
  • Dark

HubSpot Module Basics - Setup

  • Print
  • Dark


The HubSpot Module in Decisions allows you to access and update your HubSpot data using steps in a flow that hide the complexities of working with the HubSpot API directly.
Before you can do that, you will need to set up the module and the security parameters that authorize Decisions to access your HubSpot data.

Installing the HubSpot module

If you cannot find any of the steps or capabilities in this document you may need to install the HubSpot module. To install HubSpot module navigate to the System > Administration > Features folder, locate Decisions.HubSpot module in the list of Available Features, and click the Install button.

Setting Up a HubSpot Application

Access to your HubSpot data is governed by a HubSpot Application. When you log into your HubSpot developer account and click the "Apps" menu option, you can view any applications you have set up.
HubSpot_Basics2.png{height ="325" width="1612"}
You may create one for use in Decisions or use an existing one, provided it has the following settings:

  • The Scope "Basic OAuth functionality" has been checked.
  • The "Contacts" and "Content" areas have been checked.


Once set up, click on the application name to view its details. On that page, you will find the Client ID and Client Secret values. You will need them for the next step.

Setting up the HubSpot Provider

In Decisions, navigate to System > Integrations > OAuth > Providers. 

The HubSpot module installs a HubSpot provider, but you will need to initialize it with the Client ID and secret to make the access request.  Click on the HubSpot provider and select "Edit Provider Settings".  In the dialog that appears, paste the Client ID into the Default Consumer Key field, and the Client Secret into the Default Consumer Secret Key field. Click OK.
2018-01-09_110001-1.png{height ="1012" width="1920"}
2018-01-09_110033-1.png{height ="774" width="802"}

Accessing Your HubSpot Application

Using any of the pre-built HubSpot steps requires an OAuth token.  OAuth is a standard mechanism for providing security to communicate with a webservice.  In Decisions you must establish an OAuth token which represents a user that will be used to run the REST API and interact with your data in HubSpot.
There are two types of tokens for interacting with HubSpot:

  1. Authorization Token

  2. Access Token

Authorization Token

This token must be setup one time and requires communication between Decisions and HubSpot with a user signing into the HubSpot page and retrieving a token to store in Decisions.  Once you setup an authorization token it should not expire.

Access Token

The access token is created using the authorization token, but will expire periodically and needs to be refreshed.  This can be done automatically in your flows using flow steps.

Creating an Authorization Token

Creating an authorization token as a first step is important to be able to use any of the HubSpot steps in the HubSpot module.  OAuth tokens can be created in System > Integrations > OAuth > Tokens.

  1. Click 'Create Token'

  2. Create token will prompt you with a warning if your BaseURLToPortal is not configured to an externally addressable IP or FQDN. This will NOT prevent you from creating a token, but you will have a manual step because HubSpot will not be able to redirect traffic back to your Decisions installation. If you see that warning you can safely ignore it and continue to follow the instructions below.

  3. 2018-01-09_110217-1.png

  4. Fill in the following form and press “Request Token”

    1. Token Name: This is a name for you to select later in a flow.  Give the token a meaningful name that you will remember

    2. Provider: Select "HubSpot"

Once you press "Request Token" you will be redirected in a pop up window to NOTE: Popup blocking applications and add-ons may prevent this from working correctly.  Please disable them and try to request a token again.

5. Log in using your developer credentials to HubSpot. If you are asked to select an account, select the one you copied the Client ID from.

6. At this point, you will likely receive a message stating that there is a necessary parameter missing. 
HubSpot_Basics5.png{height ="255" width="1486"}
You will need to alter the web address to which the browser went in order to supply it. At the end of the web address, add `&scope=contacts%20content`. Your final address should look like:

7. Go to that web address in your browser. You should now be directed to a page that doesn't exist on your web server. The address will look like `http://localhost/?code=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx`. Copy this address.

8. Back in Decisions, in the Create and Store OAuth Credentials dialog, click the "Set Access Token Manually" link. In the Authorize URL field, paste the response address that HubSpot sent you to and then click the Save Manual Settings button. You can now exit the dialog.


Refresh the page, and the HubSpot Token that you created will appear in the list of tokens. You are now ready to use the HubSpot steps in your Decisions flows.

Was this article helpful?