> For the complete documentation index, see [llms.txt](https://docs.roadmap.so/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.roadmap.so/loyalty-and-rewards/membership-tiers-and-referrals/send-discount-codes-for-birthdays-and-tier-promotions.md).

# Send discount codes for birthdays and tier promotions

Generate a unique discount code for a member birthday or tier promotion. Deliver it through Roadmap or a Klaviyo event.

**Discount Code Generator** creates a unique, per-customer code when a member has a birthday or reaches a new tier. Deliver it by email through Roadmap or a Klaviyo event.

It is the discount-based alternative to awarding points. Use it for percentage-off loyalty perks.

In Roadmap’s **Discounts** section, create a discount and choose **Discount Code Generator**.

#### Pick the trigger

Give the generator a **Name** for admin reference. Then choose a trigger:

* **On member birthday** — choose **On their birthday**, **First of the birthday month**, or **Days before birthday**.
* **On member promotion** — runs when a customer moves into a selected tier.

Other triggers, **When review is published** and **When specific products are purchased**, belong to the Discounts & GWP guides.

{% hint style="info" %}
Send birthday discounts before the birthday when customers need planning time. An expiry date keeps the offer urgent.
{% endhint %}

#### Configure the discount code

Set:

* **Percentage** or **fixed amount**.
* **Code prefix**. Generated codes can look like `ROADMAPA83XO123`.
* **Applies to** — all products, or selected products, variants, or collections.
* **Purchase Type** — one-time purchase or subscription.
* **Minimum spend** and **Quantity limit**.
* **Expires after** — leave blank for no expiry.
* **Customer Eligibility** — all customers or members of selected tiers. Leave the tier field blank to match all tiers.

#### Choose how the code is delivered

Under **Mail Template**, choose one option:

* **Send mail via Roadmap** — Roadmap emails the customer directly.
* **Trigger a Klaviyo event** — Roadmap fires a metric and your Klaviyo flow sends the email.

For a Klaviyo event, use a recognizable metric name. For example, `Roadmap: Birthday Discount For Tier 1`.

Roadmap creates the metric after the [Klaviyo integration setup](/reviews/integrations/klaviyo-review-integration/how-to-integrate-roadmap-with-klaviyo.md). The event properties include the generated code. Use Klaviyo’s event-property Liquid snippet in your flow email.

#### Where generated codes live

Shopify Discounts stores every generated code. Search the customer’s email in Shopify admin if they lose it.

See [Where is a customer's loyalty discount code?](/loyalty-and-rewards/troubleshooting/where-is-a-customers-loyalty-discount-code.md).

#### Tier-promotion promotions

**On member promotion** uses the same configuration. Choose the trigger and target tier, then configure the amount-off or percentage-off code.

Use it when the tier perk is a discount. Use Customer Rewards when it is a specific free product.

#### Related guides

* [Reward customers for reaching a tier](/loyalty-and-rewards/membership-tiers-and-referrals/reward-customers-for-reaching-a-tier.md)
* [Award points for birthdays](/loyalty-and-rewards/points-and-ways-to-earn/award-points-for-birthdays.md)
* [Where is a customer's loyalty discount code?](/loyalty-and-rewards/troubleshooting/where-is-a-customers-loyalty-discount-code.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.roadmap.so/loyalty-and-rewards/membership-tiers-and-referrals/send-discount-codes-for-birthdays-and-tier-promotions.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
