Command Palette

Search for a command to run...

UnylyUnyly
Back to skills

referral-program

FreeNo executable scriptsNot checked

Designs, specifies and diagnoses customer referral programs and affiliate programs for software and subscription businesses: whether to run one, how large the…

TerminalSkillsby TerminalSkills★ 221 GitHub stars

About this skill

Referral Program

Overview

A referral program pays existing customers, usually in account credit, when someone they invite becomes a paying customer. An affiliate program pays outside publishers a commission for the same result. Both are acquisition channels with a cost per customer, and both fail in predictable ways: rewards larger than the margin allows, rewards paid for sign-ups that never pay, links that leak to coupon sites, and attribution that cannot be audited.

This skill takes a business from numbers to a written specification an engineer can build: an economics check, the reward rules, a data model with a status flow, the billing calls, abuse controls, the compliance points that apply, and the queries that show whether it works. It also diagnoses a program that already exists.

Instructions

1. Collect the numbers and decide whether to build

Ask for, or pull from billing and analytics: active paying customers, new customers per month and how many already arrive by recommendation (a "how did you hear about us" field, direct and branded traffic), average revenue per account per month, gross margin, monthly churn, the blended cost of acquiring a customer through paid channels, the billing system, and the refund window.

Decide with the user before designing anything:

  • If almost nobody recommends the product today, a reward will not create the habit. Fix the product or onboarding first and say so.
  • With a small customer base (a few hundred or fewer), run it by hand first: a personal email with a unique link and a manually applied credit. Build the machinery when the manual version produces customers.
  • If recommendations already happen, a program mainly makes them trackable and more frequent. Expect part of the "referred" volume to be people who would have come anyway, and plan for that in the maths.

2. Choose the program type

Customer referral Affiliate or partner
Who promotes Existing customers, to people they know Publishers, creators, consultants, to an audience
Reward Account credit, free period or plan upgrade, usually for both sides Cash commission, flat or a share of revenue for a set period
Volume and trust Low volume, high trust, high retention Higher volume, variable quality
Extra obligations Simple terms Contract, disclosure rules, tax forms, payout operations, brand rules

Start with customer referral unless the product is sold through advisers or reviewed by publishers. Run both only with separate links and separate rules, and never let one person collect both rewards for the same customer.

3. Size the reward

The reward has to be noticeable to the person sharing and still leave the channel cheaper than the alternatives. Check both with the business's own numbers:

def referral_economics(arpa, gross_margin, monthly_churn, paid_cac,
                       referrer_reward, friend_reward, incremental_share):
    """All money in one currency. incremental_share: fraction of referred
    customers who would not have signed up without the program (0-1)."""
    margin_month = arpa * gross_margin
    ltv = margin_month / monthly_churn
    cost = referrer_reward + friend_reward
    cac = cost / incremental_share
    return {
        "ltv": round(ltv), "reward_cost": cost, "effective_cac": round(cac),
        "payback_months": round(cac / margin_month, 1),
        "ltv_to_cac": round(ltv / cac, 1), "vs_paid_cac": f"{cac / paid_cac:.0%}",
    }

Rules for reading the result:

  • Count rewards at face value. Credit given to a paying customer is revenue you would otherwise have collected.
  • incremental_share is unknown at launch. Compute the result at an optimistic and a pessimistic value (for example 0.6 and 0.3) and keep the reward only if the pessimistic case is still acceptable.
  • Keep effective_cac below the paid-channel figure and the payback period inside what the business accepts for other channels. If the pessimistic case fails, lower the reward or pay it in a form that costs less than its face value (plan upgrade, usage allowance).
  • Two-sided rewards are the default: the friend gets a reason to use the link instead of signing up directly, which is what makes attribution possible.

4. Write the rules

State each of these in the specification, in one sentence each:

  • Who can refer: paying customers in good standing; staff and resellers excluded.
  • Who counts as referred: a person or company with no previous account, payment method or trial.
  • Qualifying event: the first paid invoice, and the reward is released only after the refund window has passed. Never pay on sign-up.
  • Attribution: the link https://app.../r/CODE sets a first-party cookie for a fixed window (30 to 90 days) and the code is stored on the account at sign-up; a code typed at checkout overrides the cookie; the last valid code before sign-up wins.
  • Limits: a cap per referrer per year, an expiry for unu
Full SKILL.md on GitHub

Install referral-program in Claude Code & Claude Desktop

Sign up to install this skill

Create a free account to reveal the install command and save the skill to your library.

  • Reveal the one-line install command
  • Save skills to your synced library
  • Get notified when skills update
Sign up freeI already have an account

Allowed tools

Tools this skill is permitted to call.

No restriction — this skill can use any tool.

Bundled files

_scores.json

FAQ

What does the referral-program skill do?

Designs, specifies and diagnoses customer referral programs and affiliate programs for software and subscription businesses: whether to run one, how large the reward can be, how attribution and payout work in the database and billing system, how to stop abuse, and how to measure whether it pays. Use when a user asks to "set up a referral program", "add refer-a-friend", "give credit for invites", "launch an affiliate program", "what commission should we pay", "why is nobody using our referral link", or mentions word of mouth, invite codes, ambassadors or partner payouts.

How do I install the referral-program skill?

Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.

Does the referral-program skill run scripts?

No, this skill is instructions only (SKILL.md) with no executable scripts.

Related skills

Compare referral-program with