> ## Documentation Index
> Fetch the complete documentation index at: https://knowledge.flowella.io/llms.txt
> Use this file to discover all available pages before exploring further.

# WhatsApp coupon code templates: copy code buttons

> How WhatsApp coupon code templates work, their limits, where you set the real code when you send from Flowella, and a worked example you can copy.

A coupon code template is a marketing template with a **copy code** button. When the customer taps it, WhatsApp copies your discount code to their clipboard, ready to paste at checkout. The code you enter when you create the template is only a sample for Meta's review. You set the real code each time you send, so every customer can get a different one.

> [!NOTE]
>
> **In Flowella.** Partly supported. The editor adds a **Copy coupon code** button to Marketing templates, and you can send the real code from the inbox, a test send or the [Flowella API](https://knowledge.flowella.io/api-reference/introduction.md). Bulk send and HubSpot workflow actions don't let you set a code, so they can't send coupon templates.

## Limits

| Rule | Limit |
| - | - |
| Category | Marketing only |
| Copy code buttons per template | 1 |
| Code length | Up to 20 characters |
| Button text | Set by WhatsApp. You can't change it. |
| Other buttons | Allowed alongside, for example a quick reply or URL button, within the 10-button total |
| WhatsApp Web and desktop | The button isn't supported there. The customer needs the phone app. |

> [!NOTE]
>
> **In Flowella.** The editor's sample code accepts letters and numbers only, up to 20 characters. At send, Flowella accepts any code up to 20 characters.

## What is set when

| When you create the template | When you send it |
| - | - |
| Header, body text and buttons | The real coupon code for the copy code button |
| A sample code, for review | Values for any body variables, such as the customer's name or the code shown in the text |

If your body shows the code too, for example `Use code {{2}} at checkout`, fill that variable with the same value as the button, or the customer sees two different codes.

## Build one in Flowella

**1. Create a Marketing template**

On the **Templates** page, click **New template**, then **Build your own** and **Standard message**. Set the category to **Marketing**.

**2. Write the body**

Explain the offer, when it ends and how to use the code. Keep variables for details that change per customer.

**3. Add the button**

Add a **Copy coupon code** button and enter a sample under **Coupon code**, such as `WINTER25`. For an easy opt-out, add a **Quick Reply** button with an opt-out keyword, such as `Stop`. See [How keyword opt-outs work](https://knowledge.flowella.io/app/opt-outs.md#how-keyword-opt-outs-work).

**4. Publish**

Click **Publish Template**. Meta reviews it like any marketing template.

## Worked example

A winter sale template, with one body variable for the first name and one for the code:

```text theme={null}
Our winter sale is on

Hi {{1}}, enjoy 25% off your next order with code {{2}}. Tap the button to copy it, then paste it at checkout. Ends 31 January.

[Copy code button]   [Stop]
```

| Field | Sample for review | Real value at send |
| - | - | - |
| `{{1}}` | `Priya` | The contact's first name |
| `{{2}}` | `WINTER25` | The code you issue, for example `WINTER-7F3K` |
| Coupon code button | `WINTER25` | The same code, `WINTER-7F3K` |

## Send the real code

* **Inbox**: when you choose the template in a conversation, fill in the code under **Coupon code buttons**.
* **Test send**: fill in **Coupon code buttons** on the template's test panel.
* **API**: call `POST /v1/templates/send` and pass the code in `buttonParameters`, with the copy code button's index and `subType` set to `copy_code`. Use this to send unique codes from your own system, with a value for each recipient.

If no code is given, Flowella refuses the send before it reaches Meta and asks for a coupon code.

## Good practice

* **Use single-use codes** where you can, so a shared screenshot doesn't drain the offer.
* **Say when it expires** in the body. A coupon template has no countdown. For one, Meta offers [limited-time offer templates](https://knowledge.flowella.io/whatsapp/templates/limited-time-offer-templates.md), which Flowella doesn't support.
* **Remember WhatsApp Web users.** They can't use the button, so show the code in the body as well.

## Related

> [card] [Marketing templates](https://knowledge.flowella.io/whatsapp/templates/marketing-templates.md)
>
> Opt-in, limits and other marketing types.

> [card] [Template reference](https://knowledge.flowella.io/app/template-reference.md#buttons)
>
> Every button type and limit in the editor.

> [card] [Test a template](https://knowledge.flowella.io/app/templates.md#test-a-template)
>
> Send yourself a coupon template first.

> [card] [Template variables](https://knowledge.flowella.io/app/template-variables.md)
>
> Fill in names and codes.

Checked against Meta's documentation on 18 November 2026: [Coupon code templates](https://developers.facebook.com/documentation/business-messaging/whatsapp/templates/marketing-templates/coupon-templates) and [Template components](https://developers.facebook.com/documentation/business-messaging/whatsapp/templates/components).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.