ugcinc 3.40.0 → 3.42.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 +15 -0
- package/dist/index.d.ts +1 -1
- package/dist/types.d.ts +34 -0
- package/package.json +1 -1
package/dist/automations.js
CHANGED
|
@@ -516,6 +516,21 @@ function getAllNodes() {
|
|
|
516
516
|
// - index (if randomConfig.exposeIndex is true, array mode only)
|
|
517
517
|
outputs: [],
|
|
518
518
|
},
|
|
519
|
+
{
|
|
520
|
+
type: "if",
|
|
521
|
+
label: "If",
|
|
522
|
+
description: "Conditional branching based on boolean logic",
|
|
523
|
+
category: "Control Flow",
|
|
524
|
+
nodeCategory: "generator",
|
|
525
|
+
// Dynamic inputs based on ifConfig:
|
|
526
|
+
// - Boolean inputs from ifConfig.booleanInputs (type: boolean)
|
|
527
|
+
// - Passthrough inputs from ifConfig.passthroughInputs (various types)
|
|
528
|
+
inputs: [],
|
|
529
|
+
// Dynamic outputs: for each passthrough input, creates:
|
|
530
|
+
// - true-{id} (same type as input, receives value when condition is true)
|
|
531
|
+
// - false-{id} (same type as input, receives value when condition is false)
|
|
532
|
+
outputs: [],
|
|
533
|
+
},
|
|
519
534
|
// === Terminal nodes ===
|
|
520
535
|
{
|
|
521
536
|
type: "auto-post",
|
package/dist/index.d.ts
CHANGED
|
@@ -18,4 +18,4 @@ export { MediaClient } from './media';
|
|
|
18
18
|
export { CommentsClient } from './comments';
|
|
19
19
|
export type { RenderJobResponse, RenderJobStatus, SubmitImageRenderJobParams, SubmitVideoRenderJobParams, SubmitScreenshotAnimationRenderJobParams, RenderVideoEditorConfig, } from './render';
|
|
20
20
|
export type { ClientConfig, } from './base';
|
|
21
|
-
export type { SuccessResponse, ErrorResponse, ApiResponse, Account, AccountStat, AccountTask, EditProfileInfo, Task, TaskType, Post, PostType, PostStatus, PostStat, ApiKey, EditorConfig, VideoEditorNodeConfig, VideoEditorChannel, VideoEditorSegment, VideoEditorVideoSegment, VideoEditorAudioSegment, VideoEditorImageSegment, VideoEditorTextSegment, TimeMode, SegmentTimelinePosition, ImageEditorNodeConfig, ImageEditorElement, ImageEditorNodeInput, ImageEditorNodeOutput, DimensionPresetKey, EditorChannel, TimeValue, BaseSegmentProps, VisualSegmentProps, EditorSegment, VideoSegment, AudioSegment, ImageSegment, TextSegment, StaticSegment, PositionAnchor, RelativePositionConfig, GetAccountsParams, GetAccountStatsParams, GetAccountStatusParams, UpdateAccountInfoParams, UpdateAccountSocialParams, GetTasksParams, GetPostsParams, CreateSlideshowParams, GetPostStatsParams, GetPostStatusParams, CreateVideoParams, RefreshStatsParams, RefreshStatsResponse, RefreshStatsError, DailyAggregatedStat, GetDailyAggregatedStatsParams, DailyPostStat, GetDailyPostStatsParams, TopAccount, GetTopAccountsParams, TopPost, GetTopPostsParams, MediaType, NodePort, ResolvedPorts, NodeControlConfig, NodeTypeEnum, WorkflowNodeDefinition, WorkflowDefinition, CanvasState, TemplateNode, AutomationTemplate, AutomationRun, NodeRun, ExecutorNode, ExecutionEdge, OutputSchemaProperty, SelectionMode, ExhaustionBehavior, SelectionConfig, SelectionState, OutputMode, NodeOutputValues, OutputInput, OutputNodeConfig, ManualTriggerOutput, ManualTriggerNodeConfig, TriggerIterationMode, IterationExhaustionBehavior, CollectionSelectionMode, TriggerCollectionConfig, DayOfWeek, RecurrenceMediaOutput, RecurrenceMediaConfig, RecurrenceNodeConfig, AccountNodeConfig, MediaNodeEnabledType, RecurrenceMediaEnabledType, MediaNodeOutput, MediaNodeConfig, PostSchedulingMode, PostSchedulingConfig, AutoPostMode, AutoPostInputType, AutoPostInput, AutoPostNodeConfig, SaveToMediaInput, SaveToMediaNodeConfig, DeduplicateNodeConfig, ForEachOutputProperty, ForEachInputPort, ForEachNodeConfig, RandomValueType, RandomInputPort, RandomNodeMode, RandomNodeConfig, VideoImportPlatform, VideoImportQuality, VideoImportNodeConfig, AutoCaptionPreset, AutoCaptionFontWeight, AutoCaptionPosition, AutoCaptionNodeConfig, ScreenshotAnimationNodeConfig, VideoGenerationNodeConfig, ArrayType, PortType, LLMOutputField, LLMNodeConfig, UserMedia, SocialAudio, Media, GetMediaParams, CreateSocialAudioParams, UploadMediaParams, UploadMediaResponse, UpdateMediaTagParams, DeleteMediaParams, DeleteMediaResponse, CreateMediaFromUrlParams, ImportTextParams, ImportTextResponse, Comment, CommentStatus, CreateCommentParams, CreateCommentResponse, GetCommentsParams, ValidationErrorType, ValidationError, ExportedNode, ExportedConnection, ExportedTemplate, AutomationExport, ExportedExecutor, ExportedEdge, ExportedRun, AutomationRunExport, } from './types';
|
|
21
|
+
export type { SuccessResponse, ErrorResponse, ApiResponse, Account, AccountStat, AccountTask, EditProfileInfo, Task, TaskType, Post, PostType, PostStatus, PostStat, ApiKey, EditorConfig, VideoEditorNodeConfig, VideoEditorChannel, VideoEditorSegment, VideoEditorVideoSegment, VideoEditorAudioSegment, VideoEditorImageSegment, VideoEditorTextSegment, TimeMode, SegmentTimelinePosition, ImageEditorNodeConfig, ImageEditorElement, ImageEditorNodeInput, ImageEditorNodeOutput, DimensionPresetKey, EditorChannel, TimeValue, BaseSegmentProps, VisualSegmentProps, EditorSegment, VideoSegment, AudioSegment, ImageSegment, TextSegment, StaticSegment, PositionAnchor, RelativePositionConfig, GetAccountsParams, GetAccountStatsParams, GetAccountStatusParams, UpdateAccountInfoParams, UpdateAccountSocialParams, GetTasksParams, GetPostsParams, CreateSlideshowParams, GetPostStatsParams, GetPostStatusParams, CreateVideoParams, RefreshStatsParams, RefreshStatsResponse, RefreshStatsError, DailyAggregatedStat, GetDailyAggregatedStatsParams, DailyPostStat, GetDailyPostStatsParams, TopAccount, GetTopAccountsParams, TopPost, GetTopPostsParams, MediaType, NodePort, ResolvedPorts, NodeControlConfig, NodeTypeEnum, WorkflowNodeDefinition, WorkflowDefinition, CanvasState, TemplateNode, AutomationTemplate, AutomationRun, NodeRun, ExecutorNode, ExecutionEdge, OutputSchemaProperty, SelectionMode, ExhaustionBehavior, SelectionConfig, SelectionState, OutputMode, NodeOutputValues, OutputInput, OutputNodeConfig, ManualTriggerOutput, ManualTriggerNodeConfig, TriggerIterationMode, IterationExhaustionBehavior, CollectionSelectionMode, TriggerCollectionConfig, DayOfWeek, RecurrenceMediaOutput, RecurrenceMediaConfig, RecurrenceNodeConfig, AccountNodeConfig, MediaNodeEnabledType, RecurrenceMediaEnabledType, MediaNodeOutput, MediaNodeConfig, PostSchedulingMode, PostSchedulingConfig, AutoPostMode, AutoPostInputType, AutoPostInput, AutoPostNodeConfig, SaveToMediaInput, SaveToMediaNodeConfig, DeduplicateNodeConfig, ForEachOutputProperty, ForEachInputPort, ForEachNodeConfig, RandomValueType, RandomInputPort, RandomNodeMode, RandomNodeConfig, IfLogicOperator, IfBooleanInput, IfPassthroughInput, IfNodeConfig, VideoImportPlatform, VideoImportQuality, VideoImportNodeConfig, AutoCaptionPreset, AutoCaptionFontWeight, AutoCaptionPosition, AutoCaptionNodeConfig, ScreenshotAnimationNodeConfig, VideoGenerationNodeConfig, ArrayType, PortType, LLMOutputField, LLMNodeConfig, UserMedia, SocialAudio, Media, GetMediaParams, CreateSocialAudioParams, UploadMediaParams, UploadMediaResponse, UpdateMediaTagParams, DeleteMediaParams, DeleteMediaResponse, CreateMediaFromUrlParams, ImportTextParams, ImportTextResponse, Comment, CommentStatus, CreateCommentParams, CreateCommentResponse, GetCommentsParams, ValidationErrorType, ValidationError, ExportedNode, ExportedConnection, ExportedTemplate, AutomationExport, ExportedExecutor, ExportedEdge, ExportedRun, AutomationRunExport, } from './types';
|
package/dist/types.d.ts
CHANGED
|
@@ -962,6 +962,7 @@ export interface WorkflowNodeDefinition {
|
|
|
962
962
|
customModelConfig?: CustomModelNodeConfig;
|
|
963
963
|
forEachConfig?: ForEachNodeConfig;
|
|
964
964
|
randomConfig?: RandomNodeConfig;
|
|
965
|
+
ifConfig?: IfNodeConfig;
|
|
965
966
|
autoCaptionConfig?: AutoCaptionNodeConfig;
|
|
966
967
|
screenshotAnimationConfig?: ScreenshotAnimationNodeConfig;
|
|
967
968
|
};
|
|
@@ -1276,6 +1277,39 @@ export interface RandomNodeConfig {
|
|
|
1276
1277
|
/** Input ports with probability weights (multi-input mode only) */
|
|
1277
1278
|
inputPorts?: RandomInputPort[];
|
|
1278
1279
|
}
|
|
1280
|
+
/**
|
|
1281
|
+
* If node logic operators
|
|
1282
|
+
*/
|
|
1283
|
+
export type IfLogicOperator = 'and' | 'or' | 'xor' | 'nor';
|
|
1284
|
+
/**
|
|
1285
|
+
* If node boolean input - receives boolean values for logic evaluation
|
|
1286
|
+
*/
|
|
1287
|
+
export interface IfBooleanInput {
|
|
1288
|
+
/** The input port ID (lowercase, hyphens/underscores only) */
|
|
1289
|
+
id: string;
|
|
1290
|
+
}
|
|
1291
|
+
/**
|
|
1292
|
+
* If node passthrough input - values that get routed to true/false outputs
|
|
1293
|
+
*/
|
|
1294
|
+
export interface IfPassthroughInput {
|
|
1295
|
+
/** The input port ID (lowercase, hyphens/underscores only) */
|
|
1296
|
+
id: string;
|
|
1297
|
+
/** The value type */
|
|
1298
|
+
type: 'image' | 'video' | 'audio' | 'text' | 'number' | 'boolean' | 'account' | 'object';
|
|
1299
|
+
/** Whether this is an array type */
|
|
1300
|
+
isArray?: boolean;
|
|
1301
|
+
}
|
|
1302
|
+
/**
|
|
1303
|
+
* If node configuration - conditional branching based on boolean logic
|
|
1304
|
+
*/
|
|
1305
|
+
export interface IfNodeConfig {
|
|
1306
|
+
/** Logic operator to combine boolean inputs */
|
|
1307
|
+
logicOperator: IfLogicOperator;
|
|
1308
|
+
/** Boolean inputs for logic evaluation (at least one required) */
|
|
1309
|
+
booleanInputs: IfBooleanInput[];
|
|
1310
|
+
/** Passthrough inputs that get routed to true/false outputs (at least one required) */
|
|
1311
|
+
passthroughInputs: IfPassthroughInput[];
|
|
1312
|
+
}
|
|
1279
1313
|
/**
|
|
1280
1314
|
* Supported platforms for video import
|
|
1281
1315
|
* Note: YouTube is not yet implemented
|