# Shopify

1. Log in to your Shopify Store Admin Panel

![](/files/zADGs33MUSrrkhWgOXu4)

&#x20; 2\. Select Online Store->Themes

![](/files/TBSPGPz69EfyvZcLOnBd)

3\. Select Actions->Edit Code

![](/files/qOVX8gV96MtEsJyC0Snu)

4\. In the `theme.liquid` file, paste the code snippet given below, just before the `</body>` tag

&#x20;  :warning: Replace the value of "window.\_\_GLU\_\_writeKey" with your API KEY

```
    {% comment %}__GLU__CODE__START{% endcomment %}
    {% if customer %}
      <script type="text/javascript">
        window.__GLU__userId = "{{ customer.id }}";
      </script>
    {% endif %}
    <script type="text/javascript">
      window.__GLU__writeKey = "<YOUR API KEY>";
    </script>
    <script type="text/javascript" src="https://assets.customerglu.com/scripts/sdk/v4.6/shopify.js"></script>
    {% comment %}__GLU__CODE__END{% endcomment %}
```

![](/files/goYwAeBOQYgbanZ5NiHu)

5\. Save the file

![](/files/WdjOUA4E5amNheIf64pn)

6\. Viola! You're all set!

Here's a video walkthrough of the process:

{% embed url="<https://youtu.be/4XtleYBRv-4>" %}


---

# 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.customerglu.com/sdk/shopify.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.
