get_ad_stats
Retrieves time-series statistics for a Telegram ad over a Unix-second time range, with selectable 5-minute or daily intervals.
Instructions
Get one ad's statistics for [from_time, to_time), in Unix seconds.
Returns a time series in intervals of 300 or 86400 seconds. The API rounds bounds to interval starts; at most 1000 intervals are allowed. The ad ID is scoped to the selected account.
Omitted account_id uses TELEGRAM_ADS_ACCOUNT_ID if set, otherwise the token owner's account.
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": {
"ad_id": "<ad_id>",
"from_time": "<from_time>",
"to_time": "<to_time>"
},
"name": "get_ad_stats"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ad_id | Yes | ||
| to_time | Yes | ||
| interval | No | ||
| from_time | Yes | ||
| account_id | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||