Deluge Object Reference
The Deluge Object Reference documentation aims to give a detailed idea about the various elements of the Deluge functions in ConvoKraft. The core objects supported by ConvoKraft include the data access objects, input objects, and response objects. We will be discussing each of them in detail in this section.
Data Access objects
sessionData
The details about the current chat session of the client. This data will be available for all functions under the sessionData argument.
Deluge Data type | Availability |
---|---|
Map | In all functions |
This argument comprises the following keys:
Key name | Deluge data type | Description | Sample value |
---|---|---|---|
medium | Text | The mode of communication through which the user interacts with the bot. The possible values are call or chat. | chat |
client_host | Text | The nature of the client application that hosts the bot. The possible values are mobile or web. | web |
client_identifier | Text | The unique identifier of the client.
The URL of the web application, if client_identifier is web. The package name bundle identifier of the mobile application, if client_identifier is mobile. |
https://zylker.com |
client_data | Map | The data passed from the client to ConvoKraft at the start of the session. | { "user_email": "todd@hmail.com" } |
cache
The cache object acts as a temporary storage variable. Any data stored in this object in the form of key-value pair will be accessible across all the functions of the currently executing action until that action execution completes.
Deluge Data type | Availability |
---|---|
Map | In all functions |
broadcast
If you want your bot to remember any information related to the current executing action, the information can be stored in the broadcast object. This value will be retained even after the execution of the current action, and will be available for all subsequent actions until the current chat session is over. Subsequent actions can use this value, as required by business logic.
Deluge Data type | Availability |
---|---|
Map | In all functions |
messageData
The messageData object contains the custom message sent by the client for each transcript (a message in the bot conversation) request in the data key.
Deluge Data type | Availability |
---|---|
Map | In all functions |
Input Objects
param
The input values provided by the user for each static param would be captured under the objects with the same param name across the Deluge functions.
Deluge Data type | Availability |
---|---|
corresponding param's data type | In Context handler function and Action execution function |
previousParam
The previousParam object contains the param that was last prompted to the user. The latest reply of the user will be set as a value to this param.
Deluge Data type | Availability |
---|---|
corresponding param's data type | Only in Context Handler function |
Response Objects
card
The card can be used to give a visually formatted message as a reply to the user. A card is a collection of visual elements, such as tables and images. The value of this key is a list of map objects. Each map object represents an UI element in the card. A single card may contain more than one element of the same type. Every element in the card will be displayed one below the other in the reply message.
The inline formatting options such as Bold, Italic, Underline, Strikethrough, Link, and Highlight are applicable to the card elements as well. So, any of these above mentioned formatting options can be used in the text values in any of the below cards.
The following UI elements are supported in ConvoKraft’s reply message card :
Element | Format |
---|---|
Note |
|
Title |
|
List - Bullet & Numbered |
|
Table |
|
Image |
|
File |
|
Contact card |
|
Link |
|
Button |
|
Last Updated 2023-07-20 13:39:11 +0530 +0530
Yes
No
Send your feedback to us