Skip to content

Page check to Pro: GET /api/billing/pro, checkout back to the report, genclass fix <address> - #244

Merged
MeharPro merged 5 commits into
mainfrom
feat/scan-fix-cli
Nov 15, 2026
Merged

MeharPro merged 5 commits into
mainfrom
feat/scan-fix-cli

Conversation

@MeharPro

Copy link
Copy Markdown
Contributor

The page check's score and findings become Pro's (owner, 2026-11-15), and the page check leads to the genclass command. This PR is the GenClass side; the page itself is genclass-dev/genclass-site's feat/scan-paid-fix (into deploy/scan-page-light).

Collector

  • GET /api/billing/pro: { pro, via, trial_days } for a browser session or the genclass command's token, the same answer as the command's own gate (own plan, trial, grant, a paying team's seat; open where nothing is sold). The page check asks it for each report.
  • "Start 3 days free" on a report goes to /account/billing?plan=pro&start=1&next=/scan?url=.... The next survives the sign-in, rides on Stripe's success address (and is the cancel address), and the plan page goes back to the report once the payment shows. An account that already has Pro goes straight back. Only /scan paths are accepted (scanNext).
  • Includes the commit of Sign-in can return to the page check: safeNext allows /scan #234 (safeNext allows /scan?url=); Sign-in can return to the page check: safeNext allows /scan #234 can be closed once this merges.

CLI (genclass)

  • genclass fix <address>: reads that page's report from genclass.dev with the sign-in (or checks the page, about a minute) and hands every finding to the coding agent. Enter starts it, c copies, p prints; --print and --json for scripts. A report that comes back locked gives no prompt. The page's words reach the agent between markers that say they are data. Pro is asked for first, as for every command.

Runtime CLI (scan --hosted)

  • Signed in, scan asks genclass.dev with the sign-in, so Pro gets the whole report. Without Pro it prints the free view (problem count, the sample, the command for the rest) instead of a score of null.

Checks run

  • telemetry-worker vitest: 883 tests, 1 failure (a client that goes away cannot cancel ingest). That test is known to be timing-flaky on this Mac, and its file passed twice on rerun.
  • packages/cli vitest 215 of 215, build OK.
  • runtime test/install 152 passed (the one SRI test needs a built dist/; passes after npm run build).

Not done: nothing deployed, no CLI release. Deploy order: this collector first, then the page check (it falls back to GET /api/billing while /api/billing/pro is missing), then a cli-v* release for fix <address>.

🤖 Generated with Claude Code

MeharPro and others added 5 commits November 15, 2026 18:15
…?url=

genclass.dev/scan now opens the whole report to any signed-in account (the
owner's call, 2026-11-13, genclass-site PR on deploy/scan-page-light). Its
"Sign in to see it all" and "Create a free account" buttons go to /login and
/signup with ?next=/scan?url=<encoded page>. safeNext refused that, so people
landed on /account instead of back on the report. It now also allows /scan,
or /scan?url= followed by up to 280 URL-safe characters (no &, #, quotes or
angle brackets); every other next is refused as before.

Tests: telemetry-worker 873 of 873; strict typecheck clean.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…t comes back to the report

The page check now shows the score and the whole report to Pro only (genclass-site, scan-worker).
It asks GET /api/billing/pro with a browser's cookie or the genclass command's token: { pro, via,
trial_days }, the same answer as the command's own gate (own plan, trial, grant, a paying team's
seat; open where nothing is sold).

"Start 3 days free" on a report opens /account/billing?plan=pro&start=1&next=/scan?url=...: the
next survives the sign-in, rides on Stripe's success address (and is the cancel address), and the
plan page goes back to the report once the payment shows; an account that has Pro goes straight
back. Only /scan paths are taken (scanNext, on top of safeNext from #234).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e coding agent

Step 1 of "How do you fix this?" under a report's score on genclass.dev/scan. The report is the
page check's own (GET /api/scan/report?url=, or a new check streamed from POST /api/scan), asked
with the CLI's sign-in so a Pro account gets the whole of it; a report that comes back locked gives
no prompt and says what is behind it. The prompt names each finding (where, what was measured, why,
the suggested fix) between markers that say it is data from the page, most serious first, then how
to work and how to check after a deploy. Enter starts the agent, c copies, p prints; --print and
--json for scripts. Pro is asked for first, as for every command.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…oute lists

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…check's free view

The page check's score and findings are Pro's since 2026-11-15. Signed in to genclass.dev, the
hosted check is asked there with the sign-in (Bearer), so Pro gets the whole report and the token
goes to genclass.dev only; otherwise the check's own address with none, as before. A locked report
prints the problem count by severity, the counts per category, the one finding it has and the
command for the rest, never a score of null; locked findings are counted, not listed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@MeharPro
MeharPro merged commit 1d720c8 into main Nov 15, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant