Free Eleventy plugin

Eleventy affiliate plugin: eleventy-plugin-avdeb

eleventy-plugin-avdeb turns {avdeb-products …} tags in your Markdown into product carousels, grids and lists, and adds avdebProducts, avdebProduct and avdebButton shortcodes for Nunjucks, Liquid and 11ty.js. Products are fetched once per build and written into your HTML with your referral code on every link.

  • v0.1.0
  • Eleventy 3.0+
  • Node.js 18+
  • Free

Why use eleventy-plugin-avdeb on Eleventy

  • Static HTML

    Products are written into your pages at build time: no client-side API calls, and the CSS and carousel script load only on pages that show products.

  • Resilient builds

    Responses are cached in .cache/avdeb between builds, and the last good copy is used for a week if AVDEB can't be reached. A failed embed never breaks the build.

  • Your own markup

    The avdebData filter and createAvdeb() return product cards for your own templates and data files.

  • Your referral code on every link

    Paste a secret key or referral code once; every product link earns you 5% commission.

  • Honest links

    Referral links get rel="sponsored", with an optional affiliate disclosure for FTC rules.

  • Private by default

    No cookies, trackers or third-party scripts. Your secret key stays on the server.

  • Fast and resilient

    Products are cached per query; if AVDEB is unreachable the last good copy is served for a week.

  • Four layouts

    Grid, carousel, list (“shop the post”) and spotlight. Single products as a compact card, horizontal card or hero with your own badge and note.

How to add affiliate products to Eleventy

npm install eleventy-plugin-avdeb
  1. 1

    Add the plugin

    Run npm install eleventy-plugin-avdeb and call eleventyConfig.addPlugin(avdeb) in eleventy.config.js. Options there become the default for every embed.

  2. 2

    Connect your affiliate account

    Add AVDEB_REF_CODE=YOURCODE to .env (it's read automatically), or AVDEB_SECRET_KEY=avdeb_sk_… for up to 48 products per embed. The key is only used at build time.

  3. 3

    Add products

    Write {avdeb-products https://avdeb.com/category/stickers/} on its own line in any post, or use the shortcodes in your templates.

Where products can go: Markdown posts · Nunjucks, Liquid and 11ty.js shortcodes.

Examples

eleventy.config.js

import avdeb from "eleventy-plugin-avdeb";

export default function (eleventyConfig) {
  eleventyConfig.addPlugin(avdeb, { layout: "carousel" });
}

Tags in Markdown

{avdeb-products https://avdeb.com/category/stickers/ layout="carousel"}
{avdeb-product https://avdeb.com/store/custom-qr-code-keychain/ variant="hero"}

Shortcodes

{% avdebProducts { tag: "stickers", layout: "carousel", limit: 10 } %}
{% avdebProduct "https://avdeb.com/store/cat-sticker/", { variant: "hero" } %}
{% avdebButton { href: "/creators/your-slug/", label: "Visit my shop" } %}

Paste any avdeb.com creator , category or product link — the source is detected automatically.

Earn commission from your Eleventy site

  • 5%

    of every sale you refer

  • 30 days

    cookie window

  • $50

    minimum payout, monthly via PayPal

  • Free

    to join, open worldwide

The plugin works without an account, but links only earn once you're an approved affiliate. Design stickers or 3D prints? Apply as a creator and show your own shop instead.

Eleventy plugin FAQ

How do I add affiliate products to an Eleventy site?

Install eleventy-plugin-avdeb, add your referral code to .env, and write {avdeb-products …} with any avdeb.com link in a Markdown post. The plugin renders the products at build time.

How often are prices updated?

Whenever the site builds. Products stay fresh in the cache for 6 hours by default, so a daily scheduled build keeps prices current.

Does it work with Nunjucks and Liquid?

Yes. The shortcodes work in Nunjucks, Liquid, 11ty.js and WebC, and the {avdeb-…} tags work in any HTML page Eleventy writes.

How much can I earn as an AVDEB affiliate?

5% of every completed sale you refer, with a 30-day cookie and no cap. Commissions are paid monthly via PayPal in USD once your balance reaches $50. Joining is free and open worldwide; approval usually takes under 24 hours.

Secret key or referral code — which should I use?

Both credit your sales. A secret key (avdeb_sk_…) adds your code automatically, shows who you're connected as, and allows up to 48 products per embed; it stays on the server. A referral code alone allows up to 12 products. Never put a secret key in page content.

Also available for