mirror of
https://github.com/Studio-Saelix/sencho.git
synced 2026-08-20 15:22:59 +00:00
feat(license): replace local auto-trial with Lemon Squeezy hosted trial flow (#755)
Fresh installs land on the Community tier. The 14-day Admiral trial is now issued by Lemon Squeezy via their hosted checkout: the user enters email + card, receives a license key by email, and pastes it into the existing Settings > License activation field. Backend changes: - LicenseService.initialize() no longer auto-creates a license_status='trial' row on first boot. It now only ensures an instance_id exists and starts periodic validation. - Drop the TRIAL_DURATION_DAYS constant. - Drop the status='trial' early-return in getVariant() so LS-issued trials resolve through the normal variant metadata path (variant_name / product_name). - Trial branches in getTier() and getLicenseInfo() are retained for future work that may detect trial state from Lemon Squeezy metadata; they are currently unreachable via the Sencho code paths. Frontend changes: - Settings > License surfaces a new "Try Admiral free for 14 days" CTA block with Start monthly trial and Start annual trial buttons that open Lemon Squeezy hosted checkout. The CTA is visible only when the user has no paid access and is not already on a trial. - Reserve the Admiral upgrade card for the Skipper-active upgrade path so unlicensed users see one Admiral path (the trial CTA) instead of two. - Pull the inline Lemon Squeezy checkout URLs into named module constants so the Skipper, Admiral monthly, and Admiral annual endpoints are defined in one place. Test changes: - license-service.test.ts covers the no-auto-trial startup path and updates the trial-variant test to reflect the metadata-driven resolution. - afterAll in the initialize() describe block calls destroy() so the 72-hour validation interval does not leak into sibling test files. Docs: - Rewrite the Free trial section in features/licensing.mdx to document the new LS checkout flow (email + card required, auto-converts on day 14 unless cancelled). - Add an operations/troubleshooting entry for cases where the trial license key email does not arrive.
This commit is contained in:
@@ -48,9 +48,21 @@ Lifetime pricing is an early-adopter offer available for a limited time only.
|
||||
|
||||
## Free trial
|
||||
|
||||
Every new Sencho installation starts with a **14-day Skipper trial**. No license key or credit card is required. Skipper features like fleet management, webhooks, atomic deployments, and auto-update policies are unlocked during the trial so you can evaluate them with your real infrastructure. Admiral-exclusive features (SSO, audit log, host console, scoped RBAC, unlimited accounts) require an Admiral license.
|
||||
Sencho offers a **14-day Admiral trial** on monthly and annual Admiral plans so you can evaluate the flagship features (Host Console, Scheduled Operations, LDAP / Active Directory, audit log, unlimited accounts) with your real infrastructure before committing.
|
||||
|
||||
When the trial expires, Sencho automatically reverts to the Community tier. No data is lost.
|
||||
To start a trial:
|
||||
|
||||
1. In the Sencho dashboard, go to **Settings > License**, or visit the [pricing page](https://sencho.io/pricing).
|
||||
2. Click **Start monthly trial** or **Start annual trial**.
|
||||
3. Complete the Lemon Squeezy checkout. A valid card is required for verification; you are not charged until the trial ends.
|
||||
4. Lemon Squeezy will email your license key within a few minutes.
|
||||
5. Paste the key into the **Have a license key?** field on the License page and click **Activate**.
|
||||
|
||||
When your trial ends, Lemon Squeezy automatically charges the card you provided and your plan continues as a paid Admiral subscription. To avoid being charged, cancel from the **Manage Subscription** button (or from the Lemon Squeezy receipt email) any time before day 14.
|
||||
|
||||
<Tip>
|
||||
Fresh installs land on the **Community** tier until you activate a license key. All Community features (unlimited nodes, compose editor, global logs, alerts, Custom OIDC, and more) are available immediately.
|
||||
</Tip>
|
||||
|
||||
## Upgrading your plan
|
||||
|
||||
|
||||
@@ -166,6 +166,19 @@ To re-test connectivity after making changes, open **Profile > Settings > Nodes*
|
||||
|
||||
---
|
||||
|
||||
## I didn't receive my trial license key after checkout
|
||||
|
||||
**Symptom:** You completed the Lemon Squeezy trial checkout but no license key email arrived.
|
||||
|
||||
**Checks in order:**
|
||||
|
||||
1. **Check your spam / junk folder.** Lemon Squeezy emails come from `no-reply@lemonsqueezy.com`; some providers flag them aggressively.
|
||||
2. **Verify the email address you used at checkout.** If you made a typo, the key was sent to the wrong address. Contact `licensing@sencho.io` with your order ID (from the checkout receipt) and we can resend or issue a new key.
|
||||
3. **Wait a few minutes.** Delivery is usually within 60 seconds but can take up to 10 minutes during peak load.
|
||||
4. **Still missing after 15 minutes?** Email `licensing@sencho.io` with the transaction ID from your card statement and we will resend the key.
|
||||
|
||||
---
|
||||
|
||||
## Paid features are still locked after activation
|
||||
|
||||
**Symptom:** Features remain locked even though you activated a valid license key.
|
||||
|
||||
Reference in New Issue
Block a user