Skip to content

Delete Message



DELETE /admin/message

Deletes one or more messages in a conversation. The deletion behavior depends on the type field:

  • "myself": messages are deleted only for the sender
  • "all": messages are deleted for all participants, and a real-time notification is sent to online users in the conversation.
{ Admin-Api-Key: {{ HTTP_ADMIN_API_KEY }} }

Content-Type: application/json

{
"organizationId": "680a2fae96cc69d78861f101",
"senderId": "63480e68f4794709f802a2fa",
"messageDelete": {
"cid": "63077ad836b78c3d82af0815",
"ids": ["63077ad836b78c3d82af0812", "63077ad836b78c3d82af0813"],
"type": "myself"
}
}
FieldTypeDescription
organizationIdstringOrganizationId performing request
senderIdstringUser ID performing the deletion
messageDelete.cidstringConversation ID
messageDelete.idsarray[string]List of Message IDs to delete
messageDelete.type"myself" | "all"Deletion type: for sender only (myself) or for all users (all)
{
"success": true
}
{
"message_delete": {
"cid": "63077ad836b78c3d82af0815",
"ids": ["63077ad836b78c3d82af0812", "63077ad836b78c3d82af0813"],
"type": "all",
"from": "634ec51c0b65918393dca5bf"
}
}