# Affiliates

> Invite affiliates to promote your app for a commission.

![Affiliates](@assets/docs/affiliates-table.png)

## Revenue Tracking

Revenue tracking is a crucial aspect of affiliate marketing, as it allows monitoring and measuring the performance of campaigns and attributing correct commissions to the affiliates.

<Warning>
  Setting up a revenue tracking integration is required to get started with the Affiliates feature.
  Follow instructions on the dashboard to set it up.
</Warning>

<Warning>
  Valid payment method is required to get started with the Affiliates feature. It is to
  ensure that affiliates are paid for their promotion. Follow instructions on
  the dashboard to set it up.
</Warning>

### RevenueCat

[RevenueCat](https://revenuecat.com) is a subscription management platform that simplifies the process of managing subscriptions and in-app purchases in mobile apps. Established integration provides accurate and timely data about the revenue in your app from the [App Store](https://apps.apple.com), [Google Play](https://play.google.com), and also from [Stripe](https://stripe.com) if connected.

<Info>
  For correct attribution ensure using the same user ids in RevenueCat and WinWinKit.
</Info>

### Stripe

[Stripe](https://stripe.com) is an online payment processing platform that allows businesses to accept and manage payments through their websites and apps. Established integration provides accurate and timely data about the revenue made via the platform.

<Info>
  For correct attribution set [Stripe Customer ID](/docs/users/introduction/#stripe-customer-id) when creating/updating a user in WinWinKit.
</Info>

<Warning>
    If existing [RevenueCat](https://revenuecat.com) integration provides revenue information from [Stripe](https://stripe.com) too, adding separate integration for [Stripe](https://stripe.com) is not needed, and it might cause duplicate revenue data. To verify if [RevenueCat](https://revenuecat.com) provides [Stripe](https://stripe.com) data, check the integrations page on the [RevenueCat](https://revenuecat.com) dashboard.
</Warning>

## Creating a Campaign

### General

#### Code

Each affiliate campaign has its unique code by which users claim attached rewards and are linked to a specific campaign.

Assign a custom value or generate a random one.

![Affiliates Create Code](@assets/docs/affiliates-create-code.png)

### Affiliate Rewards

Affiliates promote your app for a specified commission over a given period of time.

<Tip>
  Affiliate rewards can be used in combination or separately, giving you the
  flexibility to create a tailored campaign for your app and affiliates.
</Tip>

#### Revenue Percentage

Set the commission percentage earned from each purchase.
Initial and recurring purchases are counted towards the commission.

![Affiliates Create Revenue Percentage](@assets/docs/affiliates-create-revenue-percentage.png)

#### Amount per User

Set fixed amount earned for each user who claims the code.

<Info>
  The amount per user can be counted towards the commission only once per user.
</Info>

![Affiliates Create Amount per User](@assets/docs/affiliates-create-amount-per-user.png)

#### Amount per Conversion

Set fixed amount earned for each user conversion.

Learn more about user's [is premium](/docs/users/introduction/#is-premium) flag to understand how conversions are tracked.

<Info>
  The amount per conversion can be counted towards the commission only once per
  user.
</Info>

![Affiliates Create Amount per Conversion](@assets/docs/affiliates-create-amount-per-conversion.png)

#### Duration

Set the duration of the affiliate campaign in months.

The duration is counted from the first time the affiliate code is claimed by a user.

<Info>
  The campaign is archived after the duration is over. Note that users can still
  claim the affiliate campaign's code after the campaign's duration is over, but
  the tracked revenue is not counted towards the commission for the affiliate.
</Info>

![Affiliates Create Duration](@assets/docs/affiliates-create-duration.png)

### User Rewards

To improve conversion of signups configure rewards for the user who arrives via the affiliate campaign.

![Affiliates Create User Rewards](@assets/docs/affiliates-create-user-rewards.png)

Learn more about [Rewards](/docs/rewards/introduction/).

## States

During the life cycle of the campaign, the state of the campaign can be changed.

![Affiliates States](@assets/docs/affiliates-states.png)

### Active

The campaign is active and users can claim rewards. Tracked revenue is counted towards the commission for the affiliate.

### Pending

The campaign is pending and an affiliate should accept the campaign to activate it.

### Requests

The incoming requests from affiliates signing up via the [Affiliate Form](/docs/pages/affiliate-form/) are displayed here.
You need to accept or reject the request.

### Archived

The campaign is archived after the duration of the active campaign has passed the due date.
User can still claim rewards for the campaign, but the tracked revenue is not counted towards the commission for the affiliate.

## Preview

Press a campaign row in the table to open the preview page.
Complete information about the affiliate, rewards, and analytics are displayed there.

![Affiliates Active Preview](@assets/docs/affiliates-active-preview.png)

## Payouts

WinWinKit is responsible for tracking the revenue and transferring the commissions to the affiliates.

## Guides

Check out our guide about [setting up Affiliates with RevenueCat](/docs/guides/setting-up-affiliates-with-revenuecat/).
