Skip to main content
Glama

Query Google Ads (GAQL)

google_ads_search
Read-only

Runs a read-only Google Ads Query Language (GAQL) query on one Google Ads account and returns the rows as the API gives them (nested objects, metrics in camelCase, money in micros of the account currency). Example: SELECT campaign.name, metrics.clicks, metrics.cost_micros FROM campaign WHERE segments.date DURING LAST_7_DAYS. Invalid queries return Google's explanation in detail. Up to 500 rows. Read-only.

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": {
      "customerId": "<customerId>",
      "query": "<query>"
    },
    "name": "google_ads_search"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMaximum number of rows.
queryYesGAQL query (SELECT ... FROM ... WHERE ...).
customerIdYesGoogle Ads customer id, as returned by google_ads_list_accounts.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. First observed

TDQS

A4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already establish read-only, open-world, and non-destructive behavior. The description adds useful context beyond them: API-shaped rows, camelCase metrics, micros currency, invalid-query error detail, and a 500-row cap, though it does not cover pagination or rate limits.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact and front-loaded: purpose, query language, example, error behavior, and row limit each earn their place without repetition or filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

There is no output schema, so the description appropriately explains return shape, error handling, and row limits. It is nearly complete for calling the tool, though it could mention pagination or alternative specialized tools.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so customerId, query, and limit are already well documented. The description reinforces the single-account scope, GAQL syntax, row cap, and money-in-micros convention, but adds little parameter meaning beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses a specific verb and resource: it runs a read-only GAQL query on one Google Ads account. The included example makes clear this is the arbitrary-query tool rather than a curated reporting or mutation sibling.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The use case is implied by 'Runs a ... GAQL query' and the sample query, but the description does not explicitly say when to choose this over siblings such as google_ads_campaign_performance or google_ads_keyword_ideas, nor does it state exclusions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources