agentleFS
Ghost7802Ghost7802/awesome-api-skills/skills/lemon-squeezy/SKILL.md

lemon-squeezy

Skill13 starsChanged 27 days agoMITView on GitHub

  • Installs packages

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 2 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use webhooks (order_created, subscription_created) to sync order data.

    line 16
  2. Distinctive:

    Do not query the Lemon Squeezy API on every page load to check subscription status.

    line 25
  3. Very specific:

    If custom_data is missing in webhooks, ensure your frontend checkout URL explicitly appended the ?checkout[custom][user_id]=123 parameter …

    line 31
  4. Distinctive:

    Use this when your agent works with lemon-squeezy — structured patterns beat pasted docs and prevent common hallucinations.

    line 41

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Lemon Squeezy API Skill

Quick Start

Lemon Squeezy simplifies global tax compliance and recurring billing. The official @lemonsqueezy/lemonsqueezy.js SDK handles interactions cleanly.

npm install @lemonsqueezy/lemonsqueezy.js

Common Workflows

License Key Management

Lemon Squeezy uniquely offers built-in License Key generation for desktop apps. You can programmatically generate, activate, and validate license keys associated with a purchase.

Production Patterns

Syncing Orders

Use webhooks (order_created, subscription_created) to sync order data. When a user buys your SaaS, parse the custom_data object in the webhook payload (which should contain your internal user_id) to map the purchase.

Error Recovery

Handle rate limit errors (HTTP 429). The API is heavily cached but mutations are strictly limited. Catch generic HTTP errors using try/catch and inspect the error property returned by the SDK.

Security Notes

Webhook signatures in Lemon Squeezy use HMAC SHA256. Verify the X-Signature header against the raw request body using Node's crypto module to prevent spoofed payments.

Performance Considerations

Do not query the Lemon Squeezy API on every page load to check subscription status. Rely entirely on your database, which should be continually updated by incoming webhooks.

Testing Guidance

Lemon Squeezy provides a dedicated Test Mode. Use their test credit cards to simulate successful and failed subscription renewals.

Troubleshooting

If custom_data is missing in webhooks, ensure your frontend checkout URL explicitly appended the ?checkout[custom][user_id]=123 parameter during initialization.

References

Related Skills

  • Paddle
  • Stripe

Why use this skill

Use this when your agent works with lemon-squeezy — structured patterns beat pasted docs and prevent common hallucinations.

AI pitfalls

  • Inventing webhook event names not in the vendor catalog
  • Using secret keys in client-side or browser code
  • Skipping signature verification on webhook payloads

Production checklist

  • Webhook signatures verified on raw request body
  • Idempotency keys on mutating requests
  • Test and live keys isolated by environment

Related skills

  • paddle — related to
  • stripe — related to

Last Verified: 2026-07-02

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.