{"slug": "building-insighttrack-with-serpapi-for-the-serpapi-india-hackathon", "title": "Building InsightTrack with SerpApi for the SerpApi India Hackathon", "summary": "A developer built InsightTrack, a tool that combines analytics traffic data with SerpApi SERP data to explain why a page's traffic changed, using deterministic attribution rules rather than letting an AI guess. The project, submitted for the SerpApi India Hackathon, exposes its functionality through MCP so AI agents can query ranking and traffic evidence, with the Gemini API handling natural-language interaction. The developer also factored API credit budgets into the product design, calculating that tracking 8 keywords daily costs roughly 240 searches per month.", "body_md": "A few weeks ago, I was looking at a page whose traffic had suddenly dropped.\n\nThe analytics told me exactly what happened:\n\n**Traffic was down.**\n\nBut then I had the question that analytics couldn't answer:\n\n**Why?**\n\nDid the page lose its Google ranking?\n\nDid a competitor move above me?\n\nDid Google change the search results?\n\nDid an AI Overview start answering the query?\n\nMy next step was usually pretty manual. I'd open Google, search the keyword, check my position, look at the competitors, and try to figure out what changed.\n\nThat got me thinking:\n\n**What if I could connect my traffic data with the search results automatically?**\n\nThat's how I started building **InsightTrack**.\n\nThe idea behind InsightTrack is pretty simple.\n\nI already have one side of the story from my analytics:\n\n```\n/guides/email-templates\n\nLast week: 1,240 visits\nThis week:   719 visits\n```\n\nNow I need the other side.\n\nWhat happened in Google?\n\nThat's where **SerpApi** comes in.\n\nFor the SerpApi India Hackathon, I'm integrating SerpApi with InsightTrack to collect SERP data and track how search visibility changes over time.\n\nFor example:\n\n```\n\"free email templates\"\n\nLast week: #3\nThis week: #9\n```\n\nNow the two pieces can be connected.\n\nInstead of simply saying:\n\n“Traffic dropped 42%.”\n\nInsightTrack can say:\n\n**“Traffic dropped because the page moved from #3 to #9, while other websites moved above it.”**\n\nThat's a much more useful answer.\n\nThis became one of the most important parts of the project.\n\nImagine traffic drops by 30%, but the ranking stays exactly the same.\n\nA system that always needs to produce an explanation might blame search anyway.\n\nI didn't want that.\n\nInsightTrack uses deterministic rules to compare traffic and SERP changes.\n\nIf the evidence points to a ranking change, it reports that.\n\nIf a competitor moved above you, it can identify that.\n\nBut if search didn't really change, it can say:\n\n**“Search visibility didn't change enough to explain this. Check your referrers, campaigns, or recent deployment.”**\n\nThe goal isn't to always have an answer.\n\nThe goal is to have an answer that can be explained.\n\nSuppose we have:\n\n```\nTraffic:       -42%\nRanking:       #3 → #9\nCompetitor:    moved above us\nAI Overview:   appeared\n```\n\nInsightTrack combines those observations and produces a finding instead of making me investigate each piece manually.\n\nUnder the hood, the attribution engine is just a pure function:\n\n```\ntraffic data + keyword findings → finding\n```\n\nNo database or API calls inside that layer.\n\nThat makes it easy to test and, more importantly, makes the result reproducible.\n\nI also wanted this information to be accessible to AI agents.\n\nSo InsightTrack exposes the same functionality through **MCP**.\n\nNow I can ask:\n\n**“Who is ranking above me for ‘free email templates’, and why did they overtake me?”**\n\nThe Gemini API handles the natural-language interaction, while InsightTrack provides the underlying search and traffic data.\n\nThe AI doesn't decide the attribution rules.\n\nIt asks the tools for the evidence.\n\nOne thing I underestimated was API usage.\n\nEvery SERP check costs credits.\n\nIf I have 8 keywords and check them every day, that's roughly:\n\n```\n8 × 30 = 240 searches/month\n```\n\nSo the search budget became part of the product design.\n\nInstead of making users calculate everything themselves, InsightTrack can work out a collection schedule based on their available credits.\n\nThat was a good reminder that API limits aren't just infrastructure problems. They can affect the product itself.\n\nI want to make the search history more useful over longer periods, improve competitor tracking, and expand AI Overview monitoring.\n\nBecause search is changing.\n\nA page can keep the same traditional ranking while the actual search experience around it changes dramatically.\n\nThat's the gap I'm trying to explore with InsightTrack.\n\n**Analytics tells you what changed.**\n\n**SerpApi tells you what changed in search.**\n\n**InsightTrack connects the two.**\n\nBuilt for the **SerpApi India Hackathon**.\n\n🔗 **insightstrack.dev**\n\nGitHub: **github.com/NishikantaRay/InsightTrack**\n\n**Built with:** SerpApi · PostgreSQL · DuckDB · Node.js · React · MCP · Gemini API", "url": "https://wpnews.pro/news/building-insighttrack-with-serpapi-for-the-serpapi-india-hackathon", "canonical_source": "https://dev.to/nishikantaray/building-insighttrack-with-serpapi-for-the-serpapi-india-hackathon-5o6", "published_at": "2026-10-03 15:35:40+00:00", "updated_at": "2026-10-03 15:38:05.544670+00:00", "lang": "en", "topics": ["ai-agents", "agent-protocols", "ai-search", "developer-tools", "ai-tools"], "entities": ["InsightTrack", "SerpApi", "SerpApi India Hackathon", "Gemini API", "MCP"], "also_reported_by": [], "alternates": {"html": "https://wpnews.pro/news/building-insighttrack-with-serpapi-for-the-serpapi-india-hackathon", "markdown": "https://wpnews.pro/news/building-insighttrack-with-serpapi-for-the-serpapi-india-hackathon.md", "text": "https://wpnews.pro/news/building-insighttrack-with-serpapi-for-the-serpapi-india-hackathon.txt", "jsonld": "https://wpnews.pro/news/building-insighttrack-with-serpapi-for-the-serpapi-india-hackathon.jsonld"}}