How to configure AI Chat Agents

How to configure AI Chat Agents

This document provides instructions for configuring AI chat agents in x-bees and Collaboration 7, with integrations available for Generative AI, Webhooks, AWS SQS and Dialogflow CX.

Developer documentation: Wildix Developer Docs .

Created: August 2024

Updated: April 2026

Permalink: https://wildix.atlassian.net/wiki/x/4APOAQ

Introduction

AI chat agents are powerful tools for managing customer interactions, designed to efficiently handle a wide range of requests and tasks. You can integrate the following AI chat agents with x-bees and Collaboration 7: 

  • Generative AI lets you create highly interactive and intelligent chat agent without any coding expertise. You just need to provide clear instructions and the AI model generates dynamic, context-aware responses.

  • Webhooks provide real-time communication by sending HTTP POST requests to a specified URL when certain events occur. This allows for immediate processing and response, making it ideal for time-sensitive interactions

  • AWS SQS offers a reliable and scalable solution for message queuing, ensuring that even high volumes of chat events are handled efficiently. It decouples the processing of events, allowing your AI chat agent to manage requests asynchronously and at scale

  • Dialogflow CX enhances the natural language understanding (NLU) of your AI chat agent, enabling complex and multi-turn conversations with users. This integration is well-suited for advanced dialog management and contextual responses

Note: Setting up AI chat agents with Webhooks, AWS SQS, Dialogflow CX requires some technical knowledge, or a specialist who meets this requirement and can peform the setup. 

Requirements

AI Chat Agent Creation

Note: Some features described in this documentation will be available in production soon.

It is possible to set up to 50 AI chat agents per organization.

To create an AI chat agent, proceed with the following steps:

  • Navigate to WMS -> PBX -> Integrations -> Cloud integrations

  • In the AI section, choose Chat AI Agents

x-bees bots-WMS.jpg
  • Select Chat AI Agents and click Add new agent

x-bees bots-Add new chatbot.png
  • Enter a name for your Chat AI agent

  • Choose agent category name

  • Upload a picture (optional)

  • Select the integration type for processing chat events:

    • Generative AI 

    • Webhook

    • AWS SQS

    • Dialogflow CX

x-bees bots-Create a chat bot.png
  • Configure the chosen integration type (see instructions below) 

  • To let users interact with the bot, proceed to the Visibility Settings and enable the Allow users to find the bot using search checkbox:

allow-users-to-find-bot-using-search.png
  • Click Add to save and activate your AI chat agent

Generative AI

When setting up Generative AI as the integration type, it's important to create a clear and detailed prompt for the AI chat agent, as this greatly affects its performance and reliability. Since prompt engineering is an ongoing process, you can improve prompt effectiveness over time based on user feedback.

You can organize your system prompts into clear sections, addressing a specific aspect of the AI chat agent's behavior. For example:

  • Identity: describe the AI agent’s persona, defining its role and setting the interaction context.

  • Style: provide instructions on how the agent should communicate with users, including such details such as tone, language, and level of formality.

  • Response Guidelines: outline the desired structure of the AI’s responses, including any required formats and limitations, if any.

  • Task and Goals: clarify the tasks the agent is expected to perform and the steps it should take to achieve its objectives.

generative-ai-chat-agent.png

After creating the agent, to create API key click Create API Key button:

generative-ai-create-new-api-key.png
  • Enter a name for identification

  • Click Create and copy the secret using the Click to reveal button:

generative-ai-click-to-reveal-api-key.png

 

Add a tool

In case of Generative AI integration type, you can enhance capabilities of your AI chat agent with the following tools:

  • Third-party Function: the option was deprecated and replaced with Wilma Tools → Webhook feature.

Note:

  • Current third-party functions in existing Chat Agents continue to work. But in case you need to edit/update them, you need to replace them with Webhook tools:

  1. Create a new Webhook tool within Wilma tools

  2. Add the Webhook tool to the Chat Agent

  3. Remove the old third-party function from the Chat Agent

  • Handover: allows to transfer the chat to an agent or a service

  • Delegate: allows to delegate user’s request to another AI chat agent

  • Suggestions: gives possibility to configure quick replies 

add-tool-suggestions.png

Note: For WhatsApp, button titles created using the Suggestions tool have a 20-character limit.

generative-ai-tools.png

To add a tool:

  1. Click Add Tool -> choose the necessary option

  2. Fill out the required fields
    For example, for Handover, you need to provide description (1), choose destination – whether you wish to handover the conversation to an agent or a service (2), select the responsible agent (3) and choose if the AI chat agent has to generate reply and perform handover, generate a reply as instructed (you need to provide instructions) or handover immediately, without reply (4):

handover-tool.png

You can add multiple tools for one AI chat agent. If you need to delete a tool, click the delete icon:

delete-tool.png
  1. Set up Advanced Configuration:

  • Model: choose the preferred AI model for generating responses. If no model is selected, the system uses the default model.

chat-bot-model.png

Knowledge Bases

The Knowledge Base allows you to collect and search information from different sources, such as files, Confluence pages, and Google Drive folders. See more details in the documentation https://wildix.atlassian.net/wiki/spaces/DOC/pages/1906016259.

To add Knowledge Base to a Chat Agent:

  • Navigate to the Capabilities section

  • Click Add tool

add-tool-chat-agent.png
  • In the window that opens up, navigate to the Knowledge Bases section:

knowledge-base.png
  • To add a knowledge base, just click on it. The knowledge base gets added to the Capabilities list:

knowledge-base-added.png
  • To expand it, click the down-arrow button:

expand-knowledge-base.png
  • There, you can provide additional instructions when the Voice Agent should use the knowledge base:

knowledge-base-instructions.png

Wilma Tools

Wilma Tools includes a set of tools for AI Agents, e.g. sending message, SMS, email, setting up Webhook, etc. which can extend their functionality.

To add Wilma Tool to a Chat Agent:

  • Navigate to the Capabilities section

  • Click Add tool

  • In the window that opens up, navigate to the section below Knowledge Bases section (if available). The available Wilma Tools are displayed split into the relevant categories

wilma-tools.png
  • Select the necessary tool and click on it. The tools get added under the Capabilities section:

capabilities-wilma-tools.png
  • Click on the down arrow icon to expand the tool:

variables-wilma-tools.png
  • Configure the Variables section by selecting how each variable should be provided:

    • Auto – AI automatically detects the value based on the variable name

    • Guided – provide additional instructions if necessary how the agent should fill message variable

    • Predefined – enter static text for message variable

wilma-tools-variables.png

 

Webhook

When configuring a Webhook as the integration type, you need to specify the following fields:

  1. Target:

  • Enter the URL that the Webhook will use to send POST requests

This URL should be publicly accessible and secured with a valid HTTPS certificate. It should be designed to accept HTTP POST requests with JSON payloads and respond with status codes in the 200-299 range as quickly as possible.

It's important to ensure that your Webhook endpoint can handle multiple identical calls in case of retries due to network or server failures. AI chat agent platforms may attempt to redeliver event payloads up to 3 times if the initial delivery is unsuccessful.

  1. Secret:

  • The secret ensures that only requests from Wildix system are accepted, preventing unauthorized access or potential security breaches. The secret key is included in the headers of each POST request sent by the Webhook. Your server should validate this key to ensure the request is legitimate before processing the event data

x-bees bots-Webhook.jpg
  1. After creating the bot, click Create API Key button to create API key:

  • Enter a name for identification

  • Click Create and copy the secret using the Click to reveal button

generative-ai-create-new-api-key.png

You can configure a test Webhook bot using these instructions: https://docs.wildix.com/guides/2024/07/20/chatbot-simple/.

AWS SQS

When configuring AWS SQS as the integration type, you need to specify the following fields to establish the connection between x-bees/ Collaboration 7 and your AWS SQS queue:

  1. Target:

  • Enter the URL of your SQS queue. This is where the chat events are sent, for example, https://sqs.amazonaws.com/11111/wildix-events-queue

  1. Key:

  • Enter your AWS Access Key ID here. This key is used to sign the request that x-bees/ Collaboration 7 sends to AWS SQS

  1. Secret:

  • Enter your AWS Secret Access Key. This secret is paired with your AWS Key to securely sign the requests

x-bees bots-AWS SQS.jpg
  1. After creating the bot, click Create API Key to create API key:

  • Enter a name for identification

  • Click Create and copy the secret using the Click to reveal button

Dialogflow CX

To configure Dialogflow CX as the integration type, you'll need to provide specific information to establish the connection between x-bees/ Collaboration 7 and your Dialogflow CX agent. The fields you need to fill in are as follows:

  1. Private Key:

  • Upload the private key file associated with your Google Cloud service account

  1. Location:

  • Enter the region where your Dialogflow CX agent is deployed. This is typically a region-specific identifier, for example, us-central1, europe-west1

  1. Language:

  • Specify the language that your Dialogflow CX agent will use to understand and respond to user inputs. The language code should match the languages supported by your Dialogflow CX agent, for example, en for English, es for Spanish

  1. Agent ID:

  • Enter the unique identifier of your Dialogflow CX agent. This ID links your AI chat agent to the specific Dialogflow CX agent that you’ve configured in Google Cloud

x-bees bots-Dialogflow CX.jpg

It is possible to set up a handover to allow a AI chat agent to transfer a chat to one or multiple agentshttps://docs.wildix.com/docs/messaging/bots/integrations/dialogflow.

Access Settings

For Generative AI and Dialogflow CX integration types, you can configure Access Settings:

access-settings.png

In Access Settings, you can choose if you what to make AI chat agent available to everydoby or restrict access to internal users only (option Organization). By default, chat agent is available to everybody. 

access-settings-everybody-or-organization.png

Processing Predefined Replies 

Chatbots can display and react to predefined reply options. The reply options include buttons that allow users to perform actions, such as opening a URL or triggering specific responses (e.g., "Yes," "No"). Based on user selection, when a button is pressed, the chatbot can update messages, replacing or modifying previous responses (e.g. removing the "Yes," "No" options after user selects Yes/ No). 

To configure predefined replies, you can use Conversations API (documentation: https://docs.wildix.com/api-reference/rest/x-bees/conversations/#/operations/SendMessage and https://docs.wildix.com/api-reference/typescript/xbees-conversations-client/xbees-conversations-client.sendmessagecommand/) or integrate Dialogflow to define response options. 

Also, in case you are using Welcome message with quick replies for website widget and the conversation is routed to chat agent, you can configure the chat agent (e.g. by creating necessary prompts with Generative AI integration type) to provide responsed based on user selection.

Chat AI Agent application

Conversation with Chat AI Agent

You can find the Chat AI Agents in Search under the Bots category

When you click on it, one-on-one conversation with the chat agent opens and you can send your request: 

If you wish to have group conversation with a Chat AI Agent, create the conversation and invite the AI Agent: 

Website Widget 

Once you set up a bot, you can configure a website widget to enable customer interaction with the bot. 

  1. Go to WMS -> PBX -> Integrations -> Cloud integrations

  2. Choose Kite and select the necessary widget or create a new one

  3. Under Routing settings, select bot option and choose a specific bot from the list

kite-select-bot.png
  1. Click Save to apply the settings

  2. Embed the widget on your website

For more details, check out the guide Website widget configuration.

Chat traces

With The View Traces feature, you can closely monitor chatbot activity, including errors, tool usage, message flow, and detailed pipeline execution.

To access View Traces, follow the steps below:

  1. Go to WMS -> PBX -> Integrations -> Cloud integrations

  2. Select Chat AI Agents

  3. Click the trace diagram on the right side of the AI Agent card to open and view the traces

view-traces.png

 

  1. The Chat Traces page will open, displaying a list of all bot activity. Each trace entry includes the following columns: Trace ID, Service, User Name, Status, Duration, and Date.

  2. You can use search field to find specific trace.

chat-traces.png

To view detailed information about a specific trace follow these steps:

  1. Click on any trace entry in the list

  2. In the opened Details panel, click Request in the Pipeline section

A window will appear with full technical details, including:

  • URL

  • Headers

  • Body

  • Result