Skip to main content
DELETE
/
api
/
v1
/
chat-history
/
messages
/
{message_id}
Delete Message
curl --request DELETE \
  --url https://api.mor.org/api/v1/chat-history/messages/{message_id} \
  --header 'Authorization: <authorization>'
Delete a specific message. Permanently removes a message from a chat conversation.

Headers

Authorization
string
required
Bearer token (JWT) from OAuth2 login

Path Parameters

message_id
string
required
The ID of the message to delete

Response

Returns 204 No Content on successful deletion.
Irreversible: Deleting a message permanently removes it from the conversation. This action cannot be undone.
Sequence Integrity: When you delete a message, the sequence numbers of remaining messages are not changed. This preserves the chronological integrity of the conversation.
You can only delete messages from chats that belong to your account. Attempting to delete another user’s message will result in a 404 error.
Use Cases: Message deletion is useful for:
  • Removing sensitive information
  • Correcting errors in conversation history
  • Cleaning up test messages
  • Implementing “edit” functionality (delete + create new)