Skip to main content
Glama
Samarth GTM MCP Server

Samarth GTM MCP Server

Official

gtm_type_reference

Look up exact GTM tag, trigger, and variable type codes and their interface names before creating resources, or identify codes seen in a container and search gallery templates by vendor.

Instructions

The catalogue of GTM TYPE CODES: tag types, trigger types and user-defined variable types, each with the exact string the API expects and the name it carries in the GTM interface. Call this to ANSWER a question about what types exist ("which tag types do you support?", "what triggers can you make?", "can you add Hotjar?"), and to look up the right code BEFORE calling tags_create, triggers_create or variables_create. Read-only, no API call, no container needed. Note that Google publishes an enum for TRIGGER types but not for tag or variable types, so those codes are recorded here rather than discoverable from the API. For built-in variables use built_in_variables_list, which carries the full published enum. For a specific gallery template that is already installed, templates_list returns its exact tagType, which is always more reliable than this list.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "gtm_type_reference"
  }
}

Input Schema

NameRequiredDescriptionDefault
kindNoNarrow the answer to one kind. Defaults to "all".
searchNoLook a Community Gallery template up by product or vendor name, e.g. "hotjar", "clarity", "klaviyo". Returns the template name and its GitHub OWNER, which is the half of an import that cannot be guessed. Use this to answer "can you add X?".
identifyNoName a tag type code seen in a container, e.g. "baut", "gclidw", "cvt_MRQN8". Use this when AUDITING a container to say what a tag actually is. Returns the human name, or says plainly that the code is unrecognised instead of guessing a vendor.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.497.5

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and it does state read-only, no API call and no container needed. It also discloses a real limitation — Google publishes an enum for trigger types but not tag or variable types — and that identify reports an unrecognised code rather than guessing a vendor. It stops short of describing the overall response shape (nothing exists for a 'kind=all' call), which keeps it off a 5.

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?

Front-loads what the catalogue is, then the usage rule, then the caveat and routings — reasonable ordering with no filler. It is dense but long, and the closing routing sentences could be tightened.

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 read-only lookup with no output schema it covers purpose, entry points, limitations and return hints per parameter ('returns the template name and its GitHub OWNER', 'returns the human name'). It does not say whether kind can be combined with search or identify, which is the main remaining ambiguity for a three-mode 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 description coverage is 100%, so the per-parameter schema already explains kind, search and identify in nearly the same words used here. The description's extra value beyond the schema is small: it frames search as answering 'can you add X?' and identify as an audit aid, but adds no syntax or combination rules.

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 resource (a catalogue of GTM type codes: tag, trigger and user-defined variable types) with its scope, the exact string codes and the human names they carry. It names the siblings it is not — built_in_variables_list and templates_list — so an agent can route between them without opening a schema.

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

Usage Guidelines5/5

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

Gives explicit when-to-use: answering 'what types exist', adding Hotjar, and looking up a code BEFORE tags_create/triggers_create/variables_create. It also gives explicit when-not-to-use plus the alternative for each case, built_in_variables_list for built-in variables and templates_list for an installed gallery template.

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

Deploy Server

Other Tools