Chat Widget

All endpoints used by the chat widget embedded on your website.

The chat widget embeds your chatbot in your website. This group describes all endpoints the widget uses: availability check, public widget configuration, sending messages, conversation history, fetching new messages (for example after an agent has taken over), rating, usage events, and voice input and output.

`health` and `config` can be called without authentication so that the widget can initialise in the browser. All other endpoints expect the `widget_code` and the widget's embed token in the `X-Widget-Token` header. Zentor creates the widget during setup, stores the approved domains and provides you with the embed code containing the widget code and embed token. The server rejects calls from domains that are not approved with 403 `WIDGET_ORIGIN_DENIED` and answers calls for a deactivated widget with 404 `WIDGET_DISABLED`.

Your account's access rules (IP, country and domain rules) also apply. `message` is not idempotent: every repeated send creates another message and another reply.

GET/api/public/widget/healthGET/api/public/widget/config/:widget_codePOST/api/public/widget/messageGET/api/public/widget/historyPOST/api/public/widget/pollPOST/api/public/widget/ratingPOST/api/public/widget/trackPOST/api/public/widget/voice-transcribePOST/api/public/widget/voice-speak
← API Reference