tencentcloud-sdk-nodejs-intl-en 3.0.1029 → 3.0.1031

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tencentcloud-sdk-nodejs-intl-en",
3
- "version": "3.0.1029",
3
+ "version": "3.0.1031",
4
4
  "description": "腾讯云 API NODEJS SDK",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -1,2 +1,2 @@
1
- const sdkVersion = "3.0.1029";
1
+ const sdkVersion = "3.0.1031";
2
2
  module.exports = sdkVersion
@@ -16,21 +16,14 @@
16
16
  */
17
17
  const models = require("./models");
18
18
  const AbstractClient = require('../../common/abstract_client')
19
- const MetaData = models.MetaData;
20
19
  const LogoParam = models.LogoParam;
21
- const QueryVideoFaceFusionJobResponse = models.QueryVideoFaceFusionJobResponse;
22
- const QueryVideoFaceFusionJobRequest = models.QueryVideoFaceFusionJobRequest;
23
- const SubmitVideoFaceFusionJobResponse = models.SubmitVideoFaceFusionJobResponse;
24
- const FuseFaceReviewDetail = models.FuseFaceReviewDetail;
25
- const VideoFaceFusionOutput = models.VideoFaceFusionOutput;
20
+ const FuseParam = models.FuseParam;
26
21
  const ImageCodecParam = models.ImageCodecParam;
27
22
  const MergeInfo = models.MergeInfo;
28
- const FuseFaceReviewResult = models.FuseFaceReviewResult;
23
+ const FuseFaceResponse = models.FuseFaceResponse;
29
24
  const FuseFaceRequest = models.FuseFaceRequest;
30
25
  const FaceRect = models.FaceRect;
31
- const FuseParam = models.FuseParam;
32
- const SubmitVideoFaceFusionJobRequest = models.SubmitVideoFaceFusionJobRequest;
33
- const FuseFaceResponse = models.FuseFaceResponse;
26
+ const MetaData = models.MetaData;
34
27
 
35
28
 
36
29
  /**
@@ -43,28 +36,6 @@ class FacefusionClient extends AbstractClient {
43
36
  super("facefusion.tencentcloudapi.com", "2022-09-27", credential, region, profile);
44
37
  }
45
38
 
46
- /**
47
- * This API is used to query the progress and status of video face fusion tasks by Job ID.
48
- * @param {QueryVideoFaceFusionJobRequest} req
49
- * @param {function(string, QueryVideoFaceFusionJobResponse):void} cb
50
- * @public
51
- */
52
- QueryVideoFaceFusionJob(req, cb) {
53
- let resp = new QueryVideoFaceFusionJobResponse();
54
- this.request("QueryVideoFaceFusionJob", req, resp, cb);
55
- }
56
-
57
- /**
58
- * This API is used to submit asynchronous processing tasks of video face fusion. After a task is submitted, the Job ID, estimated completion time, and current queue length will be returned.
59
- * @param {SubmitVideoFaceFusionJobRequest} req
60
- * @param {function(string, SubmitVideoFaceFusionJobResponse):void} cb
61
- * @public
62
- */
63
- SubmitVideoFaceFusionJob(req, cb) {
64
- let resp = new SubmitVideoFaceFusionJobResponse();
65
- this.request("SubmitVideoFaceFusionJob", req, resp, cb);
66
- }
67
-
68
39
  /**
69
40
  * This API is used to perform the fusion of a single face, multiple faces, and specified faces with the material template by uploading face images. Users can add logos to generated images. See <a href="https://intl.cloud.tencent.com/document/product/670/38247?from_cn_redirect=1" target="_blank">Fusion Access Guide</a>.
70
41
 
@@ -16,41 +16,6 @@
16
16
  */
17
17
  const AbstractModel = require("../../common/abstract_model");
18
18
 
19
- /**
20
- * Metadata structure, in key/value format
21
- * @class
22
- */
23
- class MetaData extends AbstractModel {
24
- constructor(){
25
- super();
26
-
27
- /**
28
- * Metadata key
29
- * @type {string || null}
30
- */
31
- this.MetaKey = null;
32
-
33
- /**
34
- * Metadata value
35
- * @type {string || null}
36
- */
37
- this.MetaValue = null;
38
-
39
- }
40
-
41
- /**
42
- * @private
43
- */
44
- deserialize(params) {
45
- if (!params) {
46
- return;
47
- }
48
- this.MetaKey = 'MetaKey' in params ? params.MetaKey : null;
49
- this.MetaValue = 'MetaValue' in params ? params.MetaValue : null;
50
-
51
- }
52
- }
53
-
54
19
  /**
55
20
  * Logo parameter
56
21
  * @class
@@ -103,201 +68,18 @@ class LogoParam extends AbstractModel {
103
68
  }
104
69
 
105
70
  /**
106
- * QueryVideoFaceFusionJob response structure.
107
- * @class
108
- */
109
- class QueryVideoFaceFusionJobResponse extends AbstractModel {
110
- constructor(){
111
- super();
112
-
113
- /**
114
- * Current task status: queuing, processing, processing failed, or processing completed
115
- * @type {string || null}
116
- */
117
- this.JobStatus = null;
118
-
119
- /**
120
- * Video face fusion result
121
- Note: This field may return null, indicating that no valid values can be obtained.
122
- * @type {VideoFaceFusionOutput || null}
123
- */
124
- this.VideoFaceFusionOutput = null;
125
-
126
- /**
127
- * Task status code. 1: queuing; 3: processing; 5: processing failed; 7: processing completed.
128
- Note: This field may return null, indicating that no valid values can be obtained.
129
- * @type {number || null}
130
- */
131
- this.JobStatusCode = null;
132
-
133
- /**
134
- * Task failure error code
135
- Note: This field may return null, indicating that no valid values can be obtained.
136
- * @type {string || null}
137
- */
138
- this.JobErrorCode = null;
139
-
140
- /**
141
- * Task failure error message
142
- Note: This field may return null, indicating that no valid values can be obtained.
143
- * @type {string || null}
144
- */
145
- this.JobErrorMsg = null;
146
-
147
- /**
148
- * 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.
149
- * @type {string || null}
150
- */
151
- this.RequestId = null;
152
-
153
- }
154
-
155
- /**
156
- * @private
157
- */
158
- deserialize(params) {
159
- if (!params) {
160
- return;
161
- }
162
- this.JobStatus = 'JobStatus' in params ? params.JobStatus : null;
163
-
164
- if (params.VideoFaceFusionOutput) {
165
- let obj = new VideoFaceFusionOutput();
166
- obj.deserialize(params.VideoFaceFusionOutput)
167
- this.VideoFaceFusionOutput = obj;
168
- }
169
- this.JobStatusCode = 'JobStatusCode' in params ? params.JobStatusCode : null;
170
- this.JobErrorCode = 'JobErrorCode' in params ? params.JobErrorCode : null;
171
- this.JobErrorMsg = 'JobErrorMsg' in params ? params.JobErrorMsg : null;
172
- this.RequestId = 'RequestId' in params ? params.RequestId : null;
173
-
174
- }
175
- }
176
-
177
- /**
178
- * QueryVideoFaceFusionJob request structure.
179
- * @class
180
- */
181
- class QueryVideoFaceFusionJobRequest extends AbstractModel {
182
- constructor(){
183
- super();
184
-
185
- /**
186
- * Job ID of the video face fusion task
187
- * @type {string || null}
188
- */
189
- this.JobId = null;
190
-
191
- }
192
-
193
- /**
194
- * @private
195
- */
196
- deserialize(params) {
197
- if (!params) {
198
- return;
199
- }
200
- this.JobId = 'JobId' in params ? params.JobId : null;
201
-
202
- }
203
- }
204
-
205
- /**
206
- * SubmitVideoFaceFusionJob response structure.
207
- * @class
208
- */
209
- class SubmitVideoFaceFusionJobResponse extends AbstractModel {
210
- constructor(){
211
- super();
212
-
213
- /**
214
- * Job ID of the video face fusion task
215
- * @type {string || null}
216
- */
217
- this.JobId = null;
218
-
219
- /**
220
- * Estimated processing time of the video face fusion task, in seconds
221
- * @type {number || null}
222
- */
223
- this.EstimatedProcessTime = null;
224
-
225
- /**
226
- * Estimated processing time of the video face fusion task, in seconds
227
- * @type {number || null}
228
- */
229
- this.JobQueueLength = null;
230
-
231
- /**
232
- * Inappropriate content recognition result. The element order of this array is the same as that of mergeinfo in the request, with a one-to-one relationship.
233
- Note: This field may return null, indicating that no valid values can be obtained.
234
- * @type {Array.<FuseFaceReviewResult> || null}
235
- */
236
- this.ReviewResultSet = null;
237
-
238
- /**
239
- * 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.
240
- * @type {string || null}
241
- */
242
- this.RequestId = null;
243
-
244
- }
245
-
246
- /**
247
- * @private
248
- */
249
- deserialize(params) {
250
- if (!params) {
251
- return;
252
- }
253
- this.JobId = 'JobId' in params ? params.JobId : null;
254
- this.EstimatedProcessTime = 'EstimatedProcessTime' in params ? params.EstimatedProcessTime : null;
255
- this.JobQueueLength = 'JobQueueLength' in params ? params.JobQueueLength : null;
256
-
257
- if (params.ReviewResultSet) {
258
- this.ReviewResultSet = new Array();
259
- for (let z in params.ReviewResultSet) {
260
- let obj = new FuseFaceReviewResult();
261
- obj.deserialize(params.ReviewResultSet[z]);
262
- this.ReviewResultSet.push(obj);
263
- }
264
- }
265
- this.RequestId = 'RequestId' in params ? params.RequestId : null;
266
-
267
- }
268
- }
269
-
270
- /**
271
- *
71
+ * Fusion parameter
272
72
  * @class
273
73
  */
274
- class FuseFaceReviewDetail extends AbstractModel {
74
+ class FuseParam extends AbstractModel {
275
75
  constructor(){
276
76
  super();
277
77
 
278
78
  /**
279
- *
280
- * @type {string || null}
281
- */
282
- this.Field = null;
283
-
284
- /**
285
- *
286
- * @type {string || null}
287
- */
288
- this.Label = null;
289
-
290
- /**
291
- *
292
- * @type {number || null}
293
- */
294
- this.Confidence = null;
295
-
296
- /**
297
- *
298
- * @type {string || null}
79
+ * Image encoding parameter
80
+ * @type {ImageCodecParam || null}
299
81
  */
300
- this.Suggestion = null;
82
+ this.ImageCodecParam = null;
301
83
 
302
84
  }
303
85
 
@@ -308,80 +90,12 @@ class FuseFaceReviewDetail extends AbstractModel {
308
90
  if (!params) {
309
91
  return;
310
92
  }
311
- this.Field = 'Field' in params ? params.Field : null;
312
- this.Label = 'Label' in params ? params.Label : null;
313
- this.Confidence = 'Confidence' in params ? params.Confidence : null;
314
- this.Suggestion = 'Suggestion' in params ? params.Suggestion : null;
315
93
 
316
- }
317
- }
318
-
319
- /**
320
- * Returned video face fusion result
321
- * @class
322
- */
323
- class VideoFaceFusionOutput extends AbstractModel {
324
- constructor(){
325
- super();
326
-
327
- /**
328
- * URL of the video output after video face fusion
329
- * @type {string || null}
330
- */
331
- this.VideoUrl = null;
332
-
333
- /**
334
- * MD5 value of the video output after video face fusion, which is used for verification
335
- * @type {string || null}
336
- */
337
- this.VideoMD5 = null;
338
-
339
- /**
340
- * Video width
341
- * @type {number || null}
342
- */
343
- this.Width = null;
344
-
345
- /**
346
- * Video height
347
- * @type {number || null}
348
- */
349
- this.Height = null;
350
-
351
- /**
352
- * Frames per second
353
- * @type {number || null}
354
- */
355
- this.FPS = null;
356
-
357
- /**
358
- * Video duration, in seconds
359
- * @type {number || null}
360
- */
361
- this.DurationInSec = null;
362
-
363
- /**
364
- * Number of frames
365
- * @type {number || null}
366
- */
367
- this.Frame = null;
368
-
369
- }
370
-
371
- /**
372
- * @private
373
- */
374
- deserialize(params) {
375
- if (!params) {
376
- return;
94
+ if (params.ImageCodecParam) {
95
+ let obj = new ImageCodecParam();
96
+ obj.deserialize(params.ImageCodecParam)
97
+ this.ImageCodecParam = obj;
377
98
  }
378
- this.VideoUrl = 'VideoUrl' in params ? params.VideoUrl : null;
379
- this.VideoMD5 = 'VideoMD5' in params ? params.VideoMD5 : null;
380
- this.Width = 'Width' in params ? params.Width : null;
381
- this.Height = 'Height' in params ? params.Height : null;
382
- this.FPS = 'FPS' in params ? params.FPS : null;
383
- this.DurationInSec = 'DurationInSec' in params ? params.DurationInSec : null;
384
- this.Frame = 'Frame' in params ? params.Frame : null;
385
99
 
386
100
  }
387
101
  }
@@ -497,48 +211,24 @@ Width and height are no less than 30.
497
211
  }
498
212
 
499
213
  /**
500
- *
214
+ * FuseFace response structure.
501
215
  * @class
502
216
  */
503
- class FuseFaceReviewResult extends AbstractModel {
217
+ class FuseFaceResponse extends AbstractModel {
504
218
  constructor(){
505
219
  super();
506
220
 
507
221
  /**
508
- *
509
- * @type {string || null}
510
- */
511
- this.Category = null;
512
-
513
- /**
514
- *
515
- * @type {string || null}
516
- */
517
- this.Code = null;
518
-
519
- /**
520
- *
222
+ * When RspImgType is set to url, return the URL (valid for 7 days). When RspImgType is set to base64, return the Base64 code.
521
223
  * @type {string || null}
522
224
  */
523
- this.CodeDescription = null;
524
-
525
- /**
526
- *
527
- * @type {number || null}
528
- */
529
- this.Confidence = null;
225
+ this.FusedImage = null;
530
226
 
531
227
  /**
532
- *
228
+ * 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.
533
229
  * @type {string || null}
534
230
  */
535
- this.Suggestion = null;
536
-
537
- /**
538
- *
539
- * @type {Array.<FuseFaceReviewDetail> || null}
540
- */
541
- this.DetailSet = null;
231
+ this.RequestId = null;
542
232
 
543
233
  }
544
234
 
@@ -549,20 +239,8 @@ class FuseFaceReviewResult extends AbstractModel {
549
239
  if (!params) {
550
240
  return;
551
241
  }
552
- this.Category = 'Category' in params ? params.Category : null;
553
- this.Code = 'Code' in params ? params.Code : null;
554
- this.CodeDescription = 'CodeDescription' in params ? params.CodeDescription : null;
555
- this.Confidence = 'Confidence' in params ? params.Confidence : null;
556
- this.Suggestion = 'Suggestion' in params ? params.Suggestion : null;
557
-
558
- if (params.DetailSet) {
559
- this.DetailSet = new Array();
560
- for (let z in params.DetailSet) {
561
- let obj = new FuseFaceReviewDetail();
562
- obj.deserialize(params.DetailSet[z]);
563
- this.DetailSet.push(obj);
564
- }
565
- }
242
+ this.FusedImage = 'FusedImage' in params ? params.FusedImage : null;
243
+ this.RequestId = 'RequestId' in params ? params.RequestId : null;
566
244
 
567
245
  }
568
246
  }
@@ -710,158 +388,24 @@ class FaceRect extends AbstractModel {
710
388
  }
711
389
 
712
390
  /**
713
- * Fusion parameter
714
- * @class
715
- */
716
- class FuseParam extends AbstractModel {
717
- constructor(){
718
- super();
719
-
720
- /**
721
- * Image encoding parameter
722
- * @type {ImageCodecParam || null}
723
- */
724
- this.ImageCodecParam = null;
725
-
726
- }
727
-
728
- /**
729
- * @private
730
- */
731
- deserialize(params) {
732
- if (!params) {
733
- return;
734
- }
735
-
736
- if (params.ImageCodecParam) {
737
- let obj = new ImageCodecParam();
738
- obj.deserialize(params.ImageCodecParam)
739
- this.ImageCodecParam = obj;
740
- }
741
-
742
- }
743
- }
744
-
745
- /**
746
- * SubmitVideoFaceFusionJob request structure.
747
- * @class
748
- */
749
- class SubmitVideoFaceFusionJobRequest extends AbstractModel {
750
- constructor(){
751
- super();
752
-
753
- /**
754
- * Activity ID. Check it in the video face fusion console.
755
- * @type {string || null}
756
- */
757
- this.ProjectId = null;
758
-
759
- /**
760
- * Material ID. Check it in the video face fusion console.
761
- * @type {string || null}
762
- */
763
- this.ModelId = null;
764
-
765
- /**
766
- * Face position information on the user face image and material template image. Only one entry is allowed.
767
- * @type {Array.<MergeInfo> || null}
768
- */
769
- this.MergeInfos = null;
770
-
771
- /**
772
- * 0: inappropriate content recognition not required; 1: inappropriate content recognition required. Default value: 0.
773
- Note: Once the inappropriate content recognition service is enabled, you need to decide whether to adjust your business logic based on the returned results. For example, you need to replace the image if the system informs you that the image does not meet the requirements.
774
- **<font color=#1E90FF>Note: This field will be deprecated later due to business adjustments. It is not recommended for use.</font>**
775
- * @type {number || null}
776
- */
777
- this.CelebrityIdentify = null;
778
-
779
- /**
780
- * Video watermark logo parameter
781
- * @type {LogoParam || null}
782
- */
783
- this.LogoParam = null;
784
-
785
- /**
786
- * COS pre-signed URL (PUT method). If this parameter is specified, the video after fusion will be uploaded to this URL.
787
- **<font color=#1E90FF>Note: If upload to this URL fails, the video will be uploaded to the default address of Tencent Cloud.</font>**
788
- * @type {string || null}
789
- */
790
- this.UserDesignatedUrl = null;
791
-
792
- /**
793
- * User IP address
794
- * @type {string || null}
795
- */
796
- this.UserIp = null;
797
-
798
- /**
799
- * Video metadata field
800
- * @type {Array.<MetaData> || null}
801
- */
802
- this.MetaData = null;
803
-
804
- }
805
-
806
- /**
807
- * @private
808
- */
809
- deserialize(params) {
810
- if (!params) {
811
- return;
812
- }
813
- this.ProjectId = 'ProjectId' in params ? params.ProjectId : null;
814
- this.ModelId = 'ModelId' in params ? params.ModelId : null;
815
-
816
- if (params.MergeInfos) {
817
- this.MergeInfos = new Array();
818
- for (let z in params.MergeInfos) {
819
- let obj = new MergeInfo();
820
- obj.deserialize(params.MergeInfos[z]);
821
- this.MergeInfos.push(obj);
822
- }
823
- }
824
- this.CelebrityIdentify = 'CelebrityIdentify' in params ? params.CelebrityIdentify : null;
825
-
826
- if (params.LogoParam) {
827
- let obj = new LogoParam();
828
- obj.deserialize(params.LogoParam)
829
- this.LogoParam = obj;
830
- }
831
- this.UserDesignatedUrl = 'UserDesignatedUrl' in params ? params.UserDesignatedUrl : null;
832
- this.UserIp = 'UserIp' in params ? params.UserIp : null;
833
-
834
- if (params.MetaData) {
835
- this.MetaData = new Array();
836
- for (let z in params.MetaData) {
837
- let obj = new MetaData();
838
- obj.deserialize(params.MetaData[z]);
839
- this.MetaData.push(obj);
840
- }
841
- }
842
-
843
- }
844
- }
845
-
846
- /**
847
- * FuseFace response structure.
391
+ * Metadata structure, in key/value format
848
392
  * @class
849
393
  */
850
- class FuseFaceResponse extends AbstractModel {
394
+ class MetaData extends AbstractModel {
851
395
  constructor(){
852
396
  super();
853
397
 
854
398
  /**
855
- * When RspImgType is set to url, return the URL (valid for 7 days). When RspImgType is set to base64, return the Base64 code.
399
+ * Metadata key
856
400
  * @type {string || null}
857
401
  */
858
- this.FusedImage = null;
402
+ this.MetaKey = null;
859
403
 
860
404
  /**
861
- * 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.
405
+ * Metadata value
862
406
  * @type {string || null}
863
407
  */
864
- this.RequestId = null;
408
+ this.MetaValue = null;
865
409
 
866
410
  }
867
411
 
@@ -872,27 +416,20 @@ class FuseFaceResponse extends AbstractModel {
872
416
  if (!params) {
873
417
  return;
874
418
  }
875
- this.FusedImage = 'FusedImage' in params ? params.FusedImage : null;
876
- this.RequestId = 'RequestId' in params ? params.RequestId : null;
419
+ this.MetaKey = 'MetaKey' in params ? params.MetaKey : null;
420
+ this.MetaValue = 'MetaValue' in params ? params.MetaValue : null;
877
421
 
878
422
  }
879
423
  }
880
424
 
881
425
  module.exports = {
882
- MetaData: MetaData,
883
426
  LogoParam: LogoParam,
884
- QueryVideoFaceFusionJobResponse: QueryVideoFaceFusionJobResponse,
885
- QueryVideoFaceFusionJobRequest: QueryVideoFaceFusionJobRequest,
886
- SubmitVideoFaceFusionJobResponse: SubmitVideoFaceFusionJobResponse,
887
- FuseFaceReviewDetail: FuseFaceReviewDetail,
888
- VideoFaceFusionOutput: VideoFaceFusionOutput,
427
+ FuseParam: FuseParam,
889
428
  ImageCodecParam: ImageCodecParam,
890
429
  MergeInfo: MergeInfo,
891
- FuseFaceReviewResult: FuseFaceReviewResult,
430
+ FuseFaceResponse: FuseFaceResponse,
892
431
  FuseFaceRequest: FuseFaceRequest,
893
432
  FaceRect: FaceRect,
894
- FuseParam: FuseParam,
895
- SubmitVideoFaceFusionJobRequest: SubmitVideoFaceFusionJobRequest,
896
- FuseFaceResponse: FuseFaceResponse,
433
+ MetaData: MetaData,
897
434
 
898
435
  }