Skip to content

feat(tracking): ChatGPT Shopping as a Growth-gated opt-in platform (capture shoppingCards + inlineProducts) #95

Closed

Description

@gkhngyk

Epic — multi-part (new platform + plan gating + capture/storage). Not a good-first-issue. Data capture + gating only; the shopping display UI is a separate future feature.

What

Add "ChatGPT Shopping" as a separate, opt-in platform (not always-on on regular ChatGPT). When a brand enables it, tracking runs a ChatGPT request with include.shopping: true and captures the structured product data. Gated to the Growth plan in cloud; unlocked on self-hosted like every other feature.

Companion to the already-shipped shopping capture for Perplexity (#46), Copilot (#47/#87), and AI Mode (#49) — but ChatGPT is different (see below), which is why it gets its own gated platform.

Why a separate, gated platform (not always-on)

  • Shopping data is only meaningful for product / e-commerce brands — not every customer has a product catalog.
  • ChatGPT shopping is opt-in at Cloro and costs +2 credits per request (Perplexity/Copilot/AI Mode return cards for free, default-on — those stay as-is, no gating needed). So forcing it on everyone would add cost for brands that don't need it.
  • Making it a Growth-only, per-brand opt-in platform means only brands that choose it (and pay for Growth) incur the cost — "you opted in, you pay." Fits the existing per-brand platform toggles + plan allowedScrapers gating.

Findings from live testing (so this is accurate)

  • Without include.shopping the ChatGPT response has no shoppingCards/inlineProducts — only an entities array (product names only, no price/offers). Confirmed across 12+ runs incl. gpt-5-3-mini.
  • With include.shopping: true both shoppingCards and inlineProducts (camelCase) appear. The rich product data can land in either field depending on the prompt:
    • US "best sneakers under $100" → shoppingCards present (was empty in our runs).
    • FR "trottinette freestyle robuste pour ado/adulte" (ES) → shoppingCards empty, inlineProducts = 4 populated (e.g. Scooter Blunt Prodigy X, 197,90 €, Decathlon.es + others, url, image_urls).
    • → Must capture BOTH shoppingCards and inlineProducts.
  • Shopping cards mostly appear on ChatGPT's gpt-5-3-mini model (ChatGPT auto-selects → intermittent).
  • Note: inlineProducts also appears on AI Mode (default, no flag) and is currently not captured — see "bonus" below.

Approach (separate platform)

New scraper id chatgpt-shopping → Cloro taskType CHATGPT with include.shopping: true. Runs as its own scrape, writing separate prompt_results rows with platform = 'chatgpt-shopping' (distinct from chatgpt-web brand-visibility). Per-brand opt-in via brand_platforms, gated by plan.

Where to change

  • server/src/lib/cloro-scraper.js (link):
    • SCRAPER_TASK_TYPES['chatgpt-shopping'] = 'CHATGPT'
    • buildRequestBody: for chatgpt-shopping, send the ChatGPT body with include.shopping: true
    • parseScraperResponse: for chatgpt-shopping, return shopping_cards: result.shoppingCards ?? [] and inline_products: result.inlineProducts ?? []
  • Migration 00006_prompt_results_inline_products.sql: ADD COLUMN inline_products jsonb NOT NULL DEFAULT '[]' (mirrors shopping_cards).
  • web/src/types/supabase.ts + server/src/lib/cloro-result-handler.js: add inline_products to the prompt_results insert/types.
  • Plan gating web/src/config/plans.ts (link): keep chatgpt-shopping out of starter.allowedScrapers (Starter only whitelists chatgpt-web/perplexity-web); Growth has no scraper whitelist → allowed; self_hosted/enterprise unrestricted → allowed. (Net: Growth + self-hosted only.)
  • Scraper options (web/src/config/prompt-options.ts ALL_SCRAPERS): add a chatgpt-shopping entry so it shows as a selectable platform ("ChatGPT Shopping").
  • UI: it surfaces as a platform toggle in brand platform settings, shown only when the plan allows it (existing activeScrapers logic already filters by allowedScrapers).

Cost

chatgpt-shopping is a separate Cloro CHATGPT scrape + 2 credits per prompt × region, on top of chatgpt-web if that's also enabled. Contained to Growth brands that opt in.

Acceptance criteria

  • "ChatGPT Shopping" appears as a platform, selectable only on Growth (cloud) and self-hosted — not on Starter.
  • When enabled, tracking runs a ChatGPT scrape with include.shopping: true and stores shopping_cards and inline_products on platform = 'chatgpt-shopping' rows.
  • A prompt whose products land in inlineProducts (e.g. the scooter example) is captured (not dropped as empty shopping_cards).
  • No extra credits / no behavior change for brands that don't enable it.
  • Other providers' shopping capture unchanged.

Bonus (optional, same PR or follow-up)

AI Mode also returns inlineProducts (free, default) — once the inline_products column exists, capture it in the AI Mode branch too.

Out of scope

The shopping display UI (separate "Shopping" feature), scoring, brand-in-card detection, MCP/REST exposure. Gating Perplexity/Copilot/AI Mode shopping (they're free, default-on — left as-is).

Activity

  1. added
    enhancement
    help wanted
    on May 25, 2026
  2. changed the title [-]feat(tracking): capture ChatGPT shopping cards (opt-in include.shopping for chatgpt-web)[/-] [+]feat(tracking): ChatGPT Shopping as a Growth-gated opt-in platform (capture shoppingCards + inlineProducts)[/+] on May 25, 2026
  3. gkhngyk commented on Jun 2, 2026

    @gkhngyk
    ContributorAuthor

    Closing in favor of #155, which covers this issue's scope plus two newer asks: an org-level Settings toggle for "I'm in e-commerce" (auto-bulk-adds the ChatGPT Shopping platform to every brand instead of expecting per-brand opt-in deep in Brand Settings), and an explicit rule that platform = 'chatgpt-shopping' rows are excluded from Insights aggregations because they come from a different model (gpt-5-3-mini) and would skew brand-level visibility numbers.

    The capture / scraper / plan-gating work this issue described is preserved verbatim inside #155 — nothing dropped, just bundled with the org-level UX layer so the whole experience ships as one epic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementhelp wanted

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions