# Google Tag Manager

### To install Zigpoll via Google Tag Manager, follow the steps below:

1. **Log into Google Tag Manager** and select your container.
2. In the left-hand menu, click **"Tags"** > **"New"**.
3. Click **"Tag Configuration"** > choose **"Custom HTML"**.
4. Paste the Zigpoll embed script into the HTML field:

   ```html
   <script type='application/javascript'>
     ;(function () {
       window.Zigpoll = {
         accountId: '$YOUR_ACCOUNT_ID'
       };

       var script = document.createElement("script");
       script.type = "text/javascript";
       script.charset = "utf-8";
       script.src = "//cdn.zigpoll.com/static/js/main.js";
       script.async = true;

       document.head.appendChild(script);
     }());
   </script>
   ```
5. Under **Triggering**, choose **"All Pages"** (or a specific page trigger if you only want Zigpoll to run on certain pages).
6. Click **"Save"** and name your tag (e.g., `"Zigpoll Embed"`).
7. Click **"Submit"** in GTM to publish your changes.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.zigpoll.com/integrations/google-tag-manager.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
