ugcinc 2.86.0 → 2.87.0
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/dist/automations.js +111 -0
- package/dist/render.d.ts +14 -0
- package/dist/render.js +9 -0
- package/dist/types.d.ts +1 -1
- package/package.json +1 -1
package/dist/automations.js
CHANGED
|
@@ -292,6 +292,117 @@ function getAllNodes() {
|
|
|
292
292
|
inputs: [],
|
|
293
293
|
outputs: [],
|
|
294
294
|
},
|
|
295
|
+
{
|
|
296
|
+
type: "account",
|
|
297
|
+
label: "Account",
|
|
298
|
+
description: "Select accounts to post from",
|
|
299
|
+
category: "Input",
|
|
300
|
+
inputs: [],
|
|
301
|
+
outputs: [
|
|
302
|
+
{
|
|
303
|
+
id: "account",
|
|
304
|
+
title: "Account",
|
|
305
|
+
type: "account",
|
|
306
|
+
required: true,
|
|
307
|
+
},
|
|
308
|
+
],
|
|
309
|
+
},
|
|
310
|
+
{
|
|
311
|
+
type: "post-video",
|
|
312
|
+
label: "Post Video",
|
|
313
|
+
description: "Post a video to social media",
|
|
314
|
+
category: "Output",
|
|
315
|
+
inputs: [
|
|
316
|
+
{
|
|
317
|
+
id: "video",
|
|
318
|
+
title: "Video",
|
|
319
|
+
type: "video",
|
|
320
|
+
required: true,
|
|
321
|
+
},
|
|
322
|
+
{
|
|
323
|
+
id: "account",
|
|
324
|
+
title: "Account",
|
|
325
|
+
type: "account",
|
|
326
|
+
required: true,
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
id: "caption",
|
|
330
|
+
title: "Caption",
|
|
331
|
+
type: "text",
|
|
332
|
+
required: false,
|
|
333
|
+
},
|
|
334
|
+
{
|
|
335
|
+
id: "socialAudio",
|
|
336
|
+
title: "Social Audio",
|
|
337
|
+
type: "audio",
|
|
338
|
+
required: false,
|
|
339
|
+
},
|
|
340
|
+
{
|
|
341
|
+
id: "postDate",
|
|
342
|
+
title: "Post Date",
|
|
343
|
+
type: "date",
|
|
344
|
+
required: false,
|
|
345
|
+
},
|
|
346
|
+
],
|
|
347
|
+
outputs: [
|
|
348
|
+
{
|
|
349
|
+
id: "postUrl",
|
|
350
|
+
title: "Post URL",
|
|
351
|
+
type: "text",
|
|
352
|
+
required: true,
|
|
353
|
+
},
|
|
354
|
+
],
|
|
355
|
+
},
|
|
356
|
+
{
|
|
357
|
+
type: "post-slideshow",
|
|
358
|
+
label: "Post Slideshow",
|
|
359
|
+
description: "Post a slideshow to social media",
|
|
360
|
+
category: "Output",
|
|
361
|
+
// Dynamic inputs based on imageCount in config
|
|
362
|
+
inputs: [
|
|
363
|
+
{
|
|
364
|
+
id: "account",
|
|
365
|
+
title: "Account",
|
|
366
|
+
type: "account",
|
|
367
|
+
required: true,
|
|
368
|
+
},
|
|
369
|
+
{
|
|
370
|
+
id: "caption",
|
|
371
|
+
title: "Caption",
|
|
372
|
+
type: "text",
|
|
373
|
+
required: false,
|
|
374
|
+
},
|
|
375
|
+
{
|
|
376
|
+
id: "socialAudio",
|
|
377
|
+
title: "Social Audio",
|
|
378
|
+
type: "audio",
|
|
379
|
+
required: false,
|
|
380
|
+
},
|
|
381
|
+
{
|
|
382
|
+
id: "postDate",
|
|
383
|
+
title: "Post Date",
|
|
384
|
+
type: "date",
|
|
385
|
+
required: false,
|
|
386
|
+
},
|
|
387
|
+
],
|
|
388
|
+
outputs: [
|
|
389
|
+
{
|
|
390
|
+
id: "postUrl",
|
|
391
|
+
title: "Post URL",
|
|
392
|
+
type: "text",
|
|
393
|
+
required: true,
|
|
394
|
+
},
|
|
395
|
+
],
|
|
396
|
+
},
|
|
397
|
+
{
|
|
398
|
+
type: "save-to-media",
|
|
399
|
+
label: "Save To Media",
|
|
400
|
+
description: "Save outputs to media library",
|
|
401
|
+
category: "Output",
|
|
402
|
+
// Dynamic inputs based on config
|
|
403
|
+
inputs: [],
|
|
404
|
+
outputs: [],
|
|
405
|
+
},
|
|
295
406
|
];
|
|
296
407
|
}
|
|
297
408
|
/**
|
package/dist/render.d.ts
CHANGED
|
@@ -24,6 +24,12 @@ export interface SubmitImageRenderJobParams {
|
|
|
24
24
|
textValues: Record<string, string>;
|
|
25
25
|
output_type?: 'image';
|
|
26
26
|
image_format?: 'png' | 'jpeg';
|
|
27
|
+
/** If true, inject CapCut-style metadata into the output */
|
|
28
|
+
injectCapcutMetadata?: boolean;
|
|
29
|
+
/** OS to report in CapCut metadata ("ios" or "android") */
|
|
30
|
+
capcutOs?: 'ios' | 'android';
|
|
31
|
+
/** Region code to report in CapCut metadata */
|
|
32
|
+
capcutRegion?: string;
|
|
27
33
|
}
|
|
28
34
|
export type RenderVideoEditorConfig = VideoEditorNodeConfig;
|
|
29
35
|
export interface SubmitVideoRenderJobParams {
|
|
@@ -32,6 +38,14 @@ export interface SubmitVideoRenderJobParams {
|
|
|
32
38
|
output_type?: 'video' | 'image';
|
|
33
39
|
image_format?: 'png' | 'jpeg';
|
|
34
40
|
video_codec?: 'h264' | 'h265';
|
|
41
|
+
/** If true, inject CapCut-style metadata into the output */
|
|
42
|
+
injectCapcutMetadata?: boolean;
|
|
43
|
+
/** OS to report in CapCut metadata ("ios" or "android") */
|
|
44
|
+
capcutOs?: 'ios' | 'android';
|
|
45
|
+
/** Region code to report in CapCut metadata */
|
|
46
|
+
capcutRegion?: string;
|
|
47
|
+
/** If true, re-encode video to H.265/HEVC codec */
|
|
48
|
+
reencodeH265?: boolean;
|
|
35
49
|
}
|
|
36
50
|
/**
|
|
37
51
|
* Client for rendering operations
|
package/dist/render.js
CHANGED
|
@@ -36,6 +36,10 @@ class RenderClient {
|
|
|
36
36
|
},
|
|
37
37
|
output_type: params.output_type ?? 'image',
|
|
38
38
|
image_format: params.image_format ?? 'png',
|
|
39
|
+
// CapCut metadata injection options
|
|
40
|
+
inject_capcut_metadata: params.injectCapcutMetadata ?? false,
|
|
41
|
+
capcut_os: params.capcutOs ?? 'ios',
|
|
42
|
+
capcut_region: params.capcutRegion ?? 'US',
|
|
39
43
|
})
|
|
40
44
|
});
|
|
41
45
|
const text = await response.text();
|
|
@@ -91,6 +95,11 @@ class RenderClient {
|
|
|
91
95
|
output_type: params.output_type,
|
|
92
96
|
image_format: params.image_format,
|
|
93
97
|
video_codec: params.video_codec,
|
|
98
|
+
// CapCut metadata injection options
|
|
99
|
+
inject_capcut_metadata: params.injectCapcutMetadata ?? false,
|
|
100
|
+
capcut_os: params.capcutOs ?? 'ios',
|
|
101
|
+
capcut_region: params.capcutRegion ?? 'US',
|
|
102
|
+
reencode_h265: params.reencodeH265 ?? false,
|
|
94
103
|
})
|
|
95
104
|
});
|
|
96
105
|
const text = await response.text();
|
package/dist/types.d.ts
CHANGED
|
@@ -747,7 +747,7 @@ export type StaticSegment = ImageSegment | TextSegment;
|
|
|
747
747
|
/**
|
|
748
748
|
* Automation types
|
|
749
749
|
*/
|
|
750
|
-
export type MediaType = 'video' | 'image' | 'audio' | 'social_audio' | 'text';
|
|
750
|
+
export type MediaType = 'video' | 'image' | 'audio' | 'social_audio' | 'text' | 'account' | 'date';
|
|
751
751
|
/**
|
|
752
752
|
* Selection order configuration for media nodes
|
|
753
753
|
*/
|