Skip to main content
Glama
ZLeventer

google-ads-mcp

gads_campaign_assets

Retrieve campaign-linked assets with field type and status to identify active extensions on specific campaigns.

Instructions

Assets linked to campaigns with field type and status. Shows which extensions are active on which campaigns.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
customer_idNoOverride GOOGLE_ADS_CUSTOMER_ID for this call
campaign_idNoFilter to a specific campaign ID

Implementation Reference

  • src/index.ts:158-163 (registration)
    Registration of the 'gads_campaign_assets' tool with server.tool(), linking the name, description, schema, and handler.
    server.tool(
      "gads_campaign_assets",
      "Assets linked to campaigns with field type and status. Shows which extensions are active on which campaigns.",
      campaignAssetsSchema,
      async (args) => { try { return ok(await campaignAssets(args)); } catch (e) { return err(e); } }
    );
  • Input schema for campaign_assets: optional customer_id and campaign_id filters.
    export const campaignAssetsSchema = {
      customer_id: z.string().optional().describe("Override GOOGLE_ADS_CUSTOMER_ID for this call"),
      campaign_id: z.string().optional().describe("Filter to a specific campaign ID"),
    };
  • Handler function 'campaignAssets' that queries campaign_asset data joined with campaign and asset info, filtered by campaign_id, returning status and field_type.
    export async function campaignAssets(args: z.infer<z.ZodObject<typeof campaignAssetsSchema>>) {
      const customer = getCustomer(args.customer_id);
      const campaignClause = args.campaign_id ? `AND campaign.id = ${args.campaign_id}` : "";
      const rows = await customer.query(`
        SELECT
          campaign.id,
          campaign.name,
          asset.id,
          asset.name,
          asset.type,
          asset.sitelink_asset.link_text,
          asset.callout_asset.callout_text,
          asset.structured_snippet_asset.header,
          campaign_asset.status,
          campaign_asset.field_type
        FROM campaign_asset
        WHERE campaign_asset.status != 'REMOVED'
          ${campaignClause}
        ORDER BY campaign.name
        LIMIT 500
      `);
      return { rowCount: rows.length, rows };
    }
  • Import of getCustomer helper used to obtain the Google Ads client.
    import { getCustomer } from "../client.js";
Behavior3/5

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

No annotations are provided, so the description carries the full burden. It accurately describes the tool's output (assets with field type and status, extensions) but does not disclose any behavioral traits such as authentication requirements, rate limits, or potential side effects. For a read-only listing, the description is adequate but not exhaustive.

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 extremely concise, consisting of only two sentences. The first sentence states the main purpose, and the second adds a clarifying detail about extensions. Every word contributes value with no redundancy or fluff.

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?

Given the tool's simplicity (listing assets linked to campaigns) and the absence of an output schema, the description covers the key return aspects: field type, status, and extension associations. It is nearly complete for an agent to understand what to expect, though it could mention that it returns campaign IDs or asset details explicitly.

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 parameters are already documented in the input schema. The description does not add new meaning about the parameters (customer_id, campaign_id) beyond what the schema provides, meeting the baseline expectation. It focuses on output fields instead, which is helpful but not directly relevant to parameter semantics.

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 clearly states the tool shows assets linked to campaigns with field type and status, and specifies it reveals which extensions are active. This provides a specific verb-resource mapping and distinguishes it from sibling tools like gads_list_assets (which lists assets without campaign context) and gads_campaign_performance (which focuses on performance metrics).

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 description implies use cases (e.g., viewing extensions on campaigns) but does not explicitly state when to use this tool versus alternatives like gads_list_assets or gads_campaign_performance. It lacks direct guidance on exclusions or when-not-to-use, leaving the agent to infer from context.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ZLeventer/google-ads-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server