Send Message to Chat

For sending external messages to a room we use the following endpoint.

Sending a message

POST https://api.jelou.ai/v1/rooms/<roomId>/message

This endpoint allows you to send messages to a Room.

Request Body

Name
Type
Description

messages*

array

Array of messages to be send

messages.**

object

Message object

senderId*

string

Bot.id || Bot.socketId || Operator.id || uuid generic

messages.*.type*

string

Type of message to send

messages.*.text

String

String of text

messages.*.mediaUrl

String

Url of the media to be sended

messages.*.id*

String

Id of message

Ok

You can review the types of messages available here: Message

// Example

curl --request POST \
  --url https://api.jelou.ai/v1/rooms/:roomId/message \
  --header 'Authorization: Basic <Token>' \
  --header 'Content-Type: application/json' \
  --data '{
	"senderId": "<ID>", // Bot.id || Bot.socketId || Operator.id || uuid generic
	"messages": [
		{
			"id": "<ID>", // uuid generic
			"text": "<Content message>",
			"type": "TEXT"
		}
	]
}'

Last updated