Get historical trend data for a specific metric over time.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
brandId |
string | Yes | The brand ID (UUID) or brand name (e.g., "Ace Auto Repair") |
metricName |
string | Yes | The name of the metric to track (e.g., "visibilityScore", "mentionCount") |
days |
number | No | Number of days of history to retrieve (default: 30) |
Example Request
curl -X POST https://socialcrm.com/api/mcp-app \
-H "Authorization: Bearer sk_live_YOUR_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"jsonrpc": "2.0",
"id": "1",
"method": "tools/call",
"params": {
"name": "get_metric_trend",
"arguments": {
"brandId": "brand_abc123",
"metricName": "visibilityScore",
"days": 14
}
}
}'Example Response
Parsed from result.content[0].text:
[
{ "date": "2026-02-04", "value": 55 },
{ "date": "2026-02-07", "value": 58 },
{ "date": "2026-02-10", "value": 62 },
{ "date": "2026-02-14", "value": 68 },
{ "date": "2026-02-17", "value": 72 }
]Output Schema
Returns an array of data points:
| Field | Type | Description |
|---|---|---|
date |
string | Date in YYYY-MM-DD format |
value |
number | Metric value on that date |
Notes
- Data points are extracted from completed agent runs. Not every day will have a data point — only dates where the metric was recorded.
- Common metric names include
visibilityScore,mentionCount,sentimentScore, andaccuracyScore. - If no data is available for the specified metric and time range, an empty array is returned.