Groups: update
请求
HTTP 请求
PUT https://youtubeanalytics.googleapis.com/v2/groups
授权
此请求需要获得以下至少一个范围的授权(详细了解身份验证和授权)。
范围 |
https://www.googleapis.com/auth/yt-analytics.readonly |
查看 YouTube 分析工具为您的 YouTube 内容出具的报告。此范围可让您访问用户活动指标,例如观看次数和评分次数。 |
https://www.googleapis.com/auth/yt-analytics-monetary.readonly |
查看 YouTube 分析工具为您的 YouTube 内容出具的财务报告。此范围可让您访问用户活动指标以及估算的收入和广告效果指标。 |
https://www.googleapis.com/auth/youtube |
管理您的 YouTube 账号。在 YouTube Analytics API 中,频道所有者使用此范围来管理 YouTube 数据分析组和组内容。 |
https://www.googleapis.com/auth/youtubepartner |
查看和管理您在 YouTube 上的 YouTube 资产和关联内容。在 YouTube Analytics API 中,内容所有者使用此作用域来管理 YouTube 数据分析组和组项。 |
参数
下表列出了此查询支持的参数。列出的所有参数都是查询参数。
参数 |
可选参数 |
onBehalfOfContentOwner |
string
此参数只能在适当授权的请求中使用。注意:此参数仅适用于拥有和管理许多不同 YouTube 频道的 YouTube 内容合作伙伴。
onBehalfOfContentOwner 参数表示请求的授权凭据标识了代表参数值中指定的内容所有者行事的 YouTube 用户。有了它,内容所有者只需验证一次身份,即可访问自己所有的视频和频道数据,而无需为每个频道提供身份验证凭据。用户进行身份验证时使用的账号必须与指定的 YouTube 内容所有者相关联。 |
请求正文
在请求正文中提供组资源。对于该资源,您必须为以下属性指定值。请注意,该请求会更新 snippet.title
字段的值。
错误
API 不定义任何特定于此 API 方法的错误消息。不过,此方法可能仍会返回错误消息文档中列出的常规 API 错误。
试试看!
使用 APIs Explorer 调用此 API,并查看 API 请求和响应。
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2024-11-09。
[null,null,["最后更新时间 (UTC):2024-11-09。"],[[["This API method updates the metadata of a YouTube Analytics group, specifically allowing modification of the group's title."],["To use this API, you need to authorize with one of several scopes, including `yt-analytics.readonly`, `yt-analytics-monetary.readonly`, `youtube`, or `youtubepartner`, each providing different levels of access."],["The API endpoint for updating a group's metadata is `PUT https://youtubeanalytics.googleapis.com/v2/groups`."],["The request body must contain a group resource with values specified for the `id` and `snippet.title` properties."],["Content owners managing multiple channels can use the `onBehalfOfContentOwner` parameter to authenticate once and access data across all their channels."]]],["This API method updates a YouTube Analytics group's metadata, specifically the group's title. A PUT request is sent to `https://youtubeanalytics.googleapis.com/v2/groups`, requiring authorization via specific scopes for managing YouTube content and analytics. The request body must include a group resource with the `id` and the updated `snippet.title`. Content owners can use the `onBehalfOfContentOwner` parameter for channel management. Upon success, a group resource is returned.\n"]]