GenerateSaaS

Built-in events

The complete catalog of analytics events the boilerplate fires on its own - client events from useAnalytics() and server events from payment webhooks, credit settlement, and auth hooks - with the properties each carries.

The conversion funnel fires automatically - add track calls only for product-specific events. Names follow GA4 recommended events; client events reach every enabled provider, server events PostHog only.

Client events

EventFired whenProperties
pricing_viewedPricing grid enters the viewportsource (marketing / billing)
cta_clickedHero or navbar CTA click (data-analytics-event)event, location
signup_startedFirst interaction with a register form or social buttonmethod
sign_upAccount created (password, OAuth, magic link)method
loginReturning user signs inmethod
onboarding_startedOnboarding form mounts-
onboarding_completedOnboarding form submittedmarketingOptIn
begin_checkoutCheckout startstype, planId / productId / credits, interval
purchaseCheckout return (via trackRevenue)amount, currency, orderId, type
checkout_cancelledProvider checkout abandoned-
searchSearch results shown, once per query (no query text)resultCount
logoutSign-out click-
not_foundLocale 404 page renderspath, referrer (both sanitized)
error_boundaryError boundary catches a render errordigest
unsubscribedUnsubscribe page confirms the opt-out-
waitlist_joinedVisitor joins the waitlist-
organization_createdOrganization createdsource (onboarding / settings)
member_invitedInvitation sentrole
invitation_acceptedInvitation accepted-
api_key_createdAPI key created-
newsletter_subscribed / newsletter_unsubscribedMarketing-emails toggle changes-
contact_form_submittedContact form sent-
account_deletedAccount deletion confirmed-
ai_message_sentMessage sent to the AI chatbackend, hasAttachments
ai_run_cancelledAI run cancelledbackend
  • Redirect auth flows (OAuth, magic link) resolve after the redirect: accounts under 5 minutes old count as sign_up, older ones as login.
  • Client events no-op when no provider is enabled.

Server events

Payment webhooks, credit settlement, and auth hooks emit through @repo/analytics. PostHog is the only server adapter today.

EventFired fromProperties
purchaseStripe / Polar webhookamount, currency, orderId, type (plan / product / credits), providerEventId
subscription_startedwebhookplanId, interval, trial
subscription_renewedwebhook (where surfaced)planId
subscription_upgraded / subscription_downgradedwebhooktoPlanId, fromPlanId where present
subscription_cancelledwebhookplanId, atPeriodEnd where present
trial_startedwebhookplanId
refundwebhook (where surfaced)amount, currency, orderId
credits_consumedMetered credits (AI usage, web tools)amount, feature
email_verifiedBetter Auth email verification-
group organizationOrganization create-
  • Emits never fail a webhook: try/catch-wrapped, fire-and-forget, and retry-safe - each uuid is seeded from ${claimId}:${eventName}, the webhook's own claim id. providerEventId is a purchase property only.
  • purchase reaches PostHog twice by design: the client event feeds the client-only providers; the server event (providerEventId) is the revenue truth.
  • Honors config.analytics.enableInDev.

On this page