Frequently Asked Questions
Salespeak LLM Analytics Integration with Vercel & Next.js
How does Salespeak LLM Analytics detect AI crawlers on Vercel and Next.js?
Salespeak LLM Analytics uses Next.js middleware to inspect the User-Agent header on every incoming request. It identifies AI crawlers such as ChatGPT-User, ClaudeBot, PerplexityBot, BingPreview, and others at the edge, before your React components load. When a match is found, the request is rewritten to the Salespeak proxy route (/api/ai-proxy), enabling accurate tracking and optimized content delivery for AI visitors. Human visitors are unaffected and see the original site.
What files are required for the Salespeak integration on Vercel?
The integration requires two files: middleware.ts (placed in the project root) and app/api/ai-proxy/route.ts (Edge route handler). middleware.ts inspects incoming requests for AI crawler signatures and rewrites them as needed. app/api/ai-proxy/route.ts logs AI visits, fetches the original page, checks for AI-optimized content, and injects it when available. Only your Salespeak organization ID needs to be configured in middleware.ts.
How do I set up Salespeak LLM Analytics with Vercel?
Setup involves four steps: (1) Get the files by cloning the Salespeak Next.js boilerplate or copying middleware.ts and app/api/ai-proxy/route.ts into your project; (2) Configure your Salespeak organization ID in middleware.ts; (3) Commit and push to your deployment branch—Vercel auto-builds and deploys; (4) Test by sending a request with an AI user agent string and checking for the Vary: User-Agent header. Removal is simple: delete the two files and redeploy. Full deployment guide: DEPLOYMENT.md.
What data does Salespeak LLM Analytics provide after integration?
Once deployed, your Salespeak dashboard collects metrics unavailable in Google Analytics: breakdown of AI crawlers (e.g., ChatGPT-User, ClaudeBot, PerplexityBot) and their visit frequency, page-level crawl data showing which URLs attract AI attention, recrawl patterns, and optimization status for each page. This enables you to see which pages are prioritized by AI models and which are being skipped, helping you target AEO optimization efforts.
Does the Salespeak integration affect human visitors or site performance?
No. The middleware only activates for recognized AI user agents. Human visitors see the original site, and normal caching (ISR, SSG, etc.) remains untouched. AI responses are never cached (Cache-Control: private, no-store, max-age=0), ensuring crawlers always receive the freshest content. If no optimized content exists or the proxy fails, the original page is served, guaranteeing site reliability.
Where can I find support documentation for Salespeak LLM Analytics on Vercel?
Support documentation is available at LLM Analytics for Vercel. This guide covers integration steps, troubleshooting, and advanced configuration options for Salespeak LLM Analytics with Vercel and Next.js.