UNPKG

camstreamerlib

Version:

Helper library for CamStreamer ACAP applications.

543 lines (542 loc) 15.5 kB
import z from 'zod'; export declare const youtubeSchema: z.ZodObject<{ streamId: z.ZodString; enabled: z.ZodBoolean; active: z.ZodBoolean; title: z.ZodString; trigger: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{ type: z.ZodLiteral<"manual">; port: z.ZodOptional<z.ZodNumber>; }, "strip", z.ZodTypeAny, { type: "manual"; port?: number | undefined; }, { type: "manual"; port?: number | undefined; }>, z.ZodObject<{ type: z.ZodLiteral<"onetime">; startTime: z.ZodNumber; stopTime: z.ZodNumber; everActivated: z.ZodBoolean; prepareAheadS: z.ZodOptional<z.ZodNumber>; }, "strip", z.ZodTypeAny, { type: "onetime"; startTime: number; stopTime: number; everActivated: boolean; prepareAheadS?: number | undefined; }, { type: "onetime"; startTime: number; stopTime: number; everActivated: boolean; prepareAheadS?: number | undefined; }>, z.ZodObject<{ type: z.ZodLiteral<"recurrent">; schedule: z.ZodArray<z.ZodObject<{ start: z.ZodObject<{ day: z.ZodNumber; timeS: z.ZodNumber; }, "strip", z.ZodTypeAny, { day: number; timeS: number; }, { day: number; timeS: number; }>; stop: z.ZodObject<{ day: z.ZodNumber; timeS: z.ZodNumber; }, "strip", z.ZodTypeAny, { day: number; timeS: number; }, { day: number; timeS: number; }>; isActive: z.ZodBoolean; }, "strip", z.ZodTypeAny, { start: { day: number; timeS: number; }; stop: { day: number; timeS: number; }; isActive: boolean; }, { start: { day: number; timeS: number; }; stop: { day: number; timeS: number; }; isActive: boolean; }>, "many">; prepareAheadS: z.ZodOptional<z.ZodNumber>; }, "strip", z.ZodTypeAny, { type: "recurrent"; schedule: { start: { day: number; timeS: number; }; stop: { day: number; timeS: number; }; isActive: boolean; }[]; prepareAheadS?: number | undefined; }, { type: "recurrent"; schedule: { start: { day: number; timeS: number; }; stop: { day: number; timeS: number; }; isActive: boolean; }[]; prepareAheadS?: number | undefined; }>]>; video: z.ZodObject<{ output: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{ type: z.ZodLiteral<"video">; url: z.ZodNullable<z.ZodString>; parameters: z.ZodString; saveToSdCard: z.ZodOptional<z.ZodObject<{ ruleId: z.ZodString; configurationId: z.ZodString; }, "strip", z.ZodTypeAny, { ruleId: string; configurationId: string; }, { ruleId: string; configurationId: string; }>>; }, "strip", z.ZodTypeAny, { type: "video"; url: string | null; parameters: string; saveToSdCard?: { ruleId: string; configurationId: string; } | undefined; }, { type: "video"; url: string | null; parameters: string; saveToSdCard?: { ruleId: string; configurationId: string; } | undefined; }>, z.ZodObject<{ type: z.ZodLiteral<"images">; url: z.ZodNullable<z.ZodString>; imageIntervalS: z.ZodNumber; }, "strip", z.ZodTypeAny, { type: "images"; url: string | null; imageIntervalS: number; }, { type: "images"; url: string | null; imageIntervalS: number; }>, z.ZodObject<{ type: z.ZodLiteral<"none">; saveToSdCard: z.ZodObject<{ ruleId: z.ZodString; configurationId: z.ZodString; }, "strip", z.ZodTypeAny, { ruleId: string; configurationId: string; }, { ruleId: string; configurationId: string; }>; }, "strip", z.ZodTypeAny, { type: "none"; saveToSdCard: { ruleId: string; configurationId: string; }; }, { type: "none"; saveToSdCard: { ruleId: string; configurationId: string; }; }>]>; input: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{ type: z.ZodLiteral<"RTSP_URL">; url: z.ZodString; internalVapixParameters: z.ZodString; }, "strip", z.ZodTypeAny, { type: "RTSP_URL"; url: string; internalVapixParameters: string; }, { type: "RTSP_URL"; url: string; internalVapixParameters: string; }>, z.ZodObject<{ type: z.ZodLiteral<"CSw">; }, "strip", z.ZodTypeAny, { type: "CSw"; }, { type: "CSw"; }>, z.ZodObject<{ type: z.ZodLiteral<"CRS">; internalVapixParameters: z.ZodString; userVapixParameters: z.ZodString; }, "strip", z.ZodTypeAny, { type: "CRS"; internalVapixParameters: string; userVapixParameters: string; }, { type: "CRS"; internalVapixParameters: string; userVapixParameters: string; }>]>; delayS: z.ZodOptional<z.ZodNumber>; }, "strip", z.ZodTypeAny, { output: { type: "video"; url: string | null; parameters: string; saveToSdCard?: { ruleId: string; configurationId: string; } | undefined; } | { type: "images"; url: string | null; imageIntervalS: number; } | { type: "none"; saveToSdCard: { ruleId: string; configurationId: string; }; }; input: { type: "RTSP_URL"; url: string; internalVapixParameters: string; } | { type: "CSw"; } | { type: "CRS"; internalVapixParameters: string; userVapixParameters: string; }; delayS?: number | undefined; }, { output: { type: "video"; url: string | null; parameters: string; saveToSdCard?: { ruleId: string; configurationId: string; } | undefined; } | { type: "images"; url: string | null; imageIntervalS: number; } | { type: "none"; saveToSdCard: { ruleId: string; configurationId: string; }; }; input: { type: "RTSP_URL"; url: string; internalVapixParameters: string; } | { type: "CSw"; } | { type: "CRS"; internalVapixParameters: string; userVapixParameters: string; }; delayS?: number | undefined; }>; audio: z.ZodDiscriminatedUnion<"source", [z.ZodObject<{ source: z.ZodLiteral<"none">; }, "strip", z.ZodTypeAny, { source: "none"; }, { source: "none"; }>, z.ZodObject<{ source: z.ZodLiteral<"microphone">; audioChannelNbr: z.ZodNumber; forceStereo: z.ZodBoolean; }, "strip", z.ZodTypeAny, { source: "microphone"; audioChannelNbr: number; forceStereo: boolean; }, { source: "microphone"; audioChannelNbr: number; forceStereo: boolean; }>, z.ZodObject<{ source: z.ZodLiteral<"file">; name: z.ZodString; path: z.ZodString; forceStereo: z.ZodBoolean; }, "strip", z.ZodTypeAny, { path: string; name: string; source: "file"; forceStereo: boolean; }, { path: string; name: string; source: "file"; forceStereo: boolean; }>, z.ZodObject<{ source: z.ZodLiteral<"url">; name: z.ZodString; url: z.ZodString; avSyncMsec: z.ZodNumber; forceStereo: z.ZodBoolean; }, "strip", z.ZodTypeAny, { name: string; url: string; source: "url"; forceStereo: boolean; avSyncMsec: number; }, { name: string; url: string; source: "url"; forceStereo: boolean; avSyncMsec: number; }>]>; status: z.ZodObject<{ led: z.ZodBoolean; port: z.ZodOptional<z.ZodNumber>; }, "strip", z.ZodTypeAny, { led: boolean; port?: number | undefined; }, { led: boolean; port?: number | undefined; }>; } & { platform: z.ZodLiteral<"youtube">; description: z.ZodOptional<z.ZodString>; playlists: z.ZodArray<z.ZodString, "many">; tags: z.ZodArray<z.ZodString, "many">; notificationEmails: z.ZodArray<z.ZodString, "many">; streamPrivacy: z.ZodUnion<[z.ZodLiteral<"public">, z.ZodLiteral<"unlisted">, z.ZodLiteral<"private">]>; latency: z.ZodUnion<[z.ZodLiteral<"normal">, z.ZodLiteral<"low">, z.ZodLiteral<"ultra_low">]>; afterEndStatus: z.ZodUnion<[z.ZodLiteral<"no_change">, z.ZodLiteral<"public">, z.ZodLiteral<"unlisted">, z.ZodLiteral<"private">]>; dvr: z.ZodBoolean; hasWatchdogs: z.ZodBoolean; countdown: z.ZodOptional<z.ZodBoolean>; streamingProtocol: z.ZodUnion<[z.ZodLiteral<"RTMP">, z.ZodLiteral<"RTMPS">, z.ZodLiteral<"HLS">]>; }, "strip", z.ZodTypeAny, { status: { led: boolean; port?: number | undefined; }; streamId: string; enabled: boolean; active: boolean; title: string; trigger: { type: "manual"; port?: number | undefined; } | { type: "onetime"; startTime: number; stopTime: number; everActivated: boolean; prepareAheadS?: number | undefined; } | { type: "recurrent"; schedule: { start: { day: number; timeS: number; }; stop: { day: number; timeS: number; }; isActive: boolean; }[]; prepareAheadS?: number | undefined; }; video: { output: { type: "video"; url: string | null; parameters: string; saveToSdCard?: { ruleId: string; configurationId: string; } | undefined; } | { type: "images"; url: string | null; imageIntervalS: number; } | { type: "none"; saveToSdCard: { ruleId: string; configurationId: string; }; }; input: { type: "RTSP_URL"; url: string; internalVapixParameters: string; } | { type: "CSw"; } | { type: "CRS"; internalVapixParameters: string; userVapixParameters: string; }; delayS?: number | undefined; }; audio: { source: "none"; } | { source: "microphone"; audioChannelNbr: number; forceStereo: boolean; } | { path: string; name: string; source: "file"; forceStereo: boolean; } | { name: string; url: string; source: "url"; forceStereo: boolean; avSyncMsec: number; }; streamPrivacy: "public" | "unlisted" | "private"; platform: "youtube"; playlists: string[]; tags: string[]; notificationEmails: string[]; latency: "normal" | "low" | "ultra_low"; afterEndStatus: "public" | "unlisted" | "private" | "no_change"; dvr: boolean; hasWatchdogs: boolean; streamingProtocol: "RTMP" | "RTMPS" | "HLS"; description?: string | undefined; countdown?: boolean | undefined; }, { status: { led: boolean; port?: number | undefined; }; streamId: string; enabled: boolean; active: boolean; title: string; trigger: { type: "manual"; port?: number | undefined; } | { type: "onetime"; startTime: number; stopTime: number; everActivated: boolean; prepareAheadS?: number | undefined; } | { type: "recurrent"; schedule: { start: { day: number; timeS: number; }; stop: { day: number; timeS: number; }; isActive: boolean; }[]; prepareAheadS?: number | undefined; }; video: { output: { type: "video"; url: string | null; parameters: string; saveToSdCard?: { ruleId: string; configurationId: string; } | undefined; } | { type: "images"; url: string | null; imageIntervalS: number; } | { type: "none"; saveToSdCard: { ruleId: string; configurationId: string; }; }; input: { type: "RTSP_URL"; url: string; internalVapixParameters: string; } | { type: "CSw"; } | { type: "CRS"; internalVapixParameters: string; userVapixParameters: string; }; delayS?: number | undefined; }; audio: { source: "none"; } | { source: "microphone"; audioChannelNbr: number; forceStereo: boolean; } | { path: string; name: string; source: "file"; forceStereo: boolean; } | { name: string; url: string; source: "url"; forceStereo: boolean; avSyncMsec: number; }; streamPrivacy: "public" | "unlisted" | "private"; platform: "youtube"; playlists: string[]; tags: string[]; notificationEmails: string[]; latency: "normal" | "low" | "ultra_low"; afterEndStatus: "public" | "unlisted" | "private" | "no_change"; dvr: boolean; hasWatchdogs: boolean; streamingProtocol: "RTMP" | "RTMPS" | "HLS"; description?: string | undefined; countdown?: boolean | undefined; }>; export type TYouTubeStreamingProtocolType = z.infer<typeof youtubeSchema>['streamingProtocol'];