A single-bubble promotional Flex Message that delivers a time-limited coupon to each recipient with personalization.
Category: Promotion
Coupon Notification
Single-bubble promotional message with hero image, personalized greeting, coupon code, and a call-to-action button. Demonstrates Liquid personalization.
Preview
JSON template
{
"type": "bubble",
"hero": {
"type": "image",
"url": "https://example.com/images/coupon-hero.jpg",
"size": "full",
"aspectRatio": "20:13",
"aspectMode": "cover"
},
"body": {
"type": "box",
"layout": "vertical",
"contents": [
{
"type": "text",
"text": "20% OFF Coupon",
"weight": "bold",
"size": "xl"
},
{
"type": "text",
"text": "Hi {{ profile.first_name }}, enjoy 20% off your next purchase. Valid until {{ campaign.expires_on }}.",
"wrap": true,
"margin": "md",
"size": "sm",
"color": "#666666"
},
{
"type": "box",
"layout": "baseline",
"margin": "lg",
"contents": [
{
"type": "text",
"text": "Code",
"size": "sm",
"color": "#aaaaaa",
"flex": 1
},
{
"type": "text",
"text": "{{ profile.coupon_code }}",
"size": "sm",
"color": "#111111",
"weight": "bold",
"flex": 4
}
]
}
]
},
"footer": {
"type": "box",
"layout": "vertical",
"spacing": "sm",
"contents": [
{
"type": "button",
"style": "primary",
"color": "#00B900",
"action": {
"type": "uri",
"label": "Shop Now",
"uri": "https://example.com/shop?uid={{ profile.user_id }}"
}
}
]
}
}- Weekly or seasonal promotional campaigns
- Loyalty rewards targeted to a Segment
- Re-engagement offers for lapsed customers
| Field | How to customize |
|---|---|
hero.url | Upload your campaign image to a public HTTPS host (e.g. a CDN) and replace the URL. Use a 20:13 aspect ratio for best appearance. |
body.contents[0].text | Replace the headline (20% OFF Coupon) with your own offer. |
body.contents[1].text | Personalize the body using Liquid variables from your Profile schema. Expanded at delivery time. |
body.contents[2].contents[1].text | Bind the coupon code to a profile attribute (e.g. {{ profile.coupon_code }}). |
footer.contents[0].action.uri | Point to your landing page; include {{ profile.user_id }} for attribution. |