> ## Documentation Index
> Fetch the complete documentation index at: /help/llms.txt
> Use this file to discover all available pages before exploring further.

# HubSpot

> Create or update a HubSpot contact from a campaign step, matched by email, when someone accepts, replies or reaches any step.

> [!NOTE]
>
> **Pro plan.** HubSpot works through a connection and HTTP steps, which are part of Pro and Agency (and the free trial). Anything you already have keeps working on every plan. See [Plans and billing](/help/account/billing.md).

A campaign step can create the contact in HubSpot, or update the one with the same email. Put it where it matters to you: after an accepted invitation, after a reply, or at any other step.

## Connect with one click

> [!NOTE]
>
> **Coming soon.** The **HubSpot** row in **Integrations > Connections** and the **HubSpot: create or update the contact** step show up once Kerux's HubSpot app is live. Until then, use a service key ([below](#connect-with-a-service-key)).

**1. Connect HubSpot**

Go to **Integrations > Connections** and click **Connect** on the **HubSpot** row (under **CRM**). HubSpot opens: pick your HubSpot account and click **Connect app**. Kerux asks only to read and write contacts. You need to be a super admin in HubSpot, or have the **HubSpot Marketplace Access** permission there.

**2. Add the step**

In your campaign, add **HubSpot: create or update the contact**. There is nothing to fill in: it sends the contact's email, first and last name, company, job title and LinkedIn profile.

**3. What it does**

HubSpot updates the contact with that email, or creates one when there is none. A field the contact has no value for isn't sent, so nothing already in HubSpot gets erased. A contact with no email waits on the step until one is added. Later steps can use the HubSpot contact's id.

If someone removes the Kerux app in HubSpot, contacts wait on the step (**Paused: the other service rejected the key**) and the HubSpot row in **Connections** needs attention. Connect HubSpot again and they go on.

## Connect with a service key

This works today, with a **Webhook / HTTP** step.

**1. Create a service key in HubSpot**

In HubSpot, go to **Development > Keys > Service keys** and click **Create service key**. Name it "Kerux", click **Add new scope**, tick `crm.objects.contacts.read` and `crm.objects.contacts.write`, then click **Create**. Open the key, click **Show** and **Copy**.

**2. Add the connection in Kerux**

Open **Integrations > Connections** and click **Connect** on **Custom API**. Choose **Bearer token**, paste the key and set the base URL to `https://api.hubapi.com`. Click **Save**, then **Test connection**.

**3. Add the step**

Add a **Webhook / HTTP** step, pick the HubSpot connection, method **POST**, URL `/crm/v3/objects/contacts/batch/upsert`, and a JSON body with `inputs`: one item with `idProperty` set to `email`, `id` set to `{{email}}`, and the `properties` you want to send (`email`, `firstname`, `lastname`, `company`, `jobtitle`, `hs_linkedin_url`).

> [!TIP]
>
> Kerux never sends an empty variable. With the service key step, remove the properties you don't always have (a job title, a company) so contacts don't wait for them. The one-click step leaves empty fields out by itself.

To bring HubSpot form submissions into Kerux, see [HubSpot forms](/help/integrations/forms/hubspot-forms.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.