Skip to content

Create Message

Request

Posts a message to a conversation as the integration's bot or app, either as a new top-level message or as a reply in a thread. The response carries the message's uid, which update_message and delete_message accept.

Operation ID: chat_create_message

Security
BearerAuth
Path
conversationIdstringrequired

UID of the conversation (URL encoded). This is chat_message.conversation_uid in the OCSF model.

Query
metaArray of strings

Add metadata to the response by invoking meta functions. Documentation for meta functions is available. Not all meta functions are available at every endpoint.

Bodyapplication/jsonrequired
messagestringrequired

The plain-text content of the message.

parent_uidstring or null

UID of the top-level message to reply to, which starts or continues its thread. Omit to post a new top-level message.

mentionsArray of objects or null(UserReference)

Users to mention, at most 20. Each is notified and named once at the start of the message, in the provider's own mention format, which message then includes in the response and in reads.

curl
curl -i -X POST \
  'https://api.synqly.com/v1/chat/conversations/{conversationId}/messages' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "message": "string"
  }'

Responses

Bodyapplication/json
resultobject(ocsfv1.8.0chatmessageactivityChatMessageActivity)required

The message that was written.

messagesobject or null(MessagesResponse)

Additional messages from the service response that may be helpful to the client.

metaobject or null(MetaResponse)

Various metadata about the results organized by group, then type, then field.

Response
{ "result": { "activity_id": 0, "activity_name": "string", "actor": { … }, "category_name": "string", "category_uid": 0, "chat_message": { … }, "class_uid": 0, "count": 0, "duration": 0, "end_time": 0, "end_time_dt": "2019-08-24T14:15:22Z", "enrichments": [ … ], "message": "string", "metadata": { … }, "observables": [ … ], "raw_data": "string", "raw_data_hash": { … }, "raw_data_size": 0, "severity": "string", "severity_id": 0, "start_time": 0, "start_time_dt": "2019-08-24T14:15:22Z", "status": "string", "status_code": "string", "status_detail": "string", "status_id": 0, "time": 0, "time_dt": "2019-08-24T14:15:22Z", "timezone_offset": 0, "type_name": "string", "type_uid": 0, "unmapped": {} }, "messages": { "problems": [ … ] }, "meta": { "stats": { … }, "api": { … }, "mapping": { … } } }