How SentBy works
From a click on an affiliate's page to a credited sale, and what each side sees on the way.
The parts
| Part | Where it runs | What it does |
|---|---|---|
| Link | go.sentby.co.za | Records the click and sends the shopper to the store with a signed click id. |
| Referral cookie | The store's own server | Keeps the click id on the store's domain for the referral window. |
| Page script | The store's own domain | Saves the referral on cached pages and confirms the landing. Never runs on checkout. |
| Order events | The store's server to api.sentby.co.za | Reports paid, refunded and cancelled orders, signed. |
| Consoles | sentby.co.za | Where stores and affiliates see the same record. |
Links
Every affiliate gets a short link per store. It can point at any page on the store's verified domain.
https://go.sentby.co.za/<code>?u=<store page>&s=<placement>&p=<page path>
# Example: a fridge guide sending readers to a product page
https://go.sentby.co.za/7Hk2pQ9x?u=https://overlandsupply.co.za/gear/die-trommel&s=fridge-table
umust be an https address on one of the store's verified domains. Anything else is refused.sis a placement name you choose (letters, numbers, dot, dash and underscore, up to 64 characters), so you can tell a sidebar from a table.pis the path of the page the link was on. Publishers who wrap links on their own domain add it automatically.
Links never contain words like “affiliate” or “track”, so they survive most ad blockers. Until a store is verified and activated, its links show a neutral page instead of redirecting.
Click ids
Each click gets a signed id that travels to the store in the sbid query parameter. Only SentBy can check the signature; integrations should accept any id that matches the loose pattern below and pass it on unchanged.
sb1.01JD3H8M2Q4W7XKZP0A9BCDEF0.7Hk2pQ9x.K4M2QX7PZA
# Loose pattern for integrations
^sb[0-9]\.[A-Za-z0-9._-]{20,96}$
The referral cookie
The store's server sets the cookie, on the store's registrable domain, so it works on both the apex and www, and lasts as long as the store's referral window (30 days by default).
_sbid: the current click id. HttpOnly, Secure, SameSite=Lax._sbh: up to three earlier click ids, kept for disputes._sbt: a session flag that tells the page script the cookie exists.
A newer click replaces an older one. A click id minted more than an hour earlier never replaces an existing cookie. Responses that set the cookie are marked no-store so no cache keeps them.
Who gets the sale
- SentBy looks at the click id on the order and the click history. The newest valid click from this store, made before its referral window ran out, is the click claim.
- Any coupon code on the order that the store has mapped to an affiliate is the code claim.
- If the click and the code belong to different affiliates and the click was within 7 days of the order, the click wins. Otherwise the code wins. A store can choose to let codes always win.
- If there is neither, the order is not attributed. Its amount still counts in the store's split.
One order credits one affiliate. Visits from search or social after the click do not remove the credit. Commission uses the rules that applied at the time of the click, frozen on the sale.
Statuses
| Status | Means |
|---|---|
| Pending | Paid, waiting for the return window to close. |
| On hold | Needs the store's decision: a possible self-purchase, a click id used for a second order, a click replayed from several networks, a bot-like click, or a suspended affiliate. |
| Approved | Return window closed with no hold. Goes on the next monthly statement. |
| Reversed | Refunded or cancelled in the store, or declined by the store with a reason. |
What cannot be tracked
We would rather tell you now than have you find out in a dispute.
- Different devices. A click on a phone and a purchase on a laptop share nothing SentBy can use. Give creators a code as well as a link.
- In-app browsers, then a different browser later. Inside Instagram, Facebook, TikTok and LinkedIn the click id stays in the address, so “Open in browser” carries it. A purchase days later in a fresh browser, found through search, cannot be linked.
- Declined consent or cleared cookies. If the store waits for consent and the shopper says no, the referral lasts only for that visit.
- Ad blockers on cached pages. The store's server saves most referrals itself. On a page served from cache the page script does it, and an ad blocker can stop that.
- Refunds made only in the payment gateway. If nothing changes in the store, nobody can see it. Stores must record refunds in the store.