> For the complete documentation index, see [llms.txt](https://docs.chathq.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.chathq.io/api-and-developer-docs/overview.md).

# Overview

<table data-card-size="large" data-view="cards" data-full-width="false"><thead><tr><th></th><th></th><th></th><th data-type="content-ref"></th><th data-hidden data-card-target data-type="content-ref"></th><th data-hidden data-card-cover data-type="files"></th></tr></thead><tbody><tr><td><a href="/pages/Hy382xvKfFoHzU4B8Kmc"><mark style="color:purple;"><strong>JavaScript API</strong></mark></a></td><td>The Engagement Widget JavaScript API allows JavaScript code running on your site or app to interact with the Engagement Widget.</td><td></td><td></td><td></td><td></td></tr><tr><td><strong>Custom Tracking &#x26; Analytics</strong></td><td>Connecting widget analytics to 3rd party data tracking software like Google Analytics and Facebook Ad Events.</td><td><ul><li><a href="/pages/S4p2Fy7Idv71MhKePehy">Widget Events in Google Analytics</a></li><li><a href="/pages/YZBAO1BtHujnxJXa67UD">Tracking Events from Facebook Ads</a></li></ul></td><td></td><td></td><td></td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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.chathq.io/api-and-developer-docs/overview.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.
