Skip to content

Add post-subscription onboarding activation - #204

Open
paulocastellano wants to merge 52 commits into
mainfrom
feature/post-subscription-onboarding
Open

Add post-subscription onboarding activation#204
paulocastellano wants to merge 52 commits into
mainfrom
feature/post-subscription-onboarding

Conversation

@paulocastellano

Copy link
Copy Markdown
Contributor

Summary

  • Renames pre-Stripe ICP flow to Welcome (/welcome/{persona|goals|referral-source|subscribe}) and removes the social-connect gate before checkout.
  • Adds a single-page post-Stripe activation checklist at /onboarding (connect MCP → connect social → create first post, draft OK), with skip + residual banner in the app shell.
  • Sends /billing/processing to /onboarding instead of /accounts, with PostHog welcome/onboarding events and account timestamps for completion/dismissal.

Test plan

  • Unsubscribed user: /welcome/persona → goals → referral → subscribe (no social required) → Stripe checkout
  • After checkout: processing page lands on /onboarding
  • Onboarding checklist: MCP instructions, NetworkConnectGrid, sample prompt + create-post fallback; poll updates checkmarks
  • Skip → calendar; residual banner shows; dismiss hides it
  • Completing all three steps enables continue and sets onboarding_completed_at
  • Self-hosted skips welcome/onboarding to calendar
  • Legacy URLs: /onboarding/goals, /onboarding/referral-source, /onboarding/connect redirect to welcome equivalents
  • php artisan test --compact tests/Feature/Welcome tests/Feature/Onboarding tests/Feature/Actions/Onboarding

Made with Cursor

paulocastellano and others added 30 commits July 24, 2026 12:59
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
…tests.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Prevent polling analytics noise, short-circuit completed onboarding status, and align subscribe copy across locales.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Tighten welcome persona/goals/referral screens, slim goal options, redesign residual onboarding in the sidebar footer, and merge workspace/user menus into one header dropdown with notifications at the top.

Co-authored-by: Cursor <cursoragent@cursor.com>
- Update .env.example to clarify trial days and promotion code settings.
- Replace FirstMonthCheckoutDiscount with ConfigureSubscriptionCheckout for better handling of subscription checkouts.
- Ensure trial days are validated when card is not required during signup.
- Introduce support for promotion codes in the checkout process.
- Remove deprecated FirstMonthCheckoutDiscount class and its associated tests.

Co-authored-by: Cursor <cursoragent@cursor.com>
Replace polling with Echo broadcasts, keep shared residual reads pure, and DRY welcome/platform/MCP surfaces for a cleaner activation path.

Co-authored-by: Cursor <cursoragent@cursor.com>
Fill the English fallback gaps left after the activation i18n prune, including welcome_anonymous and sidebar onboarding labels.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Mirror Changelogfy’s connect/disconnect MCP UI under workspace settings, share settings tabs via a composable, and pin Outros/account links in the sidebar menus.

Co-authored-by: Cursor <cursoragent@cursor.com>
Match onboarding/settings card chrome: border-2, shadow-2xs, bold type, and bordered icon tiles.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
AccordionItem’s default border-b was zeroing the bottom edge when combined with card borders.

Co-authored-by: Cursor <cursoragent@cursor.com>
Hosted clients use config settings URLs with connect buttons; keep accordion config paste for other MCP apps.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
paulocastellano and others added 22 commits July 26, 2026 10:17
Co-authored-by: Cursor <cursoragent@cursor.com>
MCP lives under /settings/workspace, so exclude that path from the Settings active match.

Co-authored-by: Cursor <cursoragent@cursor.com>
Drop the redundant connect intro, clarify section blurbs, and align titles with other workspace settings pages.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Treat only OAuth grants as MCP connections, broadcast checklist updates on revoke/delete, stamp completion off-page, and tighten dismiss/disconnect/docs handling.

Co-authored-by: Cursor <cursoragent@cursor.com>
Stamp completion with a single Completed event, gate skip to owners, harden disconnect, and generate mcpUrl via route('mcp.trypost').

Co-authored-by: Cursor <cursoragent@cursor.com>
Harden residual to owners with hasAppAccess, expire MCP grants, atomically stamp completion, and cut disconnect/Echo noise.

Co-authored-by: Cursor <cursoragent@cursor.com>
Avoid fanning out syncProgress across every account user on MCP token
exchange, stamp completion when another workspace is already ready, and
fix frontend type/lint nits from review.

Co-authored-by: Cursor <cursoragent@cursor.com>
Backfill onboarding dismissal via hasAppAccess so past_due/grace accounts
are covered, owner-gate welcome checkout and completion stamping, keep
dismiss terminal, stamp account completion from workspace sync even when
the actor's persisted current workspace differs, restore a poll fallback
beside Echo, and filter legacy goals that would soft-lock welcome submit.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Limit Checkout trials to first-time card-required signups, add a welcome
logout escape for unpaid members, poll the residual banner when Echo is
down, and stamp account completion from sync/residual when another
workspace already finished activation.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Run observer sync/analytics afterCommit, keep shared residual read-only,
align Welcome with hasAppAccess, require app access to start social OAuth,
throttle welcome checkout, allow teammates to complete activation, and
stop the onboarding poll once the checklist is done.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Generic-trial accounts could complete MCP OAuth during onboarding and then
receive 402 on every API/MCP call because the token middleware still required
subscribed(). Match EnsureAccountReady so checklist step 1 is usable.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Add broadcastForAccount so teammate completion and owner skip refresh
every workspace channel without waiting on the residual poll, and clarify
the residual Echo terminal-state comment.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Broadcast from markCompleted so auto-complete clears banners account-wide,
fan out workspace Echo to siblings while activation is open, and stop the
onboarding poll (redirecting on remote dismiss) once status is terminal.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Redirect dismissed revisits server-side before Viewed analytics, refuse
dismiss after completion, skip client calendar visits during local Skip,
and cover afterCommit rollback so sync never outlives a failed transaction.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Full visits after completion leave before Viewed analytics while Echo
partials still show celebration; complete() stamps via tryMarkAccountComplete
when another workspace is ready; residual counts social/posts account-wide.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Full revisits still redirect to calendar, but markCompleted flashes
onboarding_just_completed so the post-OAuth router.reload can render
the checklist celebration without re-firing Viewed.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Only pull onboarding_just_completed on full visits, and reload onboarding
OAuth success as a partial so checklist celebration survives the race.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Limit qualifiesForCheckoutTrial to the default Cashier subscription type,
refresh the workspace gate docblock, and resolve checklist/residual steps
account-wide so multi-workspace progress stays consistent.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Account-scoped checklist steps already stamp via all_complete/syncProgress,
so the ready-workspace fallback is gone. Add an incomplete_expired Checkout
trial case to match the qualifiesForCheckoutTrial allow-list.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
Keep both onboardingResidual share props and main's contentTypeMediaRules
shareOnce / ContentType frontend types after conflict resolution.

Co-authored-by: Paulo Castellano <hello@paulocastellano.com>
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.

2 participants