> For the complete documentation index, see [llms.txt](https://docs.tracknow.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.tracknow.io/affiliates/affiliate-payments-with-stripe.md).

# Affiliate Payments with Stripe

Tracknow integrates with your Stripe account to enable direct affiliate payouts. When an affiliate submits a payment request and selects **Stripe** as their preferred payment method, you can approve the request and Tracknow will transfer the approved commission directly to the affiliate through Stripe.

***

## Integration with Stripe

Navigate to **Settings** → **Integrations** → **Connect Stripe Payouts**

Fill out each required field.

### Generate a Stripe API key

Visit Stripe's documentation on API keys [here](https://docs.stripe.com/keys).

The Stripe API key allows Tracknow to securely communicate with your Stripe account on your behalf.

It is used to perform the actions required for the Stripe Connect integration, including:

* Creating onboarding links so affiliates can connect their Stripe accounts.
* Retrieving information about connected Stripe accounts to verify their payout status.
* Initiating transfers to affiliates when you approve Stripe payment requests.

You create a general API key or a restricted API key.

{% hint style="info" %}
If you opt to use a restricted API key, make sure to set the following permissions:

Account → **Read**\
Connect > Accounts → **Write**\
Connect > Account Links → **Write**\
Transfers → **Write**\
\
The rest of the permissions can be set to **None**
{% endhint %}

### Create two webhooks

Visit Stripe's documentation on Webhooks [here](https://docs.stripe.com/api/webhook_endpoints/create?api-version=2026-06-24.preview\&rds=1).

Webhooks allow Stripe to automatically notify Tracknow when specific events occur in your Stripe account. This keeps affiliate payout and connected account information synchronized without requiring Tracknow to continuously check Stripe for updates.

{% hint style="info" %}
Use the following URL endpoint for both webhooks:

{% code overflow="wrap" %}

```
https://api-merchant.tracknow.io/api/webhook/stripe
```

{% endcode %}
{% endhint %}

#### **Webhook 1**

* **Scope:** Your Account
* **Event:** `transfer.reversed`

This webhook notifies Tracknow whenever a transfer to an affiliate is reversed. We use it to update the payment status in Tracknow and keep your payout records accurate.

#### **Webhook 2**

* **Scope:** Connected Accounts
* **Event:** `account.updated`

This webhook notifies Tracknow whenever one of your affiliates' connected Stripe accounts is updated. We use it to detect changes to the account's verification status, capabilities, and payout eligibility so affiliates can receive payments as soon as their accounts are ready.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.tracknow.io/affiliates/affiliate-payments-with-stripe.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
