文档中心 > API类目 > 内容开放API

taobao.content.video.publish (发布短视频内容到商家视频空间)

发布短视频内容到商家视频空间

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
file_id String 必须 017f-3eaa3638-a1b2398a-7f20d281-5037 视频上传后返回的文件id
title String 必须 女装视频 视频标题
cover_url String 必须 https://img.alicdn.com/imgextra/i2/O1CN01j61pd3292AnxSZXyS.png 封面图
video_service_id Number 必须 123 平台短视频模版ID
sub_order_id String 必须 123 服务市场的支付子订单号

响应参数

名称 类型 示例值 描述
content_id Number 3 视频空间的视频id

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
ContentVideoPublishRequest req = new ContentVideoPublishRequest();
req.setFileId("017f-3eaa3638-a1b2398a-7f20d281-5037");
req.setTitle("女装视频");
req.setCoverUrl("https://img.alicdn.com/imgextra/i2/O1CN01j61pd3292AnxSZXyS.png");
req.setVideoServiceId(123L);
req.setSubOrderId("123");
ContentVideoPublishResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<content_video_publish_response>
    <content_id>3</content_id>
</content_video_publish_response>

异常示例

  • XML示例
  • JSON示例
<error_response>
    <code>50</code>
    <msg>Remote service error</msg>
    <sub_code>isv.invalid-parameter</sub_code>
    <sub_msg>非法参数</sub_msg>
</error_response>

错误码解释

错误码 错误描述 解决方案

API工具

如何获得此API

FAQ

返回
顶部