https://gift.heyatli.com/g/GIFT-731W-N8M2) where the claim buttons and new FAQs live.
To send this email via Resend when an order is created or fulfilled, the backend needs to inject the following fields:
| Variable | Source / Description | Example |
|---|---|---|
to_email |
Buyer's email address from marketplace checkout | buyer@gmail.com |
gift_code |
Unique Crockford code generated by Atli gift service | GIFT-731W-N8M2 |
claim_url |
Direct gift link: https://gift.heyatli.com/g/{code} |
https://gift.heyatli.com/g/GIFT-731W-N8M2 |
destination |
Target destination country name | Philippines |
flag_emoji |
Country flag emoji | 🇵🇭 |
plan_summary |
Data allowance + duration | 1 GB total, 7 days |
activate_by |
Expiry deadline (30 days from purchase) | 11 Oct 2026 |
platform |
Channel source (TikTok, Shopee, Lazada) | TikTok |
order_number |
Marketplace order ID (optional, shown if present) | 576123456789012345 |
Sample Resend Node.js call:
await resend.emails.send({
from: 'Atli eSIM ',
to: order.buyer_email,
subject: `Your ${destination} eSIM voucher · ${platform} order ${order.number}`,
html: renderEmailHtml({
destination: "Philippines",
flag: "🇵🇭",
plan: "1 GB total, 7 days",
activate_by: "11 Oct 2026",
claim_url: `https://gift.heyatli.com/g/${gift.code}`,
voucher_code: gift.code,
order_number: order.number,
platform: "TikTok"
})
});