Setup
- Environment variables
- Direct config
Supported Endpoints
LemonSqueezy’s API strictly follows JSON:API standards. Certain resources like stores, products, and standard checkouts are largely managed via their hosted dashboard. The PayKit provider implements the following operational endpoints:customers.createcustomers.retrievecustomers.updatecheckouts.createcheckouts.retrievepayments.retrieve(maps to LemonSqueezyorders)refunds.create(maps to LemonSqueezyorder refunds)subscriptions.retrievesubscriptions.updatesubscriptions.cancelsubscriptions.delete
checkouts.update and subscriptions.create are not natively supported by the LemonSqueezy API and will intentionally throw an “Unsupported” error.
How it works
To create a checkout session for LemonSqueezy, you must provide your LemonSqueezystore_id and the variant_id representing the product you are selling.
Webhooks
LemonSqueezy signs webhooks with HMAC-SHA256 via thex-signature header.
Raw LemonSqueezy events
All webhook events fired by the LemonSqueezy provider emit the rawevent_name provided by LemonSqueezy (e.g. lemonsqueezy.order_created, lemonsqueezy.subscription_created). You can listen to any native LemonSqueezy event.
provider_metadata
LemonSqueezy heavily relies onprovider_metadata to pass required relationships like store_id and variant_id that are unique to their JSON:API architecture.
Refunds
LemonSqueezy refunds are issued directly against a specific payment (order). The endpoint will issue a full refund if no amount is provided, or a partial refund if anamount is specified in cents.