Skip to main content
Glama

WordPress: Install tracking

wp_install_tracking
DestructiveIdempotent

Install or remove tracking and verification on a client's WordPress site, by ID. Accepts a GA4 measurement ID (G-…), a Tag Manager container (GTM-…), a Google Ads tag (AW-…), a Search Console verification token (the meta tag from site_verification_token, or its content value), one Google Ads conversion (label + the page path it fires on, e.g. /thank-you/), and CALL TRACKING: phone_clicks=on fires a GA4 phone_click event on every tel: tap (plus an Ads conversion via phone_click_label), and call_conversion_label + phone_number installs Google's website-call number swap. The plugin builds every tag itself — this tool takes IDs ONLY and cannot install arbitrary HTML or script, by design. Send an empty string to remove an ID. Checks the live home page for tags already present so nothing is double-installed. Needs an Administrator connection and Bridge 1.2.1+. Previews (showing the exact tags) unless confirm is true.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
siteYes
ads_idNoe.g. AW-123456789 (from ads_create_conversion_action's tag); "" removes it
ga4_idNoe.g. G-ABCD123456; "" removes it
gtm_idNoe.g. GTM-ABC1234; "" removes it
confirmNo
phone_clicksNo"on" fires a GA4 phone_click event whenever a tel: link is tapped (needs ga4_id or ads_id)
phone_numberNoThe client's lead phone number as shown on the site, e.g. +1 (425) 555-0100 — used for the website-call number swap
conversion_pathNoPage the conversion fires on, e.g. /thank-you/
conversion_labelNoGoogle Ads conversion label — needs ads_id and conversion_path
gsc_verificationNoThe meta tag from site_verification_token, or its content value; "" removes it
phone_click_labelNoAds conversion label to ALSO fire on a tel: tap — from ads_create_conversion_action type WEBPAGE (a click) or AD_CALL; needs ads_id
call_conversion_labelNoAds WEBSITE_CALL conversion label — Google swaps a tracking number in for ad visitors; needs ads_id and phone_number

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Annotations already flag destructive=true, idempotent=true, openWorld=true, but the description adds substantial behavioral context beyond them: previews the exact tags unless confirm is true, checks the live home page to avoid double-install, uses empty string to remove an ID, requires Administrator + Bridge 1.2.1+, and cannot install arbitrary HTML/script by design. This is exactly the disclosure a mutation tool needs.

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

Conciseness4/5

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

The purpose is front-loaded and every sentence carries information about behavior or prerequisites, with no filler. However, it is a single dense paragraph packing GA4, GTM, Ads, GSC, call tracking, and preview semantics into one block, which slightly hurts scannability for a 12-parameter tool.

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?

For a 12-parameter, no-output-schema, destructive mutation tool, the description covers preview/confirm, removal, prerequisites, double-install avoidance, and call-tracking behavior. It does not describe the response format much beyond noting the preview, but nothing essential for correct invocation is missing.

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

Parameters4/5

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

Schema coverage is 83%, so the schema already documents most parameters, giving a baseline of 3. The description adds real meaning on top: it explains that phone_clicks fires a GA4 phone_click event on tel: taps, that call_conversion_label + phone_number installs Google's number swap, and that conversion_label pairs with a page path. Some parameter interactions remain only in the schema, keeping this at 4.

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?

States a specific verb pair (install/remove) plus the resource (tracking and verification) and the scope (a client's WordPress site, by ID). An agent can distinguish this from wp_tracking_status or site_verify without opening any schema, since the description also names the artifact types it handles (GA4, GTM, Ads, GSC).

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

Usage Guidelines4/5

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

It gives clear operational context: needs an Administrator connection and Bridge 1.2.1+, and it previews unless confirm is true. It also sources its inputs from siblings (ads_create_conversion_action, site_verification_token), which helps routing. It stops short of explicitly naming an alternative tool for checking existing state, so it is a 4 rather than a 5.

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.