Coupons: merchant codes and promotions
Fetch current coupons and promotions from your affiliate programs automatically, hide individual ones, create your own and show them on the website as a coupon box or below product boxes.
Every 6 hours, affilinode fetches the coupons and promotions of the merchants whose affiliate programs you have joined and shows them under "Coupons" in the dashboard. Expired ones and ones the network no longer supplies disappear by themselves. On the website they appear as cards with value, validity, minimum order value and "Show code".
Which networks supply coupons?
- Awin: with the Publisher API token in the affiliate program's login details – coupons and promotions of the set merchant in the shop's countries.
- Tradedoubler: with the Vouchers API token (Tradedoubler → Account → Manage tokens → system "VOUCHERS") in the new login details field – the Products token is not enough. Coupons of all programs in which your site is accepted.
- Webgains: with the same login details as the product feed – coupons (general and exclusive for your campaign) and promotions of the program.
- CJ Affiliate: with token and website ID (PID) as for product search – coupons, discount promotions and free-shipping promotions of all advertisers you have joined.
- ADCELL (only with an API access of its own, not connected yet), Yadore, eBay, AliExpress and own product feeds supply no coupons. Amazon deliberately never – you can't create coupons of your own for an Amazon shop either.
In the dashboard
- The page has two tabs: "Coupons" shows the list, "Fetch shops" the fetch per affiliate program. There it says when it was last fetched, how many coupons there are and whether something is missing (for example the Vouchers token). "Fetch now" brings the next fetch forward.
- Hide: You hide coupons that don't fit your website through the row menu. They stay hidden as long as the network supplies them.
- Own coupons: for example a newsletter or exclusive code a merchant gave you directly – with shop, code or type, discount, minimum order value, validity period, link and terms. Like every offer link, the link gets your website's tracking ID.
On the website
[affilinode_coupons]
[affilinode_coupons merchant="Gartenhaus" kind="code" limit="3"]
[affilinode_coupons product="123"]
[affilinode_product id="123" coupons="1"]
- In the block editor the block is called "Coupons"; it is also available in Elementor and in the shortcode generator.
- merchant = merchant (name as in the dashboard), product = only merchants that carry this product, shop = shop ID from the dashboard, kind = code, offer or free_shipping (comma-separated), limit (1–50, default 6), title (empty = "Coupons and promotions", 0 = no heading), heading = 3, tracking.
- Below product boxes: the setting "Show the merchant's coupons below product boxes" (off by default) or coupons="1" or "0" per box – up to three coupons of the shop with the best offer.
- "Show code" reveals the code and copies it; if the network allows it, the same click opens the shop in a new tab (usual pattern, the click counts in tracking). Without JavaScript and on AMP pages, the code is visible next to the link.
- Accessible: a section with a heading, cards as a list, "Code copied" is read aloud, terms can be expanded.
- Clicks count in the reports as box type "Coupons".
Voucher page per shop
With a few more attributes the coupon box becomes a complete page "All vouchers for shop X":
[affilinode_coupons shop="<shop ID>" mode="infinite" page_size="12" tabs="1" sort_select="1" heading="1" title="All vouchers for Gartenhaus"]
- shop = shop ID from the dashboard. Under Partner programs → tab "Deals" the shortcode for every shop is ready to copy, and so is the embed code.
- mode = more ("Load more" button), infinite (loads while scrolling) or paged (pages with Previous / Next). Without mode it stays one list.
- page_size = vouchers per page (1–50). sort = expiring (ending soon first), new (newest first) or discount (biggest discount first); without it the recommended order. sort_select="1" lets visitors choose the sorting.
- tabs="1" shows tabs for voucher codes, deals and free shipping (only kinds with results). With kind="code" it stays one kind.
- heading="1" turns the title into the main heading of the page; use it on a page that has no other H1.
- The first page is part of the HTML of the page, a small script loads the rest. Every voucher shows "Valid until …"; vouchers ending within 48 hours carry the note "Ending soon".
- There is no structured markup (Schema.org) for vouchers on purpose: search engines do not evaluate it for voucher pages.
Without WordPress: HTML, Ghost and Discourse
The coupon box is also available embedded: as a placeholder <div data-affilinode="coupons"></div> (attributes data-merchant, data-product, data-shop, data-kind, data-limit, data-title; for the voucher page also data-mode, data-page-size, data-sort, data-sort-select, data-tabs, data-heading – like the shortcode attributes; paged shows "Load more" there), as a shortcode [affilinode_coupons …] in Ghost and Discourse, and below product boxes with data-coupons="1" or coupons="1". "Generate code" in the dashboard builds the code (box type "Coupons"); in Discourse it is under "More boxes …" (component from 0.5.0). Below embedded product boxes come the coupons of the merchants that offer the product (up to three). Links carry the tracking ID of the website of the embedding key, and clicks count in the embedding statistics as "Coupons".
The terms of the respective affiliate program apply: exclusive codes only on your own website, no passing on to coupon portals, no codes in paid search if the program excludes it. For programs with restrictions on coupon advertising, check whether you may use the box there.