Thinkific Affiliate Program: Complete Integration Guide | AffiliateBase

Create an Affiliate Program with Thinkific

Step-by-step guide to integrating affiliate tracking with your Thinkific online course platform

Thinkific is a leading online course platform that helps course creators build, market, and sell online courses. If you're using Thinkific to sell courses and want to grow your student base through affiliate marketing, AffiliateBase provides seamless integration.

This comprehensive guide will walk you through everything you need to know about setting up an affiliate program with Thinkific, from webhook configuration to tracking course enrollments, subscription purchases, and student conversions.

Whether you're selling single courses, course bundles, or subscription-based access, an affiliate program can help you acquire new students while rewarding your partners for successful referrals.

Follow these steps to integrate AffiliateBase with Thinkific:

1

Set Up Thinkific Webhooks

Navigate to your Thinkific admin dashboard and go to Settings > Integrations > Webhooks. Create a new webhook endpoint pointing to AffiliateBase.
text
https://api.affiliatebase.com/webhooks/thinkific
2

Select Webhook Events

Subscribe to the following Thinkific events: enrollment.created, order.created, and subscription.created. These events will trigger affiliate tracking.
3

Add Webhook Secret to AffiliateBase

Copy your webhook secret from Thinkific and add it to your AffiliateBase dashboard under Settings > Integrations > Thinkific.
4

Configure Commission Rules

Set up your commission structure in AffiliateBase dashboard. You can configure different rates for different courses or course types.
5

Pass Affiliate IDs to Thinkific

Add affiliate tracking parameters to your Thinkific course URLs. AffiliateBase will capture these and attribute conversions correctly.
6

Test the Integration

Create a test purchase or enrollment in Thinkific to verify that affiliate tracking is working correctly. Check your AffiliateBase dashboard for the conversion.

Thinkific Webhook Handler Example

Here's an example of how to handle Thinkific webhooks for affiliate tracking:

// Example: Next.js API route for Thinkific webhooks
import { headers } from 'next/headers';
import crypto from 'crypto';
import { AffiliateBase } from '@affiliatebase/sdk';

const affiliateBase = new AffiliateBase({
  apiKey: process.env.AFFILIATEBASE_API_KEY!,
});

export async function POST(request: Request) {
  const body = await request.text();
  const signature = headers().get('x-thinkific-signature')!;
  
  // Verify webhook signature
  const expectedSignature = crypto
    .createHmac('sha256', process.env.THINKIFIC_WEBHOOK_SECRET!)
    .update(body)
    .digest('hex');
  
  if (signature !== expectedSignature) {
    return new Response('Invalid signature', { status: 401 });
  }
  
  const event = JSON.parse(body);
  
  // Handle different event types
  switch (event.type) {
    case 'enrollment.created':
      await affiliateBase.trackConversion({
        affiliateId: event.data.enrollment.metadata?.affiliateId,
        type: 'course_enrollment',
        amount: event.data.enrollment.price,
        currency: event.data.enrollment.currency,
        customerId: event.data.enrollment.user_id,
        metadata: {
          course_id: event.data.enrollment.course_id,
          course_name: event.data.enrollment.course_name,
          enrollment_id: event.data.enrollment.id,
        },
      });
      break;
      
    case 'order.created':
      await affiliateBase.trackConversion({
        affiliateId: event.data.order.metadata?.affiliateId,
        type: 'course_purchase',
        amount: event.data.order.total_price,
        currency: event.data.order.currency,
        customerId: event.data.order.customer_id,
        metadata: {
          order_id: event.data.order.id,
          line_items: event.data.order.line_items,
        },
      });
      break;
      
    case 'subscription.created':
      await affiliateBase.trackConversion({
        affiliateId: event.data.subscription.metadata?.affiliateId,
        type: 'subscription',
        amount: event.data.subscription.price,
        currency: event.data.subscription.currency,
        customerId: event.data.subscription.customer_id,
        subscriptionId: event.data.subscription.id,
      });
      break;
  }
  
  return new Response(JSON.stringify({ received: true }), { status: 200 });
}

Why Use AffiliateBase with Thinkific?

AffiliateBase is the perfect solution for Thinkific course creators who want powerful affiliate tracking without complexity.

Native Thinkific Integration

Built-in integration with Thinkific webhooks. Automatically tracks course enrollments, purchases, and subscriptions without custom code.

Real-Time Tracking

Track conversions in real-time as students enroll or purchase courses. No delays or batch processing.

Subscription Support

Tracks subscription-based course access, including monthly and annual subscriptions. Ensures affiliates receive commissions for recurring revenue.

Multiple Course Support

Support for different commission rates based on course type, price, or category. Perfect for schools with multiple courses.

Affiliate Dashboard

Give your affiliates a professional dashboard to track their performance, view commissions, and generate affiliate links for specific courses.

Webhook Security

Built-in webhook signature verification ensures only legitimate Thinkific events are processed, protecting your affiliate program from fraud.

Frequently Asked Questions

Does AffiliateBase work with Thinkific?

Yes! AffiliateBase integrates seamlessly with Thinkific through webhooks. It automatically tracks course enrollments, purchases, and subscription sign-ups.

How are course enrollments tracked?

AffiliateBase tracks Thinkific enrollments through webhooks. When a student enrolls in a course via an affiliate link, the enrollment.created webhook triggers affiliate tracking and commission calculation.

Can I track subscription-based courses?

Yes! AffiliateBase tracks Thinkific subscriptions through the subscription.created webhook. Affiliates receive commissions for subscription sign-ups and can be configured to receive commissions on renewals as well.

Can I set different commission rates for different courses?

Yes! You can configure different commission structures in AffiliateBase based on course, course category, or price. This gives you full control over your affiliate program.

How do I add affiliate tracking to my Thinkific course URLs?

Add affiliate tracking parameters to your Thinkific course URLs (e.g., ?ref=AFFILIATE_ID). AffiliateBase will capture these parameters and attribute conversions correctly when students enroll or purchase.

Do affiliates get their own dashboard?

Yes! Affiliates get access to a professional dashboard where they can view their conversions, commissions, performance metrics, and generate affiliate links for specific courses.

What happens if a student purchases multiple courses?

Each course purchase is tracked separately. If a student purchases multiple courses through an affiliate link, the affiliate receives commissions for each purchase.

Ready to Launch Your Thinkific Affiliate Program?

Get started with AffiliateBase today and start growing your Thinkific school through affiliate marketing.