modus_get_sales_insights
Analyze sales performance across 30 categories including revenue gaps, attrition risk, and pipeline coverage with AI-powered insights and confidence scores.
Instructions
Get AI-powered sales insights across 30+ categories including revenue gaps, attrition risk, territory performance, pipeline coverage, and competitive analysis. Returns detailed insights with recommendations and confidence scores.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "modus_get_sales_insights"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| categories | No | Comma-separated list of categories (e.g., 'REVENUE_GAP,ATTRITION_RISK,TERRITORY_PERFORMANCE'). Available: REVENUE_GAP, HEADCOUNT_PLANNING, CAPACITY_UTILIZATION, ATTRITION_RISK, ATTRITION_BACKFILLS, PIPELINE_COVERAGE, WIN_RATE_SHIFTS, SALES_CYCLE_BOTTLENECK, TERRITORY_PERFORMANCE, TERRITORY_DESIGN, TERRITORY_LOAD_MGMT, MARKET_EXPANSION, COMPETITIVE_ANALYSIS, SKILLS_GAP, and 20+ more. | |
| timeframe | No | JSON timeframe (e.g., '{"months": 12}') | |
| includeRecommendations | No | Include AI recommendations in results | |
| limit | No | Maximum number of insights to return (max: 100) | |
| skipCache | No | Force fresh generation (slower but current). Default: false (uses cached data) |
Implementation Reference
- modus-mcp-server.js:728-766 (handler)Handler case for modus_get_sales_insights tool. Parses arguments (categories, timeframe, includeRecommendations, limit, skipCache), calls the Modus API at /api/sales-insights with query parameters, then processes and returns the insights with summary statistics (total count, severity breakdown, category grouping, average confidence, top recommendations).
case "modus_get_sales_insights": { const { categories, timeframe, includeRecommendations = true, limit = 50, skipCache = false } = args || {}; const params = new URLSearchParams(); if (categories) params.append("categories", categories); if (timeframe) params.append("timeframe", timeframe); if (includeRecommendations !== undefined) params.append("includeRecommendations", includeRecommendations.toString()); if (limit) params.append("limit", limit.toString()); if (skipCache) params.append("skipCache", skipCache.toString()); response = await modusApi.get(`/api/sales-insights?${params.toString()}`); const insights = response.data?.insights || []; // Add summary statistics const summary = { totalInsights: insights.length, bySeverity: countBySeverity(insights), byCategory: groupByCategory(insights), averageConfidence: insights.reduce((sum, i) => sum + (i.confidence || 0), 0) / insights.length || 0, topRecommendations: getTopRecommendations(insights, 3), }; return { content: [ { type: "text", text: JSON.stringify( { summary, insights, note: insights.length >= limit ? `Showing first ${limit} insights` : null, }, null, 2 ), }, ], }; }