# Installing widgets

## Install widgets SDK&#x20;

1\. Log in to your ProdCamp account. Go to the product details page of a product which widget you want to embed.

<img src="/files/N44hT1z03qjl6sAwj5NM" alt="" width="375">

2\. Select the right product.

<img src="/files/K4LseABs3FJ3bSqdn0FI" alt="" width="375">

3\. Click on the "**Widget"**

<figure><img src="/files/uR1nSEhRUXRabTick21K" alt="" width="375"><figcaption></figcaption></figure>

3\. Click on the "**Generate**" button to generate the script code that you should insert at the end of the **body** tag on your page.

It will look something like this:

<figure><img src="/files/dExTOPgcJsdV7JhChSHV" alt="" width="375"><figcaption></figcaption></figure>

```javascript
<script>
!function(t, e, a, n) {
    function o() {
        if (!e.getElementById(a)) {
            var t = e.getElementsByTagName(n)[0],
                o = e.createElement(n);
            o.type = "text/javascript";
            o.async = !0;
            o.src = "https://cdn.prodcamp.com/js/prdcmp-sdk.js";
            t.parentNode.insertBefore(o, t)
        }
    }
    if ("function" != typeof t.ProdCamp) {
        var c = function() {
            c.args.push(arguments)
        };
        c.p = "{your_product_id}";
        c.args = [];
        c.t = t.ProdCampSettings && t.ProdCampSettings.token;
        c.f = true;
        t.ProdCamp = c;
        "complete" === e.readyState ? o() : t.attachEvent ? t.attachEvent("onload", o) : t.addEventListener("load", o, !1)
    }
}(window, document, "prodcamp-js", "script");
</script>

```

After the system generates the script code - click on the text area and the code will be copied to your clipboard. Insert this code at the end of the **`<body>`** tag on your page, right before the **`</body>`** closing tag.

## Invoke a specific widget initialization function

Now you can invoke a command using the **`ProdCamp`** global function and initiate some specific widget, how to do it you can read in one of the following articles:

* [Feedback widget](/widgets/feedback-widget.md)
* [Changelog widget](/widgets/changelog-widget.md)
* [NPS widget](/widgets/nps-widget.md)


---

# 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://help.prodcamp.com/widgets/installing-widgets.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.
