Post to Chat
Table of Contents
Note: This task is applicable to all Zoho Services, except Zoho Creator.
Overview
This task is used to post a message to any member in your organization, using the recipient's chat ID in Zoho Cliq.
This task is based on Zoho Cliq API - Post message in a chat.
Syntax
<variable> = zoho.cliq.postToChat(<chat_ID>, <message>, <connection>);
where,
Parameter | Data type | Description |
<variable> | KEY-VALUE | is the variable which will hold the response returned by Zoho Cliq. |
<chat_id> | TEXT (or) NUMBER | is the chat ID of the recipient. |
<message> | TEXT | is the message to be posted. The different types of content that can be posted in a chat window can be found here. |
<connection> | TEXT | specifies the link name of the Zoho Cliq connection. Note:
|
Example
The following script posts a message Hello, in the chat window of the intended recipient.
response = zoho.cliq.postToChat("2230642502702656126","Hello", "cliq_connection");
(or)
response = zoho.cliq.postToChat("2230642502702656126",{"text":"Hello"}, "cliq_connection");
where,
response
"2230642502702656126"
"text"
"Hello"
"cliq_connection"
Sample Response
The success response returned is of the following format.
Related Links
- Zoho Cliq API
- Common error codes can be viewed here