LemonSqueezy integration

LemonSqueezy webhooks → else.events → your product emails

LemonSqueezy handles payments and sends receipts. else.events handles your welcome, onboarding, license delivery and subscription lifecycle emails.

LemonSqueezy handles payments — product emails are still your job

LemonSqueezy sends order receipts — not your product emails

LemonSqueezy is Merchant of Record and handles receipts. Welcome emails, license key delivery and onboarding are your responsibility.

Subscription events need product follow-ups

subscription_created, subscription_cancelled, order_created — each needs a product email your app must trigger.

JSON:API response format adds complexity

LemonSqueezy webhooks use JSON:API format — extracting customer email, name and product details requires extra parsing.

No template management for product emails

Email copy for welcome, onboarding and licence delivery is hardcoded in your webhook handler or background job.

Forward LemonSqueezy events — else.events sends the product email

Parse JSON:API, forward as else.events event

Extract customer and product data from the LemonSqueezy payload, map to a clean else.events event and POST.

Rules handle product email routing

order_created + product=Pro → Pro welcome + license delivery. subscription_cancelled → cancellation email. No code per variation.

Templates editable without redeploys

Change welcome copy or add an upgrade CTA in the else.events dashboard without touching your webhook handler.

Exactly the indie hacker audience

LemonSqueezy targets indie hackers and small SaaS teams — the same teams that benefit most from else.events managed product emails.

// Node.js LemonSqueezy webhook → else.events

Parse LemonSqueezy JSON:API and forward to else.events.

app.post('/webhooks/lemonsqueezy', async (req, res) => {
  // Validate LemonSqueezy signature
  const event = req.body;

  if (event.meta.event_name === 'order_created') {
    const attrs = event.data.attributes;
    const userEmail = attrs.user_email;
    const userName  = attrs.user_name ?? 'Customer';
    const productName = attrs.first_order_item?.product_name;

    await fetch('https://app.else.events/api/events', {
      method: 'POST',
      headers: { Authorization: `Bearer ${process.env.ELSE_EVENTS_API_KEY}`, 'Content-Type': 'application/json' },
      body: JSON.stringify({
        type: 'order.created',
        user: { email: userEmail, name: userName },
        data: { product: productName, license_key: attrs.first_order_item?.license_key,
                order_number: attrs.order_number },
      }),
    });
  }
  res.sendStatus(200);
});

Extract the relevant fields from the JSON:API structure, then forward a clean event to else.events. Rules match order type and product to send the right email.

LemonSqueezy events → product emails

order_created

Welcome and license delivery on order

Welcome email with license key delivered on order_created — no custom code per product.

subscription_cancelled

Subscription cancellation email

Acknowledgment and reactivation CTA when subscription_cancelled fires.

subscription_updated

Subscription renewal confirmation

Confirmation email when subscription renews successfully.

subscription_payment_failed

Failed payment dunning

Reminder email with payment update link on failed renewal.

Frequently asked questions

What is JSON:API format and why does it matter?
LemonSqueezy webhooks return data in JSON:API format — the actual customer email is nested under data.attributes.user_email, not at the top level. Parsing it correctly is the main integration step.
Can else.events deliver license keys?
Yes. Include the license_key in the event data payload. Use {{ data.license_key }} as a template variable in your else.events email template.
How do I validate LemonSqueezy webhook signatures?
LemonSqueezy includes an X-Signature header. Compute an HMAC-SHA256 of the raw request body using your webhook secret and compare.
Can I test LemonSqueezy webhooks locally?
Yes. Use the LemonSqueezy test mode and an ngrok tunnel to receive webhooks on localhost during development.

LemonSqueezy billing emails — beyond receipts.

Forward LemonSqueezy events and send welcome, license delivery and lifecycle emails managed outside your code.

  • Built for indie hackers on LemonSqueezy
  • Templates editable without redeploys
  • License key delivery via template variables