将用户或机器人移出群聊
DELETE
/open-apis/im/v1/chats/{chat_id}/members
自建应用商店应用
错误码
HTTP状态码 | 错误码 | 描述 | 排查建议 |
---|---|---|---|
400 | 232001 | Your request contains an invalid request parameter. | 参数错误,参考本文档检查输入参数。 |
400 | 232004 | Such an app does NOT exist. | 作为操作者的 app_id 不存在,请联系技术支持。 |
400 | 232006 | Your request specifies a chat_id which is invalid. | 无效的 chat_id,请检查chat_id是否正确。 |
400 | 232007 | Your request specifies a chat_id or user_id which is invalid. | 无效的 chat_id 或者 user_id。 |
400 | 232010 | Operator and chat can NOT be in different tenants. | 操作者和被操作的群组应该在同一租户下。 |
400 | 232014 | The token used in the request does NOT have the permissions necessary to complete the request. | 操作者没有权限进行该操作,请检查是否具有相应的权限。 |
400 | 232019 | The request has been rate limited. | 触发群限流,请控制请求的速度,详情参见频控策略。 |
400 | 232025 | Bot ability is not activated. | 应用需要开启机器人能力。 |
400 | 232027 | There are no valid members in the ID list specified in your request. | 加入群聊的成员为空或不存在有效的成员。 |
400 | 232029 | There are no available candidates for chat owner. | 没有可用的候选群主。 |
400 | 232033 | The operator or invited bots does NOT have the authority to manage external chats without the scope. | 没有权限操作外部群。 |
400 | 232034 | The app is unavailable or inactivated by the tenant. | 应用在本租户下未安装或未启用。 |
400 | 232076 | Can't kick chat owner. | 群主不能被踢出群。 |
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request DELETE 'https://open.feishu.cn/open-apis/im/v1/chats/oc_a0553eda9014c201e6969b478895c230/members' \
--header 'Authorization;' \
--header 'Content-Type: application/json' \
--data-raw '{
"id_list": [
"ou_9204a37300b3700d61effaa439f34295"
]
}'
响应示例响应示例
{
"code": 0,
"msg": "success",
"data": {
"invalid_id_list": [
"ou_9204a37300b3700d61effaa439f34295"
]
}
}
请求参数
Path 参数
chat_id
必需
示例值:
oc_a0553eda9014c201e6969b478895c230
Query 参数
member_id_type
可选
示例值:
open_id
Header 参数
Authorization
string
必需
默认值:
Bearer {{access_token}}
Content-Type
string
必需
默认值:
application/json; charset=utf-8
Body 参数application/json
返回响应
修改于 2023-01-13 02:22:44