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

# Stripe Integration — Automate Partner Transactions

> Connect Stripe to Kiflo to automatically create transactions, convert leads to customers, and trigger partner rewards from Stripe payments.

Connecting Stripe to Kiflo eliminates the manual work of recording partner-sourced revenue. When a payment succeeds in Stripe, Kiflo automatically creates a Transaction, links it to the right partner, and can trigger reward calculations — so your partners are accurately credited every time.

## Enable the Stripe integration

<Steps>
  <Step title="Open Integrations">
    Go to **Manage** in the top navigation, then click **Integrations**.
  </Step>

  <Step title="Select Stripe">
    Click the **Stripe** tile.
  </Step>

  <Step title="Add to Kiflo">
    Click **Add to Kiflo**.
  </Step>

  <Step title="Connect your Stripe account">
    You will be redirected to Stripe. Sign in and authorize Kiflo to access your account. Once authorized, you will return to Kiflo automatically.
  </Step>

  <Step title="Configure settings">
    Open the **Settings** tab on the Stripe integration page and configure the options described below.
  </Step>
</Steps>

## Core settings

Open your Stripe integration's **Settings** tab to control how Kiflo pulls and processes data from Stripe.

### Convert lead to customer

When enabled, Kiflo automatically converts a Lead to a Customer upon the lead's first successful payment in Stripe. Kiflo matches the Stripe customer's email address against your Leads.

* If no Lead with that email exists, Kiflo skips it.
* If multiple Leads share the same email, only the first one is converted.

<Tip>
  Use this setting if your product is self-serve and you do not manage sales through Kiflo Deals.
</Tip>

### Associate customer on deal

When enabled, Kiflo associates a Stripe Customer with any matching Kiflo Deals on the customer's first payment. Kiflo matches the Stripe customer's email against the contact email on your Deals.

* If no matching Deal is found, Kiflo skips it.
* If multiple Deals match, all unassociated Deals are linked to the customer.
* If a Customer with the same Stripe Customer ID already exists in Kiflo, it is associated directly. Otherwise, a new Customer record is created.

<Tip>
  Use this setting when your sales process runs through Kiflo Deals.
</Tip>

### Create transaction from succeeded payment

When enabled, Kiflo creates a new Transaction record every time a successful payment is received from Stripe.

Kiflo listens to three payment events:

| Stripe event                 | When it fires                                                                                          |
| ---------------------------- | ------------------------------------------------------------------------------------------------------ |
| **Charge succeeded**         | When you charge a customer on file (with or without an invoice). Common for usage-based subscriptions. |
| **Invoice paid**             | When an invoice is marked as paid — whether collected via Stripe, another method, or manually.         |
| **Payment intent succeeded** | When a customer's Stripe balance is used to collect a payment.                                         |

**How Kiflo calculates transaction amounts**

Kiflo records the amount **net of taxes and discounts**. For example:

| Line                              | Amount  |
| --------------------------------- | ------- |
| Product A                         | €100    |
| Discount (10%)                    | −€10    |
| Subtotal                          | €90     |
| VAT (20%)                         | €18     |
| **Total**                         | €108    |
| **Transaction recorded in Kiflo** | **€90** |

<Tip>
  Enable this setting to capture partner-sourced revenue and power reward calculations for your programs.
</Tip>

### Pull existing payments on lead acceptance

When enabled, Kiflo checks Stripe for an existing customer as soon as a Lead is accepted. If a matching customer is found, Kiflo immediately converts the Lead and imports any existing transactions.

<Tip>
  Use this setting when you register Leads in Kiflo after they have already converted in Stripe — for example, after your trial period ends.
</Tip>

## Advanced configuration

Click **Show advanced options** in the Stripe settings tab to access the following controls.

### Matching method — how Kiflo links Stripe customers to Kiflo records

| Option                 | Description                                                                                    | Best for                                                                                                          |
| ---------------------- | ---------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------- |
| **Full email address** | Kiflo matches the exact email on the Stripe customer to a Lead or Deal contact email in Kiflo. | B2C — the person who signed up as a lead is the same person who pays in Stripe.                                   |
| **Email domain only**  | Kiflo matches only the domain portion of the email (e.g. `@foobar.com`).                       | B2B — the lead contact email (`john@foobar.com`) differs from the billing email in Stripe (`billing@foobar.com`). |

### Transaction naming

| Option                                   | Example                                                                 |
| ---------------------------------------- | ----------------------------------------------------------------------- |
| **Charge description or invoice number** | `"Subscription update"` or `"AD57B97A-0103"`                            |
| **Product names from the invoice**       | `"Kiflo PRM - Premier + Custom Domain"` (up to 3 products concatenated) |

### Transaction creation granularity

| Option                                    | Description                                                                                             | Example                                  |
| ----------------------------------------- | ------------------------------------------------------------------------------------------------------- | ---------------------------------------- |
| **One transaction per invoice or charge** | Creates a single Transaction for the entire invoice or charge. The amount is the sum of all line items. | An invoice with 2 items → 1 Transaction  |
| **One transaction per line item**         | Creates a separate Transaction for each line item in the invoice.                                       | An invoice with 2 items → 2 Transactions |

## Configuration examples

Use the table below to choose the right combination of settings for your business model.

<Tabs>
  <Tab title="Self-serve product">
    Customers sign up and pay without any sales involvement.

    **Recommended settings:**

    * ✅ Convert lead to customer
    * ✅ Create transaction from succeeded payment
    * Matching: Full email address (B2C) or Email domain (B2B)

    Partners are credited automatically the moment their referred customer pays.
  </Tab>

  <Tab title="Sales-led product">
    Your team manages deals in Kiflo before the customer pays in Stripe.

    **Recommended settings:**

    * ✅ Associate customer on deal
    * ✅ Create transaction from succeeded payment
    * Matching: Full email address or Email domain

    Deals are linked to Stripe payments automatically so partner attribution is preserved.
  </Tab>

  <Tab title="Sales-led with one-off items">
    You manage deals in Kiflo and your invoices include additional one-off line items (e.g. onboarding fees).

    **Recommended settings:**

    * ✅ Associate customer on deal
    * ✅ Create transaction from succeeded payment
    * Transaction creation: One transaction per line item

    Each line item generates its own Transaction, giving you granular revenue attribution for commission calculations.
  </Tab>
</Tabs>
