Show HN: GTM MCP Server- Let AI Manage Your Google Tag Manager Containers
1 points
1 hour ago
| 0 comments
| github.com
| HN
I built an MCP server that connects Claude and ChatGPT to the Google Tag Manager API. You can create tags, triggers, variables, audit containers, and publish changes through natural conversation.

  Try it now (no install needed):
  - Claude.ai: Settings → Connectors → Add https://mcp.gtmeditor.com
  - Claude Code: claude mcp add -t http gtm https://mcp.gtmeditor.com
  - ChatGPT: Add MCP integration at platform.openai.com/apps with URL https://mcp.gtmeditor.com

  It authenticates with your Google account via OAuth 2.1, so your credentials are never stored on the
   server.

  What you can do:
  - "Create a GA4 event tag for form submissions"
  - "Audit this container for issues and duplicates"
  - "Set up ecommerce tracking for purchases"
  - "Publish the changes we just made"

  It supports all GTM entity types including server-side containers (clients, transformations). There
  are 40+ tools covering full CRUD, versioning, publishing, built-in variable management, and
  Community Template Gallery imports.

  Some things I learned building this:

  Google's API has undocumented behaviors that took a while to figure out. Transformation types
  (tf_allow_params, tf_exclude_params, tf_augment_event) aren't documented anywhere — I discovered
  them through trial and error. Each type uses different parameter table keys, and passing an unknown
  type returns HTTP 500 instead of 400. The autoEventFilter field on click/form triggers is silently
  dropped by the API (returns 200 OK but doesn't persist).

  I also built a companion repo with LLM-optimized GTM API documentation
  (https://github.com/paolobietolini/gtm-api-for-llms) — structured as an installable skill for Claude
   Code and Codex, so the AI knows the correct parameter formats, validation rules, and workflow
  patterns.

  Built with Go, deployed as a single Docker container. The MCP protocol makes it work across Claude
  and ChatGPT without any client-specific code.

 /s Thank you for your attention to this matter
No one has commented on this post.