Skip to main content
Glama
Samarth GTM MCP Server

Samarth GTM MCP Server

Official

plan_server_migration_from_web

Lists every tag in a web container that can move to a server container and plans each port: which server tool builds it, public IDs to reuse, and secrets still needed. Creates nothing.

Instructions

READ-ONLY: given a WEB container, list every tag that can move to a SERVER container and the plan to port each: which server tool builds it (the create_*_capi_server_tag / create_server_tag tools here), the public ids read off the web tag (derived - Pixel IDs from template params or the fbq/ttq/pintrk/rdt/snaptr/uet/twq init calls, which pre-fill the server tag where the web id IS the server field; the Pinterest Tag ID and LinkedIn Partner ID are informational only, the server tag needs a different id listed in requires), and the secrets you must still ask the user for (requires - CAPI access tokens are never in a web container). Creates NOTHING. GA4 is reported once in ga4 (port it with create_server_tag platform "ga4" as the relay, or the setup_server_side_container prompt; a {{Constant}} Measurement ID is resolved to its value, a Lookup/RegEx Table to its G- outputs (one holding only AW-/GT- ids is a Google Ads tag, not GA4), any other {{variable}} id is listed in ga4.unresolvedRefs - ask the user for the G- id, or confirm it is a Google Ads (AW-) tag and not GA4); Google Ads conversion (awct) / remarketing (sp) -> create_server_tag; Meta/TikTok/LinkedIn/Pinterest/Reddit/Snapchat/Microsoft/Amazon/StackAdapt/X/Quora/AdRoll/Nextdoor/Yelp/Spotify/LINE Yahoo/RTB House pixels -> their typed tool (native Microsoft UET baut and LinkedIn Insight bzi tags are recognised by type); analytics (Mixpanel, Matomo, Piwik PRO, Piano, Plausible, Umami, Pirsch, Snowplow, Klaviyo) and affiliate networks (Awin, CJ, Impact, Rakuten, ShareASale, Tradedoubler, Webgains, Admitad, Adtraction, Affiliate Future, Effinity, Refersion, Tapfiliate, Everflow, Voluum) -> GENERIC items (status "generic"): templates_import_from_gallery the named stape-io repo, then tags_create with the template fields listed in requires (secrets) + derived (public ids read off the web snippet); Floodlight (flc) -> generic import path; Google Ads call conversion has no sGTM equivalent; Conversion Linker (gclidw) needs no server tag. Returns { ga4, items[], summary, truncated }.

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

Input Schema

NameRequiredDescriptionDefault
accountIdYesGTM account ID.
containerIdYesThe SERVER container ID (for the plan tool: the WEB container).
workspaceIdYesWorkspace ID.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.497.5

TDQS

A4.5/5.0
Behavior5/5

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

No annotations are supplied, so the description carries the full burden and does: it declares READ-ONLY and 'Creates NOTHING', explains that CAPI secrets must still be requested from the user, documents the `derived` vs `requires` semantics, and describes the return shape { ga4, items[], summary, truncated } including the truncated flag and the ga4.unresolvedRefs edge case.

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

Conciseness3/5

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

The purpose is front-loaded, but the body is one very long run-on paragraph with deeply nested parentheticals (the GA4 clause alone spans several sentences inside parentheses). The content mostly earns its place, but a bulleted mapping of tag type -> destination tool would be far easier to parse.

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

Completeness5/5

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

There is no output schema, and the description compensates by enumerating the returned fields and their meaning, plus the resolution rules for {{Constant}}, Lookup/RegEx Table, and unresolved variable references. For a complex planning tool this leaves nothing an agent needs missing.

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% and all three IDs are documented in-schema, including the note that containerId is the WEB container for this tool. The description reinforces 'given a WEB container' but adds no syntax or format detail beyond the schema, so the baseline 3 applies.

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?

Opens with a specific verb+resource+scope: 'given a WEB container, list every tag that can move to a SERVER container and the plan to port each'. It immediately distinguishes itself from the create_* siblings with 'Creates NOTHING', so an agent can tell this is an analysis/planning tool rather than a mutation tool.

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?

Provides an explicit routing table: GA4 goes through `ga4` (create_server_tag platform "ga4" or the setup_server_side_container prompt), awct/sp go to create_server_tag, named pixels go to their typed create_*_capi_server_tag tools, analytics/affiliate networks take the generic templates_import_from_gallery + tags_create path, and several tag types (Google Ads call conversion, Conversion Linker) need no server tag at all. It also states what must be asked of the user (CAPI access tokens never live in a web container).

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