Skip to main content
Glama
Samarth GTM MCP Server

Samarth GTM MCP Server

Official

Samarth Analytics MCP

CI npm License: MIT

An open-source Model Context Protocol (MCP) server that lets AI assistants such as Claude Desktop, Claude Code and Cursor work with Google Tag Manager and GA4. It covers the full GTM API v2 surface (100+ tools, including server-side containers), the GA4 Admin and Data APIs, a built-in implementation audit, and a second server that crawls a website to check its tags and Consent Mode v2 setup. Built by Samarth Analytics for our own client work and released under the MIT license for the analytics community.

Read-only by default. Creating, updating, publishing and deleting are each behind a separate environment flag, every write also requires confirm=true, and a dry-run mode simulates writes without touching the API. See Guardrails.

Use it at your own risk, and start on a dummy container. The server acts with your Google credentials, so every change it makes is yours. Try it first on a sandbox GTM container and a test GA4 property, keep the write flags off until you have watched how it behaves, and review the container's version history after any write session. We run it in production, but your setup is not ours.

Three ways to use it

What you get

Where to start

Hosted, no install

Our community instance at https://mcp.samarthanalytics.com/mcp. Sign in with your own Google account; it only sees your containers and properties, and it is locked to read-only. Shared, best-effort, no uptime promise.

Add it to your MCP client with mcp-remote:{"mcpServers":{"samarth-gtm":{"command":"npx","args":["mcp-remote@next","https://mcp.samarthanalytics.com/mcp"]}}}

Local

The server on your machine over stdio, with your own Google OAuth client, and the write flags under your control.

Quick Start and Google Cloud OAuth Setup

Self-hosted

The MCP server, the web-audit server and the capture worker as one docker-compose stack behind your own token.

docs/SELF_HOSTING_DOCKER.md and Cloud Deployment

The repo also ships Samarth Desktop, a local Electron app with a chat UI that embeds this server (Quick Start), and a browser-based customer portal in apps/portal/ that runs live, read-only QC audits.

Contributions are welcome. Bug reports with a reproducible container setup are the most useful thing you can send. Read CONTRIBUTING.md first; CI runs on every pull request.


Related MCP server: Google Tag Manager MCP

Table of Contents

  1. Features

  2. Quick Start

  3. Google Cloud OAuth Setup

  4. Service Account Limitations

  5. Environment Variables Reference

  6. Guardrails

  7. Available Tools

  8. Cloud Deployment

  9. Security Notes

  10. Development

  11. Releases

  12. Troubleshooting


Features

  • Full GTM API v2 surface — accounts, containers, workspaces, tags, triggers, variables, folders, built-in variables, versions, sync, publish, preview

  • Server-side & advanced GTM coverage — environments, user permissions, destinations, clients, transformations, zones, custom templates, gtag config, plus container snippet/lookup/combine/move-tag-id and workspace change-diff status

  • GA4 coverage — GA4 Admin tools (ga4_*) plus GA4 Data API reporting (ga4_run_report, ga4_run_realtime_report) for intent-vs-reality reconciliation. Reads and reporting need only analytics.readonly; the GA4 Admin write tools are off by default behind GA4_MCP_ENABLE_WRITES / GA4_MCP_ENABLE_DELETES and additionally need analytics.edit

  • Automatic pagination — every paginated list tool transparently follows nextPageToken to return all results, with optional maxPages/pageToken bounds

  • Retry with exponential backoff + jitter — transient Google API failures (HTTP 408/429/5xx, network errors) on read requests are retried automatically; mutations are never auto-retried (tunable via GTM_MCP_RETRY_*)

  • Two transport modes: stdio (local, for Claude Desktop/Cursor) and Streamable HTTP (cloud/team)

  • Guardrails by default: read-only unless explicitly enabled; publish and delete gated separately

  • Dry-run mode: simulate all writes without touching the API

  • confirm=true required on all write/delete/publish operations

  • Audit tool: inspects workspace for common GA4/GTM implementation issues

  • Export tool: full workspace dump as structured JSON

  • Zod schema validation on all inputs

  • Detailed Google API error messages surfaced to the MCP client


Quick Start

The way to run Samarth is the desktop app - a local Electron app with a chat UI that embeds the MCP server in-process. Multi-account Google sign-in, per-account LLM keys (OpenAI / Anthropic / Gemini), secrets in the OS keychain. Nothing to configure by hand: the Google OAuth client and your LLM key are entered in the app on first run.

You need: Node.js 18 or newer, Git, and a free Google "Desktop app" OAuth client - two values you create once in your Google Cloud project (exact click-by-click steps).

git clone https://github.com/samarthanalytics-sj/samarth-analytics-mcp.git
cd samarth-analytics-mcp/apps/desktop
npm install    # downloads the Electron binary (~100 MB first time)
npm run dev

The window opens; paste your OAuth client ID + secret and an LLM API key when asked, sign in to Google, and start chatting with your GTM / GA4 setup.

Prefer a config file over typing in the app? Put the OAuth client in a .env file instead - the app reads it on launch (values typed in the app and real shell variables always take precedence):

GOOGLE_DESKTOP_CLIENT_ID=your-client-id.apps.googleusercontent.com
GOOGLE_DESKTOP_CLIENT_SECRET=your-client-secret

Save it as apps/desktop/.env or at the repo root (already gitignored - never commit it). A repo-root .env using the server's GOOGLE_OAUTH_CLIENT_ID / GOOGLE_OAUTH_CLIENT_SECRET names works too, so one file can serve both the app and the MCP server. A packaged install reads .env from its data directory instead (%APPDATA% on Windows).

Your everyday launch afterwards is just:

cd samarth-analytics-mcp/apps/desktop && npm run dev

Full guide - Windows/macOS specifics, first-run setup, building a real .exe/.dmg installer, and the Error: Electron uninstall fix: apps/desktop/INSTALL.md.


Google Cloud OAuth Setup

Step 1: Enable the GTM API

  1. Go to Google Cloud Console

  2. Select or create a project

  3. Navigate to APIs & Services → Library

  4. Search for "Tag Manager API" and click Enable

  5. Search for "Google Analytics Admin API" and click Enable (required for the read-only ga4_* Admin tools)

  6. Search for "Google Analytics Data API" and click Enable (required for ga4_run_report / ga4_run_realtime_report)

Step 2: Create OAuth 2.0 Credentials

  1. Go to APIs & Services → Credentials

  2. Click Create Credentials → OAuth 2.0 Client ID

  3. Choose application type:

    • Desktop app — simplest for local stdio use (no redirect URI needed)

    • Web application — for the HTTP server (add your redirect URI)

  4. Download the JSON or copy the Client ID and Client Secret

  5. Add to .env:

    GOOGLE_CLIENT_ID=your-client-id.apps.googleusercontent.com
    GOOGLE_CLIENT_SECRET=your-client-secret
    GOOGLE_REDIRECT_URI=http://localhost:3001/oauth/callback
  1. Go to APIs & Services → OAuth consent screen

  2. Choose External (or Internal if you have Google Workspace)

  3. Fill in App name, support email

  4. Add scopes:

    • https://www.googleapis.com/auth/tagmanager.readonly

    • https://www.googleapis.com/auth/tagmanager.edit.containers

    • https://www.googleapis.com/auth/tagmanager.edit.containerversions

    • https://www.googleapis.com/auth/tagmanager.manage.accounts

    • https://www.googleapis.com/auth/tagmanager.manage.users

    • https://www.googleapis.com/auth/tagmanager.publish

    • https://www.googleapis.com/auth/analytics.readonly (read-only GA4 Admin and Data API tools)

    • https://www.googleapis.com/auth/analytics.edit (GA4 Admin write tools — gated by GA4_MCP_ENABLE_WRITES)

    • https://www.googleapis.com/auth/analytics.manage.users (GA4 access-binding write tools)

  5. Add your Google account as a test user (while the app is in "testing" mode)

Note: For personal/agency use, keeping the app in "Testing" mode is fine. You will need to re-authorize every 7 days unless you publish the app or get it verified.

Step 4: Run OAuth Setup

npm run auth:google

Or, if you prefer the older paste-the-code helper:

npm run oauth:setup

Service Account Limitations

Short version: Service accounts do NOT work with GTM by default. Use OAuth 2.0.

The Google Tag Manager API is a user-data API — it manages resources owned by individual Google accounts. Service accounts are not Google users and are not automatically granted access to GTM containers.

Option A: Add the service account as a GTM user (simplest)

If you still want to use a service account:

  1. Get the service account email (e.g., my-sa@project.iam.gserviceaccount.com)

  2. In GTM, go to Admin → User Management at the account or container level

  3. Add the service account email with the appropriate role (Read, Edit, Approve, Publish)

  4. Set GOOGLE_SERVICE_ACCOUNT_KEY_FILE=/path/to/key.json in .env

Caveats: This only works if the GTM container is associated with a Google account, not a Google Workspace that restricts external sharing.

Option B: Domain-Wide Delegation (Google Workspace only)

For Google Workspace organizations:

  1. Create a service account with a JSON key

  2. Enable Domain-Wide Delegation on the service account in Google Cloud Console

  3. In Google Workspace Admin Console → Security → API Controls → Domain-wide Delegation:

    • Add the service account client ID

    • Add scopes: https://www.googleapis.com/auth/tagmanager.edit.containers (and others as needed)

  4. In .env, set:

    GOOGLE_SERVICE_ACCOUNT_KEY_FILE=/path/to/key.json
  5. The server will impersonate the user automatically if you set a subject in buildGoogleAuth()

Caveats: Requires a paid Google Workspace account. Only available for your own domain.


Environment Variables Reference

Variable

Default

Description

GOOGLE_OAUTH_CLIENT_ID

—

OAuth client ID (preferred). Falls back to GOOGLE_CLIENT_ID.

GOOGLE_OAUTH_CLIENT_SECRET

—

OAuth client secret (preferred). Falls back to GOOGLE_CLIENT_SECRET.

GOOGLE_OAUTH_REDIRECT_URI

http://localhost:3001/oauth/callback

OAuth redirect URI. Falls back to GOOGLE_REDIRECT_URI.

GOOGLE_CLIENT_ID / GOOGLE_CLIENT_SECRET / GOOGLE_REDIRECT_URI

—

Legacy names, still supported.

SAMARTH_GOOGLE_OAUTH_CLIENT_ID

—

Hosted-only. Samarth-owned public OAuth client. Takes precedence over the self-hosted vars when set.

SAMARTH_GOOGLE_OAUTH_CLIENT_SECRET

—

Hosted-only. Inject from your platform secret manager. Never commit.

GOOGLE_ACCESS_TOKEN

—

Current OAuth access token. Env vars take precedence over the token file.

GOOGLE_REFRESH_TOKEN

—

OAuth refresh token (long-lived). Env vars take precedence over the token file.

GTM_MCP_TOKEN_FILE

./.gtm-mcp-tokens.json

Path to the local OAuth token file written by npm run auth:google (gitignored).

GOOGLE_SERVICE_ACCOUNT_KEY_FILE

—

Path to service account JSON key (see limitations above)

GTM_MCP_TRANSPORT

stdio

Transport: stdio or http

GTM_MCP_HTTP_PORT

3001

HTTP server port (http transport only; falls back to PORT)

GTM_MCP_HTTP_AUTH_TOKEN

—

Bearer token gating /mcp (http transport). With neither this nor STYTCH_PROJECT_ID set, the HTTP transport refuses to start.

GTM_MCP_HTTP_ALLOW_UNAUTHENTICATED

false

Local-dev opt-in to start without auth. Binds loopback only unless GTM_MCP_HTTP_HOST overrides.

GTM_MCP_HTTP_HOST

—

Bind host. Defaults to loopback when unauthenticated, all interfaces when authenticated.

GTM_MCP_HTTP_MAX_SESSIONS

100

Cap on live HTTP sessions (each holds its own MCP server, ~2 MB). Past it, initialize gets a JSON-RPC error (503 + Retry-After).

GTM_MCP_HTTP_MAX_SESSIONS_PER_PRINCIPAL

10 (multi-user), else the global cap

Cap per authenticated user. At the cap a new initialize replaces that user's least-recently-active idle session; if none is idle it gets a JSON-RPC error (429 + Retry-After).

STYTCH_PROJECT_ID

—

Setting this switches the HTTP transport to multi-user mode: each /mcp request carries a Stytch JWT resolved to that user's own Google identity. Unset = single-identity mode. Only Connected App access tokens are accepted (client_id required, session JWTs rejected), and issuer/audience are always pinned: STYTCH_JWT_ISSUER / STYTCH_JWT_AUDIENCE default to stytch.com/<project id> / <project id> (see .env.example).

STYTCH_SECRET

—

Stytch project secret (server-only). Required when STYTCH_PROJECT_ID is set — the server exits without it.

STYTCH_PUBLIC_TOKEN

—

Publishable token powering the /oauth/authorize page. Not a secret.

GTM_MCP_PUBLIC_URL

http://localhost:<port>

This server's public origin, advertised in the OAuth Protected Resource Metadata document.

GTM_MCP_ENABLE_WRITES

false

Allow create/update operations

GTM_MCP_ENABLE_PUBLISH

false

Allow publish operations

GTM_MCP_ENABLE_DELETES

false

Allow delete operations

GA4_MCP_ENABLE_WRITES

false

Allow GA4 Admin create and update operations. Also needs the analytics.edit scope (analytics.manage.users for user access bindings). The GA4 Data API stays read-only.

GA4_MCP_ENABLE_DELETES

false

Allow GA4 Admin delete and archive operations. Archiving a custom dimension, custom metric or audience cannot be undone.

DRY_RUN

false

Simulate all writes without calling the API

GTM_MCP_RETRY_MAX

3

Retry attempts for transient read failures (408/429/5xx, network). 0 disables retries. Mutations are never auto-retried.

GTM_MCP_RETRY_MAX_DELAY_MS

30000

Cap on a single backoff sleep (exponential backoff with jitter)

GTM_MCP_RETRY_TOTAL_TIMEOUT_MS

60000

Cap on total wall time from first request to last retry


Guardrails

The server enforces three independent guardrails in addition to the confirm=true requirement:

Guardrail

Env Variable

What it gates

Write guard

GTM_MCP_ENABLE_WRITES=true

All create and update operations

Delete guard

GTM_MCP_ENABLE_DELETES=true

All delete operations

Publish guard

GTM_MCP_ENABLE_PUBLISH=true

All version publish operations

Dry run

DRY_RUN=true

Simulate without API calls (overrides all)

confirm=true is always required on write/delete/publish tools regardless of env settings. This prevents accidental modifications even when guardrails are enabled.

Read-only exploration (default — safe for sharing with team):

GTM_MCP_ENABLE_WRITES=false
GTM_MCP_ENABLE_PUBLISH=false
GTM_MCP_ENABLE_DELETES=false

Development workspace edits (no publishing):

GTM_MCP_ENABLE_WRITES=true
GTM_MCP_ENABLE_PUBLISH=false
GTM_MCP_ENABLE_DELETES=false

Full access (use with care):

GTM_MCP_ENABLE_WRITES=true
GTM_MCP_ENABLE_PUBLISH=true
GTM_MCP_ENABLE_DELETES=true

Available Tools

Accounts

Tool

Description

accounts_list

List all accessible GTM accounts

accounts_get

Get a specific account

Containers

Tool

Description

containers_list

List containers in an account (auto-paginated)

containers_get

Get a specific container

containers_create

✏️ Create a new container

containers_snippet

Get the GTM installation snippet for a container

containers_lookup

Look up a container by linked destination/tag ID (e.g. G-XXXX)

containers_combine

✏️ Combine (merge) another container into this one

containers_move_tag_id

✏️ Move a Tag ID out into a new container

Destinations

Tool

Description

destinations_list

List linked destinations (Google tags / GA4) for a container

destinations_get

Get a specific destination

destinations_link

✏️ Link a destination to a container

Workspaces

Tool

Description

workspaces_list

List workspaces in a container (auto-paginated)

workspaces_get

Get a specific workspace

workspaces_create

✏️ Create a new workspace

workspace_get_status

Review the change diff (changed entities + merge conflicts) before versioning

workspace_sync

✏️ Sync workspace to latest container version

workspace_resolve_conflict

✏️ Resolve a merge conflict

workspace_quick_preview

Generate a preview link (read-safe)

workspace_create_version_and_publish

🚀 Create version + publish in one step

Tags

Tool

Description

tags_list

List all tags in a workspace

tags_get

Get a specific tag

tags_create

✏️ Create a tag

tags_update

✏️ Update a tag

tags_delete

🗑️ Delete a tag

Triggers

Tool

Description

triggers_list

List all triggers

triggers_get

Get a specific trigger

triggers_create

✏️ Create a trigger

triggers_update

✏️ Update a trigger

triggers_delete

🗑️ Delete a trigger

Variables

Tool

Description

variables_list

List all user-defined variables

variables_get

Get a specific variable

variables_create

✏️ Create a variable

variables_update

✏️ Update a variable

variables_delete

🗑️ Delete a variable

Folders

Tool

Description

folders_list

List all folders

folders_get

Get a specific folder

folders_entities

List entities in a folder (auto-paginated)

folders_create

✏️ Create a folder

folders_update

✏️ Update a folder

folders_delete

🗑️ Delete a folder

folders_move_entities

✏️ Move entities into a folder

Built-In Variables

Tool

Description

built_in_variables_list

List enabled built-in variables

built_in_variables_enable

✏️ Enable built-in variables

built_in_variables_disable

🗑️ Disable built-in variables

built_in_variables_revert

✏️ Revert a built-in variable to base version

Versions

Tool

Description

versions_list

List version headers

versions_get

Get a version (pass "live" for current live version)

versions_create

✏️ Create a checkpoint version from workspace

versions_set_latest

✏️ Set a version as latest

versions_publish

🚀 Publish a specific version

versions_undelete

✏️ Undelete a version

versions_delete

🗑️ Delete a version

Environments

Tool

Description

environments_list

List environments in a container (auto-paginated)

environments_get

Get a specific environment

environments_create

✏️ Create an environment

environments_update

✏️ Update an environment

environments_reauthorize

🚀 Re-generate the environment authorization token (high-impact)

environments_delete

🗑️ Delete an environment

User Permissions (account-level)

Tool

Description

user_permissions_list

List user permissions for an account (auto-paginated)

user_permissions_get

Get a specific user permission

user_permissions_create

✏️ Grant a user account/container access

user_permissions_update

✏️ Update a user's access levels

user_permissions_delete

🗑️ Revoke a user's access

Server-Side & Advanced Container Resources

These are workspace-scoped resources from GTM API v2. Create/update accept the full resource as a JSON string (bodyJson) since their bodies are deeply nested. Each supports *_list (auto-paginated), *_get, *_create ✏️, *_update ✏️, *_delete 🗑️, and (except gtag_config) *_revert ✏️.

Resource

Tools

Notes

Clients

clients_*

Server container request clients

Transformations

transformations_*

Server container event transformations

Zones

zones_*

Zone delegation

Templates

templates_*

Custom / gallery-installed templates

Gtag Config

gtag_config_*

Google tag (gtag) configuration — no revert

Analytics & Export

Tool

Description

audit_container

Inspect workspace for analytics issues

export_container

Export workspace as structured JSON

GA4 Admin (read-only)

Read-only wrappers over the Google Analytics Admin API (v1beta, with a single v1alpha call for enhanced measurement). These never write, update, or delete GA4 resources and require no confirm flag. They power the senior audit framework's GA4_ADMIN checks (custom dimensions/metrics, data streams & measurement IDs, data retention, enhanced measurement, key events, Google Ads links).

Requires the https://www.googleapis.com/auth/analytics.readonly scope and the Google Analytics Admin API enabled in your Google Cloud project. A 403 mentioning scope means you should re-run npm run auth:google.

Tool

Description

ga4_account_summaries_list

List GA4 accounts + their property summaries (best discovery entry point)

ga4_properties_list

List properties under a parent account (display name, time zone, currency, service level)

ga4_property_get

Get a single property by ID

ga4_data_streams_list

List data streams (web/Android/iOS) incl. web measurement IDs

ga4_enhanced_measurement_get

Get enhanced measurement settings for a web data stream (v1alpha)

ga4_custom_dimensions_list

List custom dimensions (parameter, scope)

ga4_custom_metrics_list

List custom metrics (parameter, unit, scope)

ga4_data_retention_get

Get event data-retention settings

ga4_key_events_list

List key events (formerly "conversion events" — current Admin naming)

ga4_google_ads_links_list

List Google Ads links (customer ID, auto-tagging/ads-personalization flags)

Accepts either a bare numeric ID (123456789) or the fully-qualified form (properties/123456789, accounts/123456) wherever a property/account is required.

Documented limitations (not exposed by the GA4 Admin API v1beta, so intentionally not implemented rather than faked):

  • Internal-traffic / unwanted-referral data filters — no public dataFilters collection; configured per data stream.

  • Referral exclusions — no dedicated Admin API resource.

  • Channel groups and audiences — exist only on the v1alpha surface and are out of scope for this read-only v1beta set.

GA4 Data API (read-only reporting)

Read-only wrappers over the Google Analytics Data API (v1beta). They never write and require no confirm flag. Use them to reconcile intent vs. reality — comparing the events a container is configured to send against the events GA4 actually reports (zero reported activity for a configured event is a red flag).

These use the same https://www.googleapis.com/auth/analytics.readonly scope as the GA4 Admin tools, so no extra consent is needed. Enable the Google Analytics Data API in your Google Cloud project.

Tool

Description

ga4_run_report

Run a report over a date range (dimensions + metrics, e.g. eventCount by eventName); supports limit, offset, and ordering

ga4_run_realtime_report

Run a Realtime report (events in roughly the last 30 minutes) for live QA

Documented gaps (intentionally not exposed rather than faked): pivot reports, cohorts, and funnels.

Pagination

All list tools backed by paginated GTM endpoints (accounts_*-scoped containers, workspaces, tags, triggers, variables, folders, folder entities, environments, user permissions, clients, transformations, zones, templates, gtag configs) auto-follow pagination and return all results by default. Optional arguments:

  • maxPages — cap the number of API pages fetched (default 50). If more pages remain, the response includes "truncated": true and a nextPageToken.

  • pageToken — resume from a previous truncated result.

Non-truncated responses keep the original { <key>: [...], count } shape unchanged.

Two tools differ, because one list key does not describe what they return:

  • folders_entities returns three parallel collections (tag, trigger, variable, always present, empty when the folder has none) plus a counts object, and adds truncated / nextPageToken only when the page ceiling was hit.

  • export_container pages five collections independently, so it takes maxPages (applied per collection) but no pageToken. A short export is marked incomplete: true with truncatedCollections, per-collection nextPageTokens and a warning — in every format, including the default summary.

Legend: ✏️ requires GTM_MCP_ENABLE_WRITES=true | 🗑️ requires GTM_MCP_ENABLE_DELETES=true | 🚀 requires GTM_MCP_ENABLE_PUBLISH=true

All ✏️ 🗑️ 🚀 tools also require confirm: true in the tool arguments.


Cloud Deployment

Transport

For cloud deployments, use GTM_MCP_TRANSPORT=http. The server exposes:

  • POST /mcp — Streamable HTTP MCP endpoint

  • GET /mcp — SSE stream for existing sessions

  • DELETE /mcp — Session termination

  • GET /health — Health check

There is no /oauth/callback route on this server. npm run auth:google runs its own short-lived listener on 127.0.0.1:3001 for the redirect; an unauthenticated callback on the hosted transport could overwrite the server's stored Google credentials, so it was removed.

Connecting Remote Clients

Clients that support Streamable HTTP can connect directly to the /mcp endpoint. For clients that only support stdio (like Claude Desktop), use mcp-remote as a proxy:

{
  "mcpServers": {
    "samarth-gtm-remote": {
      "command": "npx",
      "args": ["mcp-remote@next", "https://your-server.com/mcp"]
    }
  }
}

Vercel

Limitation: Vercel Serverless Functions have a 10-second timeout (hobby) / 60-second (pro). Stateful SSE sessions require persistent connections which Vercel does not support well. Use Vercel only for stateless MCP interactions. Recommended alternative: Vercel + external session store (Redis/Upstash), or use Render/Fly.io instead.

For Vercel, export the Express app as a serverless handler:

// api/mcp.ts
export default app; // where app is the Express instance

Set env vars in Vercel Dashboard → Settings → Environment Variables.

Render

The repo ships a Render Blueprint, render.yaml. It defines one web service, samarth-gtm-mcp:

  • Runtime: Docker. Render builds the Dockerfile on every deploy. There is no build command and no start command to set.

  • Health check path: /health.

  • Branch: render.yaml has no branch key. Render deploys the branch you select when you create the Blueprint. autoDeployTrigger: commit deploys every new commit on that branch.

  • Port: do not set one. Render provides PORT and the server listens on it.

To deploy: Render Dashboard → New → Blueprint → select this repo.

render.yaml sets only GTM_MCP_TRANSPORT=http, a generated GTM_MCP_HTTP_AUTH_TOKEN, and the three GTM guardrail flags as false. Add the other variables by hand in the Environment tab of the service. Never put their values in render.yaml.

Mode

Variables to add by hand

Shared token (one Google identity for every client)

GOOGLE_OAUTH_CLIENT_ID, GOOGLE_OAUTH_CLIENT_SECRET, GOOGLE_REFRESH_TOKEN. Leave STYTCH_PROJECT_ID unset. Clients send Authorization: Bearer <GTM_MCP_HTTP_AUTH_TOKEN>.

Per-user OAuth (each user signs in with their own Google account)

STYTCH_PROJECT_ID, STYTCH_SECRET, STYTCH_PUBLIC_TOKEN, and GTM_MCP_PUBLIC_URL=https://<your-domain> (the origin only, with no /mcp at the end). When STYTCH_PROJECT_ID is set, the server ignores the shared token.

Guardrails: GTM_MCP_ENABLE_WRITES, GTM_MCP_ENABLE_PUBLISH, GTM_MCP_ENABLE_DELETES, GA4_MCP_ENABLE_WRITES and GA4_MCP_ENABLE_DELETES are off unless the value is exactly true. Keep all five off on a public host. GET /health must show "readOnly":true. Never set GTM_MCP_HTTP_ALLOW_UNAUTHENTICATED on a public host.

Custom domain: add the domain under Settings → Custom Domains of the service. Then create a CNAME record at your DNS provider that points to <service>.onrender.com. On Cloudflare, set the record to DNS only. Start the service and check it before you add the DNS record.

For the checks, the restore order, the DNS values, rollback and retiring the endpoint, see docs/HOSTED_ENDPOINT_RUNBOOK.md.

Fly.io

fly launch --no-deploy
fly secrets set GOOGLE_CLIENT_ID=xxx GOOGLE_CLIENT_SECRET=xxx GOOGLE_REFRESH_TOKEN=xxx
TOKEN="$(openssl rand -hex 32)"   # keep this value: clients send it as the bearer token
fly secrets set GTM_MCP_HTTP_AUTH_TOKEN="$TOKEN"
fly secrets set GTM_MCP_TRANSPORT=http GTM_MCP_HTTP_PORT=3001
fly deploy

The HTTP transport refuses to start without an auth mode, so set one before the first deploy:

  • Shared token: GTM_MCP_HTTP_AUTH_TOKEN, as above. Clients send Authorization: Bearer <token>.

  • Per-user OAuth: STYTCH_PROJECT_ID, STYTCH_SECRET, STYTCH_PUBLIC_TOKEN and GTM_MCP_PUBLIC_URL (the app's public origin) as Fly secrets instead. When STYTCH_PROJECT_ID is set, the server ignores the shared token.

Never set GTM_MCP_HTTP_ALLOW_UNAUTHENTICATED on Fly.io. Make sure internal_port in the generated fly.toml matches GTM_MCP_HTTP_PORT.

Fly.io keeps long-lived connections open, which suits the SSE stream. This repo ships no fly.toml and does not test Fly.io deploys, so check GET /health and an authenticated initialize after the first deploy.

Docker

Use the repo's Dockerfile rather than writing your own. It is a three-stage build: the first stage compiles the server to dist/, the second builds the authorize app in apps/mcp-authorize, and the runtime stage installs production dependencies only and copies both outputs in. The image runs the stdio transport by default. It sets no port and has no EXPOSE.

For the HTTP transport, pass the transport and an auth variable at run time:

docker build -t samarth-gtm-mcp .
TOKEN="$(openssl rand -hex 32)"   # keep this value: clients send it as the bearer token
docker run --rm -p 3001:3001 \
  -e GTM_MCP_TRANSPORT=http \
  -e GTM_MCP_HTTP_AUTH_TOKEN="$TOKEN" \
  -e GOOGLE_OAUTH_CLIENT_ID=... -e GOOGLE_OAUTH_CLIENT_SECRET=... -e GOOGLE_REFRESH_TOKEN=... \
  samarth-gtm-mcp

The server listens on GTM_MCP_HTTP_PORT, then PORT, then 3001. For the full stack with Docker Compose, see docs/SELF_HOSTING_DOCKER.md.


Security Notes

  1. Never commit .env — it contains OAuth tokens. .env is already in .gitignore.

  2. Rotate tokens regularly — OAuth refresh tokens are long-lived but can be revoked. Revoke at myaccount.google.com/permissions.

  3. Minimum scopes — If you only need read access, revoke write scopes by removing them from the OAuth consent screen and re-authorizing. The server reads fine with tagmanager.readonly only.

  4. Cloud deployment: Store secrets in your platform's secret manager (Render Secrets, Fly.io Secrets, Vercel Env Vars), never in code or Docker images.

  5. HTTP transport: /mcp has two built-in auth modes — GTM_MCP_HTTP_AUTH_TOKEN (one shared bearer token, identifies the deployment) and STYTCH_PROJECT_ID (per-user OAuth, each request resolved to that user's own Google grant). With neither set the transport refuses to start; GTM_MCP_HTTP_ALLOW_UNAUTHENTICATED=true overrides that for local development and binds loopback only.

  6. Publish guard: Keep GTM_MCP_ENABLE_PUBLISH=false unless you explicitly intend to publish from an AI client. Publishing incorrect tags to production is the highest-risk operation.

  7. Audit logs: The server logs all session events to stderr. Pipe to a logging service in production.


Development

# Install dependencies
npm install

# TypeScript type check (no emit)
npm run typecheck

# Build
npm run build

# Watch mode
npm run build:watch

# Run dev server (stdio, with hot-reload)
npm run dev

# Run HTTP dev server
npm run dev:http

# Tests (run `npm run build` first — some suites test the compiled dist)
npm test

# Smoke test: server boots and answers tools/list
npm run smoke -- --mcp dist/index.js

# Full-surface smoke test: invokes ALL registered tools with a sanitized,
# credential-free env — every handler must respond cleanly (no crash/hang)
npm run smoke:all

# MCP Inspector (interactive tool debugging)
npm run inspector

Project Structure

samarth-gtm-mcp/
├── src/
│   ├── index.ts              # Entry point — stdio/HTTP transport setup
│   ├── server.ts             # MCP server factory + tool registration
│   ├── auth/
│   │   └── googleAuth.ts     # OAuth2 / service account auth
│   ├── tools/
│   │   ├── index.ts          # Tool registration aggregator
│   │   ├── accounts.ts       # accounts/list, accounts/get
│   │   ├── containers.ts     # containers/list/get/create
│   │   ├── workspaces.ts     # workspaces + sync/resolve_conflict
│   │   ├── tags.ts           # tags CRUD
│   │   ├── triggers.ts       # triggers CRUD
│   │   ├── variables.ts      # variables CRUD
│   │   ├── folders.ts        # folders CRUD + move_entities
│   │   ├── builtInVariables.ts # enable/disable/revert built-ins
│   │   ├── versions.ts       # versions list/get/create/publish/delete
│   │   ├── publish.ts        # quick_preview, versions_publish, create+publish
│   │   ├── audit.ts          # audit_container analytics checks
│   │   ├── export.ts         # export_container JSON dump
│   │   ├── environments.ts   # environments CRUD + reauthorize
│   │   ├── userPermissions.ts # account-level user permissions
│   │   ├── serverSide.ts     # clients, transformations, zones, templates, gtag config
│   │   ├── ga4Admin.ts       # read-only GA4 Admin tools (ga4_*)
│   │   └── ga4Data.ts        # read-only GA4 Data API reporting
│   ├── utils/
│   │   ├── guardrails.ts     # Guardrail enforcement, error formatting
│   │   ├── gtmClient.ts      # googleapis GTM v2 client factory
│   │   ├── ga4Client.ts      # GA4 Admin/Data client factories
│   │   ├── apiRetry.ts       # retry/backoff config (429/5xx, reads only)
│   │   ├── pagination.ts     # transparent nextPageToken following
│   │   ├── schemas.ts        # shared Zod input schemas
│   │   └── toolResponse.ts   # standard tool result shaping
│   ├── types/
│   │   ├── gtm.ts            # GTM API type definitions
│   │   └── index.ts
│   ├── scripts/
│   │   ├── auth-google.ts    # Browser-based OAuth onboarding (`npm run auth:google`)
│   │   └── oauth-setup.ts    # Interactive OAuth token helper (legacy paste-the-code flow)
│   └── __tests__/
│       ├── guardrails.node.test.mjs  # guardrails + buildPath
│       ├── auth.node.test.mjs        # env/auth resolution + token file paths
│       ├── pagination.node.test.mjs  # paginate/buildListResult
│       ├── ga4Admin.node.test.mjs    # GA4 tool registration (tests compiled dist)
│       └── apiRetry.node.test.mjs    # retry/backoff config (tests compiled dist)
├── scripts/
│   ├── smoke-test.mjs        # health probe: portal endpoints + MCP tools/list
│   └── smoke-all-tools.mjs   # invokes all tools with sanitized env
├── .env.example
├── .gitignore
├── package.json
├── tsconfig.json
└── README.md

Releases

Releases are fully automated via semantic-release and GitHub Actions. Every push to main triggers the release.yml workflow, which:

  1. Installs dependencies, type-checks, builds, and runs tests.

  2. Checks that it can publish. If no npm trusted publisher entry matches this workflow, the run stops here, before any commit or tag.

  3. Inspects commits since the last tag using the Conventional Commits spec and determines the next semantic version (MAJOR.MINOR.PATCH).

  4. Writes the new section of CHANGELOG.md.

  5. Bumps the version: npm version writes package.json and package-lock.json, and its version lifecycle script (scripts/sync-server-json.mjs) writes the same version into server.json.

  6. Commits those four files to main as chore(release): x.y.z [skip ci] and pushes the commit (the [skip ci] marker prevents an infinite release loop).

  7. Creates the Git tag vX.Y.Z and pushes it.

  8. Publishes the package to npm as samarth-gtm-mcp with a provenance attestation, then creates a GitHub Release with the generated notes.

The order follows the plugins in .releaserc.json. The tag is pushed before the npm publish, so a failure in step 8 leaves the release commit and tag in place without an npm release. server.json is only updated in the repo; publishing it to the MCP Registry is a separate, manual step (see docs/DIRECTORY_LISTINGS.md).

npm publishing uses Trusted Publishing: the job's GitHub OIDC token is exchanged for a short-lived npm token, so there is no npm token secret to rotate. The trusted publisher is configured on npmjs.com (GitHub Actions, this repository, workflow release.yml, no environment); setup steps and limits are in the npm publish checklist. Because main is protected, the release commit is pushed with a RELEASE_TOKEN secret (a fine-grained token of a repo admin with Contents, Issues and Pull requests read/write).

Conventional Commit Examples

Commit messages drive the version bump:

Commit prefix

Effect

Example

fix:

Patch release (x.y.Z)

fix: handle empty workspace in audit tool

feat:

Minor release (x.Y.0)

feat: add bulk tag import tool

perf:

Patch release

perf: cache GTM client between tool calls

docs: / chore: / refactor: / test: / style: / ci: / build:

No release

docs: clarify OAuth setup steps

BREAKING CHANGE: footer or ! after type

Major release (X.0.0)

see below

Breaking change examples

feat!: drop support for Node.js 18

BREAKING CHANGE: minimum required Node version is now 20.

or:

refactor(auth): rename GOOGLE_REFRESH_TOKEN env var

BREAKING CHANGE: GOOGLE_REFRESH_TOKEN is now GTM_GOOGLE_REFRESH_TOKEN.
Update your .env file accordingly.

Dry run locally

To preview what the next release would look like without publishing:

GITHUB_TOKEN=<a-token-with-no-perms-is-fine-for-dry-run> \
  npx semantic-release --dry-run --no-ci

Manual release skip

To intentionally land a commit without triggering a release, use a non-releasing type (chore:, docs:, etc.) or append [skip ci] to the commit subject.


Troubleshooting

"The caller does not have permission" (403)

  • Your Google account may not have access to this GTM account/container

  • Service account not added to GTM — see Service Account Limitations

  • Check your OAuth scopes on the consent screen

"invalid_grant" or "Token has been expired or revoked"

  • Re-run npm run auth:google to refresh the token file

  • Or set GOOGLE_REFRESH_TOKEN directly in .env if you prefer env-managed tokens

  • If you're stuck in a loop where Google won't return a refresh_token, revoke prior access at myaccount.google.com/permissions and re-run the auth script

"Write operations are disabled"

  • Set GTM_MCP_ENABLE_WRITES=true in your .env

  • Restart the server / the desktop app

Stdio server shows no output

  • The stdio server intentionally writes nothing to stdout (stdout is the JSON-RPC channel)

  • Diagnostic output goes to stderr — check your terminal or Claude Desktop logs

Desktop app: Error: Electron uninstall on npm run dev

  • The Electron binary downloaded but never finished extracting - see the reliable re-extract fix in apps/desktop/INSTALL.md

TypeScript errors on googleapis types

  • Run npm install to ensure all deps are installed

  • The googleapis package ships its own types — no @types/googleapis needed


TODOs / Known Limitations

  • workspace_resolve_conflict: The GTM API's resolve_conflict endpoint accepts a full entity body — the exact request body schema is complex. The current implementation passes through the user-supplied JSON; validate it against the entity type before calling.

  • containers_create: The usageContext enum values may differ slightly by GTM region/version. Refer to the GTM API docs for the latest allowed values.

  • Single-identity HTTP auth is a shared secret: GTM_MCP_HTTP_AUTH_TOKEN gates /mcp with one bearer token for every client, so it identifies the deployment, not the caller. For per-user identity, set STYTCH_PROJECT_ID to enable multi-user mode — see Security Notes.

  • HTTP sessions are in-memory: sessions live in the server process, so horizontal scaling requires sticky sessions. Fine for a single team instance; not yet built for multi-instance load balancing.

  • Single OAuth identity per deployment — single-identity mode only: without STYTCH_PROJECT_ID, all requests share one Google identity and therefore one Google API quota pool. Heavy multi-user load through one deployment will exhaust it; retries with backoff soften this but don't remove the quota ceiling. Multi-user mode sidesteps it — each member uses their own Google grant and quota.


Built by Samarth Analytics — Swapnil Jaykar & Sarthak Mandage

Available Tools

203 tools
accounts_getB

Get details of a specific GTM account.

Inputs: accountId (required).

accounts_listA

List all GTM accounts accessible to the authenticated user. Returns account IDs, names, and share-data flags.

Inputs: maxPages, pageToken, includeGoogleTags.

audit_containerB

Inspect a GTM workspace for common analytics implementation issues. Returns structured findings with severity levels (error/warning/info). This is a read-only operation — it never modifies anything.

Inputs: accountId (required), containerId (required), workspaceId (required), includeInfo.

built_in_variables_disableA

[DELETE] Disable one or more built-in variables in a GTM workspace. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: types (required), confirm (required), accountId (required), containerId (required), +1 more.

built_in_variables_enableB

[WRITE] Enable one or more built-in variables in a GTM workspace. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: types (required), confirm (required), accountId (required), containerId (required), +1 more.

built_in_variables_listC

List all currently enabled built-in variables in a GTM workspace.

Inputs: accountId (required), containerId (required), workspaceId (required), maxPages, +1 more.

built_in_variables_revertA

[WRITE] Revert changes to a built-in variable in the workspace to the original container version. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: type (required), confirm (required), accountId (required), containerId (required), +1 more.

clients_createA

[WRITE] Create a new GTM client. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Pass the full resource as a JSON string in bodyJson.

Inputs: confirm (required), bodyJson (required), accountId (required), containerId (required), +1 more.

clients_deleteA

[DELETE] Delete a GTM client. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: confirm (required), clientId (required), accountId (required), containerId (required), +1 more.

clients_getC

Get a specific GTM client.

Inputs: clientId (required), accountId (required), containerId (required), workspaceId (required).

clients_listB

List all GTM clients in a workspace. Automatically follows pagination.

Inputs: accountId (required), containerId (required), workspaceId (required), maxPages, +1 more.

clients_revertA

[WRITE] Revert workspace changes to a GTM client back to its last container-version state. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), clientId (required), accountId (required), containerId (required), +2 more.

clients_updateA

[WRITE] Update an existing GTM client. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Pass the full resource as a JSON string in bodyJson.

Inputs: confirm (required), bodyJson (required), clientId (required), accountId (required), +3 more.

containers_combineB

[WRITE] Combine (merge) another container into this one. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. ⚠️ This merges the source container identified by containerIdToCombine into the target container.

Inputs: confirm (required), accountId (required), containerId (required), containerIdToCombine (required), +2 more.

containers_createA

[WRITE] Create a new GTM container. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), accountId (required), usageContext (required), +2 more.

containers_getC

Get details of a specific GTM container.

Inputs: accountId (required), containerId (required).

containers_listA

List all GTM containers within a GTM account. Automatically follows pagination to return all containers.

Inputs: accountId (required), maxPages, pageToken.

containers_lookupA

Look up a GTM container by its linked destination ID (e.g. a GA4 measurement ID or tag ID).

Inputs: destinationId (required).

containers_move_tag_idA

[WRITE] Move a Tag ID out of a container into a new container. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: tagId (required), confirm (required), accountId (required), containerId (required), +5 more.

containers_set_tagging_server_urlsA

[WRITE] Set a SERVER container's taggingServerUrls (the deployed tagging-server URL, e.g. from Cloud Run/Stape). Read-modify-write via containers.update so the other container fields are preserved; rejects a non-server container. Records the URL in config only — it does NOT deploy the host. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), serverUrls (required), containerId (required).

containers_snippetA

Get the GTM installation snippet (HTML/JS tagging code) for a container.

Inputs: accountId (required), containerId (required).

create_adroll_capi_server_tagA

[WRITE] Create an AdRoll SERVER tag from the Stape template (stape-io/adroll-tag), imported automatically. Needs advertisableId AND pixelId (both public, on the web snippet as adroll_adv_id / adroll_pix_id) plus an accessToken. Omit event to inherit; pageView/productSearch/addToCart/purchase or a GA4 name are standard, anything else is a custom event. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), pixelId (required), accountId (required), accessToken (required), +12 more.

create_amazon_capi_server_tagA

[WRITE] Create an Amazon Ads Conversions API SERVER tag from the Stape template (stape-io/amazon-tag), imported automatically. No token: the only credential is tagIds (the Amazon Ads Tag UUIDs) plus tagRegion (NA | EU). Omit event to inherit; pass an Amazon standard event (Off-AmazonPurchases, Lead, …) or a GA4 name. eventId is the clientDedupeId dedup row. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: tagIds (required), confirm (required), accountId (required), containerId (required), +9 more.

create_gtm_tracking_tagA

[WRITE] PREFERRED way to create a GA4 event tag that fires on an event. Builds a CORRECT GTM resource from plain fields, so you never hand-write GTM JSON. ONE call: enables the built-in variables the tag and trigger reference, reuses or creates the named trigger, and creates the tag linked to it in the draft workspace. Use this instead of tags_create + triggers_create + built_in_variables_enable, which needs three round trips and gets the shapes wrong. eventParameters values may reference built-in variables ({{Click URL}}, {{Click Text}}, {{Page URL}}, {{Form ID}}) and those are enabled automatically. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), tagName (required), trigger (required), accountId (required), +11 more.

create_gtm_variable_typedA

[WRITE] Create a GTM variable by KIND rather than by GTM's internal type code, so the right shape is guaranteed. kind: "constant" (a fixed reused value, e.g. a Measurement ID); "data_layer" (read a key the SITE pushes to the dataLayer, dot-notation for nested, e.g. ecommerce.value) - only correct when the site actually pushes that key; "javascript" (Custom JavaScript: a function(){...} that COMPUTES a value, and the right choice for deriving something from the page or the click, e.g. extracting the address out of a mailto: {{Click URL}} - a data_layer variable CANNOT do this and would report blank); "event_data" and "request_header" (SERVER containers only). Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: kind (required), name (required), confirm (required), accountId (required), +8 more.

create_line_yahoo_capi_server_tagA

[WRITE] Create a LINE Yahoo (Yahoo! JAPAN Ads) Conversion API SERVER tag from the Stape template (stape-io/line-yahoo-tag), imported automatically. Needs the Yahoo tagId (public), accessToken and channelId. Omit event to inherit; Yahoo has NO custom events (unknown names inherit). Every event other than page_view needs its own eventSnippetId from Yahoo Ads. transactionId is the dedup row. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: tagId (required), confirm (required), accountId (required), channelId (required), +16 more.

create_linkedin_capi_server_tagA

[WRITE] Create a LinkedIn Conversions API SERVER tag from the Stape template (stape-io/linkedin-tag), imported automatically. LinkedIn CAPI fires on a CONVERSION RULE URN (urn:lla:llaPartnerConversion:…) from Campaign Manager, NOT the web Partner ID; the tag auto-maps user ids / user info / event data. eventId dedups against the Insight Tag. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), accessToken (required), containerId (required), +11 more.

create_meta_capi_server_tagA

[WRITE] Create a Meta Conversions API SERVER tag from the Stape template (stape-io/facebook-tag), imported automatically: the server counterpart of the Meta Pixel. pixelId is the Pixel ID (public, on the web pixel), accessToken the CAPI system-user token. event is the Meta event the tag sends (Purchase, Lead, a GA4 name is mapped, or a custom name). User data (em/ph/external_id/IP/user agent), ecommerce custom data and the event_id dedup key are mapped from ed - … Event Data variables, which this tool creates in the workspace when they are missing. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: event (required), confirm (required), pixelId (required), accountId (required), +5 more.

create_microsoft_capi_server_tagA

[WRITE] Create a Microsoft Ads (Bing) UET Conversions API SERVER tag from the Stape template (stape-io/microsoft-capi-tag), imported automatically. uetTagId is the UET Tag ID (public; the built-in web tag stores it as tagId), authToken the API token. event is the conversion goal / GA4 name. REQUIRES the MSCLKID to be forwarded from the web side for attribution. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: event (required), confirm (required), uetTagId (required), accountId (required), +11 more.

create_nextdoor_capi_server_tagA

[WRITE] Create a Nextdoor Conversion API SERVER tag from the Stape template (stape-io/nextdoor-tag), imported automatically. Needs pixelId (public) plus clientId and accessToken from Nextdoor Ads. Omit event to inherit; conversion/lead/purchase/sign_up/custom_conversion_1..10 or a GA4 name are standard. eventId is the dedup row. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), pixelId (required), clientId (required), accountId (required), +15 more.

create_pinterest_capi_server_tagA

[WRITE] Create a Pinterest Conversions API SERVER tag from the official template (pinterest/ss-gtm-template), imported automatically. advertiserId is the Pinterest Ad Account ID (549 followed by 9 digits, from Ads Manager; NOT the web Tag ID), apiAccessToken the Conversions API token. Omit event to inherit the incoming event name (auto-mapped); pass a Pinterest standard event (checkout, lead, signup, …) or a GA4 name to force one. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), containerId (required), workspaceId (required), +6 more.

create_quora_capi_server_tagA

[WRITE] Create a Quora Conversion API SERVER tag from the Stape template (stape-io/quora-tag), imported automatically. pixelId is the Quora Pixel ID (stored in the template's accountId field), accessToken the Quora API token. Omit event to inherit; Quora has NO custom event, so an unknown name becomes Generic. eventId is the dedup row. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), pixelId (required), accountId (required), accessToken (required), +11 more.

create_reddit_capi_server_tagA

[WRITE] Create a Reddit Conversions API SERVER tag from the Stape template (stape-io/reddit-tag), imported automatically. pixelId is the Reddit Pixel/Advertiser id (t2_/a2_, public), accessToken the Conversions Access Token. Omit event to inherit; pass a Reddit standard event (PAGE_VISIT/VIEW_CONTENT/SEARCH/ADD_TO_CART/ADD_TO_WISHLIST/PURCHASE/LEAD/SIGN_UP), a GA4 name, or a custom name. eventId is the conversion_id dedup row. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), pixelId (required), accountId (required), accessToken (required), +12 more.

create_rtb_house_server_tagA

[WRITE] Create an RTB House SERVER tag from the Stape template (stape-io/rtb-house-tag), imported automatically. A retargeting tag with NO token: needs the taggingHash (public, the id in the creativecdn.com pixel URL) and the partnerKey. Its events are PAGE TYPES, so event is required: home/listing/offer/wishlist/basketadd/basketstatus/startorder/conversion_order/conversion or a GA4 name (page_view→home, view_item→offer, add_to_cart→basketadd, purchase→conversion_order, …). containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: event (required), confirm (required), accountId (required), partnerKey (required), +16 more.

create_server_tagA

[WRITE] Create a NATIVE Google server tag in a SERVER container workspace, built with the correct shape: platform "ga4" = the GA4 relay (sgtmgaaw; omit eventName to relay every incoming event, pass one for a per-event tag; optional eventParameters / userProperties enrichment rows), "ads_conversion" = Google Ads conversion (sgtmadsct; conversionId + conversionLabel), "ads_conversion_linker" = the server Conversion Linker (sgtmadscl), "ads_remarketing" = Google Ads remarketing (sgtmadsremarket; conversionId). Pass the SERVER trigger id(s) as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), platform (required), accountId (required), +10 more.

create_snapchat_capi_server_tagA

[WRITE] Create a Snapchat Conversions API SERVER tag from the official template (Snapchat/capi-google-tag-manager-serverside-tag), imported automatically. pixelId is the Snap Pixel ID (public), apiAccessToken the CAPI token. event is the Snap event (PURCHASE, SIGN_UP, a GA4 name is mapped). eventId dedups against the Snap Pixel. User data and the default event_id are mapped from the Meta-style ed - … Event Data variables, which this tool creates in the workspace when they are missing. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: event (required), confirm (required), pixelId (required), accountId (required), +11 more.

create_spotify_capi_server_tagA

[WRITE] Create a Spotify Ads Conversion API SERVER tag from the Stape template (stape-io/spotify-tag), imported automatically. Needs authToken and connectionId. Omit event to inherit; Page_View/Sign_Up/Lead/View_Product/Add_Cart/Start_Checkout/Purchase or a GA4 name are standard, custom_event_1..5 are the only custom slots (anything else inherits). eventId is the dedup row. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), authToken (required), containerId (required), +14 more.

create_stackadapt_server_tagA

[WRITE] Create a StackAdapt SERVER pixel tag from the official template (StackAdapt/stackadapt-gtm-server-side-pixel), imported automatically. Not a CAPI: an id-only pixel (pixelID + pixelType rt/lal/conv/universal, default conv) with optional commonProperties (email/order_id/revenue/action…) and customProperties. No token, no event_id dedup. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), pixelID (required), accountId (required), containerId (required), +7 more.

create_tiktok_capi_server_tagA

[WRITE] Create a TikTok Events API SERVER tag from the Stape template (stape-io/tiktok-tag), imported automatically. pixelId is the TikTok Pixel Code (public), accessToken the Events API token. event is the TikTok event (CompletePayment, SubmitForm, a GA4 name is mapped). User data, event properties and the event_id dedup key are mapped from ed - … Event Data variables, which this tool creates in the workspace when they are missing. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: event (required), confirm (required), pixelId (required), accountId (required), +5 more.

create_x_capi_server_tagA

[WRITE] Create an X (Twitter) Conversion API SERVER tag from the Stape template (stape-io/twitter-tag), imported automatically. The template has NO event-name field: eventId is the per-conversion X "Event ID" (tw-…) from X Ads > Events Manager, so one tag = one X conversion event and the server trigger decides when it fires. Auth is EITHER pixelAccessToken OR the OAuth 1.0a quartet. conversionId is the dedup row against the X Pixel. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), eventId (required), pixelId (required), accountId (required), +15 more.

create_yelp_capi_server_tagA

[WRITE] Create a Yelp Conversion API SERVER tag from the Stape template (stape-io/yelp-tag), imported automatically. Yelp has no pixel id: only the accessToken from Yelp Ads. Omit event to inherit; purchase/add_to_cart/checkout/lead/view_content/signup/… or a GA4 name are standard. eventId is the dedup row; validate runs Yelp's payload validation. containerId must be the SERVER container. Needs a SERVER trigger (triggers_create) passed as firingTriggerId. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), accessToken (required), containerId (required), +12 more.

destinations_getB

Get details of a specific GTM destination.

Inputs: accountId (required), containerId (required), destinationId (required).

destinations_listB

List all destinations (linked Google tags / GA4 destinations) for a GTM container.

Inputs: accountId (required), containerId (required).

environments_createA

[WRITE] Create a new GTM environment. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), accountId (required), containerId (required), +3 more.

environments_deleteA

[DELETE] Delete a GTM environment. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: confirm (required), accountId (required), containerId (required), environmentId (required).

environments_getB

Get details of a specific GTM environment.

Inputs: accountId (required), containerId (required), environmentId (required).

environments_listA

List all environments in a GTM container. Automatically follows pagination.

Inputs: accountId (required), containerId (required), maxPages, pageToken.

environments_reauthorizeA

[PUBLISH] Re-generate the authorization code for a GTM environment. Requires GTM_MCP_ENABLE_PUBLISH=true and confirm=true. ⚠️ This rotates the environment auth token; any embedded snippet using the old token stops working until updated.

Inputs: confirm (required), accountId (required), containerId (required), environmentId (required).

environments_updateA

[WRITE] Update an existing GTM environment (read-modify-write: omitted fields are preserved). Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), containerId (required), environmentId (required), +5 more.

export_containerA

Export a full GTM workspace summary as structured JSON. Returns all tags, triggers, variables, folders, and built-in variables. This is a read-only operation. Use this for documentation, auditing, or feeding container data to other tools.

Inputs: accountId (required), containerId (required), workspaceId (required), format, +1 more.

folders_createB

[WRITE] Create a GTM folder. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), accountId (required), containerId (required), +2 more.

folders_deleteA

[DELETE] Delete a GTM folder. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true. Contents of the folder will be unfoldered, not deleted.

Inputs: confirm (required), folderId (required), accountId (required), containerId (required), +1 more.

folders_entitiesB

List all entities (tags, triggers, variables) within a specific GTM folder. Automatically follows pagination to return all entities.

Inputs: folderId (required), accountId (required), containerId (required), workspaceId (required), +2 more.

folders_getC

Get a specific GTM folder.

Inputs: folderId (required), accountId (required), containerId (required), workspaceId (required).

folders_listB

List all GTM folders in a workspace. Automatically follows pagination to return all folders.

Inputs: accountId (required), containerId (required), workspaceId (required), maxPages, +1 more.

folders_move_entitiesA

[WRITE] Move tags/triggers/variables into a folder. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), folderId (required), accountId (required), containerId (required), +4 more.

folders_updateA

[WRITE] Update a GTM folder (read-modify-write: omitted fields are preserved). Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), folderId (required), accountId (required), containerId (required), +4 more.

ga4_account_summaries_listA

List GA4 account summaries accessible to the authenticated user. Each summary includes the account plus a lightweight list of its property summaries (property ID + display name). Best starting point to discover available GA4 accounts and properties. Read-only.

Inputs: maxPages, pageToken.

ga4_acknowledge_user_data_collectionA

[GA4 WRITE] Acknowledge that the property owner has the required user privacy disclosures/rights. Some operations (e.g. creating certain links or MP secrets) require this once. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required).

ga4_archive_audienceA

[GA4 DELETE] Archive an audience (stops collection; effectively permanent). Archiving is effectively permanent (no un-archive). Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_archive_custom_dimensionA

[GA4 DELETE] Archive a custom dimension (there is no hard delete). Archiving is effectively permanent (no un-archive). Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_archive_custom_metricA

[GA4 DELETE] Archive a custom metric (there is no hard delete). Archiving is effectively permanent (no un-archive). Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_check_compatibilityA

Check which of the given GA4 dimensions/metrics can be combined in ONE report on this property (the Data API rejects incompatible pairs). Call this BEFORE ga4_run_report when combining unusual dimensions/metrics; drop or replace anything reported incompatible instead of retrying blind. Read-only.

Inputs: property (required), metrics, dimensions.

ga4_create_account_access_bindingA

[GA4 WRITE] Grant a user access to a GA4 account (needs analytics.manage.users). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: user (required), roles (required), confirm (required), accountId (required).

ga4_create_audienceA

[GA4 WRITE] Create an audience. Pass the filterClauses via body (see the Admin API Audience shape). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), body, description, +2 more.

ga4_create_calculated_metricA

[GA4 WRITE] Create a calculated metric (calculatedMetricId is required). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), calculatedMetricId (required), body, +3 more.

ga4_create_channel_groupA

[GA4 WRITE] Create a custom channel group. Pass groupingRule[] via body. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), body, description, +1 more.

ga4_create_custom_dimensionA

[GA4 WRITE] Create a custom dimension. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: scope (required), confirm (required), property (required), displayName (required), +3 more.

ga4_create_custom_metricB

[GA4 WRITE] Create a custom metric. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: scope (required), confirm (required), property (required), displayName (required), +4 more.

ga4_create_data_streamA

[GA4 WRITE] Create a data stream (web / Android / iOS). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: type (required), confirm (required), property (required), displayName (required), +4 more.

ga4_create_event_create_ruleA

[GA4 WRITE] Create an event-create rule on a data stream (server-side event creation). Supply eventConditions/parameterMutations via body. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), dataStreamId (required), body, +1 more.

ga4_create_expanded_data_setB

[GA4 WRITE] Create an expanded data set (GA4 360 only). Pass dimensionNames/metricNames/dimensionFilterExpression via body. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), body, description, +1 more.

ga4_create_key_eventA

[GA4 WRITE] Create a key event (conversion) on a GA4 property. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), eventName (required), body, +1 more.

ga4_create_measurement_protocol_secretA

[GA4 WRITE] Create a Measurement Protocol secret on a data stream. The response includes the secretValue — store it securely. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), displayName (required), dataStreamId (required).

ga4_create_propertyA

[GA4 WRITE] Create a new GA4 property under an account. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), timeZone (required), accountId (required), displayName (required), +2 more.

ga4_create_property_access_bindingA

[GA4 WRITE] Grant a user access to a GA4 property (needs analytics.manage.users scope). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: user (required), roles (required), confirm (required), property (required).

ga4_create_skadnetwork_conversion_value_schemaA

[GA4 WRITE] Create the SKAdNetwork conversion value schema on an iOS data stream. Supply postbackWindow settings via body. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), dataStreamId (required), body.

ga4_create_subproperty_event_filterA

[GA4 WRITE] Create a subproperty event filter (GA4 360). Supply applyToProperty + filterClauses via body. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), body.

ga4_custom_dimensions_listA

List custom dimensions configured on a GA4 property (parameter name, display name, scope: EVENT/USER/ITEM). Read-only.

Inputs: property (required), maxPages, pageToken.

ga4_custom_metrics_listA

List custom metrics configured on a GA4 property (parameter name, display name, measurement unit, scope, restricted-metric type). Read-only.

Inputs: property (required), maxPages, pageToken.

ga4_data_retention_getA

Get the data retention settings for a GA4 property (event data retention duration and whether retention resets on new activity). Read-only.

Inputs: property (required).

ga4_data_streams_listA

List data streams for a GA4 property (web, Android, iOS). Web streams include the measurement ID and default URI; app streams include package name / bundle ID. Use this to audit measurement IDs and stream config. Read-only.

Inputs: property (required), maxPages, pageToken.

ga4_delete_accountA

[GA4 DELETE] Soft-delete (trash) an entire GA4 account and all its properties. High blast radius — recoverable from the trash for a limited time. Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: confirm (required), accountId (required).

ga4_delete_account_access_bindingA

[GA4 DELETE] Revoke a user's access to an account (needs analytics.manage.users). Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_delete_calculated_metricB

[GA4 DELETE] Delete a calculated metric. Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_delete_channel_groupB

[GA4 DELETE] Delete a custom channel group. Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_delete_data_streamA

[GA4 DELETE] Delete a data stream (removes its measurement ID / firebase app id). Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_delete_event_create_ruleA

[GA4 DELETE] Delete an event-create rule. Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_delete_expanded_data_setA

[GA4 DELETE] Delete an expanded data set (360). Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_delete_key_eventA

[GA4 DELETE] Delete a key event (it reverts to a normal event). Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_delete_measurement_protocol_secretA

[GA4 DELETE] Delete a Measurement Protocol secret (revokes it). Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_delete_propertyA

[GA4 DELETE] Soft-delete (trash) a GA4 property. It is recoverable from the trash for a limited time, then permanently removed. Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: confirm (required), property (required).

ga4_delete_property_access_bindingA

[GA4 DELETE] Revoke a user's access to a property (needs analytics.manage.users). Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_delete_skadnetwork_conversion_value_schemaB

[GA4 DELETE] Delete the SKAdNetwork conversion value schema. Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_delete_subproperty_event_filterA

[GA4 DELETE] Delete a subproperty event filter (360). Requires GA4_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: name (required), confirm (required).

ga4_enhanced_measurement_getA

Get the enhanced measurement settings for a specific WEB data stream (scrolls, outbound clicks, site search, video engagement, file downloads, form interactions). Only valid for web streams. Served via the Admin API v1alpha surface (not yet in v1beta). Read-only.

Inputs: property (required), dataStreamId (required).

ga4_key_events_listA

List key events (formerly "conversion events") for a GA4 property — the current Admin API naming. Returns event name, counting method, and whether the event is deletable. Read-only.

Inputs: property (required), maxPages, pageToken.

ga4_properties_listA

List GA4 properties under a given parent account. Returns full property records (display name, time zone, currency, industry, service level). Read-only.

Inputs: accountId (required), maxPages, pageToken, showDeleted.

ga4_property_getB

Get a single GA4 property by ID, including display name, time zone, currency, industry category, and service level. Read-only.

Inputs: property (required).

ga4_run_realtime_reportA

Run a read-only GA4 Data API Realtime report (events in roughly the last 30 minutes). Useful to confirm a tag is firing right now during live QA. Read-only — never writes. Requires the analytics.readonly scope.

Inputs: metrics (required), property (required), limit, dimensions.

ga4_run_reportA

Run a read-only GA4 Data API report for a property over a date range. Returns dimension/metric rows (e.g. event counts by eventName). Useful for reconciling configured GTM/GA4 events against events GA4 actually reports (zero reported activity for a configured event is a red flag). Read-only — never writes. Requires the analytics.readonly scope.

Inputs: metrics (required), property (required), limit, offset, +4 more.

ga4_update_accountA

[GA4 WRITE] Update a GA4 account (displayName). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), displayName (required).

ga4_update_account_access_bindingA

[GA4 WRITE] Change a user's roles on an account (needs analytics.manage.users). The roles you pass replace the binding's roles. This API has no updateMask: the supplied fields replace the whole resource. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), roles (required), confirm (required).

ga4_update_attribution_settingsA

[GA4 WRITE] Update a property's attribution: reporting model, acquisition/other conversion lookback windows, and the Ads web-conversion export scope. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), reportingAttributionModel, adsWebConversionDataExportScope, +2 more.

ga4_update_audienceA

[GA4 WRITE] Update an audience (only displayName/description are mutable; filters are immutable). Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), body, updateMask, +2 more.

ga4_update_calculated_metricA

[GA4 WRITE] Update a calculated metric (formula/displayName/unit via fields or body). Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), body, formula, +3 more.

ga4_update_channel_groupA

[GA4 WRITE] Update a custom channel group (supply groupingRule/displayName via body). Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), body, updateMask.

ga4_update_custom_dimensionA

[GA4 WRITE] Update a custom dimension (parameterName and scope are immutable). Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), updateMask, description, +2 more.

ga4_update_custom_metricA

[GA4 WRITE] Update a custom metric (parameterName and scope are immutable). Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), updateMask, description, +2 more.

ga4_update_data_redactionA

[GA4 WRITE] Update a WEB data stream's client-side data redaction: email redaction and URL query-parameter redaction (with the parameter key list). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), dataStreamId (required), queryParameterKeys, +2 more.

ga4_update_data_retentionA

[GA4 WRITE] Update a property's event data retention (2/14/26/38/50 months; the longer options are 360-only) and whether it resets on new activity. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), eventDataRetention, resetUserDataOnNewActivity.

ga4_update_data_streamA

[GA4 WRITE] Update a data stream: displayName and (web) defaultUri ONLY. Cross-domain domains, unwanted referrals, internal traffic and session settings are Google tag settings with NO Admin API fields - never attempt them; direct the user to GA4 Admin > Data streams > Configure tag settings. Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), body, defaultUri, +2 more.

ga4_update_enhanced_measurementA

[GA4 WRITE] Update a WEB data stream's Enhanced Measurement: master streamEnabled plus per-signal toggles (scrolls, outbound clicks, site search + query params, video engagement, file downloads, form interactions, SPA page changes). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), dataStreamId (required), streamEnabled, +9 more.

ga4_update_event_create_ruleA

[GA4 WRITE] Update an event-create rule (conditions/mutations via body). Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), body, updateMask.

ga4_update_expanded_data_setA

[GA4 WRITE] Update an expanded data set (360). Supply fields via body. Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), body, updateMask.

ga4_update_google_signalsA

[GA4 WRITE] Turn Google Signals on or off for a property (cross-device + demographics collection - the user must confirm their privacy disclosures cover it). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: state (required), confirm (required), property (required).

ga4_update_key_eventA

[GA4 WRITE] Update a key event (e.g. its counting method or default value via body). Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), body, updateMask, +1 more.

ga4_update_measurement_protocol_secretA

[GA4 WRITE] Rename a Measurement Protocol secret. Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), displayName (required), updateMask.

ga4_update_propertyA

[GA4 WRITE] Update a GA4 property (displayName / timeZone / currencyCode / industryCategory). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), property (required), timeZone, updateMask, +3 more.

ga4_update_property_access_bindingA

[GA4 WRITE] Change a user's roles on a property (needs analytics.manage.users). The roles you pass replace the binding's roles. This API has no updateMask: the supplied fields replace the whole resource. Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), roles (required), confirm (required).

ga4_update_skadnetwork_conversion_value_schemaA

[GA4 WRITE] Update the SKAdNetwork conversion value schema. Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), body, updateMask.

ga4_update_subproperty_event_filterA

[GA4 WRITE] Update a subproperty event filter (360). Pass only the fields to change; updateMask is derived from them (override with an explicit updateMask for nested paths). Requires GA4_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), confirm (required), body, updateMask.

gtag_config_createA

[WRITE] Create a new GTM gtag config. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Pass the full resource as a JSON string in bodyJson.

Inputs: confirm (required), bodyJson (required), accountId (required), containerId (required), +1 more.

gtag_config_deleteA

[DELETE] Delete a GTM gtag config. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: confirm (required), accountId (required), containerId (required), workspaceId (required), +1 more.

gtag_config_getC

Get a specific GTM gtag config.

Inputs: accountId (required), containerId (required), workspaceId (required), gtagConfigId (required).

gtag_config_listA

List all GTM gtag configs in a workspace. Automatically follows pagination.

Inputs: accountId (required), containerId (required), workspaceId (required), maxPages, +1 more.

gtag_config_updateA

[WRITE] Update an existing GTM gtag config. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Pass the full resource as a JSON string in bodyJson.

Inputs: confirm (required), bodyJson (required), accountId (required), containerId (required), +3 more.

gtm_type_referenceA

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.

Inputs: kind, search, identify.

plan_server_migration_from_webA

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 }.

Inputs: accountId (required), containerId (required), workspaceId (required).

tags_add_ga4_event_parametersA

[WRITE] Add GA4 event parameters to a GA4 Event tag (type "gaawe"). Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Fetches the tag, APPENDS the parameters to its eventSettingsTable (the correct place for GA4 event parameters — top-level params are ignored by GA4 event tags), and saves the FULL tag so eventName/measurementId stay intact. A parameter whose name already exists has its value updated (not duplicated). Values may be GTM variables, e.g. {{Click Text}}.

Inputs: tagId (required), confirm (required), accountId (required), parameters (required), +2 more.

tags_createB

[WRITE] Create a new GTM tag. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Pass the full tag configuration as parameters.

Inputs: name (required), type (required), confirm (required), accountId (required), +8 more.

tags_deleteA

[DELETE] Delete a GTM tag. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true. This is irreversible in the workspace (the tag is removed from the workspace).

Inputs: tagId (required), confirm (required), accountId (required), containerId (required), +1 more.

tags_getC

Get details of a specific GTM tag.

Inputs: tagId (required), accountId (required), containerId (required), workspaceId (required).

tags_listA

List all GTM tags in a workspace. Automatically follows pagination to return all tags.

Inputs: accountId (required), containerId (required), workspaceId (required), maxPages, +1 more.

tags_type_profileA

Group a workspace's existing tags by TYPE and report, for each, the parameter keys those tags actually use. This is how to learn an UNDOCUMENTED tag type: Google does not publish the type codes or field names for GTM's ~68 built-in vendor templates (Criteo, Twitter, Pinterest, Quora and the rest), but a container that already uses one contains the answer, because that tag's own type and keys are definitionally correct. Use it to AUDIT what a container runs, to find an unfamiliar type code, and to copy a working shape before creating a similar tag. alwaysPresent lists keys found on every tag of that type, which is the closest thing to a required-field list for a template with no published schema. Read-only.

Inputs: accountId (required), containerId (required), workspaceId (required), type.

tags_updateA

[WRITE] Update an existing GTM tag (read-modify-write). Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. GTM's API replaces the WHOLE tag on update, so this tool first fetches the tag and only overlays the fields you pass — omitted fields are preserved. parameter is MERGED with the existing parameters BY KEY (a same-key param replaces, new keys are added, untouched keys are kept), so you will NOT wipe a GA4 tag's eventName/measurementId. To add GA4 EVENT parameters to a gaawe tag, prefer tags_add_ga4_event_parameters (event params live in the nested eventSettingsTable, which this generic parameter list cannot express).

Inputs: tagId (required), confirm (required), accountId (required), containerId (required), +9 more.

templates_createA

[WRITE] Create a new GTM template. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Pass the full resource as a JSON string in bodyJson.

Inputs: confirm (required), bodyJson (required), accountId (required), containerId (required), +1 more.

templates_deleteA

[DELETE] Delete a GTM template. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: confirm (required), accountId (required), templateId (required), containerId (required), +1 more.

templates_describe_fieldsA

Read the FIELDS a custom or Community Gallery template accepts, straight from the template's own source. Call this after templates_import_from_gallery and BEFORE tags_create, so the tag is built with that template's real parameter keys instead of guessed ones. Returns each field's name (the key for the tag's parameter array), its widget type, its label, whether it is required, and any fixed options. Also returns the template's tagType, so one call gives everything tags_create needs. Read-only. Only works for custom and gallery templates: GTM's ~68 BUILT-IN vendor templates carry no source, so for those use tags_type_profile against a container that already has one.

Inputs: accountId (required), templateId (required), containerId (required), workspaceId (required).

templates_getC

Get a specific GTM template.

Inputs: accountId (required), templateId (required), containerId (required), workspaceId (required).

templates_listA

List all GTM templates in a workspace. Automatically follows pagination.

Inputs: accountId (required), containerId (required), workspaceId (required), maxPages, +1 more.

templates_revertA

[WRITE] Revert workspace changes to a GTM template back to its last container-version state. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), templateId (required), containerId (required), +2 more.

templates_updateA

[WRITE] Update an existing GTM template. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Pass the full resource as a JSON string in bodyJson.

Inputs: confirm (required), bodyJson (required), accountId (required), templateId (required), +3 more.

transformations_createA

[WRITE] Create a new GTM transformation. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Pass the full resource as a JSON string in bodyJson.

Inputs: confirm (required), bodyJson (required), accountId (required), containerId (required), +1 more.

transformations_deleteA

[DELETE] Delete a GTM transformation. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: confirm (required), accountId (required), containerId (required), workspaceId (required), +1 more.

transformations_getC

Get a specific GTM transformation.

Inputs: accountId (required), containerId (required), workspaceId (required), transformationId (required).

transformations_listA

List all GTM transformations in a workspace. Automatically follows pagination.

Inputs: accountId (required), containerId (required), workspaceId (required), maxPages, +1 more.

transformations_revertA

[WRITE] Revert workspace changes to a GTM transformation back to its last container-version state. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), containerId (required), workspaceId (required), +2 more.

transformations_updateA

[WRITE] Update an existing GTM transformation. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Pass the full resource as a JSON string in bodyJson.

Inputs: confirm (required), bodyJson (required), accountId (required), containerId (required), +3 more.

triggers_createB

[WRITE] Create a GTM trigger. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), type (required), confirm (required), accountId (required), +15 more.

triggers_deleteB

[DELETE] Delete a GTM trigger. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: confirm (required), accountId (required), triggerId (required), containerId (required), +1 more.

triggers_getC

Get a specific GTM trigger.

Inputs: accountId (required), triggerId (required), containerId (required), workspaceId (required).

triggers_listB

List all GTM triggers in a workspace. Automatically follows pagination to return all triggers.

Inputs: accountId (required), containerId (required), workspaceId (required), maxPages, +1 more.

triggers_updateA

[WRITE] Update a GTM trigger (read-modify-write — omitted fields are preserved; parameter is merged by key). Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), triggerId (required), containerId (required), +16 more.

user_permissions_createA

[WRITE] Grant a user access to a GTM account (and optionally containers). Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), emailAddress (required), containerAccess, +1 more.

user_permissions_deleteA

[DELETE] Revoke a user's access to a GTM account. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: confirm (required), accountId (required), userPermissionId (required).

user_permissions_getB

Get a specific user permission record for a GTM account.

Inputs: accountId (required), userPermissionId (required).

user_permissions_listA

List all user permissions for a GTM account. Automatically follows pagination. Each record shows a user email plus their account and per-container access levels.

Inputs: accountId (required), maxPages, pageToken.

user_permissions_updateA

[WRITE] Update a user's account and/or container access levels. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Read-modify-write: an omitted accountPermission or containerAccess keeps the user's current value. containerAccess, when given, is the COMPLETE list (the API replaces the record): a container left out loses access. Removing access (noAccess at account or container level, or leaving a container out) is a revocation and also requires GTM_MCP_ENABLE_DELETES=true, the same as user_permissions_delete.

Inputs: confirm (required), accountId (required), userPermissionId (required), containerAccess, +1 more.

variables_createB

[WRITE] Create a GTM variable. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: name (required), type (required), confirm (required), accountId (required), +7 more.

variables_deleteA

[DELETE] Delete a GTM variable. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: confirm (required), accountId (required), variableId (required), containerId (required), +1 more.

variables_getC

Get a specific GTM variable.

Inputs: accountId (required), variableId (required), containerId (required), workspaceId (required).

variables_listB

List all user-defined GTM variables in a workspace. Automatically follows pagination to return all variables.

Inputs: accountId (required), containerId (required), workspaceId (required), maxPages, +1 more.

variables_updateA

[WRITE] Update a GTM variable (read-modify-write — omitted fields are preserved; parameter is merged by key). Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), variableId (required), containerId (required), +6 more.

versions_createA

[WRITE] Create a new GTM container version from a workspace (checkpoint). Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. This takes a snapshot of the workspace into a versioned checkpoint without publishing.

Inputs: confirm (required), accountId (required), containerId (required), workspaceId (required), +2 more.

versions_deleteA

[DELETE] Delete a GTM container version. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true. Cannot delete a currently published (live) version.

Inputs: confirm (required), accountId (required), containerId (required), containerVersionId (required).

versions_getB

Get the full contents of a specific GTM container version. Pass "live" as containerVersionId to get the currently live version.

Inputs: accountId (required), containerId (required), containerVersionId (required).

versions_listC

List all container version headers (summary) for a GTM container.

Inputs: accountId (required), containerId (required), maxPages, pageToken, +1 more.

versions_publishA

[PUBLISH] Publish a specific GTM container version to live. Requires GTM_MCP_ENABLE_PUBLISH=true and confirm=true. ⚠️ This immediately makes the version live in production.

Inputs: confirm (required), accountId (required), containerId (required), containerVersionId (required).

versions_set_latestA

[WRITE] Set a specific container version as the "latest" (synchronizes the default workspace with this version). Note: This does NOT publish. Use versions_publish to go live. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), containerId (required), containerVersionId (required).

versions_undeleteB

[WRITE] Undelete a previously deleted GTM container version. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: confirm (required), accountId (required), containerId (required), containerVersionId (required).

workspace_create_version_and_publishA

[PUBLISH] Create a new container version from a workspace and immediately publish it. Requires GTM_MCP_ENABLE_PUBLISH=true and confirm=true. ⚠️ This is the most powerful write operation — it goes live in production immediately.

Inputs: confirm (required), accountId (required), containerId (required), workspaceId (required), +2 more.

workspace_get_statusA

Get the status of a GTM workspace: the list of changed entities (workspaceChange) relative to the latest container version, plus any merge conflicts. Use this to review a change diff before creating a version or publishing.

Inputs: accountId (required), containerId (required), workspaceId (required).

workspace_quick_previewA

Generate a quick-preview (debug) link for a GTM workspace. This does NOT publish — it just enables preview mode. Returns a preview container version with any compilation errors.

Inputs: accountId (required), containerId (required), workspaceId (required).

workspace_resolve_conflictB

Resolve a merge conflict for a workspace entity. You supply the resolved entity body plus its type; the GTM API wraps it in an Entity envelope ({ "tag": {...} } / { "trigger": {...} } / …), which this tool builds for you. NOTE: This is a complex operation — review the GTM UI conflict resolution first.

Inputs: confirm (required), accountId (required), entityJson (required), entityType (required), +4 more.

workspaces_createA

[WRITE] Create a new workspace. Requires GTM_MCP_ENABLE_WRITES=true.

Inputs: name (required), confirm (required), accountId (required), containerId (required), +1 more.

workspaces_getC

Get details of a specific GTM workspace.

Inputs: accountId (required), containerId (required), workspaceId (required).

workspaces_listA

List all workspaces within a GTM container. Automatically follows pagination to return all workspaces.

Inputs: accountId (required), containerId (required), maxPages, pageToken.

workspace_syncB

Syncs a workspace to the latest container version by updating all unmodified workspace entities. Returns a list of merge conflicts if any.

Inputs: confirm (required), accountId (required), containerId (required), workspaceId (required).

zones_createA

[WRITE] Create a new GTM zone. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Pass the full resource as a JSON string in bodyJson.

Inputs: confirm (required), bodyJson (required), accountId (required), containerId (required), +1 more.

zones_deleteA

[DELETE] Delete a GTM zone. Requires GTM_MCP_ENABLE_DELETES=true and confirm=true.

Inputs: zoneId (required), confirm (required), accountId (required), containerId (required), +1 more.

zones_getC

Get a specific GTM zone.

Inputs: zoneId (required), accountId (required), containerId (required), workspaceId (required).

zones_listA

List all GTM zones in a workspace. Automatically follows pagination.

Inputs: accountId (required), containerId (required), workspaceId (required), maxPages, +1 more.

zones_revertA

[WRITE] Revert workspace changes to a GTM zone back to its last container-version state. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true.

Inputs: zoneId (required), confirm (required), accountId (required), containerId (required), +2 more.

zones_updateA

[WRITE] Update an existing GTM zone. Requires GTM_MCP_ENABLE_WRITES=true and confirm=true. Pass the full resource as a JSON string in bodyJson.

Inputs: zoneId (required), confirm (required), bodyJson (required), accountId (required), +3 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.1/5.0

    Scored across 203 tools

    Disambiguation3/5

    Most CRUD tools are cleanly separated by resource (tags_*, triggers_*, ga4_*), but the write surface has real overlap: tags_create competes with create_gtm_tracking_tag, create_server_tag, the dozen create_*_capi_server_tag tools, and templates_import_from_gallery, all of which produce tags. The descriptions explicitly try to steer the agent ("use this instead of tags_create"), which mitigates but doesn't remove the boundary problem, and 203 near-identical ga4_create_/update_/delete_ triples increase misfire risk at the margins.

    Naming Consistency3/5

    The dominant pattern is resource_verb (tags_create, folders_move_entities, ga4_update_property), but the server mixes in verb_noun forms (create_gtm_tracking_tag, create_meta_capi_server_tag, audit_container, export_container, plan_server_migration_from_web) and inconsistent resource grouping (workspace_sync / workspace_get_status alongside workspaces_list / workspaces_create). Readable throughout, but the convention shifts depending on which family a tool belongs to.

    Tool Count2/5

    203 tools is roughly four times the rubric's own ceiling, and the resulting context cost makes tool selection the dominant failure mode for an agent. Nearly every tool does map to a distinct GTM/GA4 API method rather than duplicating another, so it is an over-broad surface rather than a padded one — but the count is still inappropriate for practical use without progressive disclosure or sub-server splitting.

    Completeness4/5

    Coverage is genuinely deep: full CRUD for containers, workspaces, tags, triggers, variables, folders, versions, environments, permissions, clients, transformations, zones, templates and gtag configs, plus GA4 Admin CRUD, Data API reporting and per-platform server-side tag builders. The notable gap is read/list counterparts for several GA4 resources that have create/update/delete (audiences, channel groups, calculated metrics, event-create rules, access bindings) — an agent can mutate these but not enumerate them.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      MCP server for Google Tag Manager API v2, enabling programmatic management of accounts, containers, workspaces, tags, triggers, variables, and version workflows.
      34 npm
      16
      MIT
    • A
      license
      A
      quality
      B
      maintenance
      MCP server for the Google Tag Manager API v2, enabling natural-language management of containers, workspaces, tags, triggers, variables, and publishing. It handles OAuth authentication and built-in rate limiting for the strict GTM API quota.
      25
      536 npm
      1
      MIT
    • A
      license
      B
      quality
      C
      maintenance
      MCP server for Google Analytics 4 and Google Tag Manager with read and write access, providing 40 tools to manage GA4 reports, audiences, and GTM tags, triggers, and variables via natural language.
      40
      MIT
    • F
      license
      Not graded
      quality
      D
      maintenance
      MCP server for Google Tag Manager, offering tools to manage accounts, containers, workspaces, tags, triggers, and versions, with explicit confirmation for production-affecting actions.
      -