> For the complete documentation index, see [llms.txt](https://docs.wandreferrals.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.wandreferrals.com/programs-and-commissions/geo-and-eligibility.md).

# Geography and eligibility

## What it does

Before any commission is paid on an attributed order, Wand Referrals runs an **eligibility check**. Even when an affiliate is correctly credited, the commission can be held or denied if it fails one of these rules. This protects you from paying on out-of-territory, self-referred, or suspicious orders.

## The eligibility checks (in order)

1. **Program present** — the affiliate must belong to a valid program.
2. **Self-referral** — if *Disable self-referral* is on (the default) and the affiliate's email matches the customer's email, the commission is denied (`SELF_REFERRAL_BLOCKED`).
3. **IP blocklist** — orders from blocked IPs are denied (`IP_BLOCKED`).
4. **Paid-ad traffic** (fraud, off by default) — orders arriving with ad-click params (gclid, fbclid, …) or an ad-network referrer can be flagged for review (`PAID_AD_TRAFFIC`).
5. **IP velocity** (fraud, off by default) — too many orders from one IP can be flagged (`IP_VELOCITY_FLAGGED`).
6. **Affiliate territory override** — a per-affiliate territory restriction, if set.
7. **Program geo rules** — the shipping destination must satisfy the program's geo restriction.

A flagged (review) result routes the commission to **Pending** for your review rather than rejecting it outright.

## Geo restrictions

Turn on **Geo restriction** in a program and choose a restriction type:

| Type                          | Meaning                                                 |
| ----------------------------- | ------------------------------------------------------- |
| Home state only               | Only orders shipping to the affiliate's home state earn |
| State match / state whitelist | Only allowed states earn                                |
| Allowed states                | An explicit list of allowed states                      |
| Territory match               | Territory-based (uses the territory selector)           |

You also control **fallback behavior** when the shipping address is missing or ambiguous:

* **Deny** (default), **Allow**, **Use billing address**, or **Manual review**.

And **discount behavior** for geo-restricted orders:

* **Allow discount, deny commission** (default), **Block discount**, or **Manual review**.

Common geo reason codes on a sale: `OUT_OF_STATE`, `OUT_OF_ALLOWED_REGION`, `MISSING_SHIPPING_ADDRESS`, `MANUAL_REVIEW_REQUIRED`, `AFFILIATE_RESTRICTION_OVERRIDE`.

## Reading the decision

Every commission stores the eligibility outcome and a reason code, visible on the sale's detail page alongside the [attribution decision trace](https://github.com/wand-referrals-app/wand-referrals/tree/codex/gitbook-docs-foundation/docs/manual/attribution/how-attribution-works/README.md). If a commission you expected didn't appear or is Pending, the reason code tells you which rule fired.

## Related

* [How attribution works](https://github.com/wand-referrals-app/wand-referrals/tree/codex/gitbook-docs-foundation/docs/manual/attribution/how-attribution-works/README.md)
* [Fraud monitoring](https://github.com/wand-referrals-app/wand-referrals/tree/codex/gitbook-docs-foundation/docs/manual/settings/settings-overview/README.md)
* [Refunds, returns & chargebacks](https://github.com/wand-referrals-app/wand-referrals/tree/codex/gitbook-docs-foundation/docs/manual/reversals/refunds-returns-chargebacks/README.md)
