ga4_report
Run read-only GA4 reports on any dimension or metric, such as top pages, channels, or countries, for one property or all accessible properties. Set custom date ranges and limits to analyze traffic data.
Instructions
Run a GA4 report (read-only). Defaults to top pages by views for the last 7 days ending yesterday. Accepts any GA4 Data API dimension and metric names, e.g. sessionDefaultChannelGroup, country, activeUsers. Covers one property, or every property the account can access when propertyId is 'all' or omitted.
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": "ga4_report"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Rows per property. Default 25. | |
| endDate | No | YYYY-MM-DD or relative. Default: yesterday. | |
| metrics | No | Default: screenPageViews, sessions, engagementRate, averageSessionDuration. | |
| startDate | No | YYYY-MM-DD or relative like 7daysAgo, yesterday, today. Default: 7daysAgo. | |
| dimensions | No | Default: ['pagePath']. | |
| propertyId | No | One numeric GA4 property ID, or 'all' for every accessible property. Default: GA4_PROPERTY_ID from .env if set, otherwise all. | |
| orderByMetric | No | Metric to sort by, descending. Default: the first metric. |