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

# HubSpot App

> Install the official HubSpot app to create or update HubSpot contacts for your Dodo Payments customers and add a note for each payment, refund, and dispute.

## What the HubSpot app does

The HubSpot app creates or updates a HubSpot contact for each customer. It also adds a note to the contact for each payment, refund, and dispute. The app does not make deals and has no map from a product to a list.

## Before you start

* You are an owner or an admin of the Dodo Payments business.
* You have a HubSpot account and you can make a private app.

## Install, connect, and configure

**1. Install the app**

Open **Apps**, then **Explore**. Open **HubSpot** (publisher **Dodo Payments**) and select **Install app**.

![The Installed tab of Apps with HubSpot in the list and the status Active](https://mintcdn.com/dodopayments/9p5nlYkB8XwTy1ds/images/app-marketplace/merchant/apps/hubspot-4.png?fit=max\&auto=format\&n=9p5nlYkB8XwTy1ds\&q=85\&s=8750e8307787cd1b5b21fe570e5cb206)

**2. Connect HubSpot**

Select **Connect**. In HubSpot, open **Settings**, then **Integrations**, then **Private Apps**. Make a private app with the scopes `crm.objects.contacts.read` and `crm.objects.contacts.write`. Copy the access token of the private app. Enter it in the **Access Token** field, then select **Connect**.

![The Connect HubSpot dialog with the Access Token field](https://mintcdn.com/dodopayments/9p5nlYkB8XwTy1ds/images/app-marketplace/merchant/apps/hubspot-3.png?fit=max\&auto=format\&n=9p5nlYkB8XwTy1ds\&q=85\&s=1e03bf820409be53a87cf57c9f274723)

**3. Choose the settings**

Open the **Configure** tab, set the options, and select **Save**.

![The Configure tab of the HubSpot app with the three setting switches and the Products filter](https://mintcdn.com/dodopayments/9p5nlYkB8XwTy1ds/images/app-marketplace/merchant/apps/hubspot-1.png?fit=max\&auto=format\&n=9p5nlYkB8XwTy1ds\&q=85\&s=88ba9a0fc0c41e28fcb1b5b30dad1c9f)

**4. Make the contact properties (optional)**

To use **Write the Dodo contact properties**, open **Settings**, then **Properties** in HubSpot. Make three single-line text contact properties: `dodo_customer_id`, `dodo_subscription_status`, and `dodo_status_updated_at`. HubSpot refuses a property that does not exist.

**5. Pick the filters**

Pick the products and currencies, then select **Save**.

![The HubSpot Configure tab with the Products and Currencies filters](https://mintcdn.com/dodopayments/9p5nlYkB8XwTy1ds/images/app-marketplace/merchant/apps/hubspot-2.png?fit=max\&auto=format\&n=9p5nlYkB8XwTy1ds\&q=85\&s=4edb071e7cdb5d1e5932f76a3a61c343)

## Settings

| Setting | What it does | Default |
| - | - | - |
| Add customers as contacts | Create or update a contact by email for each successful payment and each new or renewed subscription. The app writes the first name, the last name, and the country. | On |
| Write the Dodo contact properties | Also write `dodo_customer_id`, `dodo_subscription_status`, and `dodo_status_updated_at`. The app writes the status when a subscription goes on hold, is cancelled, or expires. | Off |
| Add a note for payments, refunds and disputes | Add one note to the contact for each successful payment, each successful refund, and each opened dispute. | On |
| Products | Send data only for the products that you pick. The notes do not use this filter. | All |
| Currencies | Send data only for the currencies that you pick. | All |

## What is sent and when

Dodo Payments sends data after the Dodo Payments event happens. The app sends the email address, the first name, the last name, and the billing country code of the customer. With **Write the Dodo contact properties** on, it also sends the customer ID, the subscription status, and the time. A note shows the event, the amount in the major unit with the currency code, the product names, and the Dodo ID. The app sends no card data and no street address.

When no contact exists, the app creates a contact with only the email for a note. The app updates the name of an existing contact at each payment. A name that you changed in HubSpot changes back to the name in Dodo Payments.

## Test the app

**1. Use test mode**

Install and connect the app in test mode.

**2. Make a test payment**

Create a test payment with a test customer email.

**3. Check HubSpot**

Open **Contacts** in HubSpot. The test customer appears. If notes are on, the contact has a note for the payment.

## Troubleshooting

| Problem | What to do |
| - | - |
| The connection fails | Make a new private app token in HubSpot. Check that the private app has the scopes `crm.objects.contacts.read` and `crm.objects.contacts.write`. HubSpot gives an error for a token that is not valid and for a token without these scopes. |
| HubSpot refuses the update after you turn on **Write the Dodo contact properties** | Make the three single-line text contact properties in HubSpot. |
| A contact has the wrong name | The app writes the name of Dodo Payments at each payment. Change the name in Dodo Payments. |
| **Connection needs attention** | HubSpot stopped accepting the credentials. Select **Reconnect** and enter new credentials. |
| No data arrives | Check that the setting switch is on and that the product and currency filters do not skip the event. Check that the customer has an email address. |

## Disconnect and uninstall

Turn off the settings on the **Configure** tab to stop sending data. Uninstall the app to delete the HubSpot connection. See [Manage and uninstall](https://docs.dodopayments.com/features/app-marketplace/manage-and-uninstall.md).


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