---
title: Add leakproof codes to smart links (Shopify)
slug: add-leakproof-codes-to-smart-links-shopify
description: Add leakproof codes to Roster smart links on Shopify to secure customer discounts and prevent misuse by plugins like Honey.
createdAt: 2024-12-18T18:50:46.133Z
---

In this guide, we'll show you how to enhance your ambassadors Smart Links by adding leakproof codes. Leakproof codes offer a secure way to provide customer discounts, preventing misuse from plugins like Honey or Capital One Shopping. These single-use codes ensure ambassadors receive accurate attribution for referrals without the risk of leaked shareable discount codes.

:::hint{type="info"}
This is a Shopify-specific feature.&#x20;

For Shopify Headless merchants, refer to[Add leakproof codes to smart links (Shopify Headless)](docId\:HgZFC7EmsDgX9L5L7Imyf) &#x20;
:::

***

## Step-by-step instructions

These steps assume a smart link already exists for the program. If that's not the case, simply follow the steps in [Set up smart links](docId\:aMBVb-At8xjE4WY49t9pe) before proceeding.

::::WorkflowBlock
:::WorkflowBlockItem
### Add or edit an existing smart link

1. Click `Settings` for the desired program.
2. Open the `Referrals` tab.
3. Locate the existing Smart Link and click `Edit`.
:::

:::WorkflowBlockItem
### Enable leakproof codes

1. Open the `Customer Discount` section.
2. Select `Leakproof Code`.
3. Customize the prefix for the codes (e.g., your brand name) to ensure branding consistency.
4. Choose the discount type:
   - `Percentage Discount` - Specify a percentage (e.g., 15%).
   - `Fixed Amount` - Specify a dollar amount.
5. Define the scope of the discount:
   - All products
   - Specific products
   - Specific collections
6. Optionally, set an end date for the discount if it's tied to a promotion or season.
:::

:::WorkflowBlockItem
### Save and apply settings

1. Click `Save`.
2. Since the leakproof code setup doesn't alter the visual appearance of Smart Links, ambassadors won't need to update their shared links.
:::

:::WorkflowBlockItem
### Test the leakproof code

1. Navigate to your `Contacts` and filter by program (e.g., Influencers).
2. Select an ambassador's profile and copy their smart link.
3. Open the ambassador's smart link in a new browser tab, add a product to the cart, and proceed to checkout.
4. Verify that a leakproof code is automatically applied:
   - The code should have the custom prefix you set.
   - It should be a single-use, randomized code.
:::

:::WorkflowBlockItem
### View leakproof code usage

1. Go to the ambassador's profile in Roster.
2. Check the `Sales Attribution` section:
   - Confirm that the referral is attributed to the ambassador's Smart Link.
3. View the `Discount Rules` to see:
   - The generated leakproof codes.
   - Usage details (e.g., used or unused).

Note: Unused leakproof are automatically cleaned up after the link click's attribution window ends.
:::
::::

***

## Next steps

- [Add shareable codes to smart links (Shopify)](docId\:wYHSmGHkgSLaljHUgwWOu) as an alternative to leakproof codes.
- [Leakproof discount rules](docId\:xWzLihKWgCIVbPijw9UQ1) for a deeper understanding of how they work.
- [Smart link FAQs](docId\:fEjnMn6QyVtiqGGobU-yZ) for common questions and best practices.

***

## Need help?

If you have any questions about adding leakproof codes or optimizing your Smart Links, contact our customer success team at [cs@getroster.com](mailto\:cs@getroster.com). We're here to assist you!
