Appearance
Historical snapshot archived 2026-09-25. This records an earlier review or plan, not current implementation or live ticket state. For current work, follow root AGENTS.md, the relevant BloxClips skill, and owning repository source/tests. Preserve approved decisions as evidence; verify their present authority before acting.
Whop Integration
Scope actually present
Whop is not BloxClips login, campaign, or payout ownership. The verified integrations are reading a Whop company’s member_count for a public “creator network” statistic and the embedded support chat. Other Whop references are outbound links and a free-text username in the PV tracker.
No code was found for Whop webhooks, product/experience management, membership synchronization, Whop OAuth, Whop payments, balances, or payouts.
Company member count
| Aspect | Implementation |
|---|---|
| Purpose | Display the apparent size of the creator/clipper community |
| Whop concept | Company/business record and its member_count |
| Frontend server | BloxClips-frontend/app/api/live/clipper-count/route.ts |
| Backend server | Parallel Bloxclips-backend/src/api/routes/live.ts endpoint |
| Active frontend consumers | Public BrandStats/LiveCreatorNetworkStat components call the same-origin Next route |
| Request | GET {WHOP_API_BASE_URL}/api/v1/companies/{company route} with company API key |
| Cache | Short process-memory cache; frontend and backend caches are independent |
| Fallback | PUBLIC_CLIPPER_COUNT_FALLBACK, default 25,000 |
| Variables | WHOP_API_BASE_URL, WHOP_API_KEY/WHOP_COMPANY_API_KEY, WHOP_COMPANY_ROUTE, CLIPPER_COUNT_CACHE_MS, fallback |
Failure returns a fallback count/source rather than failing the page. The public display components update their visible value only when the response source is whop; therefore a fallback response may leave the live statistic visually unset rather than displaying the fallback. This is current behavior, not corrected here.
Embedded support chat
/dashboard/support uses Whop's embedded Elements, ChatSession, and ChatElement for both clippers and authorized staff. BloxClips keeps Google OAuth and derives the current WebUser from the authenticated server session. ensureWhopIdentity creates/reconciles a Whop connected account as needed, then persists the child account ID and its owner_user.id in the one-to-one WhopIdentity model.
WHOP_COMPANY_ID must be BloxClips's Whop company/account ID (biz_...), not WHOP_COMPANY_ROUTE=bloxclips. Set it only in Bloxclips-backend/.env; obtain it from Whop Dashboard → your company → Settings → Developer/API. The API key and company ID remain server-only.
The API key needs company:create, company:basic:read, support_chat:create, and support_chat:read; it also needs permission to mint account-scoped tokens with support_chat:read and support_chat:message:create. There is no identity migration command and no admin exemption. A verified BloxClips email is the only profile prerequisite for automatic provisioning.
Clippers call supportChannels.create({ company_id, user_id }), which Whop defines as idempotent for the customer support relationship. Authorized BloxClips staff instead use supportChannels.list({ company_id, view: 'admin' }), select a returned feed_..., and render it with the same ChatElement. Staff must separately have native Whop team support access; provisioning their connected-account identity does not grant that role.
Other references
- The bot welcome DM links users to
https://whop.com/bloxclips(src/index.ts). - Public marketing content includes Whop links.
- PV tracker creator records have a
whop_usernametext property. It is used as an operator cross-reference, not joined to a Whop API resource or Prisma user.
Terminology mapping
| Internal concept | Whop concept | Notes |
|---|---|---|
| Creator network / clipper count | Company member_count | A marketing statistic; not a locally synchronized membership table |
WHOP_COMPANY_ROUTE | Company route/identifier | Used to construct the API path |
WHOP_COMPANY_ID | Company/account id (biz_...) | Required by Whop Support Chat APIs; distinct from the route slug |
PV whop_username | Unverified username text | File-backed annotation only |
BloxClips WebUser | Connected-account owner user | WhopIdentity maps the authenticated BloxClips user to Whop |
| BloxClips campaign/payout | None established | Stored and processed internally |
Failure and ownership cautions
- Next.js and Express independently implement the same endpoint. Changing one does not change the other.
- The API key is server-only even though the resulting count is public.
- “Whop user/member” should not be used as a synonym for
WebUseror clipper based on current code. - Ask the prior team whether a broader Whop integration exists outside these repositories before designing against products, experiences, or memberships.