LiveCuepoints: insert
此方法已弃用,取而代之的是 liveBroadcasts.cuepoint
方法。
在直播中插入广告插入点。目前,使用此方法收到的请求必须有与 YouTube 内容所有者相关联的帐号授权。
请求
HTTP 请求
POST https://www.googleapis.com/youtube/partner/v1/liveCuepoints
授权
此请求需要获得以下至少一个范围的授权(详细了解身份验证和授权)。
范围 |
https://www.googleapis.com/auth/youtubepartner |
参数
下表列出了此查询支持的参数。列出的所有参数都是查询参数。
参数 |
必需参数 |
channelId |
string
channelId 参数用于标识拥有插入点的广播所属的频道。 |
onBehalfOfContentOwner |
string
onBehalfOfContentOwner 参数用于标识用户代表的内容所有者。 |
请求正文
在请求正文中提供 liveCuepoint 资源。对于相应资源:
-
您必须为以下属性指定值:
broadcastId
settings.cueType
-
您可以为以下属性设置值:
settings.offsetTimeMs
settings.walltime
settings.durationSecs
错误
下表列出了该 API 为响应对此方法的调用可能返回的错误消息。如需了解详情,请参阅错误消息文档。
错误类型 |
错误详情 |
说明 |
invalidValue (400) |
conflictingTimeFields |
只能指定 offsetTimeMs 和 walltime 中的一个。 |
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2023-02-22。
[null,null,["最后更新时间 (UTC):2023-02-22。"],[[["This API method for inserting a cuepoint into a live broadcast has been deprecated and is now replaced by the `liveBroadcasts.cuepoint` method."],["Using this method requires authorization with the `https://www.googleapis.com/auth/youtubepartner` scope and being associated with a YouTube Content Owner."],["The required parameters for this method are `channelId`, which identifies the channel owning the broadcast, and `onBehalfOfContentOwner`, which identifies the content owner."],["The request body must include a `liveCuepoint` resource with specified values for `broadcastId` and `settings.cueType`, and can optionally set `settings.offsetTimeMs`, `settings.walltime`, or `settings.durationSecs`."],["The API returns a `liveCuepoint` resource upon success, and an error, such as `invalidValue (400)` for `conflictingTimeFields` is returned if there are any errors."]]],[]]