Chat Thread - Delete Chat Message
删除消息。
DELETE {endpoint}/chat/threads/{chatThreadId}/messages/{chatMessageId}?api-version=2025-03-15
URI 参数
| 名称 | 在 | 必需 | 类型 | 说明 |
|---|---|---|---|---|
|
chat
|
path | True |
string |
消息 ID。 |
|
chat
|
path | True |
string |
消息发送到的线程 ID。 |
|
endpoint
|
path | True |
string |
Azure 通信资源的终结点。 |
|
api-version
|
query | True |
string |
要调用的 API 版本。 |
请求头
| 名称 | 必需 | 类型 | 说明 |
|---|---|---|---|
| Authorization | True |
string |
ACS(Azure 通信服务)用户访问令牌。 |
响应
| 名称 | 类型 | 说明 |
|---|---|---|
| 204 No Content |
请求成功。 |
|
| 401 Unauthorized |
Communication |
未授权。 |
| 403 Forbidden |
Communication |
已禁止。 |
| 429 Too Many Requests |
Communication |
请求过多。 |
| Other Status Codes |
Communication |
服务不可用。 |
安全性
Authorization
ACS(Azure 通信服务)用户访问令牌。
类型:
apiKey
在:
header
示例
Delete message
示例请求
DELETE https://contoso.westus.communications.azure.com/chat/threads/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/messages/1591768249318?api-version=2025-03-15
示例响应
{
"error": {
"code": "Unauthorized",
"message": "Request is not authorized."
}
}
{
"error": {
"code": "Forbidden",
"message": "User is not allowed to perform specified action."
}
}
{
"error": {
"code": "TooManyRequests",
"message": "Rate limit exceeded."
}
}
{
"error": {
"code": "ServiceUnavailable",
"message": "The server is currently unable to handle the request."
}
}