Note
Access to this page requires authorization. You can try signing in or .
Access to this page requires authorization. You can try .
Chat Thread - Delete Chat Message
- Service:
- Communication
- API Version:
- 2025-03-15
Deletes a message.
DELETE {endpoint}/chat/threads/{chatThreadId}/messages/{chatMessageId}?api-version=2025-03-15
URI Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
|
chatMessageId
|
path | True |
string |
The message id. |
|
chatThreadId
|
path | True |
string |
The thread id to which the message was sent. |
|
endpoint
|
path | True |
string |
The endpoint of the Azure Communication resource. |
|
api-version
|
query | True |
string |
Version of API to invoke. |
Request Header
| Name | Required | Type | Description |
|---|---|---|---|
| Authorization | True |
string |
An ACS (Azure Communication Services) user access token. |
Responses
| Name | Type | Description |
|---|---|---|
| 204 No Content |
Request successful. |
|
| 401 Unauthorized |
CommunicationErrorResponse |
Unauthorized. |
| 403 Forbidden |
CommunicationErrorResponse |
Forbidden. |
| 429 Too Many Requests |
CommunicationErrorResponse |
Too many requests. |
| Other Status Codes |
CommunicationErrorResponse |
Service unavailable. |
Security
Authorization
An ACS (Azure Communication Services) user access token.
Type:
apiKey
In:
header
Examples
Delete message
Sample request
DELETE https://contoso.westus.communications.azure.com/chat/threads/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/messages/1591768249318?api-version=2025-03-15
Sample response
- Status code:
- 204
- Status code:
- 401
{
"error": {
"code": "Unauthorized",
"message": "Request is not authorized."
}
}
- Status code:
- 403
{
"error": {
"code": "Forbidden",
"message": "User is not allowed to perform specified action."
}
}
- Status code:
- 429
{
"error": {
"code": "TooManyRequests",
"message": "Rate limit exceeded."
}
}
- Status code:
- 503
{
"error": {
"code": "ServiceUnavailable",
"message": "The server is currently unable to handle the request."
}
}
