gtm-debug-agent

Automate GTM debugging by validating tag firing, dataLayer events, and consent mode.

Updated Dec 15, 2025
One-click install
npx skills add https://github.com/jhillbht/hackathon-clipper-program --skill gtm-debug-agent
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gtm-debug-agent
Source: https://github.com/jhillbht/hackathon-clipper-program/tree/main/gtm-debug-agent
Command: npx skills add https://github.com/jhillbht/hackathon-clipper-program --skill gtm-debug-agent

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires pillow, and includes scripts (resource) and references (resource) components.

What problem does it solve?

Manually debugging Google Tag Manager (GTM) configurations is a complex, time-consuming, and error-prone process. Verifying tag firing, dataLayer events, and consent mode across various user actions requires meticulous attention and often leads to missed issues. This Skill automates the entire GTM debugging workflow, ensuring your tracking is always accurate.

Core Features & Use Cases

  • Automated GTM Debugging: Connects to GTM Preview mode, navigates to target URLs, executes test actions, and captures comprehensive data across Tags, Variables, Consent, and dataLayer.
  • Visual Monitoring & Annotation: Automatically takes screenshots of the GTM debug panel and annotates successes (e.g., fired tags, matched variables) with red arrows for clear, visual reports.
  • MCP Integration: Seamlessly integrates with google-tag-manager and Stape MCP servers for end-to-end container build validation and server-side tagging verification.
  • Actionable Reports: Generates detailed pass/fail reports with fix recommendations, saving hours of manual analysis and accelerating issue resolution.
  • Use Case: You've just implemented a new purchase event in GTM. Instead of manually clicking through the checkout flow and inspecting the debug panel, simply tell the AI: "Debug GTM-XXXXXXX on https://example.com/checkout, expecting 'purchase' event and 'GA4 - Purchase' tag to fire after clicking '#buy-button'". The skill will run the test, capture results, and provide an annotated report.

Quick Start

Ask the AI: Debug GTM-XXXXXXX on https://example.com/product-page, expecting 'page_view' event and 'GA4 - Page View' tag to fire.

Frequently Asked Questions about gtm-debug-agent

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate Google Tag Manager debugging across multiple test scenarios?

GTM debugging automation connects to GTM Preview mode, executes test actions on target URLs, and captures tag firing, dataLayer events, and consent validation results in a single workflow. This eliminates manual inspection of the debug panel and reduces verification time from hours to minutes.

Can I validate dataLayer events and tag firing automatically during QA testing?

Yes. The Skill automates dataLayer schema validation, tag firing assertions, and consent mode checks by parsing the GTM debug panel during browser automation. It generates structured reports with pass/fail results and fix recommendations for each test action.

How do I integrate GTM debugging with MCP servers like Stape?

The Skill integrates with google-tag-manager and Stape MCP servers to orchestrate end-to-end container build validation and server-side tagging verification. This enables unified debugging across client-side and server-side GTM configurations in a single workflow.

What's the best way to document GTM issues with visual evidence?

The Skill automatically captures annotated screenshots of the GTM debug panel, marking fired tags and matched variables with visual indicators. Reports include actionable fix recommendations, creating clear documentation for debugging and stakeholder communication.

Do I need browser automation skills to debug GTM configurations?

No. The Skill handles browser automation orchestration internally. You provide the GTM container ID, target URL, test actions, and expected events; the Skill executes the workflow, captures results, and generates the report without requiring automation code.

Can GTM debugging automation work with consent mode validation?

Yes. The Skill validates consent mode alongside tag firing and dataLayer events in a single test run. It captures consent state changes and verifies that tags fire only when consent requirements are met, ensuring compliance and tracking accuracy.