Connect Lemon Squeezy

Send your Lemon Squeezy orders, renewals and refunds to Clakta over a webhook, and credit each sale to the visitor who made it.

Lemon Squeezy sends your sales, renewals and refunds to Clakta through a webhook that you create once in Lemon Squeezy. Clakta gives you the URL and the signing secret, and you paste both there.

Connect

  1. Go to Project settings → Sales platforms.
  2. Choose Lemon Squeezy, name the connection, and click Create connection. Clakta generates a webhook URL and a signing secret. Copy both.
  3. In Lemon Squeezy, go to Settings → Webhooks and click +.
    webhooks
  4. Paste the URL, paste the signing secret into the Signing secret field.
    lemon squeezy webhook
  5. Select the four events in the table below.
EventWhat it does in Clakta
order_createdRecords the sale.
order_refundedMarks the order refunded.
subscription_payment_successRecords each subscription renewal.
subscription_payment_refundedMarks a refunded renewal.
  1. Save the webhook in Lemon Squeezy, then click Finish in Clakta.

The connection is ready as soon as you create it (the card reads Added right away), and sales start arriving once the webhook is saved in Lemon Squeezy.

Selecting extra events is harmless: anything Clakta does not handle is acknowledged and ignored.

Turn on the Clakta script

To credit each sale to the visit that brought it, install the Clakta script on the pages that link to your Lemon Squeezy checkout. The script adds the visitor's session to the checkout on its own, so there is nothing else to set up. Projects in privacy-friendly mode don't send this session.

If you build the checkout in your own code

If you create checkouts through the Lemon Squeezy API, pass the session yourself:

If you open overlays yourself, decorate the URL first:

Troubleshooting

Related articles