Skip to content

Reactivation page: instant activation after payment, desktop layout, ways to pay - #1782

Merged
helpcodeai merged 4 commits into
mainfrom
feat/reactivate-page-improvements
Nov 17, 2026
Merged

helpcodeai merged 4 commits into
mainfrom
feat/reactivate-page-improvements

Conversation

@helpcodeai

Copy link
Copy Markdown
Contributor

Summary

Three changes to the no-login reactivation page (/reactivate/<token>, Cloud only), from the read of its first ten days:

  1. The workspace switches on at once after the payment. A buyer from this page waited a median of 145 seconds, and never under two minutes, while a purchase from the app's wall is active in 6 seconds. Someone who paid and went straight back to the chat was refused again. The page now asks the backend to bind the licence as soon as the buyer is back from Stripe.
  2. Desktop layout. Desktop visitors clicked subscribe less often than phone visitors (14 % against 23 %), and one in ten left through the "Sign in" button. Signed out, the sign-in is now a quiet link, and "What happens next" sits under the plans instead of beside the subscribe button.
  3. Ways to pay under the subscribe button. Card, Apple Pay, Google Pay, PayPal and SEPA: what our Stripe Checkout offers and what buyers use. Many failed payments come from prepaid cards, and the other methods were named only in the side column.

The page's Telegram price test is unchanged. Self-hosted is unchanged: every route of the page answers 404 there.

Changes

  • LicenseService.claimPaidLicenceFor(organizationId): asks the licence site for that workspace's unactivated licences and binds those that name it, without the sweep's two-minute wait. At most one request per workspace every 5 seconds. The per-licence binding of the sweep moved into bindListedLicence, used by both.
  • POST /api/license/reactivate/:token/claim: the page calls it when ?paid=1 is in the URL. It answers the workspace's state. It binds only a licence the site sold for the token's workspace, so the link gives its holder nothing but what was paid for.
  • Page: claims before each poll, the first one at once; polls every 3 seconds for 6 minutes. A failed claim changes nothing: the sweep still binds the licence in two to three minutes.
  • Page copy in the seven languages: "usually within seconds" instead of "two or three minutes"; "Pay with" and the word for a card.

It needs HelpCode-ai/anythingmcp-website#608 for the speed-up. Deploy order does not matter: against the current site the claim finds nothing new and the sweep works as today.

Type

  • Bug fix
  • New feature
  • Documentation
  • Refactoring
  • Performance improvement
  • Other (describe below)

Testing

  • Added/updated unit tests
  • Tested manually (describe steps below)
  • No tests needed (explain why)

In packages/backend, after npm ci and prisma generate:

  • npx jest src/license src/mcp-server/trial-blocked-call --maxWorkers=4: 22 suites, 432 tests passed. New: 5 tests for claimPaidLicenceFor (binds a licence sold 10 seconds ago, ignores an older site's general list, leaves a paying workspace alone, one site request per workspace in 5 seconds, nothing off Cloud or without the service token) and 5 for the claim route.
  • npx tsc --noEmit -p tsconfig.json: clean. npm run lint: no changes.

In packages/frontend:

  • npx playwright test tests/e2e/reactivate-link.spec.ts --workers=2: 25 passed. New: the claim on return from Stripe, the return still working when the claim fails, no claim on a normal visit, "What happens next" under the plans on a desktop and after the explanation on a phone, the ways to pay, the quiet sign-in link.
  • npx tsc --noEmit -p tsconfig.json and npx eslint on the changed files: clean.

Not tested against production: the end-to-end timing can only be measured after both deploys, on the next purchases from the page.

Checklist

  • My code follows the existing code style
  • I have tested my changes locally
  • I have updated documentation (if applicable): no user documentation describes this page
  • All existing tests pass (npm test): the full suite runs in CI
  • This PR has a descriptive title

Related Issues

Follows #1574 (the page) and #1769 (the page for every workspace).

@helpcodeai
helpcodeai enabled auto-merge (squash) November 17, 2026 19:52
@helpcodeai
helpcodeai merged commit e5c335c into main Nov 17, 2026
22 of 23 checks passed
@helpcodeai
helpcodeai deleted the feat/reactivate-page-improvements branch November 17, 2026 20:57
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 17, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant