接口功能介绍
用户可在点播模式下通过本接口获得一个视频条目的全部截图列表。
接口约束
本接口的单用户QPS限制为20次/秒。超过限制,API调用会被限流,这可能会影响您的业务,请合理调用。
URI
GET /xstore-vod/snapshot/picture
请求体 Query 参数
参数 | 是否必填 | 参数类型 | 说明 | 示例 | 下级对象 |
---|---|---|---|---|---|
originVideoUuid | 是 | String | 源视频videoID。 | 494df3af1bd04fc28e2f0c5b73a45b6d | |
snapshotTemplateId | 是 | String | 必填参数,截图模板ID。 | 100000000001 | |
watermarkTemplateId | 否 | String | 选填参数,水印模板ID,截图打水印时传入该入参。 | 100000000001 |
响应参数
参数 | 是否必填 | 参数类型 | 说明 | 示例 | 下级对象 |
---|---|---|---|---|---|
code | 是 | Integer | 本次请求的结果码。 | 0 | |
message | 是 | String | 错误文本信息。 | "" | |
data | 是 | Object | 返回的结果。 | data |
表data
参数 | 是否必填 | 参数类型 | 说明 | 示例 | 下级对象 |
---|---|---|---|---|---|
webVTTFile | 否 | String | WebVTT文件(如有)。 | https://test-vod.gdoss.xstore.ctyun.cn/webVTT.vtt | |
spriteSnapshots | 否 | Array of Strings | 合成雪碧图或webVTT合成大横图(如有)。 | ["https://test-vod.gdoss.xstore.ctyun.cn/sprite-0.jpg", "https://test-vod.gdoss.xstore.ctyun.cn/sprite-1.jpg"] | |
originalSnapshots | 否 | Array of Strings | 原始截图(如有)。 | ["https://test-vod.gdoss.xstore.ctyun.cn/snapshot-00.jpg", "https://test-vod.gdoss.xstore.ctyun.cn/snapshot-10.jpg"] |
请求示例
请求体Query
?originVideoUuid=&snapshotTemplateId=&watermarkTemplateId=
响应示例
{
"code":"0",
"message":"",
"data":{
"webVTTFile":"https://test-vod.gdoss.xstore.ctyun.cn/webVTT.vtt",
"spriteSnapshots":["https://test-vod.gdoss.xstore.ctyun.cn/sprite-0.jpg", "https://test-vod.gdoss.xstore.ctyun.cn/sprite-1.jpg"],
"originalSnapshots":["https://test-vod.gdoss.xstore.ctyun.cn/snapshot-00.jpg", "https://test-vod.gdoss.xstore.ctyun.cn/snapshot-10.jpg"]
}
}
状态码
Http 状态码 | 状态码信息 | 状态码描述 |
---|---|---|
0 | 表示业务成功 | 表示业务成功 |
400 | 请求参数有误 | 请求参数有误 |
403 | 用户鉴权失败,用户无操作权限 | 用户鉴权失败,用户无操作权限 |
404 | 请求的资源不存在,输入错误的URL | 请求的资源不存在,输入错误的URL |
500 | 业务执行异常 | 业务执行异常 |
错误码
OpenAPI错误码请参考 错误码说明。