删除消息。如需查看示例,请参阅删除消息。
支持以下类型的身份验证:
使用授权范围进行应用身份验证:
https://www.googleapis.com/auth/chat.bot
使用以下某个授权范围进行用户身份验证:
https://www.googleapis.com/auth/chat.messageshttps://www.googleapis.com/auth/chat.import(仅限导入模式聊天室)
使用应用身份验证时,请求只能删除发起调用的 Chat 应用创建的消息。
HTTP 请求
DELETE https://chat.googleapis.com/v1/{name=spaces/*/messages/*}
网址采用 gRPC 转码语法。
路径参数
| 参数 | |
|---|---|
name |
必需。消息的资源名称。 格式: 如果您为消息设置了自定义 ID,则可以将 |
查询参数
| 参数 | |
|---|---|
force |
可选。当 仅在以用户身份进行身份验证时适用。在以 Chat 应用身份进行身份验证时,此属性没有任何影响。 |
请求正文
请求正文必须为空。
响应正文
如果成功,则响应正文为空的 JSON 对象。
授权范围
需要以下 OAuth 范围之一:
https://www.googleapis.com/auth/chat.bothttps://www.googleapis.com/auth/chat.importhttps://www.googleapis.com/auth/chat.messages
如需了解详情,请参阅授权指南。