tencent cloud



最后更新时间:2022-02-11 17:11:14
This document is currently invalid. Please refer to the documentation page of the product.

1. API Description

Domain name for API request: vod.tencentcloudapi.com.

This API is used to publish a VOD video on WeChat Mini Program for playback in the WeChat Mini Program player.

A maximum of 100 requests can be initiated per second for this API.

We recommend you to use API Explorer
Try it
API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters

The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.
This document describes the parameters for Signature V1. It's recommended to use the V3 signature, which provides higher security. Note that for Signature V3, the common parameters need to be placed in the HTTP Header. See details.

Parameter Name Required Type Description
Action Yes String Common parameter. The value used for this API: WeChatMiniProgramPublish.
Version Yes String Common parameter. The value used for this API: 2018-07-17.
Region No String Common parameter. This parameter is not required for this API.
FileId Yes String Media file ID.
SourceDefinition No Integer ID of the transcoding template corresponding to the published video. 0 represents the source video.
SubAppId No Integer Subapplication ID in VOD. If you need to access a resource in a subapplication, enter the subapplication ID in this field; otherwise, leave it empty.

3. Output Parameters

Parameter Name Type Description
TaskId String Task ID.
RequestId String The unique request ID, which is returned for each request. RequestId is required for locating a problem.

4. Example

Example1 Initiating a WeChat Mini Program publishing task

This example shows you how to initiate a WeChat Mini Program publishing task for a video (fileId: 5285485487985271487) by using a transcoding template (ID: 10).

Input Example

&<Common request parameters>

Output Example

  "Response": {
    "RequestId": "6ca31e3a-6b8e-4b4e-9256-fdc700064ef3",
    "TaskId": "125xxx65-wechat-mini-program-publish-bffb15f07530b57bc1aabb01fac74bca"

5. Developer Resources


TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

Command Line Interface

6. Error Code

The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

Error Code Description
FailedOperation Operation failed.
FailedOperation.InvalidVodUser The VOD service is not activated.
FailedOperation.NoPrivileges No permission to use this API.
InternalError Internal error.
InvalidParameter Invalid parameter.
InvalidParameterValue Incorrect parameter value.
InvalidParameterValue.FileId The FileId does not exist.
InvalidParameterValue.FileType Incorrect video type.
InvalidParameterValue.SourceDefinition Incorrect SourceDefinition. Please check whether the media file is bound with a transcoding template.
InvalidParameterValue.SubAppId Incorrect parameter value: subapplication ID
ResourceNotFound.FileNotExist The resource does not exist: the file does not exist.
UnauthorizedOperation Unauthorized operation.




7x24 电话支持