Api session event editor chatchannel add message

From Tygron Support wiki
Revision as of 15:22, 30 September 2026 by Frank@tygron.nl (talk | contribs) (Created page with "API Endpoint: api/session/event/editorchatchannel/add_message/ Description: Add a new Chat Message with optional Image or PDF content {|class=wikitable !Index !Importance !Type !Description !Values |- | 0 | REQUIRED | (CHAT_CHANNEL Integer ID) | Channel ID | |- | 1 | REQUIRED | (String) | Message | |- | 2 | OPTIONAL | (String) | Content Mime Type (optional) | |- | 3 | OPTIONAL | (byte or multiple values in array [a, b, c]) | Content bytes (optional) | |} ===Res...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

API Endpoint: api/session/event/editorchatchannel/add_message/

Description: Add a new Chat Message with optional Image or PDF content

Index Importance Type Description Values
0 REQUIRED (CHAT_CHANNEL Integer ID) Channel ID
1 REQUIRED (String) Message
2 OPTIONAL (String) Content Mime Type (optional)
3 OPTIONAL (byte or multiple values in array [a, b, c]) Content bytes (optional)

Response Codes

Response Code: Description
200 Integer (Returns the ID of the resulting response message.)
300-600 Codes Overview

Example POST

Curl example POST

curl 'https://engine.tygron.com/api/session/event/editorchatchannel/add_message/' -H 'Content-Type: application/json' -H 'Authorization: Bearer API_TOKEN' -d '[ 1, "Message" ]'

JavaScript example POST

var options = {
 method: "POST",
 headers: { "Content-Type": "application/json", "Authorization": "Bearer API_TOKEN" },
 body: '[ 1, "Message" ]'
};
fetch("https://engine.tygron.com/api/session/event/editorchatchannel/add_message/", options)
 .then(response => response.text())
 .then(result => console.log(result))
 .catch(error => console.log('error', error));