title: How to trigger Google Tag Manager script from java code
body: <p>I need to automate web analytics and for that I need to trigger "Google Tag Manager" GTM script from java code.
  e.g.</p>
  
  <ul>
  <li>User goes to <a href="https://www.etsy.com/" rel="nofollow noreferrer">https://www.etsy.com/</a></li>
  <li>User looks for script of GTM which is dataLayer</li>
  </ul>
  
  <p><strong><code>(window,document,'script','dataLayer','GTM-KWW5SS');</code></strong></p>
  
  <ul>
  <li>I can goto chrome console and type <strong>dataLayer</strong>, press ENTER key to see the values</li>
  </ul>
  
  <p>How can I do this from Java code ?</p>