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

# Hotmart

> Each approved purchase in Hotmart creates the buyer's Contact and their Company.

## What it brings into Brein

When a purchase is approved, Brein creates or fills in the buyer's **Contact** and their **Company** by the email domain. If you ask at connect time, it also opens an **Opportunity**.

| From Hotmart | Goes to |
| - | - |
| `data.buyer.name` | Contact name |
| `data.buyer.email` | Contact email |
| `data.buyer.checkout_phone` | Contact phone |

## Connect it

Hotmart does not sign the notice body: it sends a fixed token per account, the `hottok`, in the `X-HOTMART-HOTTOK` header. Brein compares it with the one you paste.

<Steps>
  <Step title="In Brein">
    Go to **Settings → Integrations → Connect → Hotmart** and copy the **address**.
  </Step>

  <Step title="In Hotmart">
    In Hotmart's webhook settings, create one with **version 2.0.0**. Paste the address and choose the approved purchase event.
  </Step>

  <Step title="Copy the hottok">
    Hotmart shows your `hottok` in the same settings. Copy it.
  </Step>

  <Step title="Paste it in Brein">
    In the Integration, paste the token and save. Until you paste it, Brein rejects every notice.
  </Step>
</Steps>

## Which events to choose

`PURCHASE_APPROVED`: an approved purchase. Brein ignores any other event you check.

## Limits

* A buyer with no email or phone arrives as **no person**.
* The `hottok` is the same for your whole Hotmart account.

More about results, how people are recognized and privacy: [Integrations](/integrations). Source: [Hotmart purchase webhook (version 2.0.0)](https://developers.hotmart.com/docs/en/2.0.0/webhook/purchase-webhook).


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