GA4 custom dimensions & metrics
list_ga4_custom_dimensionsUse this when the user asks which custom parameters a site's GA4 property tracks. Lists the custom dimensions and custom metrics REGISTERED on the GA4 property linked to a site (GA4 Admin > Custom definitions): the event parameters and user properties that property collects on top of the standard GA4 fields, such as a source_format or target_path sent with an internal_link_click event. Dimensions come before metrics, queryable ones first, each group by displayName. Not for the traffic numbers: use query_ga4_custom_dimensions. Each entry carries the exact apiName (e.g. customEvent:source_format) that query_ga4_custom_dimensions takes. Call this FIRST: an event parameter that is not registered cannot be reported on at all, and GA4 answers an unregistered name with an empty report rather than an error, so a name must never be guessed. Returns a notConfigured result (not an error) when Google Analytics is not connected or no GA4 property is linked to the site in the GSC Wizard app.
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": {
"siteUrl": "<siteUrl>"
},
"name": "list_ga4_custom_dimensions"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| siteUrl | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| hint | No | ||
| note | No | ||
| count | No | ||
| reason | No | ||
| thenBy | No | ||
| account | No | ||
| listKey | No | Name of the top-level field that holds the rows sortedBy describes. | |
| siteUrl | No | ||
| nextStep | No | ||
| ordering | No | ||
| sortedBy | No | ||
| sortOrder | No | ||
| thenOrder | No | ||
| dataSource | No | ||
| propertyId | No | ||
| definitions | No | ||
| metricNames | No | ||
| emptyBecause | No | ||
| methodLimits | No | ||
| notConfigured | No | ||
| dimensionNames | No | ||
| reauthRequired | No |