Skip to main content
Glama
gtm-mcp-server

gtm-mcp-server

by KUHL-HQ

gtm_built_in_variable

Create, list, remove, or revert Google Tag Manager built-in variables, with paginated listing for managing workspace variables.

Instructions

Performs all built-in variable operations: create, list, remove, revert. The 'list' action returns up to itemsPerPage items per page.

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": {
      "action": "<action>",
      "accountId": "<accountId>",
      "containerId": "<containerId>",
      "workspaceId": "<workspaceId>"
    },
    "name": "gtm_built_in_variable"
  }
}

Input Schema

NameRequiredDescriptionDefault
pageNoPage number for pagination (starts from 1). Each page contains up to itemsPerPage items.
typeNoThe built-in variable type. Required for 'revert' and 'remove' actions.
typesNoArray of built-in variable types. Optional for 'list' action.
actionYesThe built-in variable operation to perform. Must be one of: 'create', 'list', 'remove', 'revert'.
accountIdYesThe unique ID of the GTM Account containing the built-in variable.
pageTokenNoA token for pagination. Optional for 'list' action.
containerIdYesThe unique ID of the GTM Container containing the built-in variable.
workspaceIdYesThe unique ID of the GTM Workspace containing the built-in variable.
itemsPerPageNoNumber of items to return per page (1-50). Default: 50. Use lower values if experiencing response issues.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.9/5.0
Behavior2/5

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

Without annotations, the description carries full burden but only mentions pagination behavior for the 'list' action. It omits side effects, permissions, reversibility, or constraints for create/remove/revert actions, leaving a significant gap in transparency.

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 are efficient and front-loaded with key actions. No unnecessary words. The structure is clear and earns its place.

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

Completeness2/5

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

Given 9 parameters, 4 required, and no output schema, the description is too minimal. It does not explain return values, required parameter relationships (e.g., type needed for remove/revert), or pagination details beyond a brief mention. Completeness is inadequate.

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 the baseline is 3. The description adds minimal extra meaning beyond the schema (only noting that list returns up to itemsPerPage items). Parameter semantics are adequately covered by the schema.

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

Purpose4/5

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

The description clearly states the tool performs all built-in variable operations (create, list, remove, revert), making the purpose specific and distinct from siblings like gtm_variable. However, it could better differentiate from sibling tools that might also manage variables.

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

Usage Guidelines2/5

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

No guidance is provided on when to use this tool versus alternatives among sibling tools (e.g., gtm_variable). The description lacks context for appropriate usage, leaving the agent to infer applicability.

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