← API Index · How to use components

chat component #oo-chat

The shop system offers a tailored AI chat to support the sales process of a logged-on customer. The component renders the chat window as an overlay: questions and answers, a "waiting" indicator, and the conversation history which is loaded when the window opens. Answers may carry an action — typically a navigation target such as an item or group — which the component executes on the shop page.

The customer can delete the conversation, flag it for review by the shop (with a comment) and read the privacy information. The feature must be enabled and configured in the backend; see the use-built-in-chat skill for the API side, the configuration and the statistics.

How components are mounted, how switch values are resolved and how debug output is enabled is described in the use-js-components skill.

<div id="oo-chat" data-oo-shop-page="shop.html"></div>

You may create a popup version by wrapping this component's page in a page of its own.

component switches

Switch Default Description
oo-shop-page – Page hosting the shop component; navigation actions in answers lead there. If not provided, the current page is not left.

Events

Element Event Description
#oo-chat oo-chat-opened Fired when the chat overlay opens; the component uses it to load the conversation history.

debug options

Debug scope chat (enable with data-oo-debug="true" on the element or debug:chat:all+, see the skill):

Term Description
chat:all Requests and responses (including actions), history loading.