Overview
Menu

DescribeAsrHotwords

Last updated: 2025-07-23 14:32:26Download PDF

1. API Description

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

This API is used to query a smart subtitle hotword lexicon.

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 NameRequiredTypeDescription
ActionYesStringCommon Params. The value used for this API: DescribeAsrHotwords.
VersionYesStringCommon Params. The value used for this API: 2019-06-12.
RegionNoStringCommon Params. This parameter is not required for this API.
HotwordsIdNoStringID of the hotword lexicon to be queried.
Note: Either HotwordsId or Name should be specified. If both are specified, HotwordsId has a higher priority than Name.
NameNoStringHotword lexicon name.
Note: Either HotwordsId or Name should be specified. If both are specified, HotwordsId has a higher priority than Name.
OffsetNoIntegerPaging offset. Default value: 0.

LimitNoIntegerNumber of returned entries. Default value: 10. Maximum value: 100.
OrderByNoStringHotword sorting field. Valid values:

- Default: Sort by the hotword upload sequence.
- Weight: Sort by the weight.
- Lexical: Sort by the first letter of hotwords.
OrderTypeNoIntegerHotword sorting order. 0: ascending (default); 1: descending.

3. Output Parameters

Parameter NameTypeDescription
HotwordsIdStringID of the hotword lexicon to be queried.
StatusIntegerCurrent hotword lexicon id status. a value of 0 indicates that no template is bound to this hotword lexicon at the query moment and it can be deleted.
NameStringName of the hot lexicon.
TypeIntegerSpecifies the value is 0 for a temporary hotword lexicon and returns the string provided during creation.
Specifies the value is 1 for a file-based hotword lexicon, and returns the content of the file uploaded during creation.

FileNameStringName of the uploaded hotword file.
HotWordsArray of AsrHotwordsSetItemList of hotwords returned for the query.
ContentStringHotword text, which depends on the value of Type.
If the value of Type is 0, the hotword string is returned.
If the value of Type is 1, the base64-encoded content of the hotword file is returned.
WordCountIntegerNumber of words contained in the hotword lexicon.
OffsetIntegerPaging offset. Default value: 0.
LimitIntegerNumber of returned entries. Default value: 10. Maximum value: 100.
CreateTimeStringHot word lexicon createtime in ISOUTC format "2006-01-02T15:04:05Z".
UpdateTimeStringHot lexicon last modified in ISOUTC format "2006-01-02T15:04:05Z".
RequestIdStringThe 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 DescribeAsrHotwords

Input Example

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

{
    "HotwordsId": "hwd-aexxxxxxxxxxxxxx1481"
}

Output Example

{
    "Response": {
        "Content": "Tencent Cloud|10,Automatic Speech Recognition|5,ASR|10",
        "CreateTime": "2025-03-19T03:29:06Z",
        "FileName": "",
        "HotWords": [
            {
                "Id": 1,
                "Text": "Tencent Cloud",
                "Weight": 10
            },
            {
                "Id": 2,
                "Text": "Automatic Speech Recognition",
                "Weight": 5
            },
            {
                "Id": 3,
                "Text": "ASR",
                "Weight": 10
            }
        ],
        "HotwordsId": "hwd-aexxxxxxxxxxxxxx1481",
        "Limit": 0,
        "Name": "HotwordsNameExample",
        "Offset": 0,
        "RequestId": "bad606d3-8a49-427f-a6a6-26c9f1fe1dc3",
        "Status": 0,
        "Type": 0,
        "UpdateTime": "2025-03-19T03:29:06Z",
        "WordCount": 3
    }
}

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 CodeDescription
InternalErrorInternal error.
InternalError.AccessDBErrorData error.
InvalidParameterValueIncorrect parameter value.