# Share Links Overview

Share links are the URLs a referrer uses to invite friends to your referral program. When someone clicks a share link, they're redirected to your referral program's landing page, and a tracking cookie is set to credit the referrer.

### How share links are organised

Each user has many share links, organised by two dimensions:

* **Engagement medium**: where the referrer accessed the program. Values include `EMBED`, `POPUP`, `HOSTED`, `MOBILE`, `EMAIL`, and `UNKNOWN`.
* **Share medium**: the channel the referrer used to share. Values include `EMAIL`, `FACEBOOK`, `TWITTER`, `PINTEREST`, `WHATSAPP`, `LINEMESSENGER`, `FBMESSENGER`, `SMS`, `LINKEDIN`, `DIRECT`, and `UNKNOWN`.

For example, the `WHATSAPP` link under `MOBILE` is used when a referrer on a mobile device shares via WhatsApp. This segmentation powers the [impact.com analytics platform](https://help.impact.com/en/support/solutions/articles/155000000948), which provides insight into how and where your users are sharing.

A *clean* share link is also provided. If the program uses a vanity link, the clean version is unencoded (for example, `https://example.com/free`) and is returned under the `UNKNOWN` engagement and share mediums.

### How tracking works

When a friend clicks a share link, two things happen:

1. A tracking cookie is set in their browser containing the referrer's referral code. The cookie can be read using the UTT [autofill](https://integrations.impact.com/impact-brand/docs/install-the-utt#autofill-referral-codes-or-cookies) method, and is also picked up automatically by the UTT library.
2. The referrer's referral code is appended to the landing page URL as the `rsCode` query parameter, for example `https://example.com/?rsCode=JOHNDOE`.

### When to use share links vs. referral codes

Share links are ideal for channels like email marketing, CRM, and product integrations where a widget or mobile webview isn't practical.

In some cases, sharing a referral code instead is more reliable, for example on mobile apps or in environments where cookies may be blocked. Adding a "Referral Code" input to your sign-up form ensures referrals can still be tracked when the link itself can't carry the attribution. To look up a user's referral code, use the Lookup a user endpoint.

For the full list of supported share mediums, see the [Share Mediums article](https://help.impact.com/en/support/solutions/articles/155000000322-referral-program-sharing-options-open-graph-metadata-) in the help center.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://integrations.impact.com/brand-api-reference/advocate-api-reference-v1/reference/share-links-overview.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
