get_topic_metrics
Retrieve aggregate metrics for a Sprout Listening Topic over a date range, with optional breakdowns by sentiment, network, day, or location, returned in a single response.
Instructions
Get aggregate metrics for a Sprout Listening Topic over a date range, optionally broken down by dimensions. Returns everything in one response.
Examples: Volume by day: metrics=["messages_count"], dimensions=["created_time.by(day)"] Sentiment split: metrics=["messages_count"], dimensions=["sentiment"] Volume by network: metrics=["messages_count", "engagements"], dimensions=["network"]
Args: topic_id: Topic ID from list_listening_topics. start_date: Start date in YYYY-MM-DD format. end_date: End date in YYYY-MM-DD format (inclusive). metrics: Metrics to aggregate: messages_count, engagements, likes, replies, shares_count, quote_count, reshare_count, repost_count, impressions, authors_count, from.followers_count, positive_sentiments_count, neutral_sentiments_count, negative_sentiments_count. dimensions: Optional breakdowns: created_time.by(day), created_time.by(month), visual_media.media_type, distribution_type, network, sentiment, language, explicit_label, location.city, location.province, location.country. networks: Networks to include. Defaults to all listening networks. X/TWITTER is not available via the API and is dropped with a note. text_match: Text search; supports OR and quoted phrases. sentiment: Filter by sentiment: positive, negative, neutral, unclassified. public_only: If true, exclude the account's own connected profiles. Default false. filters: Extra raw Sprout filter strings appended as-is. timezone: IANA timezone for date filters and day/month buckets. Defaults to SPROUT_DEFAULT_TIMEZONE (America/Los_Angeles).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"topic_id": "<topic_id>",
"start_date": "<start_date>",
"end_date": "<end_date>",
"metrics": "<metrics>"
},
"name": "get_topic_metrics"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| filters | No | ||
| metrics | Yes | ||
| end_date | Yes | ||
| networks | No | ||
| timezone | No | ||
| topic_id | Yes | ||
| sentiment | No | ||
| dimensions | No | ||
| start_date | Yes | ||
| text_match | No | ||
| public_only | No |