Lemon Squeezy License Sync
Sync Lemon Squeezy orders and license keys into the app's entitlement state.
What it adds
A verified event pipeline mapping Lemon Squeezy orders, subscriptions, and license keys onto local entitlements, with activation limits and revocation handled.
What your agent is told to do
5
What your agent is told to do
5-
1
Verify the authenticity of every incoming provider event before it changes anything. An unverified purchase notification is a request from the internet to give away your product.
-
2
Keep an explicit server-side table mapping each purchasable variant to the entitlement it grants. Do not infer the plan from a product name, because names get edited for marketing reasons and entitlements should not move when they do.
-
3
Bind each license key to a single account on first activation and refuse to activate it against a different one afterwards, with a documented path for an operator to release a key that genuinely needs to move.
-
4
Track activations against the key's own limit, and treat deactivation as returning a slot rather than deleting the record, so an audit can show where a key has been used.
-
5
Entitlement must live in the same local access record any other billing brief writes to. If a Stripe or Paddle brief is also applied, this one adds a source, it does not add a second source of truth.
Edge cases it handles
8
Edge cases it handles
8- Events arriving without a valid signature must be rejected outright, and rejections logged. Nothing is activated on the strength of an unverified message.
- Variants and products map to entitlements through explicit server-side configuration. An unrecognised variant must park the order for an operator rather than defaulting to some plan, and a mapping change must not silently upgrade existing customers.
- Activation limits, deactivations, expiry, and refunded or charged-back orders all have to revoke or restore access correctly. A refund that leaves the license working is a hole; a refund that also deletes the customer's data is worse.
- Provider deliveries are retried. Record processed event identifiers and make handlers repeat-safe, or a retry will grant a second seat or send a second receipt.
- A license key must not attach to an unrelated account. Bind on first activation, reject mismatches, and require an explicit operator action with a record of who did it to reassign one.
- Out-of-order delivery means a cancellation can arrive before the renewal that supersedes it. Compare against a stored sequence or timestamp and ignore anything older than current state.
- When the provider is unreachable, previously activated licenses must keep working. Offline validation should fall back to the last known good state with a grace period rather than locking paying users out.
- Never expose the provider credential or the raw license key in client-visible code, and show keys to the owner only, masked until deliberately revealed.
Definition of done
9
Definition of done
9- Unsigned or unverifiable events are rejected and logged, and change no state.
- Variants map to entitlements through explicit server configuration, and unknown variants are quarantined.
- Activation limits are enforced, deactivation returns a slot, and the activation history is retained.
- Refunds, expiry, and cancellations revoke access without destroying the customer's data.
- Retried and out-of-order deliveries leave entitlement state correct.
- A license key is bound to one account and can be reassigned only by a recorded operator action.
- Provider unavailability leaves existing licenses working within a defined grace period.
- The feature matches the existing design system.
- No existing functionality is broken.
Related features
Shopify Order Import
Shopify Order Import
Import Shopify orders into the app with money, fulfilment, and later edits accurately kept.
What it does
A resumable import of the connected store's orders, mirroring line items, discounts, taxes, and fulfilment state locally.
How it works
- 1 Separate the initial backfill from the ongoing feed. The backfill walks history in a stable order behind a resumable cursor; the feed applies live updates as they arrive.
- 2 Key every imported order on the shop identifier together with the store's own order identifier, so re-running the import updates existing rows instead of duplicating them.
- 3 Store money as an exact decimal with its currency alongside it, and keep both the shop currency and the presented currency where they differ. Do not convert to a single display currency on the way in, because the original amounts cannot be recovered afterwards.
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/shopify-order-import
Shopify Customer Sync
Shopify Customer Sync
Keep Shopify customers current from app users without crossing stores or resetting consent.
What it does
A sync that creates or updates a customer record in the connected store whenever an app user's details or consent change.
How it works
- 1 Find the app events that should reach the store — account creation, profile edit, address change, consent change — and sync from those events rather than sweeping every user on a timer.
- 2 Scope every request, every lookup, and every stored identifier to one connected shop. Treat the shop as part of the customer's identity, not as ambient configuration.
- 3 Store the provider's customer identifier against the app user per shop and match on it first, falling back to a normalized email address only when no identifier has been recorded yet.
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/shopify-customer-sync
Paddle Subscription Checkout
Paddle Subscription Checkout
Sell subscriptions through Paddle with entitlements granted only by verified events.
What it does
A Paddle-backed subscription purchase and lifecycle flow where local access follows verified server events and prices stay under server control.
How it works
- 1 Hold the catalogue mapping on the server: which local plan corresponds to which provider offering, at which price and currency. The client passes a plan identifier and nothing about money.
- 2 Carry an account or workspace reference into the checkout so the subscription that comes back can be attached to the right tenant without matching on email address.
- 3 Grant access only from verified server-side events, and store the event identifier so a retried delivery changes nothing a second time.
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/paddle-subscription-checkout
How it works
-
1
Copy the link
Grab the Markdown instruction URL for this feature.
-
2
Give it to your AI
Paste it into Claude Code, Cursor, v0, Lovable — whatever you build with.
-
3
It inspects, then implements
Your agent reads your existing app first, then adds the feature to fit it.
Works with your stack
These instructions are written to adapt. They tell the agent to detect your framework, match your existing design system, and reuse what you already have — rather than assuming a particular stack.
Need it tighter than that? Customize the feature and tell it exactly what you're running.