Get Resource Metadata
get_resource_metadataDiscover which fields, metrics, and segments can be selected, filtered, or sorted for a Google Ads resource before building search queries, so you avoid guessing invalid fields.
Instructions
Retrieves the selectable, filterable, and sortable fields for a specific Google Ads resource, including compatible metrics and segments.
Use this tool to find out which fields you can select, filter by, or
sort by when querying a specific resource (e.g., 'campaign',
'ad_group') with the search tool. Metric and segment field names
start with 'metrics.' and 'segments.' respectively.
Do not guess fields — use this tool to discover them before constructing a query. Responses can be cached; they rarely change.
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": {
"resource_name": "<resource_name>"
},
"name": "get_resource_metadata"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| resource_name | Yes | The name of the Google Ads resource (e.g., 'campaign', 'ad_group'). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||