Skip to main content
A program is the core unit in AgentRef. It defines how affiliates earn commissions, how long attribution cookies last, and when payouts happen. You can run multiple programs under one merchant account.

Create a program

1

Via the dashboard

After connecting Stripe, the onboarding flow walks you through creating your first program. You can also create additional programs from Programs > New Program at any time.
2

Via the API

Program settings

Required settings

Optional settings

The payoutThreshold is specified in cents. A value of 5000 means $50.00.

Commission types

AgentRef supports three commission models:

One-time (one_time)

The affiliate earns a commission on the first payment only. If a customer upgrades, renews, or makes additional purchases, no further commissions are generated. Best for: One-time purchases, lifetime deals, products without subscriptions.

Recurring (recurring)

The affiliate earns a commission on every payment the referred customer makes, for the lifetime of the subscription. If the customer pays monthly, the affiliate earns every month. Best for: SaaS with subscriptions. This is the most popular model because it incentivizes affiliates to refer customers who stick around.

Recurring with limit (recurring_limited)

Same as recurring, but commissions stop after a configured number of months (commissionLimitMonths). For example, 25% for the first 12 months. Best for: SaaS that wants to cap lifetime affiliate payouts while still rewarding ongoing referrals during the customer’s early months.

Program status lifecycle

Every program has a status that controls whether it is actively tracking conversions: Update a program’s status via the API:

Program readiness

AgentRef tracks whether your program is fully configured and ready to process conversions. The readiness field on a program can be: Check readiness via the API by fetching the program detail:
If you are unsure where to start, these are industry-standard defaults for SaaS affiliate programs:
You can change all of these settings later. Start simple and adjust based on real performance data.

What’s next

Connect Stripe

Link your Stripe account if you haven’t already.

Install Tracking

Add the tracking script to your website to start capturing clicks.