Skip to content

OpenPanel is an open-source web and product analytics platform, an open-source alternative to Mixpanel with optional self-hosting.

wip

Carl-Gerhard Lindesvärd08ea6404e4ee
diff --git a/apps/public/content/docs/mcp/index.mdx b/apps/public/content/docs/mcp/index.mdx
index 38d196fb0..5237e1541 100644
--- a/apps/public/content/docs/mcp/index.mdx
+++ b/apps/public/content/docs/mcp/index.mdx
@@ -31,7 +31,14 @@ The token is a **base64-encoded** string of your client ID and client secret joi
base64(clientId:clientSecret)
```
-Generate it in your terminal:
+#### From the dashboard
+
+The easiest way to get your MCP token is directly from the dashboard — no terminal needed:
+
+- **New client** — after creating a client via **Settings → API Clients**, the success screen shows the **MCP Token** field ready to copy.
+- **Onboarding** — the connect step in the onboarding flow shows the MCP Token alongside your client ID and secret. Use the **Save** button to download all three values as `credentials.txt`.
+
+#### From the terminal
```bash
echo -n "YOUR_CLIENT_ID:YOUR_CLIENT_SECRET" | base64
diff --git a/apps/public/content/features/mcp.json b/apps/public/content/features/mcp.json
new file mode 100644
index 000000000..e792310af
--- /dev/null
+++ b/apps/public/content/features/mcp.json
@@ -0,0 +1,161 @@
+{
+ "slug": "mcp",
+ "short_name": "MCP",
+ "seo": {
+ "title": "Analytics MCP Server - Ask Your AI About Your Users | OpenPanel",
+ "description": "Connect Claude, Cursor, or Windsurf to your OpenPanel analytics via MCP. Query funnels, retention, user profiles, and events without opening the dashboard.",
+ "keywords": [
+ "analytics mcp server",
+ "openpanel mcp",
+ "ai product analytics",
+ "connect analytics to claude",
+ "mixpanel mcp alternative"
+ ]
+ },
+ "hero": {
+ "heading": "Ask your AI about your users",
+ "subheading": "Point Claude, Cursor, Windsurf, or any MCP client at api.openpanel.dev/mcp and your AI can query funnels, retention, user profiles, and events directly. No dashboard required.",
+ "badges": [
+ "38 tools",
+ "Works with Claude, Cursor & Windsurf",
+ "No install required",
+ "Hosted by OpenPanel"
+ ]
+ },
+ "definition": {
+ "title": "What is an analytics MCP server?",
+ "text": "The Model Context Protocol (MCP) is an open standard from Anthropic that lets AI clients connect to external data sources and tools. An analytics MCP server is a bridge: it translates your AI's requests into analytics queries and returns structured data the AI can reason over.\n\nWithout it, getting an answer from your analytics looks like this: open the dashboard, navigate to the right view, build or find the right chart, read the number, close the tab, context-switch back to what you were doing. If the answer leads to another question, repeat.\n\nWith OpenPanel's MCP server, you ask and get an answer—inside the tool you're already in.\n\n```\n\"What's the 7-day retention for users who signed up last month?\"\n\"Which funnel step has the biggest drop-off this week?\"\n\"Show me the last 5 sessions for [email protected]\"\n```\n\nOpenPanel hosts the server at `api.openpanel.dev/mcp`. There's nothing to install or run locally. You create an API client in your dashboard, generate a token, and add the URL to your AI client's config. That's it.\n\nThe server exposes **38 tools** covering every layer of your product data:\n\n- **Events and sessions** — query raw events, filter by property, inspect individual sessions\n- **User profiles** — look up users, their event history, and activity timeline\n- **Funnels** — run funnel queries for any defined event sequence\n- **Retention** — get cohort retention by day, week, or month\n- **Page analytics** — top pages, entry/exit pages, performance metrics\n- **Reports and dashboards** — fetch saved report data by name\n- **Google Search Console** — clicks, impressions, top queries, SEO opportunities (requires GSC connected)\n\n**How this compares to the Google Analytics MCP server:**\n\nGoogle Analytics MCP connects to GA4 data—pageviews, traffic sources, sessions in GA's data model. OpenPanel's MCP connects to your *product* data: custom events, user profiles, funnels you've defined, retention cohorts. If you're tracking what users *do* inside your product, OpenPanel's MCP answers those questions. GA4's doesn't.\n\nAuthentication uses a base64-encoded token built from your client ID and secret. The server is read-only—your AI can fetch and query data but cannot write events, modify users, or change any settings."
+ },
+ "capabilities_section": {
+ "title": "What you can do with it",
+ "intro": "38 tools covering every part of your analytics—queryable in plain language from any MCP client."
+ },
+ "capabilities": [
+ {
+ "title": "Ask questions in plain language",
+ "description": "No SQL, no chart builder. Describe what you want to know and your AI handles the query. Works for funnels, retention, top pages, user lookups, and anything else in your data."
+ },
+ {
+ "title": "Funnel and retention analysis",
+ "description": "Run funnel queries for any event sequence or pull cohort retention tables—without opening the dashboard. Ask follow-up questions and the AI queries again."
+ },
+ {
+ "title": "User and group lookup",
+ "description": "Find any user by email or ID, get their full event timeline, session history, and lifetime metrics. For B2B products, look up groups and their member profiles."
+ },
+ {
+ "title": "Google Search Console data",
+ "description": "If GSC is connected to your project, your AI can also query SEO data—top queries, ranking opportunities, keyword cannibalization, and per-page performance."
+ },
+ {
+ "title": "Works with every major AI client",
+ "description": "Claude Desktop, Claude Code, Cursor, Windsurf, VS Code with MCP extensions, or any other MCP-compatible client. One URL, one token, works everywhere."
+ },
+ {
+ "title": "Stays in your existing context",
+ "description": "Analytics questions come up while you're building or debugging. MCP keeps you in your editor—you get the answer without switching tabs or breaking your focus."
+ }
+ ],
+ "screenshots": [
+ {
+ "src": "/features/feature-mcp-placeholder.webp",
+ "alt": "Claude Desktop querying OpenPanel analytics via MCP",
+ "caption": "Ask about retention, funnels, or individual users directly from Claude Desktop."
+ }
+ ],
+ "how_it_works": {
+ "title": "How to connect your AI to OpenPanel",
+ "intro": "Three steps. Nothing to install—the MCP server is hosted at api.openpanel.dev/mcp.",
+ "steps": [
+ {
+ "title": "Create an API client",
+ "description": "Go to Settings → API Clients in your OpenPanel dashboard. Create a `read` client to scope access to one project, or a `root` client for cross-project access. Copy the client ID and secret."
+ },
+ {
+ "title": "Generate your token",
+ "description": "Your token is your client ID and secret joined by a colon, base64-encoded. Run `echo -n \"CLIENT_ID:CLIENT_SECRET\" | base64` in your terminal to generate it."
+ },
+ {
+ "title": "Add the URL to your AI client",
+ "description": "Paste `https://api.openpanel.dev/mcp?token=YOUR_TOKEN` into your AI client's MCP server config. In Claude Desktop that's one JSON block in `claude_desktop_config.json`. In Cursor and Windsurf it's under MCP settings."
+ },
+ {
+ "title": "Start asking questions",
+ "description": "Your AI now has access to all 38 tools. Ask about users, funnels, retention, or events. If you're not sure what events exist in your project, ask the AI to list them first."
+ }
+ ]
+ },
+ "use_cases": {
+ "title": "Who uses it",
+ "intro": "Anyone who asks analytics questions while doing something else.",
+ "items": [
+ {
+ "title": "Product teams and founders",
+ "description": "You're in a meeting, someone asks about last week's funnel drop-off. You ask Claude, get the answer in seconds, and move on. No one has to open the dashboard."
+ },
+ {
+ "title": "Developers in Cursor or Windsurf",
+ "description": "You're debugging a checkout flow and need to know how many users hit that error state. Ask in your editor. The answer shows up next to your code."
+ },
+ {
+ "title": "Teams without a dedicated analyst",
+ "description": "Most early-stage teams don't have someone who lives in the dashboard. MCP makes it practical for anyone on the team to get answers without learning the tool."
+ }
+ ]
+ },
+ "related_features": [
+ {
+ "slug": "event-tracking",
+ "title": "Event tracking",
+ "description": "The events you track are what the MCP server queries. Better event coverage means better answers."
+ },
+ {
+ "slug": "funnels",
+ "title": "Funnels",
+ "description": "Define funnels in OpenPanel and query them by name through MCP."
+ },
+ {
+ "slug": "retention",
+ "title": "Retention",
+ "description": "Ask retention questions in plain language—the MCP server handles the cohort math."
+ }
+ ],
+ "faqs": {
+ "title": "Frequently asked questions",
+ "intro": "Common questions about OpenPanel's MCP server.",
+ "items": [
+ {
+ "question": "Which AI clients work with OpenPanel MCP?",
+ "answer": "Any MCP-compatible client: Claude Desktop, Claude Code, Cursor, Windsurf, VS Code with an MCP extension, and any custom client built against the MCP spec. The transport is streamable HTTP, which all major clients support."
+ },
+ {
+ "question": "Do I need to install anything?",
+ "answer": "No. The MCP server is hosted by OpenPanel at `https://api.openpanel.dev/mcp`. You add that URL to your AI client's config with your token—nothing runs on your machine."
+ },
+ {
+ "question": "How does authentication work?",
+ "answer": "Your token is `base64(clientId:clientSecret)`. Generate it with `echo -n \"CLIENT_ID:CLIENT_SECRET\" | base64` and append it to the URL as `?token=YOUR_TOKEN`. You can also pass it as an `Authorization: Bearer` header if your client supports that."
+ },
+ {
+ "question": "What's the difference between a read client and a root client?",
+ "answer": "A `read` client is scoped to a single project—the one it was created under. A `root` client can query any project in your organization. Use `read` for single-project setups. Use `root` if you need to ask questions across multiple projects or want to list all projects."
+ },
+ {
+ "question": "Can the AI modify my data?",
+ "answer": "No. The MCP server is strictly read-only. It can query events, fetch profiles, and run analytics computations, but it has no tools for writing events, modifying users, or changing any configuration."
+ },
+ {
+ "question": "Does it work with self-hosted OpenPanel?",
+ "answer": "If you're self-hosting, the MCP server is part of the API—it runs on your instance at the same `/mcp` path. Point your AI client at your own API URL instead of `api.openpanel.dev`."
+ },
+ {
+ "question": "How is this different from the Google Analytics MCP server?",
+ "answer": "Google Analytics MCP connects to GA4 data—pageviews, traffic sources, sessions. OpenPanel's MCP connects to product event data: custom events, user profiles, funnels, retention cohorts. If you want to ask 'what's the 30-day retention for users who completed onboarding', that's not a question GA4's MCP can answer. OpenPanel's can."
+ }
+ ]
+ },
+ "cta": {
+ "label": "Connect your AI to your analytics",
+ "href": "https://dashboard.openpanel.dev/onboarding"
+ }
+}
diff --git a/apps/public/src/app/(home)/_sections/mcp.tsx b/apps/public/src/app/(home)/_sections/mcp.tsx
new file mode 100644
index 000000000..9ab389b61
--- /dev/null
+++ b/apps/public/src/app/(home)/_sections/mcp.tsx
@@ -0,0 +1,131 @@
+import { ArrowRightIcon } from 'lucide-react';
+import Link from 'next/link';
+import { McpIllustration } from '@/components/illustrations/mcp';
+import { Section, SectionLabel } from '@/components/section';
+
+const tools = [
+ 'find_groups',
+ 'find_profiles',
+ 'get_analytics_overview',
+ 'get_country_breakdown',
+ 'get_dashboard_urls',
+ 'get_device_breakdown',
+ 'get_entry_exit_pages',
+ 'get_event_property_values',
+ 'get_funnel',
+ 'get_group',
+ 'get_page_conversions',
+ 'get_page_performance',
+ 'get_profile',
+ 'get_profile_metrics',
+ 'get_profile_sessions',
+ 'get_report_data',
+ 'get_retention_cohort',
+ 'get_rolling_active_users',
+ 'get_top_pages',
+ 'get_top_referrers',
+ 'get_user_flow',
+ 'get_user_last_seen_distribution',
+ 'get_weekly_retention_series',
+ 'gsc_get_cannibalization',
+ 'gsc_get_overview',
+ 'gsc_get_page_details',
+ 'gsc_get_query_details',
+ 'gsc_get_query_opportunities',
+ 'gsc_get_top_pages',
+ 'gsc_get_top_queries',
+ 'list_dashboards',
+ 'list_event_names',
+ 'list_event_properties',
+ 'list_group_types',
+ 'list_projects',
+ 'list_reports',
+ 'query_events',
+ 'query_sessions',
+];
+
+function ToolTicker() {
+ // Duplicate for seamless loop
+ const row = [...tools, ...tools];
+
+ return (
+ <div className="relative overflow-hidden [mask-image:linear-gradient(to_right,transparent,black_15%,black_85%,transparent)]">
+ <style>{`
+ @keyframes ticker {
+ from { transform: translateX(0); }
+ to { transform: translateX(-50%); }
+ }
+ .ticker-track {
+ animation: ticker 70s linear infinite;
+ }
+ .ticker-track:hover {
+ animation-play-state: paused;
+ }
+ `}</style>
+ <div className="ticker-track flex w-max gap-2">
+ {row.map((tool, i) => (
+ <div
+ // biome-ignore lint/suspicious/noArrayIndexKey: static duplicate list
+ className="flex shrink-0 items-center gap-1.5 rounded-md border border-border bg-card px-2.5 py-1.5"
+ key={i}
+ >
+ <span className="size-1.5 rounded-full bg-emerald-500" />
+ <span className="font-mono text-[10px] text-muted-foreground">
+ {tool}
+ </span>
+ </div>
+ ))}
+ </div>
+ </div>
+ );
+}
+
+export function Mcp() {
+ return (
+ <Section className="container">
+ <div className="grid grid-cols-1 items-center gap-12 md:grid-cols-2 md:gap-16">
+ {/* Left: copy */}
+ <div className="col gap-6">
+ <SectionLabel>AI-NATIVE ANALYTICS</SectionLabel>
+
+ <h2 className="font-semibold text-3xl leading-[1.1] md:text-5xl">
+ Ask your AI{' '}
+ <span className="block text-muted-foreground">anything</span>
+ about your users
+ </h2>
+
+ <p className="text-muted-foreground leading-relaxed">
+ Connect Claude, Cursor, Windsurf, or your own AI agent to your
+ OpenPanel data via MCP. No more tab-switching or building charts,
+ your AI has the answers.
+ </p>
+
+ {/* Tool count + ticker */}
+ <ToolTicker />
+
+ {/* CTAs */}
+ <div className="row items-center gap-4">
+ <Link
+ className="inline-flex items-center gap-2 rounded-full bg-foreground px-5 py-2.5 font-semibold text-background text-sm transition-opacity hover:opacity-80"
+ href="https://dashboard.openpanel.dev/onboarding"
+ >
+ Try it now
+ <ArrowRightIcon className="size-3.5" />
+ </Link>
+ <Link
+ className="row items-center gap-2 text-muted-foreground text-sm transition-colors hover:text-foreground"
+ href="/docs/mcp#available-tools"
+ >
+ View all 38 tools <ArrowRightIcon className="size-3.5" />
+ </Link>
+ </div>
+ </div>
+
+ {/* Right: illustration */}
+ <div className="group h-[420px]">
+ <McpIllustration />
+ </div>
+ </div>
+ </Section>
+ );
+}
diff --git a/apps/public/src/app/(home)/page.tsx b/apps/public/src/app/(home)/page.tsx
index fccf9394a..ec9659f15 100644
--- a/apps/public/src/app/(home)/page.tsx
+++ b/apps/public/src/app/(home)/page.tsx
@@ -4,6 +4,7 @@ import { FeatureSpotlight } from './_sections/feature-spotlight';
import { CtaBanner } from './_sections/cta-banner';
import { DataPrivacy } from './_sections/data-privacy';
import { Faq } from './_sections/faq';
+import { Mcp } from './_sections/mcp';
import { MixpanelAlternative } from './_sections/mixpanel-alternative';
import { Hero } from './_sections/hero';
import { Pricing } from './_sections/pricing';
@@ -58,6 +59,7 @@ export default function HomePage() {
/>
<Hero />
<WhyOpenPanel />
+ <Mcp />
<AnalyticsInsights />
<FeatureSpotlight />
<Collaboration />
diff --git a/apps/public/src/components/illustrations/mcp.tsx b/apps/public/src/components/illustrations/mcp.tsx
new file mode 100644
index 000000000..1d56b4b5b
--- /dev/null
+++ b/apps/public/src/components/illustrations/mcp.tsx
@@ -0,0 +1,269 @@
+'use client';
+
+import type { ReactNode } from 'react';
+import { useEffect, useRef, useState } from 'react';
+
+const toolCalls = [
+ {
+ name: 'get_analytics_overview',
+ params: [
+ { key: 'projectId', value: '"acme-corp"' },
+ { key: 'startDate', value: '"2024-03-18"' },
+ { key: 'endDate', value: '"2024-03-24"' },
+ ],
+ result: '12,847 visitors · 1,234 signups · 3.1% bounce',
+ },
+ {
+ name: 'get_funnel',
+ params: [
+ { key: 'events', value: '["page_view", "signed_up"]' },
+ { key: 'startDate', value: '"2024-03-18"' },
+ ],
+ result: '72% conversion · up from 61% prev week',
+ },
+];
+
+// Response split into segments so highlights apply as text streams in
+const RESPONSE = 'Last week saw 1,234 new signups — up 23% from the week before. Your signup funnel is converting at 72%, the highest rate in the past month.';
+
+type Phase = 'user' | 'thinking' | 'tool1' | 'tool2' | 'streaming' | 'done';
+
+function ThinkingDots() {
+ return (
+ <div className="flex items-center gap-1 px-1 py-0.5">
+ {[0, 1, 2].map((i) => (
+ <span
+ key={i}
+ className="inline-block size-1.5 rounded-full bg-white/30 animate-bounce"
+ style={{ animationDelay: `${i * 150}ms`, animationDuration: '900ms' }}
+ />
+ ))}
+ </div>
+ );
+}
+
+function ToolCard({
+ tool,
+ visible,
+ dim,
+}: {
+ tool: (typeof toolCalls)[number];
+ visible: boolean;
+ dim: boolean;
+}) {
+ return (
+ <div
+ className="overflow-hidden transition-all duration-500 ease-out"
+ style={{
+ maxHeight: visible ? '120px' : '0px',
+ opacity: visible ? (dim ? 0.5 : 1) : 0,
+ transform: visible ? 'translateY(0)' : 'translateY(6px)',
+ }}
+ >
+ <div className="rounded-xl border border-[#d97757]/25 bg-[#d97757]/8 px-3 py-2.5">
+ <div className="mb-2 flex items-center gap-1.5">
+ <span className="inline-block size-1.5 rounded-full bg-[#d97757] animate-pulse" />
+ <span className="font-mono font-semibold text-[#d97757] text-[9px]">
+ {tool.name}
+ </span>
+ </div>
+ <div className="col gap-0.5 font-mono text-[8.5px] text-white/35">
+ {tool.params.map((p) => (
+ <div key={p.key}>
+ <span className="text-white/25">{p.key}: </span>
+ <span className="text-white/50">{p.value}</span>
+ </div>
+ ))}
+ </div>
+ <div className="mt-2 border-white/8 border-t pt-2 font-mono text-[8.5px]">
+ <span className="text-white/30">↳ </span>
+ <span className="text-emerald-400/80">{tool.result}</span>
+ </div>
+ </div>
+ </div>
+ );
+}
+
+function StreamingText({ text, done }: { text: string; done: boolean }) {
+ // Split the full response into plain/highlighted segments for rendering
+ const segments: { content: string; highlight?: 'white' | 'emerald' }[] = [
+ { content: 'Last week saw ' },
+ { content: '1,234 new signups', highlight: 'white' },
+ { content: ' — up 23% from the week before. Your signup funnel is converting at ' },
+ { content: '72%', highlight: 'emerald' },
+ { content: ', the highest rate in the past month.' },
+ ];
+
+ // Walk through segments, revealing up to text.length characters
+ let remaining = text.length;
+ const rendered: ReactNode[] = [];
+
+ for (const seg of segments) {
+ if (remaining <= 0) break;
+ const visible = seg.content.slice(0, remaining);
+ remaining -= seg.content.length;
+
+ if (seg.highlight === 'white') {
+ rendered.push(
+ <span key={seg.content} className={done ? 'font-semibold text-white/90' : 'text-white/70'}>
+ {visible}
+ </span>,
+ );
+ } else if (seg.highlight === 'emerald') {
+ rendered.push(
+ <span key={seg.content} className={done ? 'font-semibold text-emerald-400' : 'text-white/70'}>
+ {visible}
+ </span>,
+ );
+ } else {
+ rendered.push(<span key={seg.content}>{visible}</span>);
+ }
+ }
+
+ return (
+ <p className="text-[10px] text-white/70 leading-relaxed">
+ {rendered}
+ {!done && (
+ <span className="ml-0.5 inline-block h-3 w-px bg-white/60 animate-pulse align-middle" />
+ )}
+ </p>
+ );
+}
+
+export function McpIllustration() {
+ const [phase, setPhase] = useState<Phase>('user');
+ const [charCount, setCharCount] = useState(0);
+ const cancelledRef = useRef(false);
+
+ useEffect(() => {
+ cancelledRef.current = false;
+
+ let currentTimer: ReturnType<typeof setTimeout> | null = null;
+
+ function sleep(ms: number): Promise<void> {
+ return new Promise((resolve) => {
+ currentTimer = setTimeout(resolve, ms);
+ });
+ }
+
+ async function run() {
+ while (!cancelledRef.current) {
+ setPhase('user');
+ setCharCount(0);
+
+ await sleep(1000);
+ if (cancelledRef.current) return;
+ setPhase('thinking');
+
+ await sleep(900);
+ if (cancelledRef.current) return;
+ setPhase('tool1');
+
+ await sleep(800);
+ if (cancelledRef.current) return;
+ setPhase('tool2');
+
+ await sleep(700);
+ if (cancelledRef.current) return;
+ setPhase('streaming');
+
+ // Stream chars two at a time
+ for (let i = 2; i <= RESPONSE.length && !cancelledRef.current; i += 2) {
+ setCharCount(Math.min(i, RESPONSE.length));
+ await sleep(22);
+ }
+ if (cancelledRef.current) return;
+ setCharCount(RESPONSE.length);
+
+ setPhase('done');
+ await sleep(3500);
+ }
+ }
+
+ run();
+
+ return () => {
+ cancelledRef.current = true;
+ if (currentTimer) clearTimeout(currentTimer);
+ };
+ }, []);
+
+ const showThinking = phase === 'thinking' || phase === 'tool1' || phase === 'tool2';
+ const showTool1 = phase === 'tool1' || phase === 'tool2' || phase === 'streaming' || phase === 'done';
+ const showTool2 = phase === 'tool2' || phase === 'streaming' || phase === 'done';
+ const showResponse = phase === 'streaming' || phase === 'done';
+
+ return (
+ <div className="relative h-full w-full overflow-hidden rounded-2xl border border-white/10 bg-[#1a1a1a] shadow-2xl transition-transform duration-300 group-hover:scale-[1.01]">
+ {/* Window chrome */}
+ <div className="flex items-center gap-1.5 border-white/8 border-b bg-[#161616] px-4 py-3">
+ <div className="size-2.5 rounded-full bg-[#ff5f57]" />
+ <div className="size-2.5 rounded-full bg-[#febc2e]" />
+ <div className="size-2.5 rounded-full bg-[#28c840]" />
+ <span className="absolute right-0 left-0 flex-1 text-center font-medium text-[10px] text-white/30">
+ Claude
+ </span>
+ </div>
+
+ {/* Chat body */}
+ <div className="col gap-3 p-4">
+ {/* User message — always visible */}
+ <div className="flex justify-end">
+ <div className="max-w-[78%] rounded-2xl rounded-tr-md bg-[#2a2a2a] px-3.5 py-2.5">
+ <p className="text-[10px] text-white/85 leading-relaxed">
+ How did our signups perform last week, and what's our funnel
+ conversion looking like?
+ </p>
+ </div>
+ </div>
+
+ {/* Claude avatar row */}
+ <div className="flex items-center gap-2">
+ <div className="flex size-4 shrink-0 items-center justify-center">
+ <svg
+ className="size-4 fill-[#d97757]"
+ viewBox="0 0 100 100"
+ xmlns="http://www.w3.org/2000/svg"
+ >
+ <path d="m19.6 66.5 19.7-11 .3-1-.3-.5h-1l-3.3-.2-11.2-.3L14 53l-9.5-.5-2.4-.5L0 49l.2-1.5 2-1.3 2.9.2 6.3.5 9.5.6 6.9.4L38 49.1h1.6l.2-.7-.5-.4-.4-.4L29 41l-10.6-7-5.6-4.1-3-2-1.5-2-.6-4.2 2.7-3 3.7.3.9.2 3.7 2.9 8 6.1L37 36l1.5 1.2.6-.4.1-.3-.7-1.1L33 25l-6-10.4-2.7-4.3-.7-2.6c-.3-1-.4-2-.4-3l3-4.2L28 0l4.2.6L33.8 2l2.6 6 4.1 9.3L47 29.9l2 3.8 1 3.4.3 1h.7v-.5l.5-7.2 1-8.7 1-11.2.3-3.2 1.6-3.8 3-2L61 2.6l2 2.9-.3 1.8-1.1 7.7L59 27.1l-1.5 8.2h.9l1-1.1 4.1-5.4 6.9-8.6 3-3.5L77 13l2.3-1.8h4.3l3.1 4.7-1.4 4.9-4.4 5.6-3.7 4.7-5.3 7.1-3.2 5.7.3.4h.7l12-2.6 6.4-1.1 7.6-1.3 3.5 1.6.4 1.6-1.4 3.4-8.2 2-9.6 2-14.3 3.3-.2.1.2.3 6.4.6 2.8.2h6.8l12.6 1 3.3 2 1.9 2.7-.3 2-5.1 2.6-6.8-1.6-16-3.8-5.4-1.3h-.8v.4l4.6 4.5 8.3 7.5L89 80.1l.5 2.4-1.3 2-1.4-.2-9.2-7-3.6-3-8-6.8h-.5v.7l1.8 2.7 9.8 14.7.5 4.5-.7 1.4-2.6 1-2.7-.6-5.8-8-6-9-4.7-8.2-.5.4-2.9 30.2-1.3 1.5-3 1.2-2.5-2-1.4-3 1.4-6.2 1.6-8 1.3-6.4 1.2-7.9.7-2.6v-.2H49L43 72l-9 12.3-7.2 7.6-1.7.7-3-1.5.3-2.8L24 86l10-12.8 6-7.9 4-4.6-.1-.5h-.3L17.2 77.4l-4.7.6-2-2 .2-3 1-1 8-5.5Z" />
+ </svg>
+ </div>
+ <span className="font-medium text-[9px] text-white/40">Claude</span>
+ </div>
+
+ {/* Thinking dots */}
+ <div
+ className="transition-all duration-300"
+ style={{
+ maxHeight: showThinking ? '24px' : '0px',
+ opacity: showThinking ? 1 : 0,
+ overflow: 'hidden',
+ }}
+ >
+ <ThinkingDots />
+ </div>
+
+ {/* Tool calls */}
+ <div className="col gap-2">
+ <ToolCard tool={toolCalls[0]!} visible={showTool1} dim={false} />
+ <ToolCard tool={toolCalls[1]!} visible={showTool2} dim={false} />
+ </div>
+
+ {/* Streaming response */}
+ <div
+ className="transition-all duration-300"
+ style={{
+ maxHeight: showResponse ? '120px' : '0px',
+ opacity: showResponse ? 1 : 0,
+ overflow: 'hidden',
+ }}
+ >
+ <StreamingText
+ text={RESPONSE.slice(0, charCount)}
+ done={phase === 'done'}
+ />
+ </div>
+ </div>
+ </div>
+ );
+}
diff --git a/apps/public/src/components/illustrations/session-replay.tsx b/apps/public/src/components/illustrations/session-replay.tsx
index 07c8e696a..90445dbcd 100644
--- a/apps/public/src/components/illustrations/session-replay.tsx
+++ b/apps/public/src/components/illustrations/session-replay.tsx
@@ -2,7 +2,7 @@ import { PlayIcon } from 'lucide-react';
export function SessionReplayIllustration() {
return (
- <div className="h-full px-6 pb-3 pt-4">
+ <div className="session-replay-illustration h-full px-6 pb-3 pt-4">
<div className="col h-full overflow-hidden rounded-xl border border-border bg-background shadow-lg transition-transform duration-300 group-hover:-translate-y-0.5">
{/* Browser chrome */}
<div className="row shrink-0 items-center gap-1.5 border-b border-border bg-muted/30 px-3 py-2">
@@ -55,10 +55,11 @@ export function SessionReplayIllustration() {
{/* Cursor */}
<div
- className="absolute"
+ className="cursor-animated absolute"
style={{
- left: 'calc(62% + 8px)',
- top: 'calc(48% + 6px)',
+ left: 'calc(18% + 8px)',
+ top: 'calc(22% + 6px)',
+ animation: 'cursor-trail 4s cubic-bezier(0.4, 0, 0.2, 1) infinite',
}}
>
<svg fill="none" height="12" viewBox="0 0 10 12" width="10">
@@ -68,6 +69,20 @@ export function SessionReplayIllustration() {
/>
</svg>
</div>
+ <style>{`
+ @keyframes cursor-trail {
+ 0% { left: calc(18% + 8px); top: calc(22% + 6px); }
+ 55% { left: calc(62% + 8px); top: calc(48% + 6px); }
+ 75% { left: calc(62% + 8px); top: calc(48% + 6px); }
+ 100% { left: calc(18% + 8px); top: calc(22% + 6px); }
+ }
+ .session-replay-illustration .cursor-animated {
+ animation-play-state: paused;
+ }
+ .session-replay-illustration:hover .cursor-animated {
+ animation-play-state: running;
+ }
+ `}</style>
</div>
{/* Playback bar */}
diff --git a/apps/start/src/components/clients/create-client-success.tsx b/apps/start/src/components/clients/create-client-success.tsx
index 63b6ed70f..40ff32e95 100644
--- a/apps/start/src/components/clients/create-client-success.tsx
+++ b/apps/start/src/components/clients/create-client-success.tsx
@@ -1,11 +1,24 @@
import { Alert, AlertDescription, AlertTitle } from '@/components/ui/alert';
-import { RocketIcon } from 'lucide-react';
+import { Button } from '@/components/ui/button';
+import { DownloadIcon, RocketIcon } from 'lucide-react';
import CopyInput from '../forms/copy-input';
type Props = { id: string; secret: string };
export function CreateClientSuccess({ id, secret }: Props) {
+ const mcpToken = btoa(`${id}:${secret}`);
+
+ const download = () => {
+ const credentials = `CLIENT_ID=${id}\nCLIENT_SECRET=${secret}\nMCP_TOKEN=${mcpToken}`;
+ const blob = new Blob([credentials], { type: 'text/plain' });
+ const url = URL.createObjectURL(blob);
+ const a = document.createElement('a');
+ a.href = url;
+ a.download = 'credentials.txt';
+ a.click();
+ };
+
return (
<div className="grid gap-4">
<CopyInput label="Client ID" value={id} />
@@ -17,6 +30,18 @@ export function CreateClientSuccess({ id, secret }: Props) {
</p>
</div>
)}
+ {secret && (
+ <div className="w-full">
+ <CopyInput label="MCP Token" value={mcpToken} />
+ <p className="mt-1 text-sm text-muted-foreground">
+ Use this token to authenticate with the MCP server (base64 encoded
+ client ID and secret).
+ </p>
+ </div>
+ )}
+ <Button variant="outline" icon={DownloadIcon} onClick={download}>
+ Save credentials
+ </Button>
<Alert>
<RocketIcon className="h-4 w-4" />
<AlertTitle>Get started!</AlertTitle>
diff --git a/apps/start/src/routes/_steps.onboarding.$projectId.connect.tsx b/apps/start/src/routes/_steps.onboarding.$projectId.connect.tsx
index ced38f355..81ca446a2 100644
--- a/apps/start/src/routes/_steps.onboarding.$projectId.connect.tsx
+++ b/apps/start/src/routes/_steps.onboarding.$projectId.connect.tsx
@@ -53,7 +53,8 @@ function Component() {
);
}
- const credentials = `CLIENT_ID=${client.id}\nCLIENT_SECRET=${secret}`;
+ const mcpToken = btoa(`${client.id}:${secret}`);
+ const credentials = `CLIENT_ID=${client.id}\nCLIENT_SECRET=${secret}\nMCP_TOKEN=${mcpToken}`;
const download = () => {
const blob = new Blob([credentials], { type: 'text/plain' });
const url = URL.createObjectURL(blob);
@@ -92,7 +93,7 @@ function Component() {
</div>
<Syntax
className="border"
- code={`CLIENT_ID=${client.id}\nCLIENT_SECRET=${secret}`}
+ code={`CLIENT_ID=${client.id}\nCLIENT_SECRET=${secret}\nMCP_TOKEN=${mcpToken}`}
copyable={false}
language="bash"
/>