ugcinc 3.71.0 → 3.73.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 +23 -0
- package/dist/index.d.ts +1 -1
- package/dist/types.d.ts +25 -2
- package/package.json +1 -1
package/dist/automations.js
CHANGED
|
@@ -602,6 +602,29 @@ function getAllNodes() {
|
|
|
602
602
|
// - {branch-key}-{passthrough-id} (same type as input)
|
|
603
603
|
outputs: [],
|
|
604
604
|
},
|
|
605
|
+
{
|
|
606
|
+
type: "collect",
|
|
607
|
+
label: "Collect",
|
|
608
|
+
description: "Collect outputs from a for-each loop into an array",
|
|
609
|
+
category: "Control Flow",
|
|
610
|
+
nodeCategory: "generator",
|
|
611
|
+
// Input accepts any type from inside the loop
|
|
612
|
+
inputs: [
|
|
613
|
+
{
|
|
614
|
+
id: "value",
|
|
615
|
+
type: ["image", "video", "audio", "text", "object", "boolean", "number"],
|
|
616
|
+
required: true,
|
|
617
|
+
},
|
|
618
|
+
],
|
|
619
|
+
// Output is an array of the input type
|
|
620
|
+
outputs: [
|
|
621
|
+
{
|
|
622
|
+
id: "array",
|
|
623
|
+
type: ["image[]", "video[]", "audio[]", "text[]", "object[]"],
|
|
624
|
+
required: true,
|
|
625
|
+
},
|
|
626
|
+
],
|
|
627
|
+
},
|
|
605
628
|
// === Terminal nodes ===
|
|
606
629
|
{
|
|
607
630
|
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, SubmitInstagramDmRenderJobParams, SubmitIMessageDmRenderJobParams, IgDmMessage, ImDmMessage, 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, IfLogicOperator, IfBooleanInput, IfPassthroughInput, IfNodeConfig, RandomRouteBranch, RandomRoutePassthroughInput, RandomRouteObjectField, RandomRouteNodeConfig, BranchDefinition, BranchValueConfig, BranchPassthroughInput, BranchNodeConfig, VideoImportPlatform, VideoImportQuality, VideoImportNodeConfig, AutoCaptionPreset, AutoCaptionFontWeight, AutoCaptionPosition, AutoCaptionNodeConfig, ScreenshotAnimationNodeConfig, CreateDmMessage, CreateDmNodeConfig, VideoGenerationNodeConfig, ArrayType, PortType, LLMOutputField, LLMNodeConfig, UserMedia, SocialAudio, Media, MediaUse, GetMediaParams, CreateSocialAudioParams, UploadMediaParams, UploadMediaResponse, UpdateMediaTagParams, DeleteMediaParams, DeleteMediaResponse, CreateMediaFromUrlParams, ImportTextParams, ImportTextResponse, GetMediaUseParams, GetMediaUseResponse, 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, ObjectSchemaField, 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, RandomRouteBranch, RandomRoutePassthroughInput, RandomRouteObjectField, RandomRouteNodeConfig, BranchDefinition, BranchValueConfig, BranchPassthroughInput, BranchNodeConfig, VideoImportPlatform, VideoImportQuality, VideoImportNodeConfig, AutoCaptionPreset, AutoCaptionFontWeight, AutoCaptionPosition, AutoCaptionNodeConfig, ScreenshotAnimationNodeConfig, CreateDmMessage, CreateDmNodeConfig, VideoGenerationNodeConfig, ArrayType, PortType, LLMOutputField, LLMNodeConfig, UserMedia, SocialAudio, Media, MediaUse, GetMediaParams, CreateSocialAudioParams, UploadMediaParams, UploadMediaResponse, UpdateMediaTagParams, DeleteMediaParams, DeleteMediaResponse, CreateMediaFromUrlParams, ImportTextParams, ImportTextResponse, GetMediaUseParams, GetMediaUseResponse, Comment, CommentStatus, CreateCommentParams, CreateCommentResponse, GetCommentsParams, ValidationErrorType, ValidationError, ExportedNode, ExportedConnection, ExportedTemplate, AutomationExport, ExportedExecutor, ExportedEdge, ExportedRun, AutomationRunExport, } from './types';
|
package/dist/types.d.ts
CHANGED
|
@@ -846,7 +846,7 @@ export interface NodeControlConfig {
|
|
|
846
846
|
*/
|
|
847
847
|
isInitializer?: boolean;
|
|
848
848
|
}
|
|
849
|
-
export type NodeTypeEnum = 'social-audio' | 'text' | 'media' | 'video-import' | 'image-composer' | 'video-composer' | 'generate-image' | 'generate-video' | 'custom-model' | 'llm' | 'output' | 'manual-trigger' | 'recurrence' | 'compose-workflow' | 'account' | 'auto-post' | 'save-to-media' | 'deduplicate' | 'for-each' | 'random' | 'random-route' | 'branch' | 'if' | 'not' | 'transcript' | 'auto-caption' | 'screenshot-animation' | 'create-dm';
|
|
849
|
+
export type NodeTypeEnum = 'social-audio' | 'text' | 'media' | 'video-import' | 'image-composer' | 'video-composer' | 'generate-image' | 'generate-video' | 'custom-model' | 'llm' | 'output' | 'manual-trigger' | 'recurrence' | 'compose-workflow' | 'account' | 'auto-post' | 'save-to-media' | 'deduplicate' | 'for-each' | 'random' | 'random-route' | 'branch' | 'if' | 'not' | 'transcript' | 'auto-caption' | 'screenshot-animation' | 'create-dm' | 'collect';
|
|
850
850
|
export interface OutputSchemaProperty {
|
|
851
851
|
type: 'string' | 'number' | 'boolean' | 'array' | 'object';
|
|
852
852
|
items?: 'string' | 'number' | 'boolean';
|
|
@@ -970,6 +970,7 @@ export interface WorkflowNodeDefinition {
|
|
|
970
970
|
autoCaptionConfig?: AutoCaptionNodeConfig;
|
|
971
971
|
screenshotAnimationConfig?: ScreenshotAnimationNodeConfig;
|
|
972
972
|
createDmConfig?: CreateDmNodeConfig;
|
|
973
|
+
collectConfig?: CollectNodeConfig;
|
|
973
974
|
};
|
|
974
975
|
}
|
|
975
976
|
export interface OutputInput {
|
|
@@ -982,13 +983,25 @@ export interface OutputInput {
|
|
|
982
983
|
export interface OutputNodeConfig {
|
|
983
984
|
inputs: OutputInput[];
|
|
984
985
|
}
|
|
986
|
+
/**
|
|
987
|
+
* Object schema field definition for manual trigger object outputs
|
|
988
|
+
* Simplified version without array/length constraints
|
|
989
|
+
*/
|
|
990
|
+
export interface ObjectSchemaField {
|
|
991
|
+
name: string;
|
|
992
|
+
type: 'string' | 'number' | 'boolean' | 'object';
|
|
993
|
+
/** For nested objects - nested field definitions (max 3 levels of nesting) */
|
|
994
|
+
objectSchema?: ObjectSchemaField[];
|
|
995
|
+
}
|
|
985
996
|
/**
|
|
986
997
|
* Manual Trigger node output definition
|
|
987
998
|
*/
|
|
988
999
|
export interface ManualTriggerOutput {
|
|
989
1000
|
id: string;
|
|
990
|
-
type: 'image' | 'video' | 'audio' | 'text' | 'social_audio' | 'account' | 'boolean';
|
|
1001
|
+
type: 'image' | 'video' | 'audio' | 'text' | 'social_audio' | 'account' | 'boolean' | 'object';
|
|
991
1002
|
isArray?: boolean;
|
|
1003
|
+
/** Schema for object types - describes the structure of the object */
|
|
1004
|
+
objectSchema?: ObjectSchemaField[];
|
|
992
1005
|
}
|
|
993
1006
|
/**
|
|
994
1007
|
* Iteration mode for trigger nodes with account iteration
|
|
@@ -1542,6 +1555,16 @@ export interface CreateDmNodeConfig {
|
|
|
1542
1555
|
userHasStory: boolean;
|
|
1543
1556
|
};
|
|
1544
1557
|
}
|
|
1558
|
+
/**
|
|
1559
|
+
* Collect node configuration - collects outputs from for-each loop into an array
|
|
1560
|
+
* Note: Most config is set during expansion, not by user
|
|
1561
|
+
*/
|
|
1562
|
+
export interface CollectNodeConfig {
|
|
1563
|
+
/** Expected number of items to collect (set during for-each expansion) */
|
|
1564
|
+
expectedCount?: number;
|
|
1565
|
+
/** Template ID of the for-each loop this collects from (for validation) */
|
|
1566
|
+
forEachTemplateId?: string;
|
|
1567
|
+
}
|
|
1545
1568
|
/**
|
|
1546
1569
|
* Video Generation Model IDs
|
|
1547
1570
|
* Text-to-video models take just a prompt, image-to-video models require an image input
|