Repository navigation
fix(companies): invited colleagues can sign up while the waitlist is on - #528
Conversation
Clerk's Waitlist mode admits a new person only with an invitation's ticket. Patchy's invitations sent their link to /join, which never uses the ticket, so an invited colleague ended up on the waitlist. Invitations now carry no redirect, so the link opens Clerk's own sign-up or sign-in page, which uses the ticket. Clerk then sends the person to the home URL, and / takes a person without a company to /join. Signing up accepts the Clerk invitation, so revoke and resend treat Clerk's invitation_already_accepted like an already-revoked invitation. Closes #526 Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…n-up Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
|
Codex review (GPT 6.1 Sol), two passes before the PR opened. Triage trace (on the claim, before the fix): confirmed that Review of the diff: no blockers or should-fix findings. One nit: the live assertion checked the path but not the origin, so a Patchy |
While the waitlist is on, a colleague invited from
/companycouldn't create an account. The invitation link sent them to Patchy's/joinwith Clerk's invitation ticket, and Patchy never uses that ticket. So Clerk rejected their sign-up (sign_up_restricted_waitlist) and put them on the waitlist like a stranger. Closes #526; found while checking #481.Invitations now carry no redirect URL. The emailed link opens Clerk's own sign-up page (sign-in for an existing account), which uses the ticket. Clerk then sends the person to the app's home URL.
/sends anyone without a company to/join, where their invitation is waiting.Signing up through the ticket marks the Clerk invitation accepted. Clerk refuses to revoke an accepted invitation (
invitation_already_accepted), so revoke and resend now treat it like an already-revoked one.InvitationAlreadyRevokedis renamedInvitationNotPendingto match. Patchy's own invitation still decides who joins.I checked each Clerk behaviour on a throwaway app in Waitlist mode, deleted afterwards. The live Clerk test now follows the invitation link and expects the Account Portal's
/sign-upwith a ticket. Run against the development instance, it passes; the old/joinlink would fail it.Made by Claude Opus 5.5 via Claude Code, reviewed by GPT 6.1 Sol via codex.