tencentcloud-sdk-nodejs-intl-en 3.0.1384 → 3.0.1385

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,145 @@
1
+ /*
2
+ * Copyright (c) 2018 Tencent. All Rights Reserved.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing,
11
+ * software distributed under the License is distributed on an
12
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
13
+ * KIND, either express or implied. See the License for the
14
+ * specific language governing permissions and limitations
15
+ * under the License.
16
+ */
17
+ const models = require("./models");
18
+ const AbstractClient = require('../../common/abstract_client')
19
+ const ModifyGlossaryEntriesRequest = models.ModifyGlossaryEntriesRequest;
20
+ const CreateGlossaryRequest = models.CreateGlossaryRequest;
21
+ const DescribeGlossaryEntriesResponse = models.DescribeGlossaryEntriesResponse;
22
+ const DeleteGlossaryRequest = models.DeleteGlossaryRequest;
23
+ const DescribeGlossaryEntriesRequest = models.DescribeGlossaryEntriesRequest;
24
+ const DescribeGlossariesRequest = models.DescribeGlossariesRequest;
25
+ const RequestFilter = models.RequestFilter;
26
+ const DeleteGlossaryEntriesRequest = models.DeleteGlossaryEntriesRequest;
27
+ const CreateGlossaryEntriesResponse = models.CreateGlossaryEntriesResponse;
28
+ const DeleteGlossaryEntryInput = models.DeleteGlossaryEntryInput;
29
+ const GlossaryEntryItem = models.GlossaryEntryItem;
30
+ const DeleteGlossaryResponse = models.DeleteGlossaryResponse;
31
+ const CreateGlossaryEntriesRequest = models.CreateGlossaryEntriesRequest;
32
+ const RequestSort = models.RequestSort;
33
+ const ModifyGlossaryEntriesResponse = models.ModifyGlossaryEntriesResponse;
34
+ const ModifyGlossaryEntryInput = models.ModifyGlossaryEntryInput;
35
+ const DeleteGlossaryEntriesResponse = models.DeleteGlossaryEntriesResponse;
36
+ const DescribeGlossariesResponse = models.DescribeGlossariesResponse;
37
+ const GlossaryItem = models.GlossaryItem;
38
+ const GlossaryEntryInput = models.GlossaryEntryInput;
39
+ const CreateGlossaryResponse = models.CreateGlossaryResponse;
40
+
41
+
42
+ /**
43
+ * tokenhub client
44
+ * @class
45
+ */
46
+ class TokenhubClient extends AbstractClient {
47
+
48
+ constructor(credential, region, profile) {
49
+ super("tokenhub.intl.tencentcloudapi.com", "2026-03-22", credential, region, profile);
50
+ }
51
+
52
+ /**
53
+ * Delete terminology entries in batches.
54
+
55
+ Delete terminology entries in batches under the specified Termbase. You can delete up to 200 entries at a time. If the Termbase is nonexistent or NOT_IN this application, it returns a ResourceNotFound error.
56
+ * @param {DeleteGlossaryEntriesRequest} req
57
+ * @param {function(string, DeleteGlossaryEntriesResponse):void} cb
58
+ * @public
59
+ */
60
+ DeleteGlossaryEntries(req, cb) {
61
+ let resp = new DeleteGlossaryEntriesResponse();
62
+ this.request("DeleteGlossaryEntries", req, resp, cb);
63
+ }
64
+
65
+ /**
66
+ * Create terminology entries in batches.
67
+
68
+ Create terminology entries in batches under the designated Termbase. You can create up to 100 entries at a time.
69
+ * @param {CreateGlossaryEntriesRequest} req
70
+ * @param {function(string, CreateGlossaryEntriesResponse):void} cb
71
+ * @public
72
+ */
73
+ CreateGlossaryEntries(req, cb) {
74
+ let resp = new CreateGlossaryEntriesResponse();
75
+ this.request("CreateGlossaryEntries", req, resp, cb);
76
+ }
77
+
78
+ /**
79
+ * Batch modify terminology entries.
80
+
81
+ This API is used to batch modify terminology entries in a designated Termbase. You can modify up to 200 entries at a time.
82
+ * @param {ModifyGlossaryEntriesRequest} req
83
+ * @param {function(string, ModifyGlossaryEntriesResponse):void} cb
84
+ * @public
85
+ */
86
+ ModifyGlossaryEntries(req, cb) {
87
+ let resp = new ModifyGlossaryEntriesResponse();
88
+ this.request("ModifyGlossaryEntries", req, resp, cb);
89
+ }
90
+
91
+ /**
92
+ * Query the terminology repository list.
93
+
94
+ Query the Termbase list under this application. Support paginate, filter, and sort.
95
+ * @param {DescribeGlossariesRequest} req
96
+ * @param {function(string, DescribeGlossariesResponse):void} cb
97
+ * @public
98
+ */
99
+ DescribeGlossaries(req, cb) {
100
+ let resp = new DescribeGlossariesResponse();
101
+ this.request("DescribeGlossaries", req, resp, cb);
102
+ }
103
+
104
+ /**
105
+ * Create a Termbase.
106
+
107
+ Create a new Termbase in this application for custom definition source to target language terminology mapping. Return the Termbase ID upon success, which can be used to carry out other management operations on terminology entries.
108
+ * @param {CreateGlossaryRequest} req
109
+ * @param {function(string, CreateGlossaryResponse):void} cb
110
+ * @public
111
+ */
112
+ CreateGlossary(req, cb) {
113
+ let resp = new CreateGlossaryResponse();
114
+ this.request("CreateGlossary", req, resp, cb);
115
+ }
116
+
117
+ /**
118
+ * Delete a termbase.
119
+
120
+ This API is used to delete specified Termbase and ALL terminology entries under it. The deletion is idempotent and returns a successful result for non-existing Termbase. After calling the API, if the corresponding Termbase cannot be found via DescribeGlossaries, it indicates successful deletion.
121
+ * @param {DeleteGlossaryRequest} req
122
+ * @param {function(string, DeleteGlossaryResponse):void} cb
123
+ * @public
124
+ */
125
+ DeleteGlossary(req, cb) {
126
+ let resp = new DeleteGlossaryResponse();
127
+ this.request("DeleteGlossary", req, resp, cb);
128
+ }
129
+
130
+ /**
131
+ * Query the terminology entry list.
132
+
133
+ Query specified entries in a Termbase. Support pagination.
134
+ * @param {DescribeGlossaryEntriesRequest} req
135
+ * @param {function(string, DescribeGlossaryEntriesResponse):void} cb
136
+ * @public
137
+ */
138
+ DescribeGlossaryEntries(req, cb) {
139
+ let resp = new DescribeGlossaryEntriesResponse();
140
+ this.request("DescribeGlossaryEntries", req, resp, cb);
141
+ }
142
+
143
+
144
+ }
145
+ module.exports = TokenhubClient;