The Fondue Cashback SDK enables seamless integration of cashback functionality into your Shopify e-commerce platform. Once integrated, it exposes methods on the window.Fondue object to track cart events, apply promotions, and more.


🚀 Installation

To install the SDK, insert the following script in the <head> section of your HTML:

<script
  async
  id="fondue-cashback"
  src="<https://public.getfondue.com/cashback-extension/cart/fundle.js>"
  type="application/javascript"
  shop="[YOUR_SHOP]"
  api="[AJAX_OR_STOREFRONT]">
</script>

🔧 Replace Placeholders:


✅ SDK Readiness

Check the SDK status using:

if (window.Fondue.status === "ready") {
  // SDK is ready to use
}

This ensures that you only call SDK methods when it's fully loaded and available.


🧾 Cart ID Setup

To fetch cart contents and apply cashback correctly, the SDK needs to know which cart belongs to the current customer.

You must implement both of the following:

  1. Register the cart ID when a cart is created.
  2. Expose a function that returns the current cart ID whenever the SDK requests it.

Overall Flow Chart