tencent cloud

All product documents
APIs
DescribeDocument
Last updated: 2025-03-11 22:20:09
DescribeDocument
Last updated: 2025-03-11 22:20:09

1. API Description

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

This API is used to get the information of a specific document.
A maximum of 20 requests can be initiated per second for this API.

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: DescribeDocument.
Version Yes String Common Params. The value used for this API: 2022-08-17.
Region No String Common Params. This parameter is not required.
DocumentId Yes String The (unique) document ID.

3. Output Parameters

Parameter Name Type Description
DocumentId String The document ID.
DocumentUrl String The document’s original URL.
DocumentName String The document title.
Owner String The user ID of the document’s owner.
SdkAppId Integer The application ID.
Permission Integer The document access type.
TranscodeResult String The transcoding result. If the file is not transcoded, this parameter will be empty. If it is successfully transcoded, this parameter will be the URL of the transcoded file. If transcoding fails, this parameter will indicate the error code.
TranscodeType Integer The transcoding type.
TranscodeProgress Integer The transcoding progress. Value range: 0-100.
TranscodeState Integer The transcoding status. 0: The file is not transcoded. 1: The file is being transcoded. 2: Transcoding failed. 3: Transcoding is successful.
TranscodeInfo String The error message for failed transcoding.
DocumentType String The document type.
DocumentSize Integer The document size (bytes).
UpdateTime Integer The time (Unix timestamp) when the document was last updated.
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 Test Example

PDF example.

Input Example

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

{
    "DocumentId": "omxxxsdc"
}

Output Example

{
    "Response": {
        "DocumentId": "omxxxsdc",
        "DocumentName": "Didi Electronic Invoice (1).pdf",
        "DocumentSize": 38673,
        "DocumentType": "pdf",
        "DocumentUrl": "https://tcic-source.qcloudclass.com/uploads/5390248a-5eb7-4fe8-be27-c43dbad1380f/3520371/1679021408_KzpMGD38.pdf",
        "Owner": "2N1zP0mW7E3Vr3xJ2ZQ9GeFDK4t",
        "Permission": 0,
        "RequestId": "ee3fdca0-c88c-43f1-81b4-4f51f9e50521",
        "SdkAppId": 3520371,
        "TranscodeInfo": "",
        "TranscodeProgress": 100,
        "TranscodeResult": "https://tcic-test-1257307760.qcloudclass.com/doc/01aq2v7djsh31noat9gc_tiw/picture/",
        "TranscodeState": 3,
        "TranscodeType": 1,
        "UpdateTime": 1679021410
    }
}

Example2 Obtaining Document Details

Example.

Input Example

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

{
    "DocumentId": "ntxsfrzk"
}

Output Example

{
    "Response": {
        "DocumentId": "ntxsfrzk",
        "DocumentName": "test.pptx",
        "DocumentSize": 15814364,
        "DocumentType": "pptx",
        "DocumentUrl": "https://tcic-source.qcloudclass.com/uploads/5390248a-5eb7-4fe8-be27-c43dbad1380f/3520371/1677202414_85bt9f0X.pptx",
        "Owner": "2M04q0j5mhsbq1lAEbCW1dhRvA2",
        "Permission": 0,
        "RequestId": "d97f98d7-de89-455a-a1f3-b9dae84d84bb",
        "SdkAppId": 3520371,
        "TranscodeInfo": "Microsoft Macintosh PowerPoint",
        "TranscodeProgress": 100,
        "TranscodeResult": "https://tcic-test-1257307760.qcloudclass.com/doc/gsutgbm7ssh31ns71sfc_tiw/h5/index.html",
        "TranscodeState": 3,
        "TranscodeType": 1,
        "UpdateTime": 1677202419
    }
}

Example3 Example

Courseware preview example.

Input Example

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

{
    "DocumentId": "ntxsfrzk"
}

Output Example

{
    "Response": {
        "DocumentId": "ntxsfrzk",
        "DocumentName": "test.pptx",
        "DocumentSize": 15814364,
        "DocumentType": "pptx",
        "DocumentUrl": "https://tcic-source.qcloudclass.com/uploads/5390248a-5eb7-4fe8-be27-c43dbad1380f/3520371/1677202414_85bt9f0X.pptx",
        "Owner": "2M04q0j5mhsbq1lAEbCW1dhRvA2",
        "Permission": 0,
        "RequestId": "8a7bafba-bc67-4040-8203-475532db535f",
        "SdkAppId": 3520371,
        "TranscodeInfo": "Microsoft Macintosh PowerPoint",
        "TranscodeProgress": 100,
        "TranscodeResult": "https://tcic-test-1257307760.qcloudclass.com/doc/gsutgbm7ssh31ns71sfc_tiw/h5/index.html",
        "TranscodeState": 3,
        "TranscodeType": 1,
        "UpdateTime": 1677202419
    }
}

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
InternalError Internal error.
ResourceNotFound.Document The file does not exist.
Was this page helpful?
You can also Contact Sales or Submit a Ticket for help.
Yes
No

Feedback

Contact Us

Contact our sales team or business advisors to help your business.

Technical Support

Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

7x24 Phone Support