DocsPlugins

Lemon Squeezy

Lemon Squeezy for Payments: a merchant of record that charges the sales tax and pays it where it is due, with each payment on its own checkout page.

The payments-lemonsqueezy plugin lets the Payments plugin take payments with Lemon Squeezy. To add it:

sluurp plugin add payments payments-lemonsqueezy

Set up a payee

  1. In Lemon Squeezy, make a store with one product. Each payment is a checkout on that product with its own price, so the product’s own price doesn’t matter, but it decides how the sale is taxed. The store’s currency must be the one your payments are in.
  2. Open Settings, then API, and make a key. A key made in test mode pays in test mode.
  3. Add a webhook at the address the admin shows, /api/payments/webhook/lemonsqueezy/<payee>, for the order_created and order_refunded events, and give it a signing secret.
  4. In the admin, open Payments, add a payee with provider Lemon Squeezy, and paste the key and the signing secret.

A webhook call is believed only when it is signed with that secret. When a checkout is paid, Lemon Squeezy makes an order with an id of its own; from then on the payment is followed by that order. A full refund of the order is recorded against the payment.

Taking payments in your app is the same for every provider: see Payments.

View as Markdown