Skip to main content
Glama
localseodata

Local SEO Data

Official

competitor_ads

Read-only

Uncover competitor Google Ads campaigns. Get ad copy, keywords, and landing pages to refine your own ad strategy.

Instructions

Find Google Ads campaigns from a competitor domain. Returns ad copy, keywords, and landing pages. Costs 2 credits.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
domainYesCompetitor domain (e.g. "competitor.com")
locationNoGeographic location filter
formatNoAd format filter
limitNoMax ads. Default: 20, max: 100

Implementation Reference

  • The function registerCompetitiveTools registers multiple competitive tools on the McpServer, including 'competitor_ads' (line 13).
    export function registerCompetitiveTools(server: McpServer, getAuth: () => string) {
      server.tool(
        "competitor_ads",
        "Find Google Ads campaigns from a competitor domain. Returns ad copy, keywords, and landing pages. Costs 2 credits.",
        {
          domain: z.string().min(1).describe('Competitor domain (e.g. "competitor.com")'),
          location: z.string().optional().describe("Geographic location filter"),
          format: z.enum(["text", "image", "video"]).optional().describe("Ad format filter"),
          limit: z.number().int().min(1).max(100).optional().describe("Max ads. Default: 20, max: 100"),
        },
        READ_ONLY,
        withErrorHandling(async ({ domain, location, format, limit }) => {
          const result = await callApi(
            "/v1/ads/competitor",
            {
              domain,
              ...(location && { location }),
              ...(format && { format }),
              ...(limit && { limit }),
            },
            getAuth()
          );
          return { content: [{ type: "text" as const, text: formatResult(result.data, result) }] };
        })
      );
    
      server.tool(
        "brand_mentions",
        "Find online mentions of a brand across the web. Returns mention sources, sentiment, and context. Costs 3 credits.",
        {
          business_name: z.string().min(1).describe("Business or brand name to search for"),
          limit: z.number().int().min(1).max(100).optional().describe("Max mentions. Default: 20, max: 100"),
        },
        READ_ONLY,
        withErrorHandling(async ({ business_name, limit }) => {
          const result = await callApi(
            "/v1/brand/mentions",
            { business_name, ...(limit && { limit }) },
            getAuth()
          );
          return { content: [{ type: "text" as const, text: formatResult(result.data, result) }] };
        })
      );
    }
  • The 'competitor_ads' tool handler: accepts domain (required), location, format, limit params; calls POST /v1/ads/competitor with those params via callApi helper; returns text content with formatted API result.
    server.tool(
      "competitor_ads",
      "Find Google Ads campaigns from a competitor domain. Returns ad copy, keywords, and landing pages. Costs 2 credits.",
      {
        domain: z.string().min(1).describe('Competitor domain (e.g. "competitor.com")'),
        location: z.string().optional().describe("Geographic location filter"),
        format: z.enum(["text", "image", "video"]).optional().describe("Ad format filter"),
        limit: z.number().int().min(1).max(100).optional().describe("Max ads. Default: 20, max: 100"),
      },
      READ_ONLY,
      withErrorHandling(async ({ domain, location, format, limit }) => {
        const result = await callApi(
          "/v1/ads/competitor",
          {
            domain,
            ...(location && { location }),
            ...(format && { format }),
            ...(limit && { limit }),
          },
          getAuth()
        );
        return { content: [{ type: "text" as const, text: formatResult(result.data, result) }] };
      })
    );
  • The input schema for 'competitor_ads' defines domain (string), location (optional string), format (optional enum: text/image/video), and limit (optional int 1-100).
    {
      domain: z.string().min(1).describe('Competitor domain (e.g. "competitor.com")'),
      location: z.string().optional().describe("Geographic location filter"),
      format: z.enum(["text", "image", "video"]).optional().describe("Ad format filter"),
      limit: z.number().int().min(1).max(100).optional().describe("Max ads. Default: 20, max: 100"),
    },
  • src/server.ts:14-14 (registration)
    The 'registerCompetitiveTools' function is imported from ./tools/competitive.js.
    import { registerCompetitiveTools } from "./tools/competitive.js";
  • src/server.ts:46-46 (registration)
    registerCompetitiveTools is called in createMcpServer with the server instance and auth getter.
    registerCompetitiveTools(server, getAuth);
Behavior4/5

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

Annotations already indicate readOnlyHint=true and destructiveHint=false. The description adds the cost of 2 credits, a behavioral detail not in annotations. No contradictions.

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?

Two sentences with no wasted words. The first sentence clearly states the purpose, the second adds return types and cost. Front-loaded and efficient.

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?

The description covers purpose, returns, and cost. No output schema exists, but the description fills the gap with expected returns. Lacks pagination or error handling, but acceptable for a simple tool.

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 each parameter is already documented via the schema. The description adds no extra meaning beyond what the schema provides, resulting in a baseline score.

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 ('Find') and resource ('Google Ads campaigns from a competitor domain'), and lists what it returns ('ad copy, keywords, and landing pages'). It clearly differentiates from siblings like organic_serp or backlink_gap.

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?

No explicit when-to-use or when-not-to-use guidance. The description implies use for competitor ad research, but does not mention alternatives or exclusions. The cost mention provides a minor usage hint.

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/localseodata/mcp-server'

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