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

# Affiliate workflow automation

> Automate affiliate enrollment, sale notifications, commission assignments, and follow-ups using workflows in the HoopAI platform.

Workflows can automate key actions in your affiliate program — from notifying affiliates about new sales to assigning commissions based on custom logic. This reduces manual work and ensures consistent, timely communication with your affiliates.

***

## Affiliate workflow triggers

The following triggers are available for affiliate-related workflows:

| Trigger                    | Fires when                                    |
| -------------------------- | --------------------------------------------- |
| **Affiliate enrolled**     | A new affiliate is added to a campaign        |
| **Affiliate sale**         | A sale is recorded for an affiliate           |
| **Commission approved**    | A commission is approved for payout           |
| **Commission paid**        | A commission payment is processed             |
| **Affiliate link clicked** | A contact clicks an affiliate's tracking link |

***

## Common automation recipes

### Welcome sequence for new affiliates

<Steps>
  <Step title="Trigger: Affiliate enrolled">
    Set the trigger to fire when a new affiliate is enrolled in any campaign (or a specific campaign).
  </Step>

  <Step title="Send a welcome email">
    Add an email action with your affiliate welcome message — include their portal login link, tracking link, and a quick-start guide.
  </Step>

  <Step title="Wait 2 days">
    Add a wait action.
  </Step>

  <Step title="Send onboarding tips">
    Send a follow-up email with tips for promoting your product, recommended content strategies, and links to promotional materials in the affiliate portal.
  </Step>
</Steps>

### Sale notification to affiliate

1. **Trigger**: Affiliate sale
2. **Action**: Send SMS or email to the affiliate: "Congrats! You just made a sale of \[amount] in the \[campaign name] program. Keep it up!"
3. **Optional**: Add an internal notification to your team

### Automated lead assignment notification

1. **Trigger**: Affiliate link clicked (contact created)
2. **Action**: Assign the contact to the affiliate's account manager
3. **Action**: Send an internal notification: "New lead from affiliate \[name]"

### Commission milestone celebration

1. **Trigger**: Commission approved
2. **Condition**: Check if total commissions for this affiliate exceed a threshold (e.g., \$1,000)
3. **Action**: Send a congratulatory email and upgrade the affiliate to a higher commission tier

***

## Automating commission assignments

For programs with complex commission rules that go beyond the standard percentage or flat-rate model:

1. Create a workflow triggered by **Affiliate sale**
2. Use **If/Else** conditions to check:
   * The product purchased
   * The affiliate's total sales count
   * The customer's location or plan type
3. Based on the conditions, set a custom commission amount using a **Custom Field Update** or **Webhook** action to your commission tracking system

***

## Best practices

<AccordionGroup>
  <Accordion title="Keep affiliates informed">
    Automated sale notifications keep affiliates motivated. Seeing real-time results encourages continued promotion.
  </Accordion>

  <Accordion title="Use delays thoughtfully">
    Space out onboarding emails over 3-5 days. Too many emails at once can overwhelm new affiliates.
  </Accordion>

  <Accordion title="Track automation performance">
    Monitor workflow statistics to see how many affiliates complete the welcome sequence, click through onboarding emails, and start generating sales.
  </Accordion>

  <Accordion title="Combine with portal">
    Reference the affiliate portal in your automated messages. Direct affiliates to their portal for tracking links, materials, and commission status.
  </Accordion>
</AccordionGroup>
