tencent cloud

CreateDocument
Last updated: 2024-04-01 19:34:41
CreateDocument
Last updated: 2024-04-01 19:34:41

1. API Description

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

This API is used to create a document to be used in a room.

A maximum of 20 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.

Parameter Name Required Type Description
Action Yes String Common Params. The value used for this API: CreateDocument.
Version Yes String Common Params. The value used for this API: 2022-08-17.
Region No String Common Params. This parameter is not required.
SdkAppId Yes Integer LCIC SdkAppId
DocumentUrl Yes String Document URL
DocumentName Yes String Document name
Owner Yes String Document owner ID
TranscodeType No Integer Transcoding type. Valid values: 0: No transcoding required (default); 1: Documents that need to be transcoded: ppt, pptx, pdf, doc, docx; 2: Videos that need to be transcoded: mp4, 3pg, mpeg, avi, flv, wmv, rm, h264, etc.; 2: Audio that needs to be transcoded: mp3, wav, wma, aac, flac, opus
Permission No Integer Permission. Valid values: 0: Private document (default); 1: Public document
DocumentType No String Document extension
DocumentSize No Integer Document size, in bytes
AutoHandleUnsupportedElement No Boolean Whether or not to enable automatic processing for unsupported elements. Default: off. The automatically processed elements are as follows: 1. Ink: Remove unsupported ink (e.g. WPS Ink) 2. Auto Page Turn: Remove all auto page turn settings on the PPT and set it to mouse click to turn the page 3. Corrupted Audio/Video: Remove references to corrupted audio/video on the PPT

3. Output Parameters

Parameter Name Type Description
DocumentId String Document ID
RequestId String The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.

4. Example

Example1 Creating a document.

Input Example

POST / HTTP/1.1
Host: lcic.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateDocument
<Common request parameters>

{
    "SdkAppId": 1,
    "DocumentUrl": "xx",
    "DocumentName": "xx",
    "Owner": "xx",
    "TranscodeType": 1,
    "Permission": 1,
    "DocumentType": "xx",
    "DocumentSize": 100
}

Output Example

{
    "Response": {
        "DocumentId": "xx",
        "RequestId": "213das"
    }
}

5. Developer Resources

SDK

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.RequestTimedOut Request timed out.
InternalError Internal error.
InvalidParameter.SdkAppId SdkAppId is incorrect.
ResourceNotFound.User The user does not exist.
Was this page helpful?
You can also Contact Sales or Submit a Ticket for help.
Yes
No

Feedback