/** * This file was auto-generated by Fern from our API Definition. */ /** * @example * { * name: "My Example Automation", * description: "This workflow will run whenever new media is created.", * trigger: { * kind: "event", * event: "media.created" * }, * workflow: [{ * kind: "description" * }, { * kind: "image", * ref: "thumbnail" * }, { * kind: "video", * next: [{ * kind: "subtitles", * ref: "subtitles" * }] * }], * status: "active" * } */ export interface AutomationsCreateRequest { name?: string; description?: string; trigger: AutomationsCreateRequest.Trigger; workflow: AutomationsCreateRequest.Workflow.Item[]; status?: AutomationsCreateRequest.Status; } export declare namespace AutomationsCreateRequest { interface Trigger { kind: "event"; event: "media.created"; } type Workflow = Workflow.Item[]; namespace Workflow { interface Item { kind: Item.Kind; ref?: string; next?: Item.Next.Item[]; } namespace Item { type Kind = "video" | "image" | "audio" | "chapters" | "subtitles" | "thumbnails" | "nsfw" | "speech" | "description" | "outline" | "prompt" | "http"; const Kind: { readonly Video: "video"; readonly Image: "image"; readonly Audio: "audio"; readonly Chapters: "chapters"; readonly Subtitles: "subtitles"; readonly Thumbnails: "thumbnails"; readonly Nsfw: "nsfw"; readonly Speech: "speech"; readonly Description: "description"; readonly Outline: "outline"; readonly Prompt: "prompt"; readonly Http: "http"; }; type Next = Next.Item[]; namespace Next { interface Item { kind?: string; ref?: string; } } } } type Status = "active" | "paused"; const Status: { readonly Active: "active"; readonly Paused: "paused"; }; }