> ## Documentation Index
> Fetch the complete documentation index at: https://koreai-ai-for-work-dev.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Configuring the HubSpot Action

<Badge icon="arrow-left" color="gray">[Back to Actions Integrations](/ai-for-service/integrations/overview#actions)</Badge>

Connect the HubSpot integration to create, view, update, search, and delete deals and contacts using pre-built templates. See [HubSpot](https://www.hubspot.com/) for more information.

***

## Authorizations Supported

The Platform supports OAuth 2.0 for HubSpot. See [Setting Up Authorization Using OAuth v2](/ai-for-service/app-settings/dev-tools/bot-authorization/setting-up-authorization-using-oauth-v2) for details.

| Authorization Type                       | OAuth - System | OAuth - Custom |
| ---------------------------------------- | -------------- | -------------- |
| Pre-authorize the Integration            | Yes            | Yes            |
| Allow Users to Authorize the Integration | Yes            | Yes            |

***

## Step 1: Enable the HubSpot Action

**Prerequisites:**

* Create a developer account in HubSpot. See [HubSpot Developer Center](https://developers.hubspot.com/docs/api/creating-an-app) for details.
* Copy the Client ID and Client Secret key values.

**Steps:**

1. Go to **App Settings** > **Integrations** > **Actions**.
2. In the **Available** section, select **HubSpot**.

### Pre-authorize the Integration

**System Authorization**

Pre-authorize with Kore.ai's preconfigured HubSpot app:

1. Go to **App Settings** > **Integrations** > **Actions** and select **HubSpot**.

2. In **Configurations**, select the **Authorization** tab.

3. Set **Authorization Type** to **Pre-authorize the Integration** > **OAuth**.

4. Select the **System** card and click **Authorize**.

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img2.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=7fa8d33013aee20fcb656499cf54bd2b" alt="Auth type-OAuth" width="896" height="841" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img2.png" />

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img3.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=8e56b3cf5f572abb8b00a0803e72ad97" alt="Authorize Kore.ai's preconfigured HubSpot app" width="896" height="841" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img3.png" />

5. You are redirected to `login.hubspot.com`. Enter your developer account credentials.

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img4-img8.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=59dc4ae745c261b2118a564bd6844535" alt="Connect to developer account" width="1027" height="767" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img4-img8.png" />

6. Select a HubSpot account and click **Choose Account**.

7. Click **Enable**.

**Custom Authorization**

Use your own OAuth profile instead of Kore.ai's app:

1. Select **Custom** and click **Select Authorization** > **Create New**.

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img5.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=18d37329b426efcc85e748d900cd557c" alt="Create new auth" width="887" height="841" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img5.png" />

2. Select **OAuth v2**. See [Setting Up Authorization Using OAuth v2](/ai-for-service/app-settings/dev-tools/bot-authorization/setting-up-authorization-using-oauth-v2).

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img6.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=4bc41d663505c5955f581dcaa7a7dd1b" alt="Select auth mechanism" width="894" height="901" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img6.png" />

3. Enter the OAuth v2 credentials:

   * Call back URL
   * Identity Provider Name
   * Client ID
   * Client Secret
   * Authorization URL
   * Token Request URL
   * Scope
   * Refresh Token URL

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img7.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=422e266ed80f926b14c3f409739473ee" alt="Enter auth credentials" width="882" height="913" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img7.png" />

4. Click **Save Auth**, select the new profile, then click **Authorize**.

5. Enter credentials at `login.hubspot.com`.

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img4-img8.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=59dc4ae745c261b2118a564bd6844535" alt="Connect to developer account" width="1027" height="767" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img4-img8.png" />

6. Select a HubSpot account, click **Choose Account**, then click **Enable**.

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img9.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=de27af6062a572e7c74f4d0db85f5f46" alt="Enable integration" width="671" height="272" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img9.png" />

<Note>The HubSpot action moves from **Available** to **Configured** after enabling.</Note>

### Allow End User to Authorize

**System Authorization**

1. Go to **App Settings** > **Integrations** > **Actions** and select **HubSpot**.
2. In **Configurations**, select the **Authorization** tab.
3. Set **Authorization Type** to **Allow Users to Authorize the Integration** > **OAuth**.
4. Select the **System** card.
5. Click **Enable**. A link is sent to the end user to authorize integration.

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img10.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=bd6b2c82cd2dbc4f769adacec2a4158d" alt="Enable integration-authorization link sent to user" width="895" height="840" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img10.png" />

**Custom Authorization**

1. Select **Allow Users to Authorize the Integration** > **OAuth** > **Custom**.

2. Click **Select Authorization** > **Create New** and follow the Custom Authorization steps above.

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img11.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=b6af6e3c784441bf4c321649cb767d6c" alt="Create new authorization" width="871" height="830" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img11.png" />

   You can also select an existing profile:

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img12.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=e924e9cd1f074de7a99bb799ea593d57" alt="Select existing auth profile" width="899" height="846" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img12.png" />

3. Click **Enable**.

***

## Step 2: Install the HubSpot Action Templates

1. On the **Integration Successful** dialog, click **Explore Templates**.

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img9.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=de27af6062a572e7c74f4d0db85f5f46" alt="Explore templates" width="671" height="272" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img9.png" />

2. In the Integration Templates dialog, click **Install**.

   <img src="https://mintcdn.com/koreai-ai-for-work-dev/r7ifGMsN_f_HHKjV/ai-for-service/integrations/actions/images/hubspot-integration-img14.png?fit=max&auto=format&n=r7ifGMsN_f_HHKjV&q=85&s=1bcd36943b887b7426e4f4819a3de422" alt="Begin template installation" width="668" height="806" data-path="ai-for-service/integrations/actions/images/hubspot-integration-img14.png" />

3. Once installed, the associated dialog task is auto-created. Click **Go to Dialog** or go to **Automation AI** > **Use Cases** > **Dialogs**.

4. To use the templates, see [Using HubSpot Templates](/ai-for-service/integrations/actions/using-the-hubspot-action-templates).
