Method: spaces.members.patch
HTTP 请求
PATCH https://chat.googleapis.com/v1/{membership.name=spaces/*/members/*}
网址采用 gRPC 转码语法。
路径参数
参数 |
membership.name |
string
标识符。成员资格的资源名称,由服务器分配。 格式:spaces/{space}/members/{member}
|
查询参数
参数 |
updateMask |
string (FieldMask format)
必需。要更新的字段路径。使用英文逗号分隔多个值,或使用 * 更新所有字段路径。 目前支持的字段路径:
|
useAdminAccess |
boolean
可选。如果为 true ,则该方法会使用用户的 Google Workspace 管理员权限运行。 发起通话的用户必须是拥有管理聊天和聊天室对话权限的 Google Workspace 管理员。 需要 chat.admin.memberships OAuth 2.0 范围。
|
请求正文
请求正文包含一个 Membership
实例。
响应正文
如果成功,则响应正文包含一个 Membership
实例。
授权范围
需要以下 OAuth 范围之一:
https://www.googleapis.com/auth/chat.app.memberships
https://www.googleapis.com/auth/chat.admin.memberships
https://www.googleapis.com/auth/chat.import
https://www.googleapis.com/auth/chat.memberships
如需了解详情,请参阅授权指南。
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2024-11-12。
[null,null,["最后更新时间 (UTC):2024-11-12。"],[[["This method updates a Google Chat membership, allowing you to modify aspects like user roles within a space."],["It supports both app and user authentication, with an option for administrator privileges using `useAdminAccess`."],["Requires specifying fields to update with `updateMask` and includes optional use of administrator privileges."],["You need appropriate OAuth scopes such as `chat.app.memberships` or `chat.admin.memberships` for authorization."]]],["This documentation details updating a membership via a `PATCH` HTTP request to `https://chat.googleapis.com/v1/{membership.name=spaces/*/members/*}`. Key actions include setting the `membership.name` path parameter and using the `updateMask` query parameter to specify fields for updating, such as `role`. Optionally, `useAdminAccess` can grant administrator privileges. The request body defines the new membership details, and the response body will contain updated membership information. Multiple authorization scopes are required.\n"]]