aisearchindex-mcp
v1.0.0
Published
MCP server for querying AI Search Index analytics data
Downloads
17
Maintainers
Readme
AI Search Index MCP Server
A Model Context Protocol (MCP) server that allows AI assistants like Claude, ChatGPT, and others to query your AI Search Index analytics data directly.
Features
- List Websites: View all tracked websites in your account
- Get Analytics: Comprehensive analytics including bot vs human traffic
- Bot Breakdown: Detailed breakdown of which AI bots are crawling your site
- Daily Trends: Traffic trends over time with visual graphs
- Quick Summary: Fast overview of traffic metrics
Prerequisites
- Node.js 18 or higher
- An AI Search Index account with an API key
- A MCP-compatible client (Claude Desktop, Cursor, etc.)
Getting Your API Key
- Log in to AI Search Index
- Go to API Keys in the sidebar
- Click Create API Key
- Copy the generated key (starts with
sk_live_)
⚠️ Important: Save your API key securely. It's only shown once!
Installation
Option 1: Install from npm (Recommended)
npm install -g aisearchindex-mcpOption 2: Install from source
git clone https://github.com/aisearchindex/ai-search-index
cd ai-search-index/packages/aisearchindex-mcp
npm install
npm run buildConfiguration
Claude Desktop
Add to your Claude Desktop configuration file:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"aisearchindex": {
"command": "npx",
"args": ["-y", "aisearchindex-mcp"],
"env": {
"AISEARCHINDEX_API_KEY": "sk_live_your_api_key_here"
}
}
}
}Cursor
Add to your Cursor MCP settings (Settings → Features → MCP Servers):
{
"mcpServers": {
"aisearchindex": {
"command": "npx",
"args": ["-y", "aisearchindex-mcp"],
"env": {
"AISEARCHINDEX_API_KEY": "sk_live_your_api_key_here"
}
}
}
}VS Code with Continue
Add to your Continue configuration (~/.continue/config.json):
{
"mcpServers": {
"aisearchindex": {
"command": "npx",
"args": ["-y", "aisearchindex-mcp"],
"env": {
"AISEARCHINDEX_API_KEY": "sk_live_your_api_key_here"
}
}
}
}Using Local Installation
If you installed from source or locally, use the full path:
{
"mcpServers": {
"aisearchindex": {
"command": "node",
"args": ["/path/to/aisearchindex-mcp/dist/index.js"],
"env": {
"AISEARCHINDEX_API_KEY": "sk_live_your_api_key_here"
}
}
}
}Available Tools
Once configured, you can ask your AI assistant to use these tools:
list_websites
Lists all websites tracked in your AI Search Index account.
Example prompts:
- "Show me my tracked websites"
- "What websites am I tracking?"
get_analytics
Gets comprehensive analytics for a specific website.
Parameters:
website_id(required): The website UUIDstart_date(optional): Start date (YYYY-MM-DD)end_date(optional): End date (YYYY-MM-DD)
Example prompts:
- "Get analytics for my website"
- "Show me traffic data for the last 7 days"
get_bot_breakdown
Shows which bots are crawling your site, categorized by type (AI crawlers, search engines, etc.).
Parameters:
website_id(required): The website UUIDstart_date(optional): Start date (YYYY-MM-DD)end_date(optional): End date (YYYY-MM-DD)
Example prompts:
- "Which AI bots are crawling my site?"
- "Show me the bot breakdown for my website"
get_daily_trends
Displays daily traffic trends with visual representation.
Parameters:
website_id(required): The website UUIDstart_date(optional): Start date (YYYY-MM-DD)end_date(optional): End date (YYYY-MM-DD)
Example prompts:
- "Show me daily traffic trends"
- "How has my bot traffic changed over time?"
get_summary
Quick overview of traffic metrics.
Parameters:
website_id(required): The website UUIDstart_date(optional): Start date (YYYY-MM-DD)end_date(optional): End date (YYYY-MM-DD)
Example prompts:
- "Give me a quick summary of my traffic"
- "How many bot visits did I get this month?"
Example Conversation
Here's an example of how you might interact with the MCP server through Claude:
You: What websites am I tracking with AI Search Index?
Claude: Let me check your tracked websites.
📊 example.com ID: 550e8400-e29b-41d4-a716-446655440000 URL: https://example.com Tracking ID: tid_abc123 Created: 12/15/2024
You: Which AI bots are crawling example.com?
Claude: Let me get the bot breakdown for your website.
🤖 Bot Breakdown (2024-11-24 to 2024-12-24) ──────────────────────────────────────────────────
Total Bot Visits: 15,432
🧠 AI Crawlers: GPTBot: 5,234 visits (33.9%) ClaudeBot: 3,122 visits (20.2%) PerplexityBot: 2,456 visits (15.9%)
🔍 Search Engine Bots: Googlebot: 2,890 visits (18.7%) Bingbot: 1,234 visits (8.0%)
Troubleshooting
"AISEARCHINDEX_API_KEY environment variable is required"
Make sure your API key is properly set in your MCP client configuration. The key should start with sk_live_.
"Invalid API key"
- Verify your API key is correct (no extra spaces)
- Check that the key hasn't expired
- Make sure you're using an API key, not a Bot Tracking Key
"Website not found"
The website_id must be a valid UUID for a website you own. Use list_websites first to get the correct ID.
Connection Issues
If the MCP server isn't connecting:
- Restart your MCP client (Claude Desktop, Cursor, etc.)
- Check that Node.js 18+ is installed:
node --version - Verify the configuration file syntax is valid JSON
- Check logs for error messages
Testing the Server Manually
You can test the MCP server directly:
export AISEARCHINDEX_API_KEY=sk_live_your_key_here
npx aisearchindex-mcpIf installed from source:
cd packages/aisearchindex-mcp
npm run build
AISEARCHINDEX_API_KEY=sk_live_your_key_here node dist/index.jsEnvironment Variables
| Variable | Required | Default | Description |
|----------|----------|---------|-------------|
| AISEARCHINDEX_API_KEY | Yes | - | Your API key from AI Search Index |
| AISEARCHINDEX_API_URL | No | https://aisearchindex.com | API base URL (for self-hosted) |
Security Notes
- Never commit your API key to version control
- Use environment variables or secure secret management
- API keys have read access to your analytics data
- Rotate keys periodically for security
Support
- Documentation: aisearchindex.com/docs
- FAQ: aisearchindex.com/faq
- Contact: aisearchindex.com/contact
License
MIT License - see LICENSE for details.
