Article

How to create and track vouchers

A tracked voucher lets you credit a sale to a publisher even when the shopper never clicked a tracked link: the code entered at checkout identifies the publisher. Setup happens in two stages, you create the code in Affilae, then your conversion tag tells Affilae which code the customer used.

Requirements: an active partnership with the publisher (only active partnerships appear in the list), the discount code already created in your shop back office (Affilae records the code, it does not create the discount), and a conversion tag able to send the voucher parameter.

Step 1, create the voucher in Affilae

Affilae
MANAGE MY PROGRAMS
Settings
My affiliates
Medias
Ads
Products Feeds
Vouchers
Clicks
Conversions
Payments
The program menu: « Vouchers » sits under « Medias ».
  1. In the left menu, open Manage programs and click the program concerned.
  2. In the program menu, expand Medias and click Vouchers.
  3. Click the Add button at the top right of the list.
  4. Stay on the Individual voucher tab, then fill in Select a partnership: pick the publisher or publishers who own this code.
  5. In Voucher, type the code exactly as it exists in your shop, then press Enter or Space to confirm it. You can add several codes in a row.
  6. Set the Beginning date and Expiration date if needed, then the Description (required), which helps the publisher recognise the code.
  7. Click Submit. The code appears in the list right away, and the publisher sees it in their own Vouchers menu.
Create voucher
Individual voucher Bulk add vouchers
Select a partnership *
Lea Creations
Voucher *
LEA20 To add a voucher, press Enter or Space
Maximum 40 characters. To add promo codes in bulk, separate them with a comma
Beginning date
01/09/2026
Expiration date
31/12/2026
Description *
Exclusive Instagram code, 20 % off
Cancel Submit
The « Create voucher » form: partnership, code, validity dates and description.

There is deliberately no discount amount field and no commission rule attached to the code. The value of the discount stays in your shop, and the commission paid follows the commission rules of the partnership concerned.

Create several codes at once (CSV import)

The Bulk add vouchers tab imports a CSV file. Click Download template to get a file with the five expected columns:

  • TrackingID: the publisher identifier, that is the value of the ID column in My affiliates.
  • VoucherName: the voucher code itself (despite its name, this is not a label).
  • VoucherDescription: the description the publisher will see.
  • StartDate and EndDate: the validity dates in DD/MM/YYYY format.

Drop the file, click Submit: Affilae shows a row by row summary and flags the errors (« Unknown tracking ID », « Voucher already exists », « Duplicate in file », « Invalid date », « Missing data »). Delete the faulty rows, then click Submit a second time to save the import.

Tip: build the CSV in Google Sheets or LibreOffice rather than Excel, which often rewrites the separator and the date format. Affilae accepts both the comma and the semicolon, and the file must be encoded in UTF-8.

Next to Add, the Blacklist button covers the opposite case: it automatically refuses sales made with codes you do not want to reward, either for one partner or for all of them.

Step 2, send the code in the conversion tag

Creating the code in Affilae is not enough. Your site must tell Affilae, on every order, which code the customer used. That information travels in the voucher parameter of the conversion tag.

  1. Open Manage programs, your program, then Configuration.
  2. Go to the Tracking tab, expand Custom integration (Script) and find the Track conversions step.
  3. Copy the tag, then make the voucher line fill itself dynamically with the code actually entered at checkout.
Conversion tag, JavaScript excerpt
var aeEvent = {};
aeEvent.key = ‘your-tracking-key’;
aeEvent.Conversion = {};
aeEvent.Conversion.id = ‘ORD-10245’;
aeEvent.Conversion.amount = ‘89.90’;
aeEvent.Conversion.currency = ‘EUR’;
aeEvent.Conversion.voucher = ‘LEA20’;
AeTracker.sendConversion(aeEvent);
Image or iframe tag variant, the code travels in the URL:
https://lb.affilae.com/?key=your-tracking-key&id=ORD-10245&amount=89.90&currency=EUR&voucher=LEA20
The « voucher » parameter carries the promo code, with sample values.

Three things to remember:

  • The code is matched exactly, uppercase and lowercase included. « LEA20 » and « lea20 » are not the same code.
  • If the order uses no voucher, leave the parameter empty. Affilae simply ignores it.
  • The same parameter exists in the Postback – Server-to-Server integration and in the Custom Integration – API. If you use an Affilae plugin (PrestaShop, WooCommerce, Shopify), the plugin sends the code for you and there is no tag to edit.

When a tracked click and a voucher overlap

This is the least understood case. When an order carries a voucher and a valid tracked click is still in memory, Affilae does not pick a winner at random: the voucher adds an extra contribution to the conversion funnel, and the program Attribution mode (program Settings) decides who is paid.

  • First click: the commission goes to the publisher behind the first contribution, so to the tracked click. The code owner appears in the funnel without earning anything.
  • Last click: the voucher contribution being the most recent one, the commission goes to the code owner.
  • Share: the commission is split between the contributing partners, according to their respective weight.

With no valid tracked click, or when the last click is older than the tracking duration of your rule, the voucher owner receives the whole commission whatever the attribution mode.

Why track your vouchers

  • Reward content creators where clickable links work poorly: Instagram, TikTok, YouTube, Snapchat, podcasts, stories.
  • Recover lost sales when the shopper saw the publisher content, then came straight to your site without using a link.
  • Track offline sales, by phone or in store, through a dedicated code.
  • Measure partner by partner, since each code belongs to one publisher and shows up in your conversions like any other affiliate sale.

Best practices

  • One code per publisher, never shared. If two partners hold the same code, attribution becomes ambiguous.
  • Keep the code exclusive. Do not publish it on your own site or on coupon sites, otherwise you pay a commission on sales you would have made anyway.
  • Fill in the validity dates so the Affilae code matches the real campaign. The Status filter on the list then separates Active and Inactive codes.
  • Create the code in your shop before creating it in Affilae, to avoid any spelling mismatch between the two.
Tip: before sharing the code with your partner, place a test order using the code without clicking any tracked link. If the conversion lands on the right publisher, your voucher parameter is correctly wired.

Use cases

  • An Instagram influencer. Lea features your products in her stories, with no usable clickable link. You create the LEA20 code valid for three months: every order placed with that code is credited to her and triggers her commission.
  • A media outlet reviewing your products. The magazine publishes an article and a reader code. Some readers click the tracked link, others only remember the code. Both paths are recorded, and your attribution mode decides the split.
  • A radio or podcast campaign. The listener clicks nothing, they just remember a code read out on air. That code, created for the partnership concerned, is the only measurable link between the broadcast and the sale.

Related articles

Frequently asked
questions

In the program menu, open « My affiliates »: the « ID » column shows the tracking number of each partner. That value, not the publisher name, is what the TrackingID column expects. A number unknown to the program triggers the « Unknown tracking ID » error.

Yes. Affilae matches the code received in the conversion tag exactly, uppercase and lowercase included. Enter the code in Affilae exactly as it exists in your shop, and check that your site does not alter it (automatic uppercasing, extra space).

A non expired code with that name already exists for this partner. Find it in the list with the search bar, then edit its dates with the pencil icon instead of creating it again. To give the same code to another partner, prefer a distinct code so attribution stays unambiguous.

No, attribution is not retroactive. Only conversions received after the code was saved, and within its validity period, are credited to the publisher. To catch up on earlier sales, use a manual conversion or a bonus.

The code stops being recognised: later orders using it are no longer credited to the publisher. Conversions already recorded are not modified and keep their commission. To pause a code without deleting it, simply set an expiration date.

Check three things in order: the code exists in the « Vouchers » list and is active on the order date, the partnership is active, and your conversion tag really sends the voucher parameter with the right value. A test order using the code, without clicking a tracked link, settles it immediately.

Need help?

Stay up to date with the latest trends in affiliate marketing and never miss any of our articles.

Contact Us