@shotstack/schemas 1.4.3 → 1.4.5
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/api.bundled.json +12 -2
- package/dist/schema.d.ts +6 -0
- package/dist/zod/zod.gen.cjs +916 -1063
- package/dist/zod/zod.gen.d.ts +323 -635
- package/dist/zod/zod.gen.js +917 -1064
- package/dist/zod/zod.gen.ts +1599 -1531
- package/package.json +1 -1
package/dist/zod/zod.gen.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// This file is auto-generated by @hey-api/openapi-ts
|
|
2
2
|
|
|
3
|
-
import { z } from
|
|
3
|
+
import { z } from "zod";
|
|
4
4
|
|
|
5
5
|
export const editRootSchema = z.unknown();
|
|
6
6
|
|
|
@@ -38,10 +38,10 @@ export const uploadRootSchema = z.unknown();
|
|
|
38
38
|
* Displays a background box behind the caption text.
|
|
39
39
|
*/
|
|
40
40
|
export const captionpropertiesCaptionBackgroundSchema = z.object({
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
41
|
+
color: z.optional(z.string()),
|
|
42
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
43
|
+
padding: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
44
|
+
borderRadius: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
45
45
|
});
|
|
46
46
|
|
|
47
47
|
export const captionBackgroundSchema = captionpropertiesCaptionBackgroundSchema;
|
|
@@ -50,13 +50,13 @@ export const captionBackgroundSchema = captionpropertiesCaptionBackgroundSchema;
|
|
|
50
50
|
* Font properties for captions text.
|
|
51
51
|
*/
|
|
52
52
|
export const captionpropertiesCaptionFontSchema = z.object({
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
53
|
+
family: z.optional(z.string()),
|
|
54
|
+
color: z.optional(z.string()),
|
|
55
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
56
|
+
size: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
57
|
+
lineHeight: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
58
|
+
stroke: z.optional(z.string()),
|
|
59
|
+
strokeWidth: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
60
60
|
});
|
|
61
61
|
|
|
62
62
|
export const captionFontSchema = captionpropertiesCaptionFontSchema;
|
|
@@ -65,9 +65,9 @@ export const captionFontSchema = captionpropertiesCaptionFontSchema;
|
|
|
65
65
|
* The margin properties for captions. Margins are used to position the caption text and background on the screen.
|
|
66
66
|
*/
|
|
67
67
|
export const captionpropertiesCaptionMarginSchema = z.object({
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
68
|
+
top: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
69
|
+
left: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
70
|
+
right: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
71
71
|
});
|
|
72
72
|
|
|
73
73
|
export const captionMarginSchema = captionpropertiesCaptionMarginSchema;
|
|
@@ -85,13 +85,13 @@ export const captionMarginSchema = captionpropertiesCaptionMarginSchema;
|
|
|
85
85
|
*
|
|
86
86
|
*/
|
|
87
87
|
export const captionassetCaptionAssetSchema = z.object({
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
88
|
+
type: z.enum(["caption"]),
|
|
89
|
+
src: z.string(),
|
|
90
|
+
font: z.optional(captionpropertiesCaptionFontSchema),
|
|
91
|
+
background: z.optional(captionpropertiesCaptionBackgroundSchema),
|
|
92
|
+
margin: z.optional(captionpropertiesCaptionMarginSchema),
|
|
93
|
+
trim: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
94
|
+
speed: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(10))),
|
|
95
95
|
});
|
|
96
96
|
|
|
97
97
|
export const captionAssetSchema = captionassetCaptionAssetSchema;
|
|
@@ -100,9 +100,9 @@ export const captionAssetSchema = captionassetCaptionAssetSchema;
|
|
|
100
100
|
* Chroma key is a technique that replaces a specific color in a video with a different background image or video, enabling seamless integration of diverse environments. Commonly used for green screen and blue screen effects.
|
|
101
101
|
*/
|
|
102
102
|
export const chromakeyChromaKeySchema = z.object({
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
103
|
+
color: z.string().regex(/^#[0-9a-fA-F]{6}$/),
|
|
104
|
+
threshold: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(0).lte(250))),
|
|
105
|
+
halo: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(0).lte(250))),
|
|
106
106
|
});
|
|
107
107
|
|
|
108
108
|
export const chromaKeySchema = chromakeyChromaKeySchema;
|
|
@@ -111,19 +111,14 @@ export const chromaKeySchema = chromakeyChromaKeySchema;
|
|
|
111
111
|
* Options for the D-ID text-to-avatar service. Set the text to be converted to an avatar and configure the avatar and background. The output will be generated as an MP4 video file.
|
|
112
112
|
*/
|
|
113
113
|
export const didTextToAvatarOptionsDidTextToAvatarOptionsSchema = z.object({
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
'lana',
|
|
119
|
-
'lily',
|
|
120
|
-
'matt',
|
|
121
|
-
'rian'
|
|
122
|
-
]),
|
|
123
|
-
background: z.optional(z.string())
|
|
114
|
+
type: z.enum(["text-to-avatar"]),
|
|
115
|
+
text: z.string(),
|
|
116
|
+
avatar: z.enum(["jack", "lana", "lily", "matt", "rian"]),
|
|
117
|
+
background: z.optional(z.string()),
|
|
124
118
|
});
|
|
125
119
|
|
|
126
|
-
export const didTextToAvatarOptionsSchema =
|
|
120
|
+
export const didTextToAvatarOptionsSchema =
|
|
121
|
+
didTextToAvatarOptionsDidTextToAvatarOptionsSchema;
|
|
127
122
|
|
|
128
123
|
/**
|
|
129
124
|
* Generate assets using the third party D-ID provider AI services.
|
|
@@ -132,18 +127,21 @@ export const didTextToAvatarOptionsSchema = didTextToAvatarOptionsDidTextToAvata
|
|
|
132
127
|
* <li><a href="#tocs_didtexttoavataroptions">DidTextToAvatarOptions</a></li>
|
|
133
128
|
* </ul>
|
|
134
129
|
*/
|
|
135
|
-
export const didGeneratedAssetOptionsDidGeneratedAssetOptionsSchema = z
|
|
136
|
-
|
|
137
|
-
|
|
130
|
+
export const didGeneratedAssetOptionsDidGeneratedAssetOptionsSchema = z
|
|
131
|
+
.object({
|
|
132
|
+
type: z.literal("didTextToAvatarOptions_DIDTextToAvatarOptions"),
|
|
133
|
+
})
|
|
134
|
+
.and(didTextToAvatarOptionsDidTextToAvatarOptionsSchema);
|
|
138
135
|
|
|
139
|
-
export const didGeneratedAssetOptionsSchema =
|
|
136
|
+
export const didGeneratedAssetOptionsSchema =
|
|
137
|
+
didGeneratedAssetOptionsDidGeneratedAssetOptionsSchema;
|
|
140
138
|
|
|
141
139
|
/**
|
|
142
140
|
* Generate assets using D-ID. D-ID provide a text-to-avatar service. The D-ID provider works on a bring-your-own-key basis, credentials are required and must be added via the [dashboard](https://dashboard.shotstack.io/integrations/d-id), not in the request.
|
|
143
141
|
*/
|
|
144
142
|
export const didGeneratedAssetDidGeneratedAssetSchema = z.object({
|
|
145
|
-
|
|
146
|
-
|
|
143
|
+
provider: z.enum(["d-id"]),
|
|
144
|
+
options: didGeneratedAssetOptionsDidGeneratedAssetOptionsSchema,
|
|
147
145
|
});
|
|
148
146
|
|
|
149
147
|
export const didGeneratedAssetSchema = didGeneratedAssetDidGeneratedAssetSchema;
|
|
@@ -151,23 +149,25 @@ export const didGeneratedAssetSchema = didGeneratedAssetDidGeneratedAssetSchema;
|
|
|
151
149
|
/**
|
|
152
150
|
* Options for the ElevenLabs text-to-speech service. Set the text to be converted to speech and choose a voice to set the speaking style. The output will be generated as an MP3 audio file available at the URL returned in the response.
|
|
153
151
|
*/
|
|
154
|
-
export const elevenlabsTextToSpeechOptionsElevenLabsTextToSpeechOptionsSchema =
|
|
155
|
-
|
|
152
|
+
export const elevenlabsTextToSpeechOptionsElevenLabsTextToSpeechOptionsSchema =
|
|
153
|
+
z.object({
|
|
154
|
+
type: z.enum(["text-to-speech"]),
|
|
156
155
|
text: z.string(),
|
|
157
156
|
voice: z.enum([
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
])
|
|
168
|
-
});
|
|
157
|
+
"Adam",
|
|
158
|
+
"Antoni",
|
|
159
|
+
"Arnold",
|
|
160
|
+
"Bella",
|
|
161
|
+
"Domi",
|
|
162
|
+
"Elli",
|
|
163
|
+
"Josh",
|
|
164
|
+
"Rachel",
|
|
165
|
+
"Sam",
|
|
166
|
+
]),
|
|
167
|
+
});
|
|
169
168
|
|
|
170
|
-
export const elevenLabsTextToSpeechOptionsSchema =
|
|
169
|
+
export const elevenLabsTextToSpeechOptionsSchema =
|
|
170
|
+
elevenlabsTextToSpeechOptionsElevenLabsTextToSpeechOptionsSchema;
|
|
171
171
|
|
|
172
172
|
/**
|
|
173
173
|
* Generate assets using the third party ElevenLabs provider AI services.
|
|
@@ -176,148 +176,157 @@ export const elevenLabsTextToSpeechOptionsSchema = elevenlabsTextToSpeechOptions
|
|
|
176
176
|
* <li><a href="#tocs_elevenlabstexttospeechoptions">ElevenLabsTextToSpeechOptions</a></li>
|
|
177
177
|
* </ul>
|
|
178
178
|
*/
|
|
179
|
-
export const elevenlabsGeneratedAssetOptionsElevenLabsGeneratedAssetOptionsSchema =
|
|
180
|
-
|
|
181
|
-
|
|
179
|
+
export const elevenlabsGeneratedAssetOptionsElevenLabsGeneratedAssetOptionsSchema =
|
|
180
|
+
z
|
|
181
|
+
.object({
|
|
182
|
+
type: z.literal(
|
|
183
|
+
"elevenlabsTextToSpeechOptions_ElevenLabsTextToSpeechOptions",
|
|
184
|
+
),
|
|
185
|
+
})
|
|
186
|
+
.and(elevenlabsTextToSpeechOptionsElevenLabsTextToSpeechOptionsSchema);
|
|
182
187
|
|
|
183
|
-
export const elevenLabsGeneratedAssetOptionsSchema =
|
|
188
|
+
export const elevenLabsGeneratedAssetOptionsSchema =
|
|
189
|
+
elevenlabsGeneratedAssetOptionsElevenLabsGeneratedAssetOptionsSchema;
|
|
184
190
|
|
|
185
191
|
/**
|
|
186
192
|
* Generate assets using ElevenLabs. ElevenLabs provide a text-to-speech service. The ElevenLabs provider works on a bring-your-own-key basis, credentials are required and must be added via the [dashboard](https://dashboard.shotstack.io/integrations/elevenlabs), not in the request.
|
|
187
193
|
*/
|
|
188
194
|
export const elevenlabsGeneratedAssetElevenLabsGeneratedAssetSchema = z.object({
|
|
189
|
-
|
|
190
|
-
|
|
195
|
+
provider: z.enum(["elevenlabs"]),
|
|
196
|
+
options: elevenlabsGeneratedAssetOptionsElevenLabsGeneratedAssetOptionsSchema,
|
|
191
197
|
});
|
|
192
198
|
|
|
193
|
-
export const elevenLabsGeneratedAssetSchema =
|
|
199
|
+
export const elevenLabsGeneratedAssetSchema =
|
|
200
|
+
elevenlabsGeneratedAssetElevenLabsGeneratedAssetSchema;
|
|
194
201
|
|
|
195
202
|
/**
|
|
196
203
|
* Options for the HeyGen text-to-avatar service. Set the text to be converted to an avatar and configure the avatars voice, speaking style, appearance and background. The output will be generated as an MP4 video file available at the URL returned in the response.
|
|
197
204
|
*/
|
|
198
|
-
export const heygenTextToAvatarOptionsHeyGenTextToAvatarOptionsSchema =
|
|
199
|
-
|
|
205
|
+
export const heygenTextToAvatarOptionsHeyGenTextToAvatarOptionsSchema =
|
|
206
|
+
z.object({
|
|
207
|
+
type: z.enum(["text-to-avatar"]),
|
|
200
208
|
text: z.string(),
|
|
201
209
|
avatar: z.enum([
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
210
|
+
"Angela",
|
|
211
|
+
"Bill",
|
|
212
|
+
"Daisy",
|
|
213
|
+
"Derek",
|
|
214
|
+
"Eva",
|
|
215
|
+
"Jake",
|
|
216
|
+
"Jeff",
|
|
217
|
+
"Jerome",
|
|
218
|
+
"Joon",
|
|
219
|
+
"Kayla",
|
|
220
|
+
"Kent",
|
|
221
|
+
"Luna",
|
|
222
|
+
"Mark",
|
|
223
|
+
"Matthew",
|
|
224
|
+
"Monica",
|
|
225
|
+
"Peter",
|
|
226
|
+
"Selina",
|
|
227
|
+
"Tanya",
|
|
228
|
+
"Thomas",
|
|
229
|
+
"Tina",
|
|
230
|
+
"Tyler",
|
|
231
|
+
"Vanessa",
|
|
232
|
+
"Vera",
|
|
233
|
+
"Wilson",
|
|
234
|
+
"Zoey",
|
|
227
235
|
]),
|
|
228
236
|
voice: z.enum([
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
237
|
+
"Abbi - Natural",
|
|
238
|
+
"Adam - Natural",
|
|
239
|
+
"Aiston - Friendly",
|
|
240
|
+
"Alice - Newscaster",
|
|
241
|
+
"Alison - Cheerful",
|
|
242
|
+
"Amber - Friendly",
|
|
243
|
+
"Amy - Warm",
|
|
244
|
+
"Ana - Cheerful",
|
|
245
|
+
"Antoni - Friendly",
|
|
246
|
+
"Aria - Newscaster",
|
|
247
|
+
"Arnold - Cheerful",
|
|
248
|
+
"Arthur - Natural",
|
|
249
|
+
"Bella - Friendly",
|
|
250
|
+
"Belle - Natural",
|
|
251
|
+
"Brandon - Warm",
|
|
252
|
+
"Brian - Natural",
|
|
253
|
+
"Bruce - Natural",
|
|
254
|
+
"Cerise - Cheerful",
|
|
255
|
+
"Christopher - Calm",
|
|
256
|
+
"Clara - Professional",
|
|
257
|
+
"Connor - Natural",
|
|
258
|
+
"Dahlia - Friendly",
|
|
259
|
+
"Davis - Professional",
|
|
260
|
+
"Dean - Natural",
|
|
261
|
+
"Delbert - Cheerful",
|
|
262
|
+
"Edward - Friendly",
|
|
263
|
+
"Elaine - Calm",
|
|
264
|
+
"Emily - Natural",
|
|
265
|
+
"Emma - Newscaster",
|
|
266
|
+
"Eric - Newscaster",
|
|
267
|
+
"Grace - Natural",
|
|
268
|
+
"Hailey - Calm",
|
|
269
|
+
"Indira - Cheerful",
|
|
270
|
+
"Isabella - Cheerful",
|
|
271
|
+
"Jacob - Natural",
|
|
272
|
+
"Jahmai - Friendly",
|
|
273
|
+
"Jane - Serious",
|
|
274
|
+
"Jason - Serious",
|
|
275
|
+
"Jelle - Friendly",
|
|
276
|
+
"Jen - Natural",
|
|
277
|
+
"Jenny - Professional",
|
|
278
|
+
"Jodi - Cheerful",
|
|
279
|
+
"Joey - Calm",
|
|
280
|
+
"Johan - Friendly",
|
|
281
|
+
"Josie - Cheerful",
|
|
282
|
+
"Keanan - Natural",
|
|
283
|
+
"Keith - Cheerful",
|
|
284
|
+
"Kellie - Friendly",
|
|
285
|
+
"Lauren - Friendly",
|
|
286
|
+
"Leah - Natural",
|
|
287
|
+
"Liam - Professional",
|
|
288
|
+
"Libby - Natural",
|
|
289
|
+
"Lily - Professional",
|
|
290
|
+
"Lucas - Natural",
|
|
291
|
+
"Luke - Professional",
|
|
292
|
+
"Luna - Natural",
|
|
293
|
+
"Marieke - Natural",
|
|
294
|
+
"Matthew - Professional",
|
|
295
|
+
"Michelle - Natural",
|
|
296
|
+
"Mitchell - Natural",
|
|
297
|
+
"Molly - Newscaster",
|
|
298
|
+
"Monica - Calm",
|
|
299
|
+
"Natasha - Professional",
|
|
300
|
+
"Neerja - Newscaster",
|
|
301
|
+
"Noah - Serious",
|
|
302
|
+
"Oliver - Newscaster",
|
|
303
|
+
"Olivia - Calm",
|
|
304
|
+
"Paul - Natural",
|
|
305
|
+
"Prabhat - Natural",
|
|
306
|
+
"Raveena - Natural",
|
|
307
|
+
"Rudi - Friendly",
|
|
308
|
+
"Ryan - Professional",
|
|
309
|
+
"Sam - Natural",
|
|
310
|
+
"Sara - Cheerful",
|
|
311
|
+
"Sherry - Friendly",
|
|
312
|
+
"Sonia - Warm",
|
|
313
|
+
"Thomas - Natural",
|
|
314
|
+
"Todd - Professional",
|
|
315
|
+
"Tony - Professional",
|
|
316
|
+
"Tracy - Cheerful",
|
|
317
|
+
"Wayne - Natural",
|
|
318
|
+
"Wilder - Natural",
|
|
319
|
+
"Wille - Natural",
|
|
320
|
+
"William - Friendly",
|
|
313
321
|
]),
|
|
314
|
-
avatarStyle: z.optional(z.enum([
|
|
322
|
+
avatarStyle: z.optional(z.enum(["normal", "circle"])),
|
|
315
323
|
background: z.optional(z.string()),
|
|
316
|
-
ratio: z.optional(z.enum([
|
|
317
|
-
test: z.optional(z.boolean())
|
|
318
|
-
});
|
|
324
|
+
ratio: z.optional(z.enum(["16:9", "9:16"])),
|
|
325
|
+
test: z.optional(z.boolean()),
|
|
326
|
+
});
|
|
319
327
|
|
|
320
|
-
export const heyGenTextToAvatarOptionsSchema =
|
|
328
|
+
export const heyGenTextToAvatarOptionsSchema =
|
|
329
|
+
heygenTextToAvatarOptionsHeyGenTextToAvatarOptionsSchema;
|
|
321
330
|
|
|
322
331
|
/**
|
|
323
332
|
* Generate assets using the third party HeyGen provider AI services.
|
|
@@ -326,33 +335,39 @@ export const heyGenTextToAvatarOptionsSchema = heygenTextToAvatarOptionsHeyGenTe
|
|
|
326
335
|
* <li><a href="#tocs_heygentexttoavataroptions">HeyGenTextToAvatarOptions</a></li>
|
|
327
336
|
* </ul>
|
|
328
337
|
*/
|
|
329
|
-
export const heygenGeneratedAssetOptionsHeyGenGeneratedAssetOptionsSchema = z
|
|
330
|
-
|
|
331
|
-
|
|
338
|
+
export const heygenGeneratedAssetOptionsHeyGenGeneratedAssetOptionsSchema = z
|
|
339
|
+
.object({
|
|
340
|
+
type: z.literal("heygenTextToAvatarOptions_HeyGenTextToAvatarOptions"),
|
|
341
|
+
})
|
|
342
|
+
.and(heygenTextToAvatarOptionsHeyGenTextToAvatarOptionsSchema);
|
|
332
343
|
|
|
333
|
-
export const heyGenGeneratedAssetOptionsSchema =
|
|
344
|
+
export const heyGenGeneratedAssetOptionsSchema =
|
|
345
|
+
heygenGeneratedAssetOptionsHeyGenGeneratedAssetOptionsSchema;
|
|
334
346
|
|
|
335
347
|
/**
|
|
336
348
|
* Generate assets using HeyGen. HeyGen provide a text-to-avatar service. The HeyGen provider works on a bring-your-own-key basis, credentials are required and must be added via the [dashboard](https://dashboard.shotstack.io/integrations/heygen), not in the request.
|
|
337
349
|
*/
|
|
338
350
|
export const heygenGeneratedAssetHeyGenGeneratedAssetSchema = z.object({
|
|
339
|
-
|
|
340
|
-
|
|
351
|
+
provider: z.enum(["heygen"]),
|
|
352
|
+
options: heygenGeneratedAssetOptionsHeyGenGeneratedAssetOptionsSchema,
|
|
341
353
|
});
|
|
342
354
|
|
|
343
|
-
export const heyGenGeneratedAssetSchema =
|
|
355
|
+
export const heyGenGeneratedAssetSchema =
|
|
356
|
+
heygenGeneratedAssetHeyGenGeneratedAssetSchema;
|
|
344
357
|
|
|
345
358
|
/**
|
|
346
359
|
* Options for the OpenAI text-generator service. Set a text prompt that will be used to generate a new body of text. The output will be generated as a text (txt) file available at the URL returned in the response.
|
|
347
360
|
*/
|
|
348
|
-
export const openaiTextGeneratorOptionsOpenAiTextGeneratorOptionsSchema =
|
|
349
|
-
|
|
361
|
+
export const openaiTextGeneratorOptionsOpenAiTextGeneratorOptionsSchema =
|
|
362
|
+
z.object({
|
|
363
|
+
type: z.enum(["text-generator"]),
|
|
350
364
|
prompt: z.string(),
|
|
351
|
-
model: z.enum([
|
|
352
|
-
systemPrompt: z.optional(z.string())
|
|
353
|
-
});
|
|
365
|
+
model: z.enum(["gpt-3.5-turbo", "gpt-4"]),
|
|
366
|
+
systemPrompt: z.optional(z.string()),
|
|
367
|
+
});
|
|
354
368
|
|
|
355
|
-
export const openAiTextGeneratorOptionsSchema =
|
|
369
|
+
export const openAiTextGeneratorOptionsSchema =
|
|
370
|
+
openaiTextGeneratorOptionsOpenAiTextGeneratorOptionsSchema;
|
|
356
371
|
|
|
357
372
|
/**
|
|
358
373
|
* Generate assets using OpenAI provider AI services.
|
|
@@ -361,293 +376,333 @@ export const openAiTextGeneratorOptionsSchema = openaiTextGeneratorOptionsOpenAi
|
|
|
361
376
|
* <li><a href="#tocs_openaitextgeneratoroptions">OpenAiTextGeneratorOptions</a></li>
|
|
362
377
|
* </ul>
|
|
363
378
|
*/
|
|
364
|
-
export const openaiGeneratedAssetOptionsOpenAiGeneratedAssetOptionsSchema = z
|
|
365
|
-
|
|
366
|
-
|
|
379
|
+
export const openaiGeneratedAssetOptionsOpenAiGeneratedAssetOptionsSchema = z
|
|
380
|
+
.object({
|
|
381
|
+
type: z.literal("openaiTextGeneratorOptions_OpenAiTextGeneratorOptions"),
|
|
382
|
+
})
|
|
383
|
+
.and(openaiTextGeneratorOptionsOpenAiTextGeneratorOptionsSchema);
|
|
367
384
|
|
|
368
|
-
export const openAiGeneratedAssetOptionsSchema =
|
|
385
|
+
export const openAiGeneratedAssetOptionsSchema =
|
|
386
|
+
openaiGeneratedAssetOptionsOpenAiGeneratedAssetOptionsSchema;
|
|
369
387
|
|
|
370
388
|
/**
|
|
371
389
|
* Generate assets using OpenAI. OpenAI provide a text generation service using ChatGPT 3.5 and 4. The OpenAI provider works on a bring-your-own-key basis, credentials are required and must be added via the [dashboard](https://dashboard.shotstack.io/integrations/openai), not in the request.
|
|
372
390
|
*/
|
|
373
391
|
export const openaiGeneratedAssetOpenAiGeneratedAssetSchema = z.object({
|
|
374
|
-
|
|
375
|
-
|
|
392
|
+
provider: z.enum(["openai"]),
|
|
393
|
+
options: openaiGeneratedAssetOptionsOpenAiGeneratedAssetOptionsSchema,
|
|
376
394
|
});
|
|
377
395
|
|
|
378
|
-
export const openAiGeneratedAssetSchema =
|
|
396
|
+
export const openAiGeneratedAssetSchema =
|
|
397
|
+
openaiGeneratedAssetOpenAiGeneratedAssetSchema;
|
|
379
398
|
|
|
380
399
|
/**
|
|
381
400
|
* Individual errors returned by the Create API.
|
|
382
401
|
*/
|
|
383
|
-
export const generatedAssetErrorResponseDataGeneratedAssetErrorResponseDataSchema =
|
|
402
|
+
export const generatedAssetErrorResponseDataGeneratedAssetErrorResponseDataSchema =
|
|
403
|
+
z.object({
|
|
384
404
|
status: z.string(),
|
|
385
405
|
title: z.string(),
|
|
386
|
-
detail: z.string()
|
|
387
|
-
});
|
|
406
|
+
detail: z.string(),
|
|
407
|
+
});
|
|
388
408
|
|
|
389
|
-
export const generatedAssetErrorResponseDataSchema =
|
|
409
|
+
export const generatedAssetErrorResponseDataSchema =
|
|
410
|
+
generatedAssetErrorResponseDataGeneratedAssetErrorResponseDataSchema;
|
|
390
411
|
|
|
391
412
|
/**
|
|
392
413
|
* Error response data for validation and other errors returned by the Create API.
|
|
393
414
|
*/
|
|
394
|
-
export const generatedAssetErrorResponseGeneratedAssetErrorResponseSchema =
|
|
395
|
-
|
|
396
|
-
|
|
415
|
+
export const generatedAssetErrorResponseGeneratedAssetErrorResponseSchema =
|
|
416
|
+
z.object({
|
|
417
|
+
errors: z.array(
|
|
418
|
+
generatedAssetErrorResponseDataGeneratedAssetErrorResponseDataSchema,
|
|
419
|
+
),
|
|
420
|
+
});
|
|
397
421
|
|
|
398
|
-
export const generatedAssetErrorResponseSchema =
|
|
422
|
+
export const generatedAssetErrorResponseSchema =
|
|
423
|
+
generatedAssetErrorResponseGeneratedAssetErrorResponseSchema;
|
|
399
424
|
|
|
400
425
|
/**
|
|
401
426
|
* The id and attributes of the generated asset.
|
|
402
427
|
*/
|
|
403
|
-
export const generatedAssetResponseAttributesGeneratedAssetResponseAttributesSchema =
|
|
428
|
+
export const generatedAssetResponseAttributesGeneratedAssetResponseAttributesSchema =
|
|
429
|
+
z.object({
|
|
404
430
|
owner: z.string(),
|
|
405
|
-
provider: z.enum([
|
|
406
|
-
|
|
407
|
-
'elevenlabs',
|
|
408
|
-
'heygen',
|
|
409
|
-
'd-id'
|
|
410
|
-
]),
|
|
411
|
-
type: z.enum(['text-to-speech', 'text-to-avatar']),
|
|
431
|
+
provider: z.enum(["shotstack", "elevenlabs", "heygen", "d-id"]),
|
|
432
|
+
type: z.enum(["text-to-speech", "text-to-avatar"]),
|
|
412
433
|
url: z.optional(z.string()),
|
|
413
|
-
status: z.enum([
|
|
414
|
-
'queued',
|
|
415
|
-
'processing',
|
|
416
|
-
'saving',
|
|
417
|
-
'done',
|
|
418
|
-
'failed'
|
|
419
|
-
]),
|
|
434
|
+
status: z.enum(["queued", "processing", "saving", "done", "failed"]),
|
|
420
435
|
created: z.string(),
|
|
421
|
-
updated: z.string()
|
|
422
|
-
});
|
|
436
|
+
updated: z.string(),
|
|
437
|
+
});
|
|
423
438
|
|
|
424
|
-
export const generatedAssetResponseAttributesSchema =
|
|
439
|
+
export const generatedAssetResponseAttributesSchema =
|
|
440
|
+
generatedAssetResponseAttributesGeneratedAssetResponseAttributesSchema;
|
|
425
441
|
|
|
426
442
|
/**
|
|
427
443
|
* The type of resource (an asset), it's id and attributes of the generated file.
|
|
428
444
|
*/
|
|
429
|
-
export const generatedAssetResponseDataGeneratedAssetResponseDataSchema =
|
|
445
|
+
export const generatedAssetResponseDataGeneratedAssetResponseDataSchema =
|
|
446
|
+
z.object({
|
|
430
447
|
type: z.string(),
|
|
431
448
|
id: z.string(),
|
|
432
|
-
attributes:
|
|
433
|
-
|
|
449
|
+
attributes:
|
|
450
|
+
generatedAssetResponseAttributesGeneratedAssetResponseAttributesSchema,
|
|
451
|
+
});
|
|
434
452
|
|
|
435
|
-
export const generatedAssetResponseDataSchema =
|
|
453
|
+
export const generatedAssetResponseDataSchema =
|
|
454
|
+
generatedAssetResponseDataGeneratedAssetResponseDataSchema;
|
|
436
455
|
|
|
437
456
|
/**
|
|
438
457
|
* The response returned by the Create API [generate asset](#generate-asset) and [get generated asset](#get-generated-asset) requests. Includes status and details of the generated asset. The response follows the [json:api](https://jsonapi.org/) specification.
|
|
439
458
|
*/
|
|
440
459
|
export const generatedAssetResponseGeneratedAssetResponseSchema = z.object({
|
|
441
|
-
|
|
460
|
+
data: generatedAssetResponseDataGeneratedAssetResponseDataSchema,
|
|
442
461
|
});
|
|
443
462
|
|
|
444
|
-
export const generatedAssetResponseSchema =
|
|
463
|
+
export const generatedAssetResponseSchema =
|
|
464
|
+
generatedAssetResponseGeneratedAssetResponseSchema;
|
|
445
465
|
|
|
446
466
|
/**
|
|
447
467
|
* Options for the Shotstack image-to-video service. Set the URL of an image to convert in to a video. The output will be generated as an MP4 file available at the URL returned in the response.
|
|
448
468
|
*/
|
|
449
|
-
export const shotstackImageToVideoOptionsShotstackImageToVideoOptionsSchema =
|
|
450
|
-
|
|
469
|
+
export const shotstackImageToVideoOptionsShotstackImageToVideoOptionsSchema =
|
|
470
|
+
z.object({
|
|
471
|
+
type: z.enum(["image-to-video"]),
|
|
451
472
|
imageUrl: z.string(),
|
|
452
473
|
guidanceScale: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())).default(1.8),
|
|
453
|
-
motion: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())).default(127)
|
|
454
|
-
});
|
|
474
|
+
motion: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())).default(127),
|
|
475
|
+
});
|
|
455
476
|
|
|
456
|
-
export const shotstackImageToVideoOptionsSchema =
|
|
477
|
+
export const shotstackImageToVideoOptionsSchema =
|
|
478
|
+
shotstackImageToVideoOptionsShotstackImageToVideoOptionsSchema;
|
|
457
479
|
|
|
458
480
|
/**
|
|
459
481
|
* Options for the Shotstack text-generator service. Set a text prompt that will be used to generate a new body of text. The output will be generated as a text (txt) file available at the URL returned in the response.
|
|
460
482
|
*/
|
|
461
|
-
export const shotstackTextGeneratorOptionsShotstackTextGeneratorOptionsSchema =
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
483
|
+
export const shotstackTextGeneratorOptionsShotstackTextGeneratorOptionsSchema =
|
|
484
|
+
z.object({
|
|
485
|
+
type: z.enum(["text-generator"]),
|
|
486
|
+
prompt: z.string(),
|
|
487
|
+
});
|
|
465
488
|
|
|
466
|
-
export const shotstackTextGeneratorOptionsSchema =
|
|
489
|
+
export const shotstackTextGeneratorOptionsSchema =
|
|
490
|
+
shotstackTextGeneratorOptionsShotstackTextGeneratorOptionsSchema;
|
|
467
491
|
|
|
468
492
|
/**
|
|
469
493
|
* Options for the Shotstack text-to-image service. Set a text prompt to generate an image from. The output will be generated as a PNG file available at the URL returned in the response.
|
|
470
494
|
*/
|
|
471
|
-
export const shotstackTextToImageOptionsShotstackTextToImageOptionsSchema =
|
|
472
|
-
|
|
495
|
+
export const shotstackTextToImageOptionsShotstackTextToImageOptionsSchema =
|
|
496
|
+
z.object({
|
|
497
|
+
type: z.enum(["text-to-image"]),
|
|
473
498
|
prompt: z.string(),
|
|
474
499
|
width: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int()),
|
|
475
|
-
height: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())
|
|
476
|
-
});
|
|
500
|
+
height: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int()),
|
|
501
|
+
});
|
|
477
502
|
|
|
478
|
-
export const shotstackTextToImageOptionsSchema =
|
|
503
|
+
export const shotstackTextToImageOptionsSchema =
|
|
504
|
+
shotstackTextToImageOptionsShotstackTextToImageOptionsSchema;
|
|
479
505
|
|
|
480
506
|
/**
|
|
481
507
|
* Options for the Shotstack text-to-speech service. Set the text to be converted to speech and choose a voice to set the speaking style. The output will be generated as an MP3 audio file available at the URL returned in the response.
|
|
482
508
|
*/
|
|
483
|
-
export const shotstackTextToSpeechOptionsShotstackTextToSpeechOptionsSchema =
|
|
484
|
-
|
|
509
|
+
export const shotstackTextToSpeechOptionsShotstackTextToSpeechOptionsSchema =
|
|
510
|
+
z.object({
|
|
511
|
+
type: z.enum(["text-to-speech"]),
|
|
485
512
|
text: z.string(),
|
|
486
513
|
voice: z.enum([
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
514
|
+
"Hala",
|
|
515
|
+
"Lisa",
|
|
516
|
+
"Arlet",
|
|
517
|
+
"Hiujin",
|
|
518
|
+
"Zhiyu",
|
|
519
|
+
"Sofie",
|
|
520
|
+
"Laura",
|
|
521
|
+
"Olivia",
|
|
522
|
+
"Amy",
|
|
523
|
+
"Emma",
|
|
524
|
+
"Brian",
|
|
525
|
+
"Arthur",
|
|
526
|
+
"Kajal",
|
|
527
|
+
"Niamh",
|
|
528
|
+
"Aria",
|
|
529
|
+
"Ayanda",
|
|
530
|
+
"Ivy",
|
|
531
|
+
"Joanna",
|
|
532
|
+
"Kendra",
|
|
533
|
+
"Kimberly",
|
|
534
|
+
"Salli",
|
|
535
|
+
"Joey",
|
|
536
|
+
"Justin",
|
|
537
|
+
"Kevin",
|
|
538
|
+
"Matthew",
|
|
539
|
+
"Ruth",
|
|
540
|
+
"Stephen",
|
|
541
|
+
"Suvi",
|
|
542
|
+
"Léa",
|
|
543
|
+
"Rémi",
|
|
544
|
+
"Gabrielle",
|
|
545
|
+
"Liam",
|
|
546
|
+
"Vicki",
|
|
547
|
+
"Daniel",
|
|
548
|
+
"Hannah",
|
|
549
|
+
"Kajal",
|
|
550
|
+
"Bianca",
|
|
551
|
+
"Adriano",
|
|
552
|
+
"Takumi",
|
|
553
|
+
"Kazuha",
|
|
554
|
+
"Tomoko",
|
|
555
|
+
"Seoyeon",
|
|
556
|
+
"Ida",
|
|
557
|
+
"Ola",
|
|
558
|
+
"Camila",
|
|
559
|
+
"Vitória",
|
|
560
|
+
"Vitoria",
|
|
561
|
+
"Thiago",
|
|
562
|
+
"Inês",
|
|
563
|
+
"Ines",
|
|
564
|
+
"Lucia",
|
|
565
|
+
"Sergio",
|
|
566
|
+
"Mia",
|
|
567
|
+
"Andrés",
|
|
568
|
+
"Lupe",
|
|
569
|
+
"Pedro",
|
|
570
|
+
"Elin",
|
|
544
571
|
]),
|
|
545
|
-
language: z.optional(
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
572
|
+
language: z.optional(
|
|
573
|
+
z.enum([
|
|
574
|
+
"cmn-CN",
|
|
575
|
+
"da-DK",
|
|
576
|
+
"de-DE",
|
|
577
|
+
"en-AU",
|
|
578
|
+
"en-GB",
|
|
579
|
+
"en-IN",
|
|
580
|
+
"en-US",
|
|
581
|
+
"es-ES",
|
|
582
|
+
"es-MX",
|
|
583
|
+
"es-US",
|
|
584
|
+
"fr-CA",
|
|
585
|
+
"fr-FR",
|
|
586
|
+
"it-IT",
|
|
587
|
+
"ja-JP",
|
|
588
|
+
"hi-IN",
|
|
589
|
+
"ko-KR",
|
|
590
|
+
"nb-NO",
|
|
591
|
+
"nl-NL",
|
|
592
|
+
"pl-PL",
|
|
593
|
+
"pt-BR",
|
|
594
|
+
"pt-PT",
|
|
595
|
+
"sv-SE",
|
|
596
|
+
"en-NZ",
|
|
597
|
+
"en-ZA",
|
|
598
|
+
"ca-ES",
|
|
599
|
+
"de-AT",
|
|
600
|
+
"yue-CN",
|
|
601
|
+
"ar-AE",
|
|
602
|
+
"fi-FI",
|
|
603
|
+
]),
|
|
604
|
+
),
|
|
605
|
+
newscaster: z.optional(z.boolean()).default(false),
|
|
606
|
+
});
|
|
607
|
+
|
|
608
|
+
export const shotstackTextToSpeechOptionsSchema =
|
|
609
|
+
shotstackTextToSpeechOptionsShotstackTextToSpeechOptionsSchema;
|
|
580
610
|
|
|
581
611
|
/**
|
|
582
612
|
* Generate assets using the native Shotstack provider AI services.
|
|
583
613
|
*/
|
|
584
|
-
export const shotstackGeneratedAssetOptionsShotstackGeneratedAssetOptionsSchema =
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
type: z.literal(
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
614
|
+
export const shotstackGeneratedAssetOptionsShotstackGeneratedAssetOptionsSchema =
|
|
615
|
+
z.union([
|
|
616
|
+
z
|
|
617
|
+
.object({
|
|
618
|
+
type: z.literal(
|
|
619
|
+
"shotstackTextToSpeechOptions_ShotstackTextToSpeechOptions",
|
|
620
|
+
),
|
|
621
|
+
})
|
|
622
|
+
.and(shotstackTextToSpeechOptionsShotstackTextToSpeechOptionsSchema),
|
|
623
|
+
z
|
|
624
|
+
.object({
|
|
625
|
+
type: z.literal(
|
|
626
|
+
"shotstackTextToImageOptions_ShotstackTextToImageOptions",
|
|
627
|
+
),
|
|
628
|
+
})
|
|
629
|
+
.and(shotstackTextToImageOptionsShotstackTextToImageOptionsSchema),
|
|
630
|
+
z
|
|
631
|
+
.object({
|
|
632
|
+
type: z.literal(
|
|
633
|
+
"shotstackTextGeneratorOptions_ShotstackTextGeneratorOptions",
|
|
634
|
+
),
|
|
635
|
+
})
|
|
636
|
+
.and(shotstackTextGeneratorOptionsShotstackTextGeneratorOptionsSchema),
|
|
637
|
+
z
|
|
638
|
+
.object({
|
|
639
|
+
type: z.literal(
|
|
640
|
+
"shotstackImageToVideoOptions_ShotstackImageToVideoOptions",
|
|
641
|
+
),
|
|
642
|
+
})
|
|
643
|
+
.and(shotstackImageToVideoOptionsShotstackImageToVideoOptionsSchema),
|
|
644
|
+
]);
|
|
645
|
+
|
|
646
|
+
export const shotstackGeneratedAssetOptionsSchema =
|
|
647
|
+
shotstackGeneratedAssetOptionsShotstackGeneratedAssetOptionsSchema;
|
|
600
648
|
|
|
601
649
|
/**
|
|
602
650
|
* Generate assets using the native Shotstack provider. Shotstack provides a text-to-speech and a text-to-image service. The Shotstack provider works natively with your existing API key, no additional credentials are required.
|
|
603
651
|
*/
|
|
604
652
|
export const shotstackGeneratedAssetShotstackGeneratedAssetSchema = z.object({
|
|
605
|
-
|
|
606
|
-
|
|
653
|
+
provider: z.enum(["shotstack"]),
|
|
654
|
+
options: shotstackGeneratedAssetOptionsShotstackGeneratedAssetOptionsSchema,
|
|
607
655
|
});
|
|
608
656
|
|
|
609
|
-
export const shotstackGeneratedAssetSchema =
|
|
657
|
+
export const shotstackGeneratedAssetSchema =
|
|
658
|
+
shotstackGeneratedAssetShotstackGeneratedAssetSchema;
|
|
610
659
|
|
|
611
660
|
/**
|
|
612
661
|
* Options for the Stability AI text-to-image service. Set a text prompt to generate an image from plus other engine and configuration options. The output will be generated as a JPG file available at the URL returned in the response.
|
|
613
662
|
*/
|
|
614
|
-
export const stabilityAiTextToImageOptionsStabilityAiTextToImageOptionsSchema =
|
|
615
|
-
|
|
663
|
+
export const stabilityAiTextToImageOptionsStabilityAiTextToImageOptionsSchema =
|
|
664
|
+
z.object({
|
|
665
|
+
type: z.enum(["text-to-image"]),
|
|
616
666
|
prompt: z.string(),
|
|
617
|
-
engine: z.optional(
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
667
|
+
engine: z.optional(
|
|
668
|
+
z.enum([
|
|
669
|
+
"stable-diffusion-xl-1024-v0-9",
|
|
670
|
+
"stable-diffusion-xl-1024-v1-0",
|
|
671
|
+
"stable-diffusion-v1-6",
|
|
672
|
+
"stable-diffusion-512-v2-1",
|
|
673
|
+
"stable-diffusion-xl-beta-v2-2-2",
|
|
674
|
+
]),
|
|
675
|
+
),
|
|
624
676
|
width: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int()),
|
|
625
677
|
height: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int()),
|
|
626
678
|
steps: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())).default(30),
|
|
627
679
|
seed: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())).default(0),
|
|
628
680
|
cfgScale: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())).default(7),
|
|
629
|
-
stylePreset: z.optional(
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
681
|
+
stylePreset: z.optional(
|
|
682
|
+
z.enum([
|
|
683
|
+
"3d-model",
|
|
684
|
+
"analog-film",
|
|
685
|
+
"anime",
|
|
686
|
+
"cinematic",
|
|
687
|
+
"comic-book",
|
|
688
|
+
"digital-art",
|
|
689
|
+
"enhance",
|
|
690
|
+
"fantasy-art",
|
|
691
|
+
"isometric",
|
|
692
|
+
"line-art",
|
|
693
|
+
"low-poly",
|
|
694
|
+
"modeling-compound",
|
|
695
|
+
"neon-punk",
|
|
696
|
+
"origami",
|
|
697
|
+
"photographic",
|
|
698
|
+
"pixel-art",
|
|
699
|
+
"tile-texture",
|
|
700
|
+
]),
|
|
701
|
+
),
|
|
702
|
+
});
|
|
703
|
+
|
|
704
|
+
export const stabilityAiTextToImageOptionsSchema =
|
|
705
|
+
stabilityAiTextToImageOptionsStabilityAiTextToImageOptionsSchema;
|
|
651
706
|
|
|
652
707
|
/**
|
|
653
708
|
* Generate assets using Stability AI provider AI services.
|
|
@@ -656,44 +711,67 @@ export const stabilityAiTextToImageOptionsSchema = stabilityAiTextToImageOptions
|
|
|
656
711
|
* <li><a href="#tocs_stabilityaitexttoimageoptions">StabilityAiTextToImageOptions</a></li>
|
|
657
712
|
* </ul>
|
|
658
713
|
*/
|
|
659
|
-
export const stabilityAiGeneratedAssetOptionsStabilityAiGeneratedAssetOptionsSchema =
|
|
660
|
-
|
|
661
|
-
|
|
714
|
+
export const stabilityAiGeneratedAssetOptionsStabilityAiGeneratedAssetOptionsSchema =
|
|
715
|
+
z
|
|
716
|
+
.object({
|
|
717
|
+
type: z.literal(
|
|
718
|
+
"stabilityAiTextToImageOptions_StabilityAiTextToImageOptions",
|
|
719
|
+
),
|
|
720
|
+
})
|
|
721
|
+
.and(stabilityAiTextToImageOptionsStabilityAiTextToImageOptionsSchema);
|
|
662
722
|
|
|
663
|
-
export const stabilityAiGeneratedAssetOptionsSchema =
|
|
723
|
+
export const stabilityAiGeneratedAssetOptionsSchema =
|
|
724
|
+
stabilityAiGeneratedAssetOptionsStabilityAiGeneratedAssetOptionsSchema;
|
|
664
725
|
|
|
665
726
|
/**
|
|
666
727
|
* Generate assets using Stability AI. Stability AI provide a text-to-image service using Stable Diffusion. The Stability AI provider works on a bring-your-own-key basis, credentials are required and must be added via the [dashboard](https://dashboard.shotstack.io/integrations/stability-ai), not in the request.
|
|
667
728
|
*/
|
|
668
|
-
export const stabilityAiGeneratedAssetStabilityAiGeneratedAssetSchema =
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
729
|
+
export const stabilityAiGeneratedAssetStabilityAiGeneratedAssetSchema =
|
|
730
|
+
z.object({
|
|
731
|
+
provider: z.enum(["stability-ai"]),
|
|
732
|
+
options:
|
|
733
|
+
stabilityAiGeneratedAssetOptionsStabilityAiGeneratedAssetOptionsSchema,
|
|
734
|
+
});
|
|
672
735
|
|
|
673
|
-
export const stabilityAiGeneratedAssetSchema =
|
|
736
|
+
export const stabilityAiGeneratedAssetSchema =
|
|
737
|
+
stabilityAiGeneratedAssetStabilityAiGeneratedAssetSchema;
|
|
674
738
|
|
|
675
739
|
/**
|
|
676
740
|
* A generated asset is a media asset created by the Create API. You can use native or third party providers to generate video, audio and image files using Generative AI services like text-to-speech and text-to-avatar.
|
|
677
741
|
*/
|
|
678
742
|
export const generatedAssetGeneratedAssetSchema = z.union([
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
})
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
743
|
+
z
|
|
744
|
+
.object({
|
|
745
|
+
provider: z.literal("shotstackGeneratedAsset_ShotstackGeneratedAsset"),
|
|
746
|
+
})
|
|
747
|
+
.and(shotstackGeneratedAssetShotstackGeneratedAssetSchema),
|
|
748
|
+
z
|
|
749
|
+
.object({
|
|
750
|
+
provider: z.literal("didGeneratedAsset_DIDGeneratedAsset"),
|
|
751
|
+
})
|
|
752
|
+
.and(didGeneratedAssetDidGeneratedAssetSchema),
|
|
753
|
+
z
|
|
754
|
+
.object({
|
|
755
|
+
provider: z.literal("elevenlabsGeneratedAsset_ElevenLabsGeneratedAsset"),
|
|
756
|
+
})
|
|
757
|
+
.and(elevenlabsGeneratedAssetElevenLabsGeneratedAssetSchema),
|
|
758
|
+
z
|
|
759
|
+
.object({
|
|
760
|
+
provider: z.literal("heygenGeneratedAsset_HeyGenGeneratedAsset"),
|
|
761
|
+
})
|
|
762
|
+
.and(heygenGeneratedAssetHeyGenGeneratedAssetSchema),
|
|
763
|
+
z
|
|
764
|
+
.object({
|
|
765
|
+
provider: z.literal("openaiGeneratedAsset_OpenAiGeneratedAsset"),
|
|
766
|
+
})
|
|
767
|
+
.and(openaiGeneratedAssetOpenAiGeneratedAssetSchema),
|
|
768
|
+
z
|
|
769
|
+
.object({
|
|
770
|
+
provider: z.literal(
|
|
771
|
+
"stabilityAiGeneratedAsset_StabilityAiGeneratedAsset",
|
|
772
|
+
),
|
|
773
|
+
})
|
|
774
|
+
.and(stabilityAiGeneratedAssetStabilityAiGeneratedAssetSchema),
|
|
697
775
|
]);
|
|
698
776
|
|
|
699
777
|
export const generatedAssetSchema = generatedAssetGeneratedAssetSchema;
|
|
@@ -702,10 +780,10 @@ export const generatedAssetSchema = generatedAssetGeneratedAssetSchema;
|
|
|
702
780
|
* Crop the sides of an asset by a relative amount. The size of the crop is specified using a scale between 0 and 1, relative to the screen width - i.e a left crop of 0.5 will crop half of the asset from the left, a top crop of 0.25 will crop the top by quarter of the asset.
|
|
703
781
|
*/
|
|
704
782
|
export const cropCropSchema = z.object({
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
783
|
+
top: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))),
|
|
784
|
+
bottom: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))),
|
|
785
|
+
left: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))),
|
|
786
|
+
right: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))),
|
|
709
787
|
});
|
|
710
788
|
|
|
711
789
|
export const cropSchema = cropCropSchema;
|
|
@@ -713,60 +791,70 @@ export const cropSchema = cropCropSchema;
|
|
|
713
791
|
/**
|
|
714
792
|
* Pass additional options to control how files are stored in Google Cloud Storage.
|
|
715
793
|
*/
|
|
716
|
-
export const googleCloudStorageDestinationOptionsGoogleCloudStorageDestinationOptionsSchema =
|
|
794
|
+
export const googleCloudStorageDestinationOptionsGoogleCloudStorageDestinationOptionsSchema =
|
|
795
|
+
z.object({
|
|
717
796
|
bucket: z.string(),
|
|
718
797
|
prefix: z.optional(z.string()),
|
|
719
|
-
filename: z.optional(z.string())
|
|
720
|
-
});
|
|
798
|
+
filename: z.optional(z.string()),
|
|
799
|
+
});
|
|
721
800
|
|
|
722
|
-
export const googleCloudStorageDestinationOptionsSchema =
|
|
801
|
+
export const googleCloudStorageDestinationOptionsSchema =
|
|
802
|
+
googleCloudStorageDestinationOptionsGoogleCloudStorageDestinationOptionsSchema;
|
|
723
803
|
|
|
724
804
|
/**
|
|
725
805
|
* Send videos and assets to a [Google Cloud Storage](https://cloud.google.com/storage) bucket. Send files with your own prefix and filename. Google Cloud credentials are required and added via the [dashboard](https://dashboard.shotstack.io/integrations/google-cloud-storage), not in the request.
|
|
726
806
|
*/
|
|
727
|
-
export const googleCloudStorageDestinationGoogleCloudStorageDestinationSchema =
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
807
|
+
export const googleCloudStorageDestinationGoogleCloudStorageDestinationSchema =
|
|
808
|
+
z.object({
|
|
809
|
+
provider: z.literal("google-cloud-storage"),
|
|
810
|
+
options: z.optional(
|
|
811
|
+
googleCloudStorageDestinationOptionsGoogleCloudStorageDestinationOptionsSchema,
|
|
812
|
+
),
|
|
813
|
+
});
|
|
731
814
|
|
|
732
|
-
export const googleCloudStorageDestinationSchema =
|
|
815
|
+
export const googleCloudStorageDestinationSchema =
|
|
816
|
+
googleCloudStorageDestinationGoogleCloudStorageDestinationSchema;
|
|
733
817
|
|
|
734
818
|
/**
|
|
735
819
|
* Pass the folder ID and options to configure how assets are stored in Google Drive.
|
|
736
820
|
*/
|
|
737
|
-
export const googleDriveDestinationOptionsGoogleDriveDestinationOptionsSchema =
|
|
821
|
+
export const googleDriveDestinationOptionsGoogleDriveDestinationOptionsSchema =
|
|
822
|
+
z.object({
|
|
738
823
|
folderId: z.string(),
|
|
739
|
-
filename: z.optional(z.string())
|
|
740
|
-
});
|
|
824
|
+
filename: z.optional(z.string()),
|
|
825
|
+
});
|
|
741
826
|
|
|
742
|
-
export const googleDriveDestinationOptionsSchema =
|
|
827
|
+
export const googleDriveDestinationOptionsSchema =
|
|
828
|
+
googleDriveDestinationOptionsGoogleDriveDestinationOptionsSchema;
|
|
743
829
|
|
|
744
830
|
/**
|
|
745
831
|
* Send rendered videos and assets to the [Google Drive](https://shotstack.io/docs/guide/serving-assets/destinations/google-drive/) cloud storage service. Google Drive uses OAuth and you must authenticate and link your Google account via [dashboard](https://dashboard.shotstack.io/integrations/google-drive), not in the request.
|
|
746
832
|
*/
|
|
747
833
|
export const googleDriveDestinationGoogleDriveDestinationSchema = z.object({
|
|
748
|
-
|
|
749
|
-
|
|
834
|
+
provider: z.literal("google-drive"),
|
|
835
|
+
options: googleDriveDestinationOptionsGoogleDriveDestinationOptionsSchema,
|
|
750
836
|
});
|
|
751
837
|
|
|
752
|
-
export const googleDriveDestinationSchema =
|
|
838
|
+
export const googleDriveDestinationSchema =
|
|
839
|
+
googleDriveDestinationGoogleDriveDestinationSchema;
|
|
753
840
|
|
|
754
841
|
/**
|
|
755
842
|
* Pass additional options to control how Mux processes video. Currently supports playback_policy and passthrough options.
|
|
756
843
|
*/
|
|
757
844
|
export const muxDestinationOptionsMuxDestinationOptionsSchema = z.object({
|
|
758
|
-
|
|
759
|
-
|
|
845
|
+
playbackPolicy: z.optional(z.array(z.enum(["public", "signed"]))),
|
|
846
|
+
passthrough: z.optional(z.string().max(255)),
|
|
760
847
|
});
|
|
761
848
|
|
|
762
|
-
export const muxDestinationOptionsSchema =
|
|
849
|
+
export const muxDestinationOptionsSchema =
|
|
850
|
+
muxDestinationOptionsMuxDestinationOptionsSchema;
|
|
763
851
|
|
|
764
852
|
/**
|
|
765
853
|
* Send videos to the [Mux](https://shotstack.io/docs/guide/serving-assets/destinations/mux/) video hosting and streaming service. Mux credentials are required and added via the [dashboard](https://dashboard.shotstack.io/integrations/mux), not in the request.
|
|
766
854
|
*/
|
|
767
855
|
export const muxDestinationMuxDestinationSchema = z.object({
|
|
768
|
-
|
|
769
|
-
|
|
856
|
+
provider: z.literal("mux"),
|
|
857
|
+
options: z.optional(muxDestinationOptionsMuxDestinationOptionsSchema),
|
|
770
858
|
});
|
|
771
859
|
|
|
772
860
|
export const muxDestinationSchema = muxDestinationMuxDestinationSchema;
|
|
@@ -775,21 +863,22 @@ export const muxDestinationSchema = muxDestinationMuxDestinationSchema;
|
|
|
775
863
|
* Pass additional options to control how files are stored in S3.
|
|
776
864
|
*/
|
|
777
865
|
export const s3DestinationOptionsS3DestinationOptionsSchema = z.object({
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
866
|
+
region: z.string(),
|
|
867
|
+
bucket: z.string(),
|
|
868
|
+
prefix: z.optional(z.string()),
|
|
869
|
+
filename: z.optional(z.string()),
|
|
870
|
+
acl: z.optional(z.string()),
|
|
783
871
|
});
|
|
784
872
|
|
|
785
|
-
export const s3DestinationOptionsSchema =
|
|
873
|
+
export const s3DestinationOptionsSchema =
|
|
874
|
+
s3DestinationOptionsS3DestinationOptionsSchema;
|
|
786
875
|
|
|
787
876
|
/**
|
|
788
877
|
* Send videos and assets to an [Amazon S3](https://shotstack.io/docs/guide/serving-assets/destinations/s3/) bucket. Send files to any region with your own prefix and filename. AWS credentials are required and added via the [dashboard](https://dashboard.shotstack.io/integrations/s3), not in the request.
|
|
789
878
|
*/
|
|
790
879
|
export const s3DestinationS3DestinationSchema = z.object({
|
|
791
|
-
|
|
792
|
-
|
|
880
|
+
provider: z.literal("s3"),
|
|
881
|
+
options: z.optional(s3DestinationOptionsS3DestinationOptionsSchema),
|
|
793
882
|
});
|
|
794
883
|
|
|
795
884
|
export const s3DestinationSchema = s3DestinationS3DestinationSchema;
|
|
@@ -798,78 +887,70 @@ export const s3DestinationSchema = s3DestinationS3DestinationSchema;
|
|
|
798
887
|
* Send videos and assets to the [Shotstack hosting and CDN](https://shotstack.io/docs/guide/serving-assets/destinations/shotstack/) service. This destination is enabled by default.
|
|
799
888
|
*/
|
|
800
889
|
export const shotstackDestinationShotstackDestinationSchema = z.object({
|
|
801
|
-
|
|
802
|
-
|
|
890
|
+
provider: z.literal("shotstack"),
|
|
891
|
+
exclude: z.optional(z.boolean()),
|
|
803
892
|
});
|
|
804
893
|
|
|
805
|
-
export const shotstackDestinationSchema =
|
|
894
|
+
export const shotstackDestinationSchema =
|
|
895
|
+
shotstackDestinationShotstackDestinationSchema;
|
|
806
896
|
|
|
807
897
|
/**
|
|
808
898
|
* Pass additional options to control how TikTok publishes video.
|
|
809
899
|
*/
|
|
810
900
|
export const tiktokDestinationOptionsTiktokDestinationOptionsSchema = z.object({
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
])),
|
|
817
|
-
disableDuet: z.optional(z.boolean()).default(false),
|
|
818
|
-
disableStitch: z.optional(z.boolean()).default(false),
|
|
819
|
-
disableComment: z.optional(z.boolean()).default(false)
|
|
901
|
+
title: z.optional(z.string().max(150)),
|
|
902
|
+
privacyLevel: z.optional(z.enum(["public", "friends", "private"])),
|
|
903
|
+
disableDuet: z.optional(z.boolean()).default(false),
|
|
904
|
+
disableStitch: z.optional(z.boolean()).default(false),
|
|
905
|
+
disableComment: z.optional(z.boolean()).default(false),
|
|
820
906
|
});
|
|
821
907
|
|
|
822
908
|
/**
|
|
823
909
|
* Send videos to TikTok. TikTok credentials are required and added via the [dashboard](https://dashboard.shotstack.io/integrations/tiktok), not in the request.
|
|
824
910
|
*/
|
|
825
911
|
export const tiktokDestinationTiktokDestinationSchema = z.object({
|
|
826
|
-
|
|
827
|
-
|
|
912
|
+
provider: z.literal("tiktok"),
|
|
913
|
+
options: z.optional(tiktokDestinationOptionsTiktokDestinationOptionsSchema),
|
|
828
914
|
});
|
|
829
915
|
|
|
830
916
|
/**
|
|
831
917
|
* Options to control the visibility of videos and privacy features.
|
|
832
918
|
*/
|
|
833
|
-
export const vimeoDestinationPrivacyOptionsVimeoDestinationPrivacyOptionsSchema =
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
comments: z.optional(z.enum([
|
|
847
|
-
'anybody',
|
|
848
|
-
'nobody',
|
|
849
|
-
'contacts'
|
|
850
|
-
]))
|
|
851
|
-
});
|
|
852
|
-
|
|
853
|
-
export const vimeoDestinationPrivacyOptionsSchema = vimeoDestinationPrivacyOptionsVimeoDestinationPrivacyOptionsSchema;
|
|
919
|
+
export const vimeoDestinationPrivacyOptionsVimeoDestinationPrivacyOptionsSchema =
|
|
920
|
+
z.object({
|
|
921
|
+
view: z.optional(
|
|
922
|
+
z.enum(["anybody", "nobody", "contacts", "password", "unlisted"]),
|
|
923
|
+
),
|
|
924
|
+
embed: z.optional(z.enum(["public", "private", "whitelist"])),
|
|
925
|
+
comments: z.optional(z.enum(["anybody", "nobody", "contacts"])),
|
|
926
|
+
download: z.optional(z.boolean()),
|
|
927
|
+
add: z.optional(z.boolean()),
|
|
928
|
+
});
|
|
929
|
+
|
|
930
|
+
export const vimeoDestinationPrivacyOptionsSchema =
|
|
931
|
+
vimeoDestinationPrivacyOptionsVimeoDestinationPrivacyOptionsSchema;
|
|
854
932
|
|
|
855
933
|
/**
|
|
856
934
|
* Pass additional options to control how Vimeo publishes video, including name, description and privacy settings.
|
|
857
935
|
*/
|
|
858
936
|
export const vimeoDestinationOptionsVimeoDestinationOptionsSchema = z.object({
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
937
|
+
name: z.optional(z.string()),
|
|
938
|
+
description: z.optional(z.string()),
|
|
939
|
+
privacy: z.optional(
|
|
940
|
+
vimeoDestinationPrivacyOptionsVimeoDestinationPrivacyOptionsSchema,
|
|
941
|
+
),
|
|
942
|
+
folderUri: z.optional(z.string()),
|
|
863
943
|
});
|
|
864
944
|
|
|
865
|
-
export const vimeoDestinationOptionsSchema =
|
|
945
|
+
export const vimeoDestinationOptionsSchema =
|
|
946
|
+
vimeoDestinationOptionsVimeoDestinationOptionsSchema;
|
|
866
947
|
|
|
867
948
|
/**
|
|
868
949
|
* Send videos to [Vimeo](https://shotstack.io/docs/guide/serving-assets/destinations/vimeo/) video hosting and streaming service. Vimeo credentials are required and added via the [dashboard](https://dashboard.shotstack.io/integrations/vimeo), not in the request.
|
|
869
950
|
*/
|
|
870
951
|
export const vimeoDestinationVimeoDestinationSchema = z.object({
|
|
871
|
-
|
|
872
|
-
|
|
952
|
+
provider: z.literal("vimeo"),
|
|
953
|
+
options: z.optional(vimeoDestinationOptionsVimeoDestinationOptionsSchema),
|
|
873
954
|
});
|
|
874
955
|
|
|
875
956
|
export const vimeoDestinationSchema = vimeoDestinationVimeoDestinationSchema;
|
|
@@ -879,28 +960,14 @@ export const vimeoDestinationSchema = vimeoDestinationVimeoDestinationSchema;
|
|
|
879
960
|
*
|
|
880
961
|
* By default all ingested and generated assets are automatically sent to the [Shotstack hosting destination](https://shotstack.io/docs/guide/serving-assets/hosting/). You can [opt-out](https://shotstack.io/docs/guide/serving-assets/self-host/) from by setting the Shotstack destination **exclude** property to **true**.
|
|
881
962
|
*/
|
|
882
|
-
export const destinationsDestinationsSchema = z.
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
destinations: z.optional(z.literal('s3Destination_S3Destination'))
|
|
891
|
-
}).and(s3DestinationS3DestinationSchema),
|
|
892
|
-
z.object({
|
|
893
|
-
destinations: z.optional(z.literal('googleCloudStorageDestination_GoogleCloudStorageDestination'))
|
|
894
|
-
}).and(googleCloudStorageDestinationGoogleCloudStorageDestinationSchema),
|
|
895
|
-
z.object({
|
|
896
|
-
destinations: z.optional(z.literal('googleDriveDestination_GoogleDriveDestination'))
|
|
897
|
-
}).and(googleDriveDestinationGoogleDriveDestinationSchema),
|
|
898
|
-
z.object({
|
|
899
|
-
destinations: z.optional(z.literal('vimeoDestination_VimeoDestination'))
|
|
900
|
-
}).and(vimeoDestinationVimeoDestinationSchema),
|
|
901
|
-
z.object({
|
|
902
|
-
destinations: z.optional(z.literal('tiktokDestination_TiktokDestination'))
|
|
903
|
-
}).and(tiktokDestinationTiktokDestinationSchema)
|
|
963
|
+
export const destinationsDestinationsSchema = z.discriminatedUnion("provider", [
|
|
964
|
+
shotstackDestinationShotstackDestinationSchema,
|
|
965
|
+
muxDestinationMuxDestinationSchema,
|
|
966
|
+
s3DestinationS3DestinationSchema,
|
|
967
|
+
googleCloudStorageDestinationGoogleCloudStorageDestinationSchema,
|
|
968
|
+
googleDriveDestinationGoogleDriveDestinationSchema,
|
|
969
|
+
vimeoDestinationVimeoDestinationSchema,
|
|
970
|
+
tiktokDestinationTiktokDestinationSchema
|
|
904
971
|
]);
|
|
905
972
|
|
|
906
973
|
export const destinationsSchema = destinationsDestinationsSchema;
|
|
@@ -909,17 +976,18 @@ export const destinationsSchema = destinationsDestinationsSchema;
|
|
|
909
976
|
* Flip a clip vertically or horizontally. Acts as a mirror effect of the clip along the selected plane.
|
|
910
977
|
*/
|
|
911
978
|
export const fliptransformationFlipTransformationSchema = z.object({
|
|
912
|
-
|
|
913
|
-
|
|
979
|
+
horizontal: z.optional(z.boolean()),
|
|
980
|
+
vertical: z.optional(z.boolean()),
|
|
914
981
|
});
|
|
915
982
|
|
|
916
|
-
export const flipTransformationSchema =
|
|
983
|
+
export const flipTransformationSchema =
|
|
984
|
+
fliptransformationFlipTransformationSchema;
|
|
917
985
|
|
|
918
986
|
/**
|
|
919
987
|
* Download a custom font to use with the HTML asset type, using the font name in the CSS or font tag. See our [custom fonts](https://shotstack.io/learn/html-custom-fonts/) getting started guide for more details.
|
|
920
988
|
*/
|
|
921
989
|
export const fontFontSchema = z.object({
|
|
922
|
-
|
|
990
|
+
src: z.string(),
|
|
923
991
|
});
|
|
924
992
|
|
|
925
993
|
export const fontSchema = fontFontSchema;
|
|
@@ -935,23 +1003,25 @@ export const fontSchema = fontFontSchema;
|
|
|
935
1003
|
* @deprecated
|
|
936
1004
|
*/
|
|
937
1005
|
export const htmlassetHtmlAssetSchema = z.object({
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
1006
|
+
type: z.enum(["html"]),
|
|
1007
|
+
html: z.string(),
|
|
1008
|
+
css: z.optional(z.string()),
|
|
1009
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
1010
|
+
height: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
1011
|
+
background: z.optional(z.string()),
|
|
1012
|
+
position: z.optional(
|
|
1013
|
+
z.enum([
|
|
1014
|
+
"top",
|
|
1015
|
+
"topRight",
|
|
1016
|
+
"right",
|
|
1017
|
+
"bottomRight",
|
|
1018
|
+
"bottom",
|
|
1019
|
+
"bottomLeft",
|
|
1020
|
+
"left",
|
|
1021
|
+
"topLeft",
|
|
1022
|
+
"center",
|
|
1023
|
+
]),
|
|
1024
|
+
),
|
|
955
1025
|
});
|
|
956
1026
|
|
|
957
1027
|
export const htmlAssetSchema = htmlassetHtmlAssetSchema;
|
|
@@ -960,9 +1030,9 @@ export const htmlAssetSchema = htmlassetHtmlAssetSchema;
|
|
|
960
1030
|
* The ImageAsset is used to create video from images to compose an image. The src must be a publicly accessible URL to an image resource such as a jpg or png file.
|
|
961
1031
|
*/
|
|
962
1032
|
export const imageassetImageAssetSchema = z.object({
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
1033
|
+
type: z.enum(["image"]),
|
|
1034
|
+
src: z.string(),
|
|
1035
|
+
crop: z.optional(cropCropSchema),
|
|
966
1036
|
});
|
|
967
1037
|
|
|
968
1038
|
export const imageAssetSchema = imageassetImageAssetSchema;
|
|
@@ -971,20 +1041,14 @@ export const imageAssetSchema = imageassetImageAssetSchema;
|
|
|
971
1041
|
* The ImageToVideoAsset lets you create a video from an image and a text prompt.
|
|
972
1042
|
*/
|
|
973
1043
|
export const imagetovideoassetImageToVideoAssetSchema = z.object({
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
'3:4',
|
|
983
|
-
'21:9',
|
|
984
|
-
'9:21'
|
|
985
|
-
])),
|
|
986
|
-
speed: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(10))),
|
|
987
|
-
crop: z.optional(cropCropSchema)
|
|
1044
|
+
type: z.optional(z.enum(["image-to-video"])),
|
|
1045
|
+
src: z.optional(z.string()),
|
|
1046
|
+
prompt: z.optional(z.string()),
|
|
1047
|
+
aspectRatio: z.optional(
|
|
1048
|
+
z.enum(["1:1", "4:3", "16:9", "9:16", "3:4", "21:9", "9:21"]),
|
|
1049
|
+
),
|
|
1050
|
+
speed: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(10))),
|
|
1051
|
+
crop: z.optional(cropCropSchema),
|
|
988
1052
|
});
|
|
989
1053
|
|
|
990
1054
|
export const imageToVideoAssetSchema = imagetovideoassetImageToVideoAssetSchema;
|
|
@@ -993,27 +1057,28 @@ export const imageToVideoAssetSchema = imagetovideoassetImageToVideoAssetSchema;
|
|
|
993
1057
|
* Options for the Dolby.io audio enhancement provider.
|
|
994
1058
|
*/
|
|
995
1059
|
export const dolbyEnhancementOptionsDolbyEnhancementOptionsSchema = z.object({
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1060
|
+
preset: z.enum([
|
|
1061
|
+
"conference",
|
|
1062
|
+
"interview",
|
|
1063
|
+
"lecture",
|
|
1064
|
+
"meeting",
|
|
1065
|
+
"mobile_phone",
|
|
1066
|
+
"music",
|
|
1067
|
+
"podcast",
|
|
1068
|
+
"studio",
|
|
1069
|
+
"voice_over",
|
|
1070
|
+
]),
|
|
1007
1071
|
});
|
|
1008
1072
|
|
|
1009
|
-
export const dolbyEnhancementOptionsSchema =
|
|
1073
|
+
export const dolbyEnhancementOptionsSchema =
|
|
1074
|
+
dolbyEnhancementOptionsDolbyEnhancementOptionsSchema;
|
|
1010
1075
|
|
|
1011
1076
|
/**
|
|
1012
1077
|
* Dolby.io audio enhancement provider. Credentials are required and must be added via the [dashboard](https://dashboard.shotstack.io/integrations/dolby), not in the request.
|
|
1013
1078
|
*/
|
|
1014
1079
|
export const dolbyEnhancementDolbyEnhancementSchema = z.object({
|
|
1015
|
-
|
|
1016
|
-
|
|
1080
|
+
provider: z.string().default("dolby"),
|
|
1081
|
+
options: dolbyEnhancementOptionsDolbyEnhancementOptionsSchema,
|
|
1017
1082
|
});
|
|
1018
1083
|
|
|
1019
1084
|
export const dolbyEnhancementSchema = dolbyEnhancementDolbyEnhancementSchema;
|
|
@@ -1024,9 +1089,11 @@ export const dolbyEnhancementSchema = dolbyEnhancementDolbyEnhancementSchema;
|
|
|
1024
1089
|
* <li><a href="#tocs_dolbyenhancement">DolbyEnhancement</a></li>
|
|
1025
1090
|
* </ul>
|
|
1026
1091
|
*/
|
|
1027
|
-
export const audioEnhancementAudioEnhancementSchema = z
|
|
1028
|
-
|
|
1029
|
-
|
|
1092
|
+
export const audioEnhancementAudioEnhancementSchema = z
|
|
1093
|
+
.object({
|
|
1094
|
+
enhancement: z.literal("dolbyEnhancement_DolbyEnhancement"),
|
|
1095
|
+
})
|
|
1096
|
+
.and(dolbyEnhancementDolbyEnhancementSchema);
|
|
1030
1097
|
|
|
1031
1098
|
export const audioEnhancementSchema = audioEnhancementAudioEnhancementSchema;
|
|
1032
1099
|
|
|
@@ -1034,7 +1101,7 @@ export const audioEnhancementSchema = audioEnhancementAudioEnhancementSchema;
|
|
|
1034
1101
|
* Enhancements that can be applied to a rendition. Currently only supports the Dolby audio enhancement.
|
|
1035
1102
|
*/
|
|
1036
1103
|
export const enhancementsEnhancementsSchema = z.object({
|
|
1037
|
-
|
|
1104
|
+
audio: z.optional(audioEnhancementAudioEnhancementSchema),
|
|
1038
1105
|
});
|
|
1039
1106
|
|
|
1040
1107
|
export const enhancementsSchema = enhancementsEnhancementsSchema;
|
|
@@ -1043,68 +1110,74 @@ export const enhancementsSchema = enhancementsEnhancementsSchema;
|
|
|
1043
1110
|
* Individual errors returned by the Ingest API.
|
|
1044
1111
|
*/
|
|
1045
1112
|
export const ingesterrorresponsedataIngestErrorResponseDataSchema = z.object({
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1113
|
+
status: z.string(),
|
|
1114
|
+
title: z.string(),
|
|
1115
|
+
detail: z.string(),
|
|
1049
1116
|
});
|
|
1050
1117
|
|
|
1051
|
-
export const ingestErrorResponseDataSchema =
|
|
1118
|
+
export const ingestErrorResponseDataSchema =
|
|
1119
|
+
ingesterrorresponsedataIngestErrorResponseDataSchema;
|
|
1052
1120
|
|
|
1053
1121
|
/**
|
|
1054
1122
|
* Error response data for validation and other errors returned by the Ingest API.
|
|
1055
1123
|
*/
|
|
1056
1124
|
export const ingesterrorresponseIngestErrorResponseSchema = z.object({
|
|
1057
|
-
|
|
1125
|
+
errors: z.array(ingesterrorresponsedataIngestErrorResponseDataSchema),
|
|
1058
1126
|
});
|
|
1059
1127
|
|
|
1060
|
-
export const ingestErrorResponseSchema =
|
|
1128
|
+
export const ingestErrorResponseSchema =
|
|
1129
|
+
ingesterrorresponseIngestErrorResponseSchema;
|
|
1061
1130
|
|
|
1062
1131
|
/**
|
|
1063
1132
|
* The type of resource (a source) and the newly created source id. Returned with [QueuedSourceResponse](#tocs_queuedsourceresponse).
|
|
1064
1133
|
*/
|
|
1065
1134
|
export const queuedsourceresponsedataQueuedSourceResponseDataSchema = z.object({
|
|
1066
|
-
|
|
1067
|
-
|
|
1135
|
+
type: z.string(),
|
|
1136
|
+
id: z.string(),
|
|
1068
1137
|
});
|
|
1069
1138
|
|
|
1070
|
-
export const queuedSourceResponseDataSchema =
|
|
1139
|
+
export const queuedSourceResponseDataSchema =
|
|
1140
|
+
queuedsourceresponsedataQueuedSourceResponseDataSchema;
|
|
1071
1141
|
|
|
1072
1142
|
/**
|
|
1073
1143
|
* The response returned by the Ingest API [fetch source](#fetch-source) request. Includes the id of the source file. The response follows the [json:api](https://jsonapi.org/) specification.
|
|
1074
1144
|
*/
|
|
1075
1145
|
export const queuedsourceresponseQueuedSourceResponseSchema = z.object({
|
|
1076
|
-
|
|
1146
|
+
data: queuedsourceresponsedataQueuedSourceResponseDataSchema,
|
|
1077
1147
|
});
|
|
1078
1148
|
|
|
1079
|
-
export const queuedSourceResponseSchema =
|
|
1149
|
+
export const queuedSourceResponseSchema =
|
|
1150
|
+
queuedsourceresponseQueuedSourceResponseSchema;
|
|
1080
1151
|
|
|
1081
1152
|
/**
|
|
1082
1153
|
* The id and attributes of the upload file including the signed URL to send the binary file data to.
|
|
1083
1154
|
*/
|
|
1084
1155
|
export const uploadresponseattributesUploadResponseAttributesSchema = z.object({
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1156
|
+
id: z.string(),
|
|
1157
|
+
url: z.string(),
|
|
1158
|
+
expires: z.string(),
|
|
1088
1159
|
});
|
|
1089
1160
|
|
|
1090
|
-
export const uploadResponseAttributesSchema =
|
|
1161
|
+
export const uploadResponseAttributesSchema =
|
|
1162
|
+
uploadresponseattributesUploadResponseAttributesSchema;
|
|
1091
1163
|
|
|
1092
1164
|
/**
|
|
1093
1165
|
* The type of resource (an upload), it's id and attributes of the upload request.
|
|
1094
1166
|
*/
|
|
1095
1167
|
export const uploadresponsedataUploadResponseDataSchema = z.object({
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1168
|
+
type: z.string(),
|
|
1169
|
+
id: z.string(),
|
|
1170
|
+
attributes: uploadresponseattributesUploadResponseAttributesSchema,
|
|
1099
1171
|
});
|
|
1100
1172
|
|
|
1101
|
-
export const uploadResponseDataSchema =
|
|
1173
|
+
export const uploadResponseDataSchema =
|
|
1174
|
+
uploadresponsedataUploadResponseDataSchema;
|
|
1102
1175
|
|
|
1103
1176
|
/**
|
|
1104
1177
|
* The response returned by the Ingest API [direct upload](#direct-upload) request. Includes the id of the file and the signed url to send the binary file to. The response follows the [json:api](https://jsonapi.org/) specification.
|
|
1105
1178
|
*/
|
|
1106
1179
|
export const uploadresponseUploadResponseSchema = z.object({
|
|
1107
|
-
|
|
1180
|
+
data: uploadresponsedataUploadResponseDataSchema,
|
|
1108
1181
|
});
|
|
1109
1182
|
|
|
1110
1183
|
export const uploadResponseSchema = uploadresponseUploadResponseSchema;
|
|
@@ -1113,8 +1186,8 @@ export const uploadResponseSchema = uploadresponseUploadResponseSchema;
|
|
|
1113
1186
|
* Set the playback speed of a video or audio file. Allows you to preserve the pitch of the audio so that it is sped up without sounding too high pitched or too low.
|
|
1114
1187
|
*/
|
|
1115
1188
|
export const speedSpeedSchema = z.object({
|
|
1116
|
-
|
|
1117
|
-
|
|
1189
|
+
speed: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(10))),
|
|
1190
|
+
preservePitch: z.optional(z.boolean()),
|
|
1118
1191
|
});
|
|
1119
1192
|
|
|
1120
1193
|
export const speedSchema = speedSpeedSchema;
|
|
@@ -1123,7 +1196,7 @@ export const speedSchema = speedSpeedSchema;
|
|
|
1123
1196
|
* Generate a transcription of the audio in the video. The transcription can be output as a file in SRT or VTT format.
|
|
1124
1197
|
*/
|
|
1125
1198
|
export const transcriptionTranscriptionSchema = z.object({
|
|
1126
|
-
|
|
1199
|
+
format: z.optional(z.enum(["srt", "vtt"])),
|
|
1127
1200
|
});
|
|
1128
1201
|
|
|
1129
1202
|
export const transcriptionSchema = transcriptionTranscriptionSchema;
|
|
@@ -1132,9 +1205,9 @@ export const transcriptionSchema = transcriptionTranscriptionSchema;
|
|
|
1132
1205
|
* The LumaAsset is used to create luma matte masks, transitions and effects between other assets. A luma matte is a grey scale image or animated video where the black areas are transparent and the white areas solid. The luma matte animation should be provided as an mp4 video file. The src must be a publicly accessible URL to the file.
|
|
1133
1206
|
*/
|
|
1134
1207
|
export const lumaassetLumaAssetSchema = z.object({
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1208
|
+
type: z.enum(["luma"]),
|
|
1209
|
+
src: z.string(),
|
|
1210
|
+
trim: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
1138
1211
|
});
|
|
1139
1212
|
|
|
1140
1213
|
export const lumaAssetSchema = lumaassetLumaAssetSchema;
|
|
@@ -1143,8 +1216,8 @@ export const lumaAssetSchema = lumaassetLumaAssetSchema;
|
|
|
1143
1216
|
* A merge field consists of a key; `find`, and a value; `replace`. Merge fields can be used to replace placeholders within the JSON edit to create re-usable templates. Placeholders should be a string with double brace delimiters, i.e. `"{{NAME}}"`. A placeholder can be used for any value within the JSON edit.
|
|
1144
1217
|
*/
|
|
1145
1218
|
export const mergefieldMergeFieldSchema = z.object({
|
|
1146
|
-
|
|
1147
|
-
|
|
1219
|
+
find: z.string(),
|
|
1220
|
+
replace: z.unknown(),
|
|
1148
1221
|
});
|
|
1149
1222
|
|
|
1150
1223
|
export const mergeFieldSchema = mergefieldMergeFieldSchema;
|
|
@@ -1153,7 +1226,7 @@ export const mergeFieldSchema = mergefieldMergeFieldSchema;
|
|
|
1153
1226
|
* Generate a poster image for the video at a specific point from the timeline. The poster image size will match the size of the output video.
|
|
1154
1227
|
*/
|
|
1155
1228
|
export const posterPosterSchema = z.object({
|
|
1156
|
-
|
|
1229
|
+
capture: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number()),
|
|
1157
1230
|
});
|
|
1158
1231
|
|
|
1159
1232
|
export const posterSchema = posterPosterSchema;
|
|
@@ -1162,8 +1235,8 @@ export const posterSchema = posterPosterSchema;
|
|
|
1162
1235
|
* Specify a time range to render, i.e. to render only a portion of a video or audio file. Omit this setting to export the entire video. Range can also be used to render a frame at a specific time point - setting a range and output format as `jpg` will output a single frame image at the range `start` point.
|
|
1163
1236
|
*/
|
|
1164
1237
|
export const rangeRangeSchema = z.object({
|
|
1165
|
-
|
|
1166
|
-
|
|
1238
|
+
start: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))),
|
|
1239
|
+
length: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))),
|
|
1167
1240
|
});
|
|
1168
1241
|
|
|
1169
1242
|
export const rangeSchema = rangeRangeSchema;
|
|
@@ -1172,31 +1245,27 @@ export const rangeSchema = rangeRangeSchema;
|
|
|
1172
1245
|
* The list of asset attributes and their values.
|
|
1173
1246
|
*/
|
|
1174
1247
|
export const assetresponseattributesAssetResponseAttributesSchema = z.object({
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
'failed',
|
|
1186
|
-
'deleted'
|
|
1187
|
-
]),
|
|
1188
|
-
created: z.optional(z.string()),
|
|
1189
|
-
updated: z.optional(z.string())
|
|
1248
|
+
id: z.string(),
|
|
1249
|
+
owner: z.string(),
|
|
1250
|
+
region: z.optional(z.string()),
|
|
1251
|
+
renderId: z.optional(z.string()),
|
|
1252
|
+
providerId: z.optional(z.string()),
|
|
1253
|
+
filename: z.optional(z.string()),
|
|
1254
|
+
url: z.optional(z.string()),
|
|
1255
|
+
status: z.enum(["importing", "ready", "failed", "deleted"]),
|
|
1256
|
+
created: z.optional(z.string()),
|
|
1257
|
+
updated: z.optional(z.string()),
|
|
1190
1258
|
});
|
|
1191
1259
|
|
|
1192
|
-
export const assetResponseAttributesSchema =
|
|
1260
|
+
export const assetResponseAttributesSchema =
|
|
1261
|
+
assetresponseattributesAssetResponseAttributesSchema;
|
|
1193
1262
|
|
|
1194
1263
|
/**
|
|
1195
1264
|
* The type of resource (an asset) and attributes of the asset.
|
|
1196
1265
|
*/
|
|
1197
1266
|
export const assetresponsedataAssetResponseDataSchema = z.object({
|
|
1198
|
-
|
|
1199
|
-
|
|
1267
|
+
type: z.string(),
|
|
1268
|
+
attributes: assetresponseattributesAssetResponseAttributesSchema,
|
|
1200
1269
|
});
|
|
1201
1270
|
|
|
1202
1271
|
export const assetResponseDataSchema = assetresponsedataAssetResponseDataSchema;
|
|
@@ -1205,16 +1274,17 @@ export const assetResponseDataSchema = assetresponsedataAssetResponseDataSchema;
|
|
|
1205
1274
|
* The response returned by the Serve API [get asset by render id](#get-asset-by-render-id) request. The response is an array of asset resources, including video, image, audio, thumbnail and poster image. The response follows the [json:api](https://jsonapi.org/) specification.
|
|
1206
1275
|
*/
|
|
1207
1276
|
export const assetrenderresponseAssetRenderResponseSchema = z.object({
|
|
1208
|
-
|
|
1277
|
+
data: z.array(assetresponsedataAssetResponseDataSchema),
|
|
1209
1278
|
});
|
|
1210
1279
|
|
|
1211
|
-
export const assetRenderResponseSchema =
|
|
1280
|
+
export const assetRenderResponseSchema =
|
|
1281
|
+
assetrenderresponseAssetRenderResponseSchema;
|
|
1212
1282
|
|
|
1213
1283
|
/**
|
|
1214
1284
|
* The response returned by the Serve API [get asset](#get-asset) request. Includes details of a hosted video, image, audio file, thumbnail or poster image. The response follows the [json:api](https://jsonapi.org/) specification.
|
|
1215
1285
|
*/
|
|
1216
1286
|
export const assetresponseAssetResponseSchema = z.object({
|
|
1217
|
-
|
|
1287
|
+
data: assetresponsedataAssetResponseDataSchema,
|
|
1218
1288
|
});
|
|
1219
1289
|
|
|
1220
1290
|
export const assetResponseSchema = assetresponseAssetResponseSchema;
|
|
@@ -1223,9 +1293,9 @@ export const assetResponseSchema = assetresponseAssetResponseSchema;
|
|
|
1223
1293
|
* The response received after a [probe request](#inspect-media) is submitted. The probe requests returns data from FFprobe formatted as JSON.
|
|
1224
1294
|
*/
|
|
1225
1295
|
export const proberesponseProbeResponseSchema = z.object({
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1296
|
+
success: z.boolean(),
|
|
1297
|
+
message: z.string(),
|
|
1298
|
+
response: z.record(z.string(), z.unknown()),
|
|
1229
1299
|
});
|
|
1230
1300
|
|
|
1231
1301
|
export const probeResponseSchema = proberesponseProbeResponseSchema;
|
|
@@ -1234,19 +1304,20 @@ export const probeResponseSchema = proberesponseProbeResponseSchema;
|
|
|
1234
1304
|
* The response data returned with the [QueuedResponse](#tocs_queuedresponse).
|
|
1235
1305
|
*/
|
|
1236
1306
|
export const queuedresponsedataQueuedResponseDataSchema = z.object({
|
|
1237
|
-
|
|
1238
|
-
|
|
1307
|
+
message: z.string(),
|
|
1308
|
+
id: z.string(),
|
|
1239
1309
|
});
|
|
1240
1310
|
|
|
1241
|
-
export const queuedResponseDataSchema =
|
|
1311
|
+
export const queuedResponseDataSchema =
|
|
1312
|
+
queuedresponsedataQueuedResponseDataSchema;
|
|
1242
1313
|
|
|
1243
1314
|
/**
|
|
1244
1315
|
* The response received after a [render request](#render-asset) or [template render](#render-template) is submitted. The render task is queued for rendering and a unique render id is returned.
|
|
1245
1316
|
*/
|
|
1246
1317
|
export const queuedresponseQueuedResponseSchema = z.object({
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1318
|
+
success: z.boolean(),
|
|
1319
|
+
message: z.string(),
|
|
1320
|
+
response: queuedresponsedataQueuedResponseDataSchema,
|
|
1250
1321
|
});
|
|
1251
1322
|
|
|
1252
1323
|
export const queuedResponseSchema = queuedresponseQueuedResponseSchema;
|
|
@@ -1255,52 +1326,56 @@ export const queuedResponseSchema = queuedresponseQueuedResponseSchema;
|
|
|
1255
1326
|
* The individual template item returned with the [TemplateListResponseData](#tocs_templatelistresponsedata) templates list.
|
|
1256
1327
|
*/
|
|
1257
1328
|
export const templatelistresponseitemTemplateListResponseItemSchema = z.object({
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1329
|
+
id: z.string(),
|
|
1330
|
+
name: z.string(),
|
|
1331
|
+
created: z.optional(z.string()),
|
|
1332
|
+
updated: z.optional(z.string()),
|
|
1262
1333
|
});
|
|
1263
1334
|
|
|
1264
|
-
export const templateListResponseItemSchema =
|
|
1335
|
+
export const templateListResponseItemSchema =
|
|
1336
|
+
templatelistresponseitemTemplateListResponseItemSchema;
|
|
1265
1337
|
|
|
1266
1338
|
/**
|
|
1267
1339
|
* The response data returned with the [TemplateListResponse](#tocs_templatelistresponse).
|
|
1268
1340
|
*/
|
|
1269
1341
|
export const templatelistresponsedataTemplateListResponseDataSchema = z.object({
|
|
1270
|
-
|
|
1271
|
-
|
|
1342
|
+
owner: z.string(),
|
|
1343
|
+
templates: z.array(templatelistresponseitemTemplateListResponseItemSchema),
|
|
1272
1344
|
});
|
|
1273
1345
|
|
|
1274
|
-
export const templateListResponseDataSchema =
|
|
1346
|
+
export const templateListResponseDataSchema =
|
|
1347
|
+
templatelistresponsedataTemplateListResponseDataSchema;
|
|
1275
1348
|
|
|
1276
1349
|
/**
|
|
1277
1350
|
* A list of previously saved templates.
|
|
1278
1351
|
*/
|
|
1279
1352
|
export const templatelistresponseTemplateListResponseSchema = z.object({
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1353
|
+
success: z.boolean(),
|
|
1354
|
+
message: z.string(),
|
|
1355
|
+
response: templatelistresponsedataTemplateListResponseDataSchema,
|
|
1283
1356
|
});
|
|
1284
1357
|
|
|
1285
|
-
export const templateListResponseSchema =
|
|
1358
|
+
export const templateListResponseSchema =
|
|
1359
|
+
templatelistresponseTemplateListResponseSchema;
|
|
1286
1360
|
|
|
1287
1361
|
/**
|
|
1288
1362
|
* The response data returned with the [TemplateResponse](#tocs_templateresponse).
|
|
1289
1363
|
*/
|
|
1290
1364
|
export const templateresponsedataTemplateResponseDataSchema = z.object({
|
|
1291
|
-
|
|
1292
|
-
|
|
1365
|
+
message: z.string(),
|
|
1366
|
+
id: z.string(),
|
|
1293
1367
|
});
|
|
1294
1368
|
|
|
1295
|
-
export const templateResponseDataSchema =
|
|
1369
|
+
export const templateResponseDataSchema =
|
|
1370
|
+
templateresponsedataTemplateResponseDataSchema;
|
|
1296
1371
|
|
|
1297
1372
|
/**
|
|
1298
1373
|
* The response received after a [template](#create-template) is submitted. The template is saved and a unique template id is returned.
|
|
1299
1374
|
*/
|
|
1300
1375
|
export const templateresponseTemplateResponseSchema = z.object({
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1376
|
+
success: z.boolean(),
|
|
1377
|
+
message: z.string(),
|
|
1378
|
+
response: templateresponsedataTemplateResponseDataSchema,
|
|
1304
1379
|
});
|
|
1305
1380
|
|
|
1306
1381
|
export const templateResponseSchema = templateresponseTemplateResponseSchema;
|
|
@@ -1309,76 +1384,70 @@ export const templateResponseSchema = templateresponseTemplateResponseSchema;
|
|
|
1309
1384
|
* Text alignment properties (horizontal and vertical).
|
|
1310
1385
|
*/
|
|
1311
1386
|
export const richtextpropertiesRichTextAlignmentSchema = z.object({
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
'center',
|
|
1315
|
-
'right'
|
|
1316
|
-
])),
|
|
1317
|
-
vertical: z.optional(z.enum([
|
|
1318
|
-
'top',
|
|
1319
|
-
'middle',
|
|
1320
|
-
'bottom'
|
|
1321
|
-
]))
|
|
1387
|
+
horizontal: z.optional(z.enum(["left", "center", "right"])),
|
|
1388
|
+
vertical: z.optional(z.enum(["top", "middle", "bottom"])),
|
|
1322
1389
|
});
|
|
1323
1390
|
|
|
1324
|
-
export const richTextAlignmentSchema =
|
|
1391
|
+
export const richTextAlignmentSchema =
|
|
1392
|
+
richtextpropertiesRichTextAlignmentSchema;
|
|
1325
1393
|
|
|
1326
1394
|
/**
|
|
1327
1395
|
* Animation properties for text entrance effects.
|
|
1328
1396
|
*/
|
|
1329
1397
|
export const richtextpropertiesRichTextAnimationSchema = z.object({
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
'left',
|
|
1343
|
-
'right',
|
|
1344
|
-
'up',
|
|
1345
|
-
'down'
|
|
1346
|
-
]))
|
|
1398
|
+
preset: z.enum([
|
|
1399
|
+
"fadeIn",
|
|
1400
|
+
"slideIn",
|
|
1401
|
+
"typewriter",
|
|
1402
|
+
"ascend",
|
|
1403
|
+
"shift",
|
|
1404
|
+
"movingLetters",
|
|
1405
|
+
]),
|
|
1406
|
+
speed: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0.1).lte(10))).default(1),
|
|
1407
|
+
duration: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0.1).lte(30))),
|
|
1408
|
+
style: z.optional(z.enum(["character", "word"])),
|
|
1409
|
+
direction: z.optional(z.enum(["left", "right", "up", "down"])),
|
|
1347
1410
|
});
|
|
1348
1411
|
|
|
1349
|
-
export const richTextAnimationSchema =
|
|
1412
|
+
export const richTextAnimationSchema =
|
|
1413
|
+
richtextpropertiesRichTextAnimationSchema;
|
|
1350
1414
|
|
|
1351
1415
|
/**
|
|
1352
1416
|
* Background styling properties for the text bounding box.
|
|
1353
1417
|
*/
|
|
1354
1418
|
export const richtextpropertiesRichTextBackgroundSchema = z.object({
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1419
|
+
color: z.optional(z.string().regex(/^#[A-Fa-f0-9]{6}$/)),
|
|
1420
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(1),
|
|
1421
|
+
borderRadius: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))).default(0),
|
|
1358
1422
|
});
|
|
1359
1423
|
|
|
1360
|
-
export const richTextBackgroundSchema =
|
|
1424
|
+
export const richTextBackgroundSchema =
|
|
1425
|
+
richtextpropertiesRichTextBackgroundSchema;
|
|
1361
1426
|
|
|
1362
1427
|
/**
|
|
1363
1428
|
* Border styling properties for the text bounding box.
|
|
1364
1429
|
*/
|
|
1365
1430
|
export const richtextpropertiesRichTextBorderSchema = z.object({
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1431
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))).default(0),
|
|
1432
|
+
color: z.optional(z.string().regex(/^#[A-Fa-f0-9]{6}$/)).default("#000000"),
|
|
1433
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(1),
|
|
1434
|
+
radius: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))).default(0),
|
|
1370
1435
|
});
|
|
1371
1436
|
|
|
1372
1437
|
/**
|
|
1373
1438
|
* Gradient properties for text fill.
|
|
1374
1439
|
*/
|
|
1375
1440
|
export const richtextpropertiesRichTextGradientSchema = z.object({
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1441
|
+
type: z.optional(z.enum(["linear", "radial"])),
|
|
1442
|
+
angle: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(360))).default(0),
|
|
1443
|
+
stops: z
|
|
1444
|
+
.array(
|
|
1445
|
+
z.object({
|
|
1379
1446
|
offset: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1)),
|
|
1380
|
-
color: z.string().regex(/^#[A-Fa-f0-9]{6}$/)
|
|
1381
|
-
|
|
1447
|
+
color: z.string().regex(/^#[A-Fa-f0-9]{6}$/),
|
|
1448
|
+
}),
|
|
1449
|
+
)
|
|
1450
|
+
.min(2),
|
|
1382
1451
|
});
|
|
1383
1452
|
|
|
1384
1453
|
export const richTextGradientSchema = richtextpropertiesRichTextGradientSchema;
|
|
@@ -1387,21 +1456,21 @@ export const richTextGradientSchema = richtextpropertiesRichTextGradientSchema;
|
|
|
1387
1456
|
* Padding properties for individual sides of the text bounding box.
|
|
1388
1457
|
*/
|
|
1389
1458
|
export const richtextpropertiesRichTextPaddingSchema = z.object({
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1459
|
+
top: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))).default(0),
|
|
1460
|
+
right: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))).default(0),
|
|
1461
|
+
bottom: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))).default(0),
|
|
1462
|
+
left: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))).default(0),
|
|
1394
1463
|
});
|
|
1395
1464
|
|
|
1396
1465
|
/**
|
|
1397
1466
|
* Text shadow properties.
|
|
1398
1467
|
*/
|
|
1399
1468
|
export const richtextpropertiesRichTextShadowSchema = z.object({
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1469
|
+
offsetX: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())).default(0),
|
|
1470
|
+
offsetY: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())).default(0),
|
|
1471
|
+
blur: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))).default(0),
|
|
1472
|
+
color: z.optional(z.string().regex(/^#[A-Fa-f0-9]{6}$/)).default("#000000"),
|
|
1473
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(0.5),
|
|
1405
1474
|
});
|
|
1406
1475
|
|
|
1407
1476
|
export const richTextShadowSchema = richtextpropertiesRichTextShadowSchema;
|
|
@@ -1410,9 +1479,9 @@ export const richTextShadowSchema = richtextpropertiesRichTextShadowSchema;
|
|
|
1410
1479
|
* Text stroke (outline) properties.
|
|
1411
1480
|
*/
|
|
1412
1481
|
export const richtextpropertiesRichTextStrokeSchema = z.object({
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1482
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))).default(0),
|
|
1483
|
+
color: z.optional(z.string().regex(/^#[A-Fa-f0-9]{6}$/)).default("#000000"),
|
|
1484
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(1),
|
|
1416
1485
|
});
|
|
1417
1486
|
|
|
1418
1487
|
export const richTextStrokeSchema = richtextpropertiesRichTextStrokeSchema;
|
|
@@ -1421,13 +1490,13 @@ export const richTextStrokeSchema = richtextpropertiesRichTextStrokeSchema;
|
|
|
1421
1490
|
* Font properties for rich text.
|
|
1422
1491
|
*/
|
|
1423
1492
|
export const richtextpropertiesRichTextFontSchema = z.object({
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1493
|
+
family: z.optional(z.string()).default("Open Sans"),
|
|
1494
|
+
size: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(1).lte(500))).default(24),
|
|
1495
|
+
weight: z.optional(z.unknown()).default("400"),
|
|
1496
|
+
color: z.optional(z.string().regex(/^#[A-Fa-f0-9]{6}$/)).default("#ffffff"),
|
|
1497
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(1),
|
|
1498
|
+
background: z.optional(z.string().regex(/^#[A-Fa-f0-9]{6}$/)),
|
|
1499
|
+
stroke: z.optional(richtextpropertiesRichTextStrokeSchema),
|
|
1431
1500
|
});
|
|
1432
1501
|
|
|
1433
1502
|
export const richTextFontSchema = richtextpropertiesRichTextFontSchema;
|
|
@@ -1436,20 +1505,13 @@ export const richTextFontSchema = richtextpropertiesRichTextFontSchema;
|
|
|
1436
1505
|
* Text style properties including spacing, line height, and transformations.
|
|
1437
1506
|
*/
|
|
1438
1507
|
export const richtextpropertiesRichTextStyleSchema = z.object({
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
])),
|
|
1447
|
-
textDecoration: z.optional(z.enum([
|
|
1448
|
-
'none',
|
|
1449
|
-
'underline',
|
|
1450
|
-
'line-through'
|
|
1451
|
-
])),
|
|
1452
|
-
gradient: z.optional(richtextpropertiesRichTextGradientSchema)
|
|
1508
|
+
letterSpacing: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())).default(0),
|
|
1509
|
+
lineHeight: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(10))).default(1.2),
|
|
1510
|
+
textTransform: z.optional(
|
|
1511
|
+
z.enum(["none", "uppercase", "lowercase", "capitalize"]),
|
|
1512
|
+
),
|
|
1513
|
+
textDecoration: z.optional(z.enum(["none", "underline", "line-through"])),
|
|
1514
|
+
gradient: z.optional(richtextpropertiesRichTextGradientSchema),
|
|
1453
1515
|
});
|
|
1454
1516
|
|
|
1455
1517
|
export const richTextStyleSchema = richtextpropertiesRichTextStyleSchema;
|
|
@@ -1460,19 +1522,18 @@ export const richTextStyleSchema = richtextpropertiesRichTextStyleSchema;
|
|
|
1460
1522
|
*
|
|
1461
1523
|
*/
|
|
1462
1524
|
export const richtextassetRichTextAssetSchema = z.object({
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
animation: z.optional(richtextpropertiesRichTextAnimationSchema)
|
|
1525
|
+
type: z.enum(["rich-text"]),
|
|
1526
|
+
text: z.string().max(5000),
|
|
1527
|
+
font: z.optional(richtextpropertiesRichTextFontSchema),
|
|
1528
|
+
style: z.optional(richtextpropertiesRichTextStyleSchema),
|
|
1529
|
+
shadow: z.optional(richtextpropertiesRichTextShadowSchema),
|
|
1530
|
+
background: z.optional(richtextpropertiesRichTextBackgroundSchema),
|
|
1531
|
+
border: z.optional(richtextpropertiesRichTextBorderSchema),
|
|
1532
|
+
padding: z.optional(
|
|
1533
|
+
z.union([z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0)), richtextpropertiesRichTextPaddingSchema]),
|
|
1534
|
+
),
|
|
1535
|
+
align: z.optional(richtextpropertiesRichTextAlignmentSchema),
|
|
1536
|
+
animation: z.optional(richtextpropertiesRichTextAnimationSchema),
|
|
1476
1537
|
});
|
|
1477
1538
|
|
|
1478
1539
|
export const richTextAssetSchema = richtextassetRichTextAssetSchema;
|
|
@@ -1480,30 +1541,35 @@ export const richTextAssetSchema = richtextassetRichTextAssetSchema;
|
|
|
1480
1541
|
/**
|
|
1481
1542
|
* The transfer request attributes inlcudling the user specified ID and status. Returned with [TransferResponseData](#tocs_transferresponsedata).
|
|
1482
1543
|
*/
|
|
1483
|
-
export const transferresponseattributesTransferResponseAttributesSchema =
|
|
1544
|
+
export const transferresponseattributesTransferResponseAttributesSchema =
|
|
1545
|
+
z.object({
|
|
1484
1546
|
id: z.optional(z.string()),
|
|
1485
1547
|
owner: z.optional(z.string()),
|
|
1486
|
-
status: z.optional(z.enum([
|
|
1487
|
-
created: z.optional(z.string())
|
|
1488
|
-
});
|
|
1548
|
+
status: z.optional(z.enum(["queued", "failed"])),
|
|
1549
|
+
created: z.optional(z.string()),
|
|
1550
|
+
});
|
|
1489
1551
|
|
|
1490
|
-
export const transferResponseAttributesSchema =
|
|
1552
|
+
export const transferResponseAttributesSchema =
|
|
1553
|
+
transferresponseattributesTransferResponseAttributesSchema;
|
|
1491
1554
|
|
|
1492
1555
|
/**
|
|
1493
1556
|
* The type of resource (an asset) and the transfer attributes. Returned with [TransferResponse](#tocs_transferresponse).
|
|
1494
1557
|
*/
|
|
1495
1558
|
export const transferresponsedataTransferResponseDataSchema = z.object({
|
|
1496
|
-
|
|
1497
|
-
|
|
1559
|
+
type: z.optional(z.string()),
|
|
1560
|
+
attributes: z.optional(
|
|
1561
|
+
transferresponseattributesTransferResponseAttributesSchema,
|
|
1562
|
+
),
|
|
1498
1563
|
});
|
|
1499
1564
|
|
|
1500
|
-
export const transferResponseDataSchema =
|
|
1565
|
+
export const transferResponseDataSchema =
|
|
1566
|
+
transferresponsedataTransferResponseDataSchema;
|
|
1501
1567
|
|
|
1502
1568
|
/**
|
|
1503
1569
|
* The response returned by the Serve API [transfer asset](#transfer-asset) request. The response includes the ID and transfer status. The response follows the [json:api](https://jsonapi.org/) specification.
|
|
1504
1570
|
*/
|
|
1505
1571
|
export const transferresponseTransferResponseSchema = z.object({
|
|
1506
|
-
|
|
1572
|
+
data: transferresponsedataTransferResponseDataSchema,
|
|
1507
1573
|
});
|
|
1508
1574
|
|
|
1509
1575
|
export const transferResponseSchema = transferresponseTransferResponseSchema;
|
|
@@ -1512,9 +1578,9 @@ export const transferResponseSchema = transferresponseTransferResponseSchema;
|
|
|
1512
1578
|
* The asset URL to fetch and transfer to a destination.
|
|
1513
1579
|
*/
|
|
1514
1580
|
export const transferTransferSchema = z.object({
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1581
|
+
url: z.string(),
|
|
1582
|
+
id: z.string(),
|
|
1583
|
+
destinations: z.array(destinationsDestinationsSchema),
|
|
1518
1584
|
});
|
|
1519
1585
|
|
|
1520
1586
|
export const transferSchema = transferTransferSchema;
|
|
@@ -1525,34 +1591,40 @@ export const transferSchema = transferTransferSchema;
|
|
|
1525
1591
|
*
|
|
1526
1592
|
*/
|
|
1527
1593
|
export const shapeassetShapeAssetSchema = z.object({
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1594
|
+
type: z.enum(["shape"]),
|
|
1595
|
+
shape: z.enum(["rectangle", "circle", "line"]),
|
|
1596
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
1597
|
+
height: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
1598
|
+
fill: z.optional(
|
|
1599
|
+
z.object({
|
|
1600
|
+
color: z.optional(z.string()),
|
|
1601
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
1602
|
+
}),
|
|
1603
|
+
),
|
|
1604
|
+
stroke: z.optional(
|
|
1605
|
+
z.object({
|
|
1606
|
+
color: z.optional(z.string()),
|
|
1607
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
1608
|
+
}),
|
|
1609
|
+
),
|
|
1610
|
+
rectangle: z.optional(
|
|
1611
|
+
z.object({
|
|
1612
|
+
width: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int()),
|
|
1613
|
+
height: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int()),
|
|
1614
|
+
cornerRadius: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
1615
|
+
}),
|
|
1616
|
+
),
|
|
1617
|
+
circle: z.optional(
|
|
1618
|
+
z.object({
|
|
1619
|
+
radius: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int()),
|
|
1620
|
+
}),
|
|
1621
|
+
),
|
|
1622
|
+
line: z.optional(
|
|
1623
|
+
z.object({
|
|
1624
|
+
length: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int()),
|
|
1625
|
+
thickness: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int()),
|
|
1626
|
+
}),
|
|
1627
|
+
),
|
|
1556
1628
|
});
|
|
1557
1629
|
|
|
1558
1630
|
export const shapeAssetSchema = shapeassetShapeAssetSchema;
|
|
@@ -1561,8 +1633,8 @@ export const shapeAssetSchema = shapeassetShapeAssetSchema;
|
|
|
1561
1633
|
* Set a custom size for a video or image in pixels. When using a custom size omit the `resolution` and `aspectRatio`. Custom sizes must be divisible by 2 based on the encoder specifications.
|
|
1562
1634
|
*/
|
|
1563
1635
|
export const sizeSizeSchema = z.object({
|
|
1564
|
-
|
|
1565
|
-
|
|
1636
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(1).lte(4096))),
|
|
1637
|
+
height: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(1).lte(4096))),
|
|
1566
1638
|
});
|
|
1567
1639
|
|
|
1568
1640
|
export const sizeSchema = sizeSizeSchema;
|
|
@@ -1571,56 +1643,50 @@ export const sizeSchema = sizeSizeSchema;
|
|
|
1571
1643
|
* A rendition is a new output file that is generated from the source. The rendition can be encoded to a different format and have transformations applied to it such as resizing, cropping, etc...
|
|
1572
1644
|
*/
|
|
1573
1645
|
export const renditionRenditionSchema = z.object({
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1611
|
-
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
|
|
1618
|
-
speed: z.optional(speedSpeedSchema),
|
|
1619
|
-
keyframeInterval: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(1).lte(300))),
|
|
1620
|
-
fixOffset: z.optional(z.boolean()),
|
|
1621
|
-
fixRotation: z.optional(z.boolean()),
|
|
1622
|
-
enhance: z.optional(enhancementsEnhancementsSchema),
|
|
1623
|
-
filename: z.optional(z.string())
|
|
1646
|
+
format: z.optional(
|
|
1647
|
+
z.enum([
|
|
1648
|
+
"mp4",
|
|
1649
|
+
"webm",
|
|
1650
|
+
"mov",
|
|
1651
|
+
"avi",
|
|
1652
|
+
"mkv",
|
|
1653
|
+
"ogv",
|
|
1654
|
+
"wmv",
|
|
1655
|
+
"avif",
|
|
1656
|
+
"gif",
|
|
1657
|
+
"mp3",
|
|
1658
|
+
"wav",
|
|
1659
|
+
"jpg",
|
|
1660
|
+
"png",
|
|
1661
|
+
"webp",
|
|
1662
|
+
"tif",
|
|
1663
|
+
]),
|
|
1664
|
+
),
|
|
1665
|
+
size: z.optional(sizeSizeSchema),
|
|
1666
|
+
fit: z.optional(z.enum(["cover", "contain", "crop"])),
|
|
1667
|
+
resolution: z.optional(z.enum(["preview", "mobile", "sd", "hd", "fhd"])),
|
|
1668
|
+
quality: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(1).lte(100))),
|
|
1669
|
+
fps: z.optional(
|
|
1670
|
+
z.union([
|
|
1671
|
+
z.literal(12),
|
|
1672
|
+
z.literal(15),
|
|
1673
|
+
z.literal(23.976),
|
|
1674
|
+
z.literal(24),
|
|
1675
|
+
z.literal(25),
|
|
1676
|
+
z.literal(29.97),
|
|
1677
|
+
z.literal(30),
|
|
1678
|
+
z.literal(48),
|
|
1679
|
+
z.literal(50),
|
|
1680
|
+
z.literal(59.94),
|
|
1681
|
+
z.literal(60),
|
|
1682
|
+
]),
|
|
1683
|
+
),
|
|
1684
|
+
speed: z.optional(speedSpeedSchema),
|
|
1685
|
+
keyframeInterval: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(1).lte(300))),
|
|
1686
|
+
fixOffset: z.optional(z.boolean()),
|
|
1687
|
+
fixRotation: z.optional(z.boolean()),
|
|
1688
|
+
enhance: z.optional(enhancementsEnhancementsSchema),
|
|
1689
|
+
filename: z.optional(z.string()),
|
|
1624
1690
|
});
|
|
1625
1691
|
|
|
1626
1692
|
export const renditionSchema = renditionRenditionSchema;
|
|
@@ -1629,8 +1695,8 @@ export const renditionSchema = renditionRenditionSchema;
|
|
|
1629
1695
|
* The output renditions and transformations that should be generated from the source file.
|
|
1630
1696
|
*/
|
|
1631
1697
|
export const outputsOutputsSchema = z.object({
|
|
1632
|
-
|
|
1633
|
-
|
|
1698
|
+
renditions: z.optional(z.array(renditionRenditionSchema)),
|
|
1699
|
+
transcription: z.optional(transcriptionTranscriptionSchema),
|
|
1634
1700
|
});
|
|
1635
1701
|
|
|
1636
1702
|
export const outputsSchema = outputsOutputsSchema;
|
|
@@ -1638,32 +1704,38 @@ export const outputsSchema = outputsOutputsSchema;
|
|
|
1638
1704
|
/**
|
|
1639
1705
|
* The id and attributes of the generated rendition file.
|
|
1640
1706
|
*/
|
|
1641
|
-
export const renditionresponseattributesRenditionResponseAttributesSchema =
|
|
1707
|
+
export const renditionresponseattributesRenditionResponseAttributesSchema =
|
|
1708
|
+
z.object({
|
|
1642
1709
|
id: z.string(),
|
|
1643
|
-
status: z.optional(
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1710
|
+
status: z.optional(
|
|
1711
|
+
z.enum([
|
|
1712
|
+
"queued",
|
|
1713
|
+
"importing",
|
|
1714
|
+
"ready",
|
|
1715
|
+
"failed",
|
|
1716
|
+
"deleted",
|
|
1717
|
+
"overwritten",
|
|
1718
|
+
]),
|
|
1719
|
+
),
|
|
1651
1720
|
url: z.optional(z.string()),
|
|
1652
1721
|
executionTime: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
1653
1722
|
transformation: z.optional(renditionRenditionSchema),
|
|
1654
1723
|
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
1655
1724
|
height: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
1656
1725
|
duration: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
1657
|
-
fps: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number()))
|
|
1658
|
-
});
|
|
1726
|
+
fps: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
1727
|
+
});
|
|
1659
1728
|
|
|
1660
|
-
export const renditionResponseAttributesSchema =
|
|
1729
|
+
export const renditionResponseAttributesSchema =
|
|
1730
|
+
renditionresponseattributesRenditionResponseAttributesSchema;
|
|
1661
1731
|
|
|
1662
1732
|
/**
|
|
1663
1733
|
* The list of outputs generated from the source file. Currently supports renditions which are versions of the source file with different transformations applied.
|
|
1664
1734
|
*/
|
|
1665
1735
|
export const outputsresponseOutputsResponseSchema = z.object({
|
|
1666
|
-
|
|
1736
|
+
renditions: z.optional(
|
|
1737
|
+
z.array(renditionresponseattributesRenditionResponseAttributesSchema),
|
|
1738
|
+
),
|
|
1667
1739
|
});
|
|
1668
1740
|
|
|
1669
1741
|
export const outputsResponseSchema = outputsresponseOutputsResponseSchema;
|
|
@@ -1672,54 +1744,59 @@ export const outputsResponseSchema = outputsresponseOutputsResponseSchema;
|
|
|
1672
1744
|
* The id and attributes of the source file.
|
|
1673
1745
|
*/
|
|
1674
1746
|
export const sourceresponseattributesSourceResponseAttributesSchema = z.object({
|
|
1675
|
-
|
|
1676
|
-
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1747
|
+
id: z.string(),
|
|
1748
|
+
owner: z.string(),
|
|
1749
|
+
input: z.optional(z.string()),
|
|
1750
|
+
source: z.optional(z.string()),
|
|
1751
|
+
status: z.optional(
|
|
1752
|
+
z.enum([
|
|
1753
|
+
"queued",
|
|
1754
|
+
"importing",
|
|
1755
|
+
"ready",
|
|
1756
|
+
"failed",
|
|
1757
|
+
"deleted",
|
|
1758
|
+
"overwritten",
|
|
1759
|
+
]),
|
|
1760
|
+
),
|
|
1761
|
+
outputs: z.optional(outputsresponseOutputsResponseSchema),
|
|
1762
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
1763
|
+
height: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
1764
|
+
duration: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
1765
|
+
fps: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
1766
|
+
created: z.optional(z.string()),
|
|
1767
|
+
updated: z.optional(z.string()),
|
|
1694
1768
|
});
|
|
1695
1769
|
|
|
1696
|
-
export const sourceResponseAttributesSchema =
|
|
1770
|
+
export const sourceResponseAttributesSchema =
|
|
1771
|
+
sourceresponseattributesSourceResponseAttributesSchema;
|
|
1697
1772
|
|
|
1698
1773
|
/**
|
|
1699
1774
|
* The type of resource (a source), it's id and attributes of the source file.
|
|
1700
1775
|
*/
|
|
1701
1776
|
export const sourceresponsedataSourceResponseDataSchema = z.object({
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1777
|
+
type: z.string(),
|
|
1778
|
+
id: z.string(),
|
|
1779
|
+
attributes: sourceresponseattributesSourceResponseAttributesSchema,
|
|
1705
1780
|
});
|
|
1706
1781
|
|
|
1707
|
-
export const sourceResponseDataSchema =
|
|
1782
|
+
export const sourceResponseDataSchema =
|
|
1783
|
+
sourceresponsedataSourceResponseDataSchema;
|
|
1708
1784
|
|
|
1709
1785
|
/**
|
|
1710
1786
|
* A list of all ingested source files fetched or uploaded to a users account.
|
|
1711
1787
|
*/
|
|
1712
1788
|
export const sourcelistresponseSourceListResponseSchema = z.object({
|
|
1713
|
-
|
|
1789
|
+
data: z.array(sourceresponsedataSourceResponseDataSchema),
|
|
1714
1790
|
});
|
|
1715
1791
|
|
|
1716
|
-
export const sourceListResponseSchema =
|
|
1792
|
+
export const sourceListResponseSchema =
|
|
1793
|
+
sourcelistresponseSourceListResponseSchema;
|
|
1717
1794
|
|
|
1718
1795
|
/**
|
|
1719
1796
|
* The response returned by the Ingest API [get source](#get-source) request. Includes details of the ingested source file. The response follows the [json:api](https://jsonapi.org/) specification.
|
|
1720
1797
|
*/
|
|
1721
1798
|
export const sourceresponseSourceResponseSchema = z.object({
|
|
1722
|
-
|
|
1799
|
+
data: sourceresponsedataSourceResponseDataSchema,
|
|
1723
1800
|
});
|
|
1724
1801
|
|
|
1725
1802
|
export const sourceResponseSchema = sourceresponseSourceResponseSchema;
|
|
@@ -1729,10 +1806,10 @@ export const sourceResponseSchema = sourceresponseSourceResponseSchema;
|
|
|
1729
1806
|
* A rendition is a new version, generated from the source. This can be used to create new sizes and aspect ratios tht serve different purposes within an application.
|
|
1730
1807
|
*/
|
|
1731
1808
|
export const sourceSourceSchema = z.object({
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
|
|
1809
|
+
url: z.optional(z.string()),
|
|
1810
|
+
outputs: z.optional(outputsOutputsSchema),
|
|
1811
|
+
destinations: z.optional(destinationsDestinationsSchema),
|
|
1812
|
+
callback: z.optional(z.string()),
|
|
1736
1813
|
});
|
|
1737
1814
|
|
|
1738
1815
|
export const sourceSchema = sourceSourceSchema;
|
|
@@ -1741,13 +1818,9 @@ export const sourceSchema = sourceSourceSchema;
|
|
|
1741
1818
|
* A music or audio file in mp3 format that plays for the duration of the rendered video or the length of the audio file, which ever is shortest.
|
|
1742
1819
|
*/
|
|
1743
1820
|
export const soundtrackSoundtrackSchema = z.object({
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
'fadeOut',
|
|
1748
|
-
'fadeInFadeOut'
|
|
1749
|
-
])),
|
|
1750
|
-
volume: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number()))
|
|
1821
|
+
src: z.string(),
|
|
1822
|
+
effect: z.optional(z.enum(["fadeIn", "fadeOut", "fadeInFadeOut"])),
|
|
1823
|
+
volume: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
1751
1824
|
});
|
|
1752
1825
|
|
|
1753
1826
|
export const soundtrackSchema = soundtrackSoundtrackSchema;
|
|
@@ -1758,8 +1831,8 @@ export const soundtrackSchema = soundtrackSoundtrackSchema;
|
|
|
1758
1831
|
*
|
|
1759
1832
|
*/
|
|
1760
1833
|
export const svgpropertiesSvgGradientStopSchema = z.object({
|
|
1761
|
-
|
|
1762
|
-
|
|
1834
|
+
offset: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1)),
|
|
1835
|
+
color: z.string().regex(/^#[A-Fa-f0-9]{6}$/),
|
|
1763
1836
|
});
|
|
1764
1837
|
|
|
1765
1838
|
export const svgGradientStopSchema = svgpropertiesSvgGradientStopSchema;
|
|
@@ -1770,13 +1843,14 @@ export const svgGradientStopSchema = svgpropertiesSvgGradientStopSchema;
|
|
|
1770
1843
|
*
|
|
1771
1844
|
*/
|
|
1772
1845
|
export const svgpropertiesSvgLinearGradientFillSchema = z.object({
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1846
|
+
type: z.enum(["linear"]),
|
|
1847
|
+
angle: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(360))).default(0),
|
|
1848
|
+
stops: z.array(svgpropertiesSvgGradientStopSchema).min(2),
|
|
1849
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(1),
|
|
1777
1850
|
});
|
|
1778
1851
|
|
|
1779
|
-
export const svgLinearGradientFillSchema =
|
|
1852
|
+
export const svgLinearGradientFillSchema =
|
|
1853
|
+
svgpropertiesSvgLinearGradientFillSchema;
|
|
1780
1854
|
|
|
1781
1855
|
/**
|
|
1782
1856
|
* A radial gradient fill that transitions colors radiating outward from a center point.
|
|
@@ -1784,23 +1858,24 @@ export const svgLinearGradientFillSchema = svgpropertiesSvgLinearGradientFillSch
|
|
|
1784
1858
|
*
|
|
1785
1859
|
*/
|
|
1786
1860
|
export const svgpropertiesSvgRadialGradientFillSchema = z.object({
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1861
|
+
type: z.enum(["radial"]),
|
|
1862
|
+
stops: z.array(svgpropertiesSvgGradientStopSchema).min(2),
|
|
1863
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(1),
|
|
1790
1864
|
});
|
|
1791
1865
|
|
|
1792
|
-
export const svgRadialGradientFillSchema =
|
|
1866
|
+
export const svgRadialGradientFillSchema =
|
|
1867
|
+
svgpropertiesSvgRadialGradientFillSchema;
|
|
1793
1868
|
|
|
1794
1869
|
/**
|
|
1795
1870
|
* Drop shadow properties for SVG shapes. Creates a shadow effect behind the shape.
|
|
1796
1871
|
*
|
|
1797
1872
|
*/
|
|
1798
1873
|
export const svgpropertiesSvgShadowSchema = z.object({
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1874
|
+
offsetX: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())).default(0),
|
|
1875
|
+
offsetY: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())).default(0),
|
|
1876
|
+
blur: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))).default(0),
|
|
1877
|
+
color: z.optional(z.string().regex(/^#[A-Fa-f0-9]{6}$/)).default("#000000"),
|
|
1878
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(0.5),
|
|
1804
1879
|
});
|
|
1805
1880
|
|
|
1806
1881
|
export const svgShadowSchema = svgpropertiesSvgShadowSchema;
|
|
@@ -1809,9 +1884,12 @@ export const svgShadowSchema = svgpropertiesSvgShadowSchema;
|
|
|
1809
1884
|
* A solid color fill for SVG shapes.
|
|
1810
1885
|
*/
|
|
1811
1886
|
export const svgpropertiesSvgSolidFillSchema = z.object({
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1887
|
+
type: z.enum(["solid"]),
|
|
1888
|
+
color: z
|
|
1889
|
+
.string()
|
|
1890
|
+
.regex(/^#[A-Fa-f0-9]{6}$/)
|
|
1891
|
+
.default("#000000"),
|
|
1892
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(1),
|
|
1815
1893
|
});
|
|
1816
1894
|
|
|
1817
1895
|
export const svgSolidFillSchema = svgpropertiesSvgSolidFillSchema;
|
|
@@ -1835,21 +1913,13 @@ export const svgFillSchema = svgpropertiesSvgFillSchema;
|
|
|
1835
1913
|
*
|
|
1836
1914
|
*/
|
|
1837
1915
|
export const svgpropertiesSvgStrokeSchema = z.object({
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
])),
|
|
1846
|
-
lineJoin: z.optional(z.enum([
|
|
1847
|
-
'miter',
|
|
1848
|
-
'round',
|
|
1849
|
-
'bevel'
|
|
1850
|
-
])),
|
|
1851
|
-
dashArray: z.optional(z.array(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0)))),
|
|
1852
|
-
dashOffset: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())).default(0)
|
|
1916
|
+
color: z.optional(z.string().regex(/^#[A-Fa-f0-9]{6}$/)).default("#000000"),
|
|
1917
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(100))).default(1),
|
|
1918
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(1),
|
|
1919
|
+
lineCap: z.optional(z.enum(["butt", "round", "square"])),
|
|
1920
|
+
lineJoin: z.optional(z.enum(["miter", "round", "bevel"])),
|
|
1921
|
+
dashArray: z.optional(z.array(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0)))),
|
|
1922
|
+
dashOffset: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())).default(0),
|
|
1853
1923
|
});
|
|
1854
1924
|
|
|
1855
1925
|
export const svgStrokeSchema = svgpropertiesSvgStrokeSchema;
|
|
@@ -1859,12 +1929,12 @@ export const svgStrokeSchema = svgpropertiesSvgStrokeSchema;
|
|
|
1859
1929
|
*
|
|
1860
1930
|
*/
|
|
1861
1931
|
export const svgpropertiesSvgTransformSchema = z.object({
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1932
|
+
x: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())).default(0),
|
|
1933
|
+
y: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())).default(0),
|
|
1934
|
+
rotation: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(-360).lte(360))).default(0),
|
|
1935
|
+
scale: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0.01).lte(100))).default(1),
|
|
1936
|
+
originX: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(0.5),
|
|
1937
|
+
originY: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))).default(0.5),
|
|
1868
1938
|
});
|
|
1869
1939
|
|
|
1870
1940
|
export const svgTransformSchema = svgpropertiesSvgTransformSchema;
|
|
@@ -1875,11 +1945,11 @@ export const svgTransformSchema = svgpropertiesSvgTransformSchema;
|
|
|
1875
1945
|
*
|
|
1876
1946
|
*/
|
|
1877
1947
|
export const svgshapesSvgArrowShapeSchema = z.object({
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1948
|
+
type: z.enum(["arrow"]),
|
|
1949
|
+
length: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(4096)),
|
|
1950
|
+
headWidth: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(1000)),
|
|
1951
|
+
headLength: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(1000)),
|
|
1952
|
+
shaftWidth: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(1000)),
|
|
1883
1953
|
});
|
|
1884
1954
|
|
|
1885
1955
|
export const svgArrowShapeSchema = svgshapesSvgArrowShapeSchema;
|
|
@@ -1890,8 +1960,8 @@ export const svgArrowShapeSchema = svgshapesSvgArrowShapeSchema;
|
|
|
1890
1960
|
*
|
|
1891
1961
|
*/
|
|
1892
1962
|
export const svgshapesSvgCircleShapeSchema = z.object({
|
|
1893
|
-
|
|
1894
|
-
|
|
1963
|
+
type: z.enum(["circle"]),
|
|
1964
|
+
radius: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(2048)),
|
|
1895
1965
|
});
|
|
1896
1966
|
|
|
1897
1967
|
export const svgCircleShapeSchema = svgshapesSvgCircleShapeSchema;
|
|
@@ -1902,10 +1972,10 @@ export const svgCircleShapeSchema = svgshapesSvgCircleShapeSchema;
|
|
|
1902
1972
|
*
|
|
1903
1973
|
*/
|
|
1904
1974
|
export const svgshapesSvgCrossShapeSchema = z.object({
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1975
|
+
type: z.enum(["cross"]),
|
|
1976
|
+
width: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(4096)),
|
|
1977
|
+
height: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(4096)),
|
|
1978
|
+
thickness: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(500)),
|
|
1909
1979
|
});
|
|
1910
1980
|
|
|
1911
1981
|
export const svgCrossShapeSchema = svgshapesSvgCrossShapeSchema;
|
|
@@ -1916,9 +1986,9 @@ export const svgCrossShapeSchema = svgshapesSvgCrossShapeSchema;
|
|
|
1916
1986
|
*
|
|
1917
1987
|
*/
|
|
1918
1988
|
export const svgshapesSvgEllipseShapeSchema = z.object({
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1989
|
+
type: z.enum(["ellipse"]),
|
|
1990
|
+
radiusX: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(2048)),
|
|
1991
|
+
radiusY: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(2048)),
|
|
1922
1992
|
});
|
|
1923
1993
|
|
|
1924
1994
|
export const svgEllipseShapeSchema = svgshapesSvgEllipseShapeSchema;
|
|
@@ -1929,8 +1999,8 @@ export const svgEllipseShapeSchema = svgshapesSvgEllipseShapeSchema;
|
|
|
1929
1999
|
*
|
|
1930
2000
|
*/
|
|
1931
2001
|
export const svgshapesSvgHeartShapeSchema = z.object({
|
|
1932
|
-
|
|
1933
|
-
|
|
2002
|
+
type: z.enum(["heart"]),
|
|
2003
|
+
size: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(4096)),
|
|
1934
2004
|
});
|
|
1935
2005
|
|
|
1936
2006
|
export const svgHeartShapeSchema = svgshapesSvgHeartShapeSchema;
|
|
@@ -1941,9 +2011,9 @@ export const svgHeartShapeSchema = svgshapesSvgHeartShapeSchema;
|
|
|
1941
2011
|
*
|
|
1942
2012
|
*/
|
|
1943
2013
|
export const svgshapesSvgLineShapeSchema = z.object({
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
2014
|
+
type: z.enum(["line"]),
|
|
2015
|
+
length: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(4096)),
|
|
2016
|
+
thickness: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(500)),
|
|
1947
2017
|
});
|
|
1948
2018
|
|
|
1949
2019
|
export const svgLineShapeSchema = svgshapesSvgLineShapeSchema;
|
|
@@ -1966,8 +2036,8 @@ export const svgLineShapeSchema = svgshapesSvgLineShapeSchema;
|
|
|
1966
2036
|
*
|
|
1967
2037
|
*/
|
|
1968
2038
|
export const svgshapesSvgPathShapeSchema = z.object({
|
|
1969
|
-
|
|
1970
|
-
|
|
2039
|
+
type: z.enum(["path"]),
|
|
2040
|
+
d: z.string().min(1).max(100000),
|
|
1971
2041
|
});
|
|
1972
2042
|
|
|
1973
2043
|
export const svgPathShapeSchema = svgshapesSvgPathShapeSchema;
|
|
@@ -1979,9 +2049,9 @@ export const svgPathShapeSchema = svgshapesSvgPathShapeSchema;
|
|
|
1979
2049
|
*
|
|
1980
2050
|
*/
|
|
1981
2051
|
export const svgshapesSvgPolygonShapeSchema = z.object({
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
2052
|
+
type: z.enum(["polygon"]),
|
|
2053
|
+
sides: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(3).lte(100)),
|
|
2054
|
+
radius: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(2048)),
|
|
1985
2055
|
});
|
|
1986
2056
|
|
|
1987
2057
|
export const svgPolygonShapeSchema = svgshapesSvgPolygonShapeSchema;
|
|
@@ -1992,10 +2062,10 @@ export const svgPolygonShapeSchema = svgshapesSvgPolygonShapeSchema;
|
|
|
1992
2062
|
*
|
|
1993
2063
|
*/
|
|
1994
2064
|
export const svgshapesSvgRectangleShapeSchema = z.object({
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
2065
|
+
type: z.enum(["rectangle"]),
|
|
2066
|
+
width: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(4096)),
|
|
2067
|
+
height: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(4096)),
|
|
2068
|
+
cornerRadius: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(2048))).default(0),
|
|
1999
2069
|
});
|
|
2000
2070
|
|
|
2001
2071
|
export const svgRectangleShapeSchema = svgshapesSvgRectangleShapeSchema;
|
|
@@ -2006,9 +2076,9 @@ export const svgRectangleShapeSchema = svgshapesSvgRectangleShapeSchema;
|
|
|
2006
2076
|
*
|
|
2007
2077
|
*/
|
|
2008
2078
|
export const svgshapesSvgRingShapeSchema = z.object({
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
|
|
2079
|
+
type: z.enum(["ring"]),
|
|
2080
|
+
outerRadius: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(2048)),
|
|
2081
|
+
innerRadius: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(2048)),
|
|
2012
2082
|
});
|
|
2013
2083
|
|
|
2014
2084
|
export const svgRingShapeSchema = svgshapesSvgRingShapeSchema;
|
|
@@ -2020,10 +2090,10 @@ export const svgRingShapeSchema = svgshapesSvgRingShapeSchema;
|
|
|
2020
2090
|
*
|
|
2021
2091
|
*/
|
|
2022
2092
|
export const svgshapesSvgStarShapeSchema = z.object({
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2093
|
+
type: z.enum(["star"]),
|
|
2094
|
+
points: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(3).lte(100)),
|
|
2095
|
+
outerRadius: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(2048)),
|
|
2096
|
+
innerRadius: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(2048)),
|
|
2027
2097
|
});
|
|
2028
2098
|
|
|
2029
2099
|
export const svgStarShapeSchema = svgshapesSvgStarShapeSchema;
|
|
@@ -2144,8 +2214,8 @@ export const svgAssetSchema = svgassetSvgAssetSchema;
|
|
|
2144
2214
|
* Configure the id and optional merge fields to render a template by id.
|
|
2145
2215
|
*/
|
|
2146
2216
|
export const templaterenderTemplateRenderSchema = z.object({
|
|
2147
|
-
|
|
2148
|
-
|
|
2217
|
+
id: z.string(),
|
|
2218
|
+
merge: z.optional(z.array(mergefieldMergeFieldSchema)),
|
|
2149
2219
|
});
|
|
2150
2220
|
|
|
2151
2221
|
export const templateRenderSchema = templaterenderTemplateRenderSchema;
|
|
@@ -2154,16 +2224,8 @@ export const templateRenderSchema = templaterenderTemplateRenderSchema;
|
|
|
2154
2224
|
* Horizontal and vertical alignment properties for text.
|
|
2155
2225
|
*/
|
|
2156
2226
|
export const textpropertiesTextAlignmentSchema = z.object({
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
'center',
|
|
2160
|
-
'right'
|
|
2161
|
-
])),
|
|
2162
|
-
vertical: z.optional(z.enum([
|
|
2163
|
-
'top',
|
|
2164
|
-
'center',
|
|
2165
|
-
'bottom'
|
|
2166
|
-
]))
|
|
2227
|
+
horizontal: z.optional(z.enum(["left", "center", "right"])),
|
|
2228
|
+
vertical: z.optional(z.enum(["top", "center", "bottom"])),
|
|
2167
2229
|
});
|
|
2168
2230
|
|
|
2169
2231
|
export const textAlignmentSchema = textpropertiesTextAlignmentSchema;
|
|
@@ -2172,18 +2234,18 @@ export const textAlignmentSchema = textpropertiesTextAlignmentSchema;
|
|
|
2172
2234
|
* Animation properties for text entrance effects.
|
|
2173
2235
|
*/
|
|
2174
2236
|
export const textpropertiesTextAnimationSchema = z.object({
|
|
2175
|
-
|
|
2176
|
-
|
|
2237
|
+
preset: z.enum(["typewriter"]),
|
|
2238
|
+
duration: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0.1).lte(30))),
|
|
2177
2239
|
});
|
|
2178
2240
|
|
|
2179
2241
|
/**
|
|
2180
2242
|
* Displays a background box behind the text.
|
|
2181
2243
|
*/
|
|
2182
2244
|
export const textpropertiesTextBackgroundSchema = z.object({
|
|
2183
|
-
|
|
2184
|
-
|
|
2185
|
-
|
|
2186
|
-
|
|
2245
|
+
color: z.optional(z.string().regex(/^#[A-Fa-f0-9]{6}$/)),
|
|
2246
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1))),
|
|
2247
|
+
padding: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(100))),
|
|
2248
|
+
borderRadius: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0))),
|
|
2187
2249
|
});
|
|
2188
2250
|
|
|
2189
2251
|
export const textBackgroundSchema = textpropertiesTextBackgroundSchema;
|
|
@@ -2192,12 +2254,12 @@ export const textBackgroundSchema = textpropertiesTextBackgroundSchema;
|
|
|
2192
2254
|
* Font properties for text.
|
|
2193
2255
|
*/
|
|
2194
2256
|
export const textpropertiesTextFontSchema = z.object({
|
|
2195
|
-
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
|
|
2199
|
-
|
|
2200
|
-
|
|
2257
|
+
family: z.optional(z.string()),
|
|
2258
|
+
color: z.optional(z.string()),
|
|
2259
|
+
opacity: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
2260
|
+
size: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
2261
|
+
weight: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
2262
|
+
lineHeight: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
2201
2263
|
});
|
|
2202
2264
|
|
|
2203
2265
|
export const textFontSchema = textpropertiesTextFontSchema;
|
|
@@ -2206,8 +2268,8 @@ export const textFontSchema = textpropertiesTextFontSchema;
|
|
|
2206
2268
|
* Text stroke (outline) properties.
|
|
2207
2269
|
*/
|
|
2208
2270
|
export const textpropertiesTextStrokeSchema = z.object({
|
|
2209
|
-
|
|
2210
|
-
|
|
2271
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(10))),
|
|
2272
|
+
color: z.optional(z.string().regex(/^#[A-Fa-f0-9]{6}$/)),
|
|
2211
2273
|
});
|
|
2212
2274
|
|
|
2213
2275
|
/**
|
|
@@ -2216,16 +2278,16 @@ export const textpropertiesTextStrokeSchema = z.object({
|
|
|
2216
2278
|
*
|
|
2217
2279
|
*/
|
|
2218
2280
|
export const textassetTextAssetSchema = z.object({
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
|
|
2222
|
-
|
|
2223
|
-
|
|
2224
|
-
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2228
|
-
|
|
2281
|
+
type: z.enum(["text"]),
|
|
2282
|
+
text: z.string(),
|
|
2283
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
2284
|
+
height: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
2285
|
+
font: z.optional(textpropertiesTextFontSchema),
|
|
2286
|
+
background: z.optional(textpropertiesTextBackgroundSchema),
|
|
2287
|
+
alignment: z.optional(textpropertiesTextAlignmentSchema),
|
|
2288
|
+
stroke: z.optional(textpropertiesTextStrokeSchema),
|
|
2289
|
+
animation: z.optional(textpropertiesTextAnimationSchema),
|
|
2290
|
+
ellipsis: z.optional(z.string()),
|
|
2229
2291
|
});
|
|
2230
2292
|
|
|
2231
2293
|
export const textAssetSchema = textassetTextAssetSchema;
|
|
@@ -2234,11 +2296,11 @@ export const textAssetSchema = textassetTextAssetSchema;
|
|
|
2234
2296
|
* The TextToImageAsset lets you create a dynamic image from a text prompt.
|
|
2235
2297
|
*/
|
|
2236
2298
|
export const texttoimageassetTextToImageAssetSchema = z.object({
|
|
2237
|
-
|
|
2238
|
-
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2299
|
+
type: z.enum(["text-to-image"]),
|
|
2300
|
+
prompt: z.string(),
|
|
2301
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
2302
|
+
height: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int())),
|
|
2303
|
+
crop: z.optional(cropCropSchema),
|
|
2242
2304
|
});
|
|
2243
2305
|
|
|
2244
2306
|
export const textToImageAssetSchema = texttoimageassetTextToImageAssetSchema;
|
|
@@ -2247,8 +2309,8 @@ export const textToImageAssetSchema = texttoimageassetTextToImageAssetSchema;
|
|
|
2247
2309
|
* Generate a thumbnail image for the video or image at a specific point from the timeline.
|
|
2248
2310
|
*/
|
|
2249
2311
|
export const thumbnailThumbnailSchema = z.object({
|
|
2250
|
-
|
|
2251
|
-
|
|
2312
|
+
capture: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number()),
|
|
2313
|
+
scale: z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1)),
|
|
2252
2314
|
});
|
|
2253
2315
|
|
|
2254
2316
|
export const thumbnailSchema = thumbnailThumbnailSchema;
|
|
@@ -2257,64 +2319,35 @@ export const thumbnailSchema = thumbnailThumbnailSchema;
|
|
|
2257
2319
|
* The output format, render range and type of media to generate.
|
|
2258
2320
|
*/
|
|
2259
2321
|
export const outputOutputSchema = z.object({
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
|
|
2322
|
+
format: z.enum(["mp4", "gif", "mp3", "jpg", "png", "bmp"]),
|
|
2323
|
+
resolution: z.optional(
|
|
2324
|
+
z.enum(["preview", "mobile", "sd", "hd", "1080", "4k"]),
|
|
2325
|
+
),
|
|
2326
|
+
aspectRatio: z.optional(z.enum(["16:9", "9:16", "1:1", "4:5", "4:3"])),
|
|
2327
|
+
size: z.optional(sizeSizeSchema),
|
|
2328
|
+
fps: z.optional(
|
|
2329
|
+
z.union([
|
|
2330
|
+
z.literal(12),
|
|
2331
|
+
z.literal(15),
|
|
2332
|
+
z.literal(23.976),
|
|
2333
|
+
z.literal(24),
|
|
2334
|
+
z.literal(25),
|
|
2335
|
+
z.literal(29.97),
|
|
2336
|
+
z.literal(30),
|
|
2337
|
+
z.literal(48),
|
|
2338
|
+
z.literal(50),
|
|
2339
|
+
z.literal(59.94),
|
|
2340
|
+
z.literal(60),
|
|
2267
2341
|
]),
|
|
2268
|
-
|
|
2269
|
-
|
|
2270
|
-
|
|
2271
|
-
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
'16:9',
|
|
2278
|
-
'9:16',
|
|
2279
|
-
'1:1',
|
|
2280
|
-
'4:5',
|
|
2281
|
-
'4:3'
|
|
2282
|
-
])),
|
|
2283
|
-
size: z.optional(sizeSizeSchema),
|
|
2284
|
-
fps: z.optional(z.union([
|
|
2285
|
-
z.literal(12),
|
|
2286
|
-
z.literal(15),
|
|
2287
|
-
z.literal(23.976),
|
|
2288
|
-
z.literal(24),
|
|
2289
|
-
z.literal(25),
|
|
2290
|
-
z.literal(29.97),
|
|
2291
|
-
z.literal(30),
|
|
2292
|
-
z.literal(48),
|
|
2293
|
-
z.literal(50),
|
|
2294
|
-
z.literal(59.94),
|
|
2295
|
-
z.literal(60)
|
|
2296
|
-
])),
|
|
2297
|
-
scaleTo: z.optional(z.enum([
|
|
2298
|
-
'preview',
|
|
2299
|
-
'mobile',
|
|
2300
|
-
'sd',
|
|
2301
|
-
'hd',
|
|
2302
|
-
'1080',
|
|
2303
|
-
'4k'
|
|
2304
|
-
])),
|
|
2305
|
-
quality: z.optional(z.enum([
|
|
2306
|
-
'verylow',
|
|
2307
|
-
'low',
|
|
2308
|
-
'medium',
|
|
2309
|
-
'high',
|
|
2310
|
-
'veryhigh'
|
|
2311
|
-
])),
|
|
2312
|
-
repeat: z.optional(z.boolean()),
|
|
2313
|
-
mute: z.optional(z.boolean()),
|
|
2314
|
-
range: z.optional(rangeRangeSchema),
|
|
2315
|
-
poster: z.optional(posterPosterSchema),
|
|
2316
|
-
thumbnail: z.optional(thumbnailThumbnailSchema),
|
|
2317
|
-
destinations: z.optional(z.array(destinationsDestinationsSchema))
|
|
2342
|
+
),
|
|
2343
|
+
scaleTo: z.optional(z.enum(["preview", "mobile", "sd", "hd", "1080", "4k"])),
|
|
2344
|
+
quality: z.optional(z.enum(["verylow", "low", "medium", "high", "veryhigh"])),
|
|
2345
|
+
repeat: z.optional(z.boolean()),
|
|
2346
|
+
mute: z.optional(z.boolean()),
|
|
2347
|
+
range: z.optional(rangeRangeSchema),
|
|
2348
|
+
poster: z.optional(posterPosterSchema),
|
|
2349
|
+
thumbnail: z.optional(thumbnailThumbnailSchema),
|
|
2350
|
+
destinations: z.optional(z.array(destinationsDestinationsSchema)),
|
|
2318
2351
|
});
|
|
2319
2352
|
|
|
2320
2353
|
export const outputSchema = outputOutputSchema;
|
|
@@ -2323,134 +2356,138 @@ export const outputSchema = outputOutputSchema;
|
|
|
2323
2356
|
* In and out transitions for a clip - i.e. fade in and fade out
|
|
2324
2357
|
*/
|
|
2325
2358
|
export const transitionTransitionSchema = z.object({
|
|
2326
|
-
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
|
|
2331
|
-
|
|
2332
|
-
|
|
2333
|
-
|
|
2334
|
-
|
|
2335
|
-
|
|
2336
|
-
|
|
2337
|
-
|
|
2338
|
-
|
|
2339
|
-
|
|
2340
|
-
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
|
|
2344
|
-
|
|
2345
|
-
|
|
2346
|
-
|
|
2347
|
-
|
|
2348
|
-
|
|
2349
|
-
|
|
2350
|
-
|
|
2351
|
-
|
|
2352
|
-
|
|
2353
|
-
|
|
2354
|
-
|
|
2355
|
-
|
|
2356
|
-
|
|
2357
|
-
|
|
2358
|
-
|
|
2359
|
-
|
|
2360
|
-
|
|
2361
|
-
|
|
2362
|
-
|
|
2363
|
-
|
|
2364
|
-
|
|
2365
|
-
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
2371
|
-
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
|
|
2375
|
-
|
|
2376
|
-
|
|
2377
|
-
|
|
2378
|
-
|
|
2379
|
-
|
|
2380
|
-
|
|
2381
|
-
|
|
2382
|
-
|
|
2383
|
-
|
|
2384
|
-
|
|
2385
|
-
|
|
2386
|
-
|
|
2387
|
-
|
|
2388
|
-
|
|
2389
|
-
|
|
2390
|
-
|
|
2391
|
-
|
|
2392
|
-
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
|
|
2398
|
-
|
|
2399
|
-
|
|
2400
|
-
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2420
|
-
|
|
2421
|
-
|
|
2422
|
-
|
|
2423
|
-
|
|
2424
|
-
|
|
2425
|
-
|
|
2426
|
-
|
|
2427
|
-
|
|
2428
|
-
|
|
2429
|
-
|
|
2430
|
-
|
|
2431
|
-
|
|
2432
|
-
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
|
|
2451
|
-
|
|
2452
|
-
|
|
2453
|
-
|
|
2359
|
+
in: z.optional(
|
|
2360
|
+
z.enum([
|
|
2361
|
+
"none",
|
|
2362
|
+
"fade",
|
|
2363
|
+
"fadeSlow",
|
|
2364
|
+
"fadeFast",
|
|
2365
|
+
"reveal",
|
|
2366
|
+
"revealSlow",
|
|
2367
|
+
"revealFast",
|
|
2368
|
+
"wipeLeft",
|
|
2369
|
+
"wipeLeftSlow",
|
|
2370
|
+
"wipeLeftFast",
|
|
2371
|
+
"wipeRight",
|
|
2372
|
+
"wipeRightSlow",
|
|
2373
|
+
"wipeRightFast",
|
|
2374
|
+
"slideLeft",
|
|
2375
|
+
"slideLeftSlow",
|
|
2376
|
+
"slideLeftFast",
|
|
2377
|
+
"slideRight",
|
|
2378
|
+
"slideRightSlow",
|
|
2379
|
+
"slideRightFast",
|
|
2380
|
+
"slideUp",
|
|
2381
|
+
"slideUpSlow",
|
|
2382
|
+
"slideUpFast",
|
|
2383
|
+
"slideDown",
|
|
2384
|
+
"slideDownSlow",
|
|
2385
|
+
"slideDownFast",
|
|
2386
|
+
"carouselLeft",
|
|
2387
|
+
"carouselLeftSlow",
|
|
2388
|
+
"carouselLeftFast",
|
|
2389
|
+
"carouselRight",
|
|
2390
|
+
"carouselRightSlow",
|
|
2391
|
+
"carouselRightFast",
|
|
2392
|
+
"carouselUp",
|
|
2393
|
+
"carouselUpSlow",
|
|
2394
|
+
"carouselUpFast",
|
|
2395
|
+
"carouselDown",
|
|
2396
|
+
"carouselDownSlow",
|
|
2397
|
+
"carouselDownFast",
|
|
2398
|
+
"shuffleTopRight",
|
|
2399
|
+
"shuffleTopRightSlow",
|
|
2400
|
+
"shuffleTopRightFast",
|
|
2401
|
+
"shuffleRightTop",
|
|
2402
|
+
"shuffleRightTopSlow",
|
|
2403
|
+
"shuffleRightTopFast",
|
|
2404
|
+
"shuffleRightBottom",
|
|
2405
|
+
"shuffleRightBottomSlow",
|
|
2406
|
+
"shuffleRightBottomFast",
|
|
2407
|
+
"shuffleBottomRight",
|
|
2408
|
+
"shuffleBottomRightSlow",
|
|
2409
|
+
"shuffleBottomRightFast",
|
|
2410
|
+
"shuffleBottomLeft",
|
|
2411
|
+
"shuffleBottomLeftSlow",
|
|
2412
|
+
"shuffleBottomLeftFast",
|
|
2413
|
+
"shuffleLeftBottom",
|
|
2414
|
+
"shuffleLeftBottomSlow",
|
|
2415
|
+
"shuffleLeftBottomFast",
|
|
2416
|
+
"shuffleLeftTop",
|
|
2417
|
+
"shuffleLeftTopSlow",
|
|
2418
|
+
"shuffleLeftTopFast",
|
|
2419
|
+
"shuffleTopLeft",
|
|
2420
|
+
"shuffleTopLeftSlow",
|
|
2421
|
+
"shuffleTopLeftFast",
|
|
2422
|
+
"zoom",
|
|
2423
|
+
]),
|
|
2424
|
+
),
|
|
2425
|
+
out: z.optional(
|
|
2426
|
+
z.enum([
|
|
2427
|
+
"none",
|
|
2428
|
+
"fade",
|
|
2429
|
+
"fadeSlow",
|
|
2430
|
+
"fadeFast",
|
|
2431
|
+
"reveal",
|
|
2432
|
+
"revealSlow",
|
|
2433
|
+
"revealFast",
|
|
2434
|
+
"wipeLeft",
|
|
2435
|
+
"wipeLeftSlow",
|
|
2436
|
+
"wipeLeftFast",
|
|
2437
|
+
"wipeRight",
|
|
2438
|
+
"wipeRightSlow",
|
|
2439
|
+
"wipeRightFast",
|
|
2440
|
+
"slideLeft",
|
|
2441
|
+
"slideLeftSlow",
|
|
2442
|
+
"slideLeftFast",
|
|
2443
|
+
"slideRight",
|
|
2444
|
+
"slideRightSlow",
|
|
2445
|
+
"slideRightFast",
|
|
2446
|
+
"slideUp",
|
|
2447
|
+
"slideUpSlow",
|
|
2448
|
+
"slideUpFast",
|
|
2449
|
+
"slideDown",
|
|
2450
|
+
"slideDownSlow",
|
|
2451
|
+
"slideDownFast",
|
|
2452
|
+
"carouselLeft",
|
|
2453
|
+
"carouselLeftSlow",
|
|
2454
|
+
"carouselLeftFast",
|
|
2455
|
+
"carouselRight",
|
|
2456
|
+
"carouselRightSlow",
|
|
2457
|
+
"carouselRightFast",
|
|
2458
|
+
"carouselUp",
|
|
2459
|
+
"carouselUpSlow",
|
|
2460
|
+
"carouselUpFast",
|
|
2461
|
+
"carouselDown",
|
|
2462
|
+
"carouselDownSlow",
|
|
2463
|
+
"carouselDownFast",
|
|
2464
|
+
"shuffleTopRight",
|
|
2465
|
+
"shuffleTopRightSlow",
|
|
2466
|
+
"shuffleTopRightFast",
|
|
2467
|
+
"shuffleRightTop",
|
|
2468
|
+
"shuffleRightTopSlow",
|
|
2469
|
+
"shuffleRightTopFast",
|
|
2470
|
+
"shuffleRightBottom",
|
|
2471
|
+
"shuffleRightBottomSlow",
|
|
2472
|
+
"shuffleRightBottomFast",
|
|
2473
|
+
"shuffleBottomRight",
|
|
2474
|
+
"shuffleBottomRightSlow",
|
|
2475
|
+
"shuffleBottomRightFast",
|
|
2476
|
+
"shuffleBottomLeft",
|
|
2477
|
+
"shuffleBottomLeftSlow",
|
|
2478
|
+
"shuffleBottomLeftFast",
|
|
2479
|
+
"shuffleLeftBottom",
|
|
2480
|
+
"shuffleLeftBottomSlow",
|
|
2481
|
+
"shuffleLeftBottomFast",
|
|
2482
|
+
"shuffleLeftTop",
|
|
2483
|
+
"shuffleLeftTopSlow",
|
|
2484
|
+
"shuffleLeftTopFast",
|
|
2485
|
+
"shuffleTopLeft",
|
|
2486
|
+
"shuffleTopLeftSlow",
|
|
2487
|
+
"shuffleTopLeftFast",
|
|
2488
|
+
"zoom",
|
|
2489
|
+
]),
|
|
2490
|
+
),
|
|
2454
2491
|
});
|
|
2455
2492
|
|
|
2456
2493
|
export const transitionSchema = transitionTransitionSchema;
|
|
@@ -2466,45 +2503,43 @@ export const transitionSchema = transitionTransitionSchema;
|
|
|
2466
2503
|
* </ul>
|
|
2467
2504
|
*/
|
|
2468
2505
|
export const tweenTweenSchema = z.object({
|
|
2469
|
-
|
|
2470
|
-
|
|
2471
|
-
|
|
2472
|
-
|
|
2473
|
-
|
|
2474
|
-
|
|
2475
|
-
|
|
2476
|
-
|
|
2477
|
-
|
|
2478
|
-
|
|
2479
|
-
|
|
2480
|
-
|
|
2481
|
-
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
|
|
2485
|
-
|
|
2486
|
-
|
|
2487
|
-
|
|
2488
|
-
|
|
2489
|
-
|
|
2490
|
-
|
|
2491
|
-
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
'easeInOutBack'
|
|
2507
|
-
]))
|
|
2506
|
+
from: z.optional(z.unknown()),
|
|
2507
|
+
to: z.optional(z.unknown()),
|
|
2508
|
+
start: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
2509
|
+
length: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
2510
|
+
interpolation: z.optional(z.enum(["linear", "bezier", "constant"])),
|
|
2511
|
+
easing: z.optional(
|
|
2512
|
+
z.enum([
|
|
2513
|
+
"ease",
|
|
2514
|
+
"easeIn",
|
|
2515
|
+
"easeOut",
|
|
2516
|
+
"easeInOut",
|
|
2517
|
+
"easeInQuad",
|
|
2518
|
+
"easeInCubic",
|
|
2519
|
+
"easeInQuart",
|
|
2520
|
+
"easeInQuint",
|
|
2521
|
+
"easeInSine",
|
|
2522
|
+
"easeInExpo",
|
|
2523
|
+
"easeInCirc",
|
|
2524
|
+
"easeInBack",
|
|
2525
|
+
"easeOutQuad",
|
|
2526
|
+
"easeOutCubic",
|
|
2527
|
+
"easeOutQuart",
|
|
2528
|
+
"easeOutQuint",
|
|
2529
|
+
"easeOutSine",
|
|
2530
|
+
"easeOutExpo",
|
|
2531
|
+
"easeOutCirc",
|
|
2532
|
+
"easeOutBack",
|
|
2533
|
+
"easeInOutQuad",
|
|
2534
|
+
"easeInOutCubic",
|
|
2535
|
+
"easeInOutQuart",
|
|
2536
|
+
"easeInOutQuint",
|
|
2537
|
+
"easeInOutSine",
|
|
2538
|
+
"easeInOutExpo",
|
|
2539
|
+
"easeInOutCirc",
|
|
2540
|
+
"easeInOutBack",
|
|
2541
|
+
]),
|
|
2542
|
+
),
|
|
2508
2543
|
});
|
|
2509
2544
|
|
|
2510
2545
|
export const tweenSchema = tweenTweenSchema;
|
|
@@ -2513,20 +2548,14 @@ export const tweenSchema = tweenTweenSchema;
|
|
|
2513
2548
|
* The AudioAsset is used to add sound effects and audio at specific intervals on the timeline. The src must be a publicly accessible URL to an audio resource such as an mp3 file.
|
|
2514
2549
|
*/
|
|
2515
2550
|
export const audioassetAudioAssetSchema = z.object({
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
|
|
2524
|
-
effect: z.optional(z.enum([
|
|
2525
|
-
'none',
|
|
2526
|
-
'fadeIn',
|
|
2527
|
-
'fadeOut',
|
|
2528
|
-
'fadeInFadeOut'
|
|
2529
|
-
]))
|
|
2551
|
+
type: z.enum(["audio"]),
|
|
2552
|
+
src: z.string(),
|
|
2553
|
+
trim: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
2554
|
+
volume: z.optional(
|
|
2555
|
+
z.union([z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1)), z.array(tweenTweenSchema)]),
|
|
2556
|
+
),
|
|
2557
|
+
speed: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(10))),
|
|
2558
|
+
effect: z.optional(z.enum(["none", "fadeIn", "fadeOut", "fadeInFadeOut"])),
|
|
2530
2559
|
});
|
|
2531
2560
|
|
|
2532
2561
|
export const audioAssetSchema = audioassetAudioAssetSchema;
|
|
@@ -2535,14 +2564,12 @@ export const audioAssetSchema = audioassetAudioAssetSchema;
|
|
|
2535
2564
|
* Offsets the position of an asset horizontally or vertically by a relative distance.
|
|
2536
2565
|
*/
|
|
2537
2566
|
export const offsetOffsetSchema = z.object({
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
|
|
2541
|
-
|
|
2542
|
-
|
|
2543
|
-
|
|
2544
|
-
z.array(tweenTweenSchema)
|
|
2545
|
-
]))
|
|
2567
|
+
x: z.optional(
|
|
2568
|
+
z.union([z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(-10).lte(10)), z.array(tweenTweenSchema)]),
|
|
2569
|
+
),
|
|
2570
|
+
y: z.optional(
|
|
2571
|
+
z.union([z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(-10).lte(10)), z.array(tweenTweenSchema)]),
|
|
2572
|
+
),
|
|
2546
2573
|
});
|
|
2547
2574
|
|
|
2548
2575
|
export const offsetSchema = offsetOffsetSchema;
|
|
@@ -2551,29 +2578,28 @@ export const offsetSchema = offsetOffsetSchema;
|
|
|
2551
2578
|
* Rotate a clip by the specified angle in degrees. Rotation origin is set based on the clips `position`.
|
|
2552
2579
|
*/
|
|
2553
2580
|
export const rotatetransformationRotateTransformationSchema = z.object({
|
|
2554
|
-
|
|
2555
|
-
|
|
2556
|
-
|
|
2557
|
-
]))
|
|
2581
|
+
angle: z.optional(
|
|
2582
|
+
z.union([z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(-360).lte(360)), z.array(tweenTweenSchema)]),
|
|
2583
|
+
),
|
|
2558
2584
|
});
|
|
2559
2585
|
|
|
2560
|
-
export const rotateTransformationSchema =
|
|
2586
|
+
export const rotateTransformationSchema =
|
|
2587
|
+
rotatetransformationRotateTransformationSchema;
|
|
2561
2588
|
|
|
2562
2589
|
/**
|
|
2563
2590
|
* Skew a clip so its edges are sheared at an angle. Use values between -100 and 100. Values over 3 or under -3 will skew the clip almost flat.
|
|
2564
2591
|
*/
|
|
2565
2592
|
export const skewtransformationSkewTransformationSchema = z.object({
|
|
2566
|
-
|
|
2567
|
-
|
|
2568
|
-
|
|
2569
|
-
|
|
2570
|
-
|
|
2571
|
-
|
|
2572
|
-
z.array(tweenTweenSchema)
|
|
2573
|
-
]))
|
|
2593
|
+
x: z.optional(
|
|
2594
|
+
z.union([z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(-100).lte(100)), z.array(tweenTweenSchema)]),
|
|
2595
|
+
),
|
|
2596
|
+
y: z.optional(
|
|
2597
|
+
z.union([z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(-100).lte(100)), z.array(tweenTweenSchema)]),
|
|
2598
|
+
),
|
|
2574
2599
|
});
|
|
2575
2600
|
|
|
2576
|
-
export const skewTransformationSchema =
|
|
2601
|
+
export const skewTransformationSchema =
|
|
2602
|
+
skewtransformationSkewTransformationSchema;
|
|
2577
2603
|
|
|
2578
2604
|
/**
|
|
2579
2605
|
* **Notice: The TitleAsset is deprecated, use the [TextAsset](#tocs_textasset) instead.**
|
|
@@ -2584,43 +2610,49 @@ export const skewTransformationSchema = skewtransformationSkewTransformationSche
|
|
|
2584
2610
|
* @deprecated
|
|
2585
2611
|
*/
|
|
2586
2612
|
export const titleassetTitleAssetSchema = z.object({
|
|
2587
|
-
|
|
2588
|
-
|
|
2589
|
-
|
|
2590
|
-
|
|
2591
|
-
|
|
2592
|
-
|
|
2593
|
-
|
|
2594
|
-
|
|
2595
|
-
|
|
2596
|
-
|
|
2597
|
-
|
|
2598
|
-
|
|
2599
|
-
|
|
2600
|
-
|
|
2601
|
-
|
|
2602
|
-
|
|
2603
|
-
|
|
2604
|
-
|
|
2605
|
-
|
|
2606
|
-
|
|
2607
|
-
|
|
2608
|
-
|
|
2609
|
-
|
|
2610
|
-
|
|
2611
|
-
|
|
2612
|
-
|
|
2613
|
-
|
|
2614
|
-
|
|
2615
|
-
|
|
2616
|
-
|
|
2617
|
-
|
|
2618
|
-
|
|
2619
|
-
|
|
2620
|
-
|
|
2621
|
-
|
|
2622
|
-
|
|
2623
|
-
|
|
2613
|
+
type: z.enum(["title"]),
|
|
2614
|
+
text: z.string(),
|
|
2615
|
+
style: z.optional(
|
|
2616
|
+
z.enum([
|
|
2617
|
+
"minimal",
|
|
2618
|
+
"blockbuster",
|
|
2619
|
+
"vogue",
|
|
2620
|
+
"sketchy",
|
|
2621
|
+
"skinny",
|
|
2622
|
+
"chunk",
|
|
2623
|
+
"chunkLight",
|
|
2624
|
+
"marker",
|
|
2625
|
+
"future",
|
|
2626
|
+
"subtitle",
|
|
2627
|
+
]),
|
|
2628
|
+
),
|
|
2629
|
+
color: z.optional(z.string()),
|
|
2630
|
+
size: z.optional(
|
|
2631
|
+
z.enum([
|
|
2632
|
+
"xx-small",
|
|
2633
|
+
"x-small",
|
|
2634
|
+
"small",
|
|
2635
|
+
"medium",
|
|
2636
|
+
"large",
|
|
2637
|
+
"x-large",
|
|
2638
|
+
"xx-large",
|
|
2639
|
+
]),
|
|
2640
|
+
),
|
|
2641
|
+
background: z.optional(z.string()),
|
|
2642
|
+
position: z.optional(
|
|
2643
|
+
z.enum([
|
|
2644
|
+
"top",
|
|
2645
|
+
"topRight",
|
|
2646
|
+
"right",
|
|
2647
|
+
"bottomRight",
|
|
2648
|
+
"bottom",
|
|
2649
|
+
"bottomLeft",
|
|
2650
|
+
"left",
|
|
2651
|
+
"topLeft",
|
|
2652
|
+
"center",
|
|
2653
|
+
]),
|
|
2654
|
+
),
|
|
2655
|
+
offset: z.optional(offsetOffsetSchema),
|
|
2624
2656
|
});
|
|
2625
2657
|
|
|
2626
2658
|
export const titleAssetSchema = titleassetTitleAssetSchema;
|
|
@@ -2629,9 +2661,9 @@ export const titleAssetSchema = titleassetTitleAssetSchema;
|
|
|
2629
2661
|
* Apply one or more transformations to a clip. Transformations alter the visual properties of a clip and can be combined to create new shapes and effects.
|
|
2630
2662
|
*/
|
|
2631
2663
|
export const transformationTransformationSchema = z.object({
|
|
2632
|
-
|
|
2633
|
-
|
|
2634
|
-
|
|
2664
|
+
rotate: z.optional(rotatetransformationRotateTransformationSchema),
|
|
2665
|
+
skew: z.optional(skewtransformationSkewTransformationSchema),
|
|
2666
|
+
flip: z.optional(fliptransformationFlipTransformationSchema),
|
|
2635
2667
|
});
|
|
2636
2668
|
|
|
2637
2669
|
export const transformationSchema = transformationTransformationSchema;
|
|
@@ -2640,23 +2672,19 @@ export const transformationSchema = transformationTransformationSchema;
|
|
|
2640
2672
|
* The VideoAsset is used to create video sequences from video files. The src must be a publicly accessible URL to a video resource such as an mp4 file.
|
|
2641
2673
|
*/
|
|
2642
2674
|
export const videoassetVideoAssetSchema = z.object({
|
|
2643
|
-
|
|
2644
|
-
|
|
2645
|
-
|
|
2646
|
-
|
|
2647
|
-
|
|
2648
|
-
|
|
2649
|
-
|
|
2650
|
-
|
|
2651
|
-
|
|
2652
|
-
|
|
2653
|
-
|
|
2654
|
-
|
|
2655
|
-
|
|
2656
|
-
])),
|
|
2657
|
-
speed: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(10))),
|
|
2658
|
-
crop: z.optional(cropCropSchema),
|
|
2659
|
-
chromaKey: z.optional(chromakeyChromaKeySchema)
|
|
2675
|
+
type: z.enum(["video"]),
|
|
2676
|
+
src: z.string(),
|
|
2677
|
+
transcode: z.optional(z.boolean()),
|
|
2678
|
+
trim: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
2679
|
+
volume: z.optional(
|
|
2680
|
+
z.union([z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(1)), z.array(tweenTweenSchema)]),
|
|
2681
|
+
),
|
|
2682
|
+
volumeEffect: z.optional(
|
|
2683
|
+
z.enum(["none", "fadeIn", "fadeOut", "fadeInFadeOut"]),
|
|
2684
|
+
),
|
|
2685
|
+
speed: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(0).lte(10))),
|
|
2686
|
+
crop: z.optional(cropCropSchema),
|
|
2687
|
+
chromaKey: z.optional(chromakeyChromaKeySchema),
|
|
2660
2688
|
});
|
|
2661
2689
|
|
|
2662
2690
|
export const videoAssetSchema = videoassetVideoAssetSchema;
|
|
@@ -2686,77 +2714,72 @@ export const assetSchema = assetAssetSchema;
|
|
|
2686
2714
|
* A clip is a container for a specific type of asset, i.e. a title, image, video, audio or html. You use a Clip to define when an asset will display on the timeline, how long it will play for and transitions, filters and effects to apply to it.
|
|
2687
2715
|
*/
|
|
2688
2716
|
export const clipClipSchema = z.object({
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2717
|
+
asset: assetAssetSchema,
|
|
2718
|
+
start: z.union([
|
|
2719
|
+
z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number()),
|
|
2720
|
+
z.string().regex(/^(auto|alias:\/\/[A-Za-z0-9_-]+)$/),
|
|
2721
|
+
]),
|
|
2722
|
+
length: z.union([
|
|
2723
|
+
z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number()),
|
|
2724
|
+
z.string().regex(/^(auto|end|alias:\/\/[A-Za-z0-9_-]+)$/),
|
|
2725
|
+
]),
|
|
2726
|
+
fit: z.optional(z.enum(["cover", "contain", "crop", "none"])),
|
|
2727
|
+
scale: z.optional(z.union([z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number()), z.array(tweenTweenSchema)])),
|
|
2728
|
+
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(3840))),
|
|
2729
|
+
height: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().gte(1).lte(2160))),
|
|
2730
|
+
position: z.optional(
|
|
2731
|
+
z.enum([
|
|
2732
|
+
"top",
|
|
2733
|
+
"topRight",
|
|
2734
|
+
"right",
|
|
2735
|
+
"bottomRight",
|
|
2736
|
+
"bottom",
|
|
2737
|
+
"bottomLeft",
|
|
2738
|
+
"left",
|
|
2739
|
+
"topLeft",
|
|
2740
|
+
"center",
|
|
2741
|
+
]),
|
|
2742
|
+
),
|
|
2743
|
+
offset: z.optional(offsetOffsetSchema),
|
|
2744
|
+
transition: z.optional(transitionTransitionSchema),
|
|
2745
|
+
effect: z.optional(
|
|
2746
|
+
z.enum([
|
|
2747
|
+
"zoomIn",
|
|
2748
|
+
"zoomInSlow",
|
|
2749
|
+
"zoomInFast",
|
|
2750
|
+
"zoomOut",
|
|
2751
|
+
"zoomOutSlow",
|
|
2752
|
+
"zoomOutFast",
|
|
2753
|
+
"slideLeft",
|
|
2754
|
+
"slideLeftSlow",
|
|
2755
|
+
"slideLeftFast",
|
|
2756
|
+
"slideRight",
|
|
2757
|
+
"slideRightSlow",
|
|
2758
|
+
"slideRightFast",
|
|
2759
|
+
"slideUp",
|
|
2760
|
+
"slideUpSlow",
|
|
2761
|
+
"slideUpFast",
|
|
2762
|
+
"slideDown",
|
|
2763
|
+
"slideDownSlow",
|
|
2764
|
+
"slideDownFast",
|
|
2693
2765
|
]),
|
|
2694
|
-
|
|
2695
|
-
|
|
2696
|
-
|
|
2766
|
+
),
|
|
2767
|
+
filter: z.optional(
|
|
2768
|
+
z.enum([
|
|
2769
|
+
"none",
|
|
2770
|
+
"blur",
|
|
2771
|
+
"boost",
|
|
2772
|
+
"contrast",
|
|
2773
|
+
"darken",
|
|
2774
|
+
"greyscale",
|
|
2775
|
+
"lighten",
|
|
2776
|
+
"muted",
|
|
2777
|
+
"negative",
|
|
2697
2778
|
]),
|
|
2698
|
-
|
|
2699
|
-
|
|
2700
|
-
|
|
2701
|
-
|
|
2702
|
-
'none'
|
|
2703
|
-
])),
|
|
2704
|
-
scale: z.optional(z.union([
|
|
2705
|
-
z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number()),
|
|
2706
|
-
z.array(tweenTweenSchema)
|
|
2707
|
-
])),
|
|
2708
|
-
width: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(1).lte(3840))),
|
|
2709
|
-
height: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number().int().gte(1).lte(2160))),
|
|
2710
|
-
position: z.optional(z.enum([
|
|
2711
|
-
'top',
|
|
2712
|
-
'topRight',
|
|
2713
|
-
'right',
|
|
2714
|
-
'bottomRight',
|
|
2715
|
-
'bottom',
|
|
2716
|
-
'bottomLeft',
|
|
2717
|
-
'left',
|
|
2718
|
-
'topLeft',
|
|
2719
|
-
'center'
|
|
2720
|
-
])),
|
|
2721
|
-
offset: z.optional(offsetOffsetSchema),
|
|
2722
|
-
transition: z.optional(transitionTransitionSchema),
|
|
2723
|
-
effect: z.optional(z.enum([
|
|
2724
|
-
'zoomIn',
|
|
2725
|
-
'zoomInSlow',
|
|
2726
|
-
'zoomInFast',
|
|
2727
|
-
'zoomOut',
|
|
2728
|
-
'zoomOutSlow',
|
|
2729
|
-
'zoomOutFast',
|
|
2730
|
-
'slideLeft',
|
|
2731
|
-
'slideLeftSlow',
|
|
2732
|
-
'slideLeftFast',
|
|
2733
|
-
'slideRight',
|
|
2734
|
-
'slideRightSlow',
|
|
2735
|
-
'slideRightFast',
|
|
2736
|
-
'slideUp',
|
|
2737
|
-
'slideUpSlow',
|
|
2738
|
-
'slideUpFast',
|
|
2739
|
-
'slideDown',
|
|
2740
|
-
'slideDownSlow',
|
|
2741
|
-
'slideDownFast'
|
|
2742
|
-
])),
|
|
2743
|
-
filter: z.optional(z.enum([
|
|
2744
|
-
'none',
|
|
2745
|
-
'blur',
|
|
2746
|
-
'boost',
|
|
2747
|
-
'contrast',
|
|
2748
|
-
'darken',
|
|
2749
|
-
'greyscale',
|
|
2750
|
-
'lighten',
|
|
2751
|
-
'muted',
|
|
2752
|
-
'negative'
|
|
2753
|
-
])),
|
|
2754
|
-
opacity: z.optional(z.union([
|
|
2755
|
-
z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number()),
|
|
2756
|
-
z.array(tweenTweenSchema)
|
|
2757
|
-
])),
|
|
2758
|
-
transform: z.optional(transformationTransformationSchema),
|
|
2759
|
-
alias: z.optional(z.string().regex(/^[A-Za-z0-9_-]+$/))
|
|
2779
|
+
),
|
|
2780
|
+
opacity: z.optional(z.union([z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number()), z.array(tweenTweenSchema)])),
|
|
2781
|
+
transform: z.optional(transformationTransformationSchema),
|
|
2782
|
+
alias: z.optional(z.string().regex(/^[A-Za-z0-9_-]+$/)),
|
|
2760
2783
|
});
|
|
2761
2784
|
|
|
2762
2785
|
export const clipSchema = clipClipSchema;
|
|
@@ -2765,7 +2788,7 @@ export const clipSchema = clipClipSchema;
|
|
|
2765
2788
|
* A track contains an array of clips. Tracks are layered on top of each other in the order in the array. The top most track will render on top of those below it.
|
|
2766
2789
|
*/
|
|
2767
2790
|
export const trackTrackSchema = z.object({
|
|
2768
|
-
|
|
2791
|
+
clips: z.array(clipClipSchema),
|
|
2769
2792
|
});
|
|
2770
2793
|
|
|
2771
2794
|
export const trackSchema = trackTrackSchema;
|
|
@@ -2774,11 +2797,11 @@ export const trackSchema = trackTrackSchema;
|
|
|
2774
2797
|
* A timeline represents the contents of a video edit over time, an audio edit over time, in seconds, or an image layout. A timeline consists of layers called tracks. Tracks are composed of titles, images, audio, html or video segments referred to as clips which are placed along the track at specific starting point and lasting for a specific amount of time.
|
|
2775
2798
|
*/
|
|
2776
2799
|
export const timelineTimelineSchema = z.object({
|
|
2777
|
-
|
|
2778
|
-
|
|
2779
|
-
|
|
2780
|
-
|
|
2781
|
-
|
|
2800
|
+
soundtrack: z.optional(soundtrackSoundtrackSchema),
|
|
2801
|
+
background: z.optional(z.string()),
|
|
2802
|
+
fonts: z.optional(z.array(fontFontSchema)),
|
|
2803
|
+
tracks: z.array(trackTrackSchema),
|
|
2804
|
+
cache: z.optional(z.boolean()),
|
|
2782
2805
|
});
|
|
2783
2806
|
|
|
2784
2807
|
export const timelineSchema = timelineTimelineSchema;
|
|
@@ -2787,11 +2810,11 @@ export const timelineSchema = timelineTimelineSchema;
|
|
|
2787
2810
|
* An edit defines the arrangement of a video on a timeline, an audio edit or an image design and the output format. Video assets are automatically preprocessed to fix common compatibility issues before rendering. You can control preprocessing behavior using the `transcode` flag on video assets.
|
|
2788
2811
|
*/
|
|
2789
2812
|
export const editEditSchema = z.object({
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2794
|
-
|
|
2813
|
+
timeline: timelineTimelineSchema,
|
|
2814
|
+
output: outputOutputSchema,
|
|
2815
|
+
merge: z.optional(z.array(mergefieldMergeFieldSchema)),
|
|
2816
|
+
callback: z.optional(z.string()),
|
|
2817
|
+
disk: z.optional(z.enum(["local", "mount"])),
|
|
2795
2818
|
});
|
|
2796
2819
|
|
|
2797
2820
|
export const editSchema = editEditSchema;
|
|
@@ -2800,44 +2823,39 @@ export const editSchema = editEditSchema;
|
|
|
2800
2823
|
* The response data returned with the [RenderResponse](#tocs_renderresponse) including status and URL.
|
|
2801
2824
|
*/
|
|
2802
2825
|
export const renderresponsedataRenderResponseDataSchema = z.object({
|
|
2803
|
-
|
|
2804
|
-
|
|
2805
|
-
|
|
2806
|
-
|
|
2807
|
-
|
|
2808
|
-
|
|
2809
|
-
|
|
2810
|
-
|
|
2811
|
-
|
|
2812
|
-
|
|
2813
|
-
|
|
2814
|
-
|
|
2815
|
-
|
|
2816
|
-
|
|
2817
|
-
|
|
2818
|
-
|
|
2819
|
-
|
|
2820
|
-
|
|
2821
|
-
|
|
2822
|
-
|
|
2823
|
-
|
|
2824
|
-
|
|
2825
|
-
|
|
2826
|
-
|
|
2827
|
-
|
|
2828
|
-
created: z.optional(z.string()),
|
|
2829
|
-
updated: z.optional(z.string())
|
|
2830
|
-
});
|
|
2831
|
-
|
|
2832
|
-
export const renderResponseDataSchema = renderresponsedataRenderResponseDataSchema;
|
|
2826
|
+
id: z.string(),
|
|
2827
|
+
owner: z.string(),
|
|
2828
|
+
plan: z.optional(z.string()),
|
|
2829
|
+
status: z.enum([
|
|
2830
|
+
"queued",
|
|
2831
|
+
"fetching",
|
|
2832
|
+
"preprocessing",
|
|
2833
|
+
"rendering",
|
|
2834
|
+
"saving",
|
|
2835
|
+
"done",
|
|
2836
|
+
"failed",
|
|
2837
|
+
]),
|
|
2838
|
+
error: z.optional(z.string()),
|
|
2839
|
+
duration: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
2840
|
+
renderTime: z.optional(z.preprocess(((v: unknown) => { if (v === '' || v === null || v === undefined) return undefined; if (Array.isArray(v)) return v; if (typeof v === 'string') return Number(v); return v; }), z.number())),
|
|
2841
|
+
url: z.optional(z.string()),
|
|
2842
|
+
poster: z.optional(z.union([z.string(), z.null()])),
|
|
2843
|
+
thumbnail: z.optional(z.union([z.string(), z.null()])),
|
|
2844
|
+
data: z.optional(editEditSchema),
|
|
2845
|
+
created: z.optional(z.string()),
|
|
2846
|
+
updated: z.optional(z.string()),
|
|
2847
|
+
});
|
|
2848
|
+
|
|
2849
|
+
export const renderResponseDataSchema =
|
|
2850
|
+
renderresponsedataRenderResponseDataSchema;
|
|
2833
2851
|
|
|
2834
2852
|
/**
|
|
2835
2853
|
* The response received after a [render status request](#get-render-status) is submitted. The response includes details about status of a render and the output URL.
|
|
2836
2854
|
*/
|
|
2837
2855
|
export const renderresponseRenderResponseSchema = z.object({
|
|
2838
|
-
|
|
2839
|
-
|
|
2840
|
-
|
|
2856
|
+
success: z.boolean(),
|
|
2857
|
+
message: z.string(),
|
|
2858
|
+
response: renderresponsedataRenderResponseDataSchema,
|
|
2841
2859
|
});
|
|
2842
2860
|
|
|
2843
2861
|
export const renderResponseSchema = renderresponseRenderResponseSchema;
|
|
@@ -2846,39 +2864,41 @@ export const renderResponseSchema = renderresponseRenderResponseSchema;
|
|
|
2846
2864
|
* The response data returned with the [TemplateDataResponse](#tocs_templatedataresponse).
|
|
2847
2865
|
*/
|
|
2848
2866
|
export const templatedataresponsedataTemplateDataResponseDataSchema = z.object({
|
|
2849
|
-
|
|
2850
|
-
|
|
2851
|
-
|
|
2852
|
-
|
|
2867
|
+
id: z.string(),
|
|
2868
|
+
name: z.string(),
|
|
2869
|
+
owner: z.string(),
|
|
2870
|
+
template: editEditSchema,
|
|
2853
2871
|
});
|
|
2854
2872
|
|
|
2855
|
-
export const templateDataResponseDataSchema =
|
|
2873
|
+
export const templateDataResponseDataSchema =
|
|
2874
|
+
templatedataresponsedataTemplateDataResponseDataSchema;
|
|
2856
2875
|
|
|
2857
2876
|
/**
|
|
2858
2877
|
* The template data including the template name and [Edit](#tocs_edit).
|
|
2859
2878
|
*/
|
|
2860
2879
|
export const templatedataresponseTemplateDataResponseSchema = z.object({
|
|
2861
|
-
|
|
2862
|
-
|
|
2863
|
-
|
|
2880
|
+
success: z.boolean(),
|
|
2881
|
+
message: z.string(),
|
|
2882
|
+
response: templatedataresponsedataTemplateDataResponseDataSchema,
|
|
2864
2883
|
});
|
|
2865
2884
|
|
|
2866
|
-
export const templateDataResponseSchema =
|
|
2885
|
+
export const templateDataResponseSchema =
|
|
2886
|
+
templatedataresponseTemplateDataResponseSchema;
|
|
2867
2887
|
|
|
2868
2888
|
/**
|
|
2869
2889
|
* A template is a saved [Edit](#tocs_edit) than can be loaded and re-used.
|
|
2870
2890
|
*/
|
|
2871
2891
|
export const templateTemplateSchema = z.object({
|
|
2872
|
-
|
|
2873
|
-
|
|
2892
|
+
name: z.string(),
|
|
2893
|
+
template: z.optional(editEditSchema),
|
|
2874
2894
|
});
|
|
2875
2895
|
|
|
2876
2896
|
export const templateSchema = templateTemplateSchema;
|
|
2877
2897
|
|
|
2878
2898
|
export const postRenderRequest = z.object({
|
|
2879
|
-
|
|
2880
|
-
|
|
2881
|
-
|
|
2899
|
+
body: editEditSchema,
|
|
2900
|
+
path: z.optional(z.never()),
|
|
2901
|
+
query: z.optional(z.never()),
|
|
2882
2902
|
});
|
|
2883
2903
|
|
|
2884
2904
|
/**
|
|
@@ -2887,14 +2907,20 @@ export const postRenderRequest = z.object({
|
|
|
2887
2907
|
export const postRenderResponse = queuedresponseQueuedResponseSchema;
|
|
2888
2908
|
|
|
2889
2909
|
export const getRenderRequest = z.object({
|
|
2890
|
-
|
|
2891
|
-
|
|
2892
|
-
|
|
2910
|
+
body: z.optional(z.never()),
|
|
2911
|
+
path: z.object({
|
|
2912
|
+
id: z
|
|
2913
|
+
.string()
|
|
2914
|
+
.regex(
|
|
2915
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
2916
|
+
),
|
|
2917
|
+
}),
|
|
2918
|
+
query: z.optional(
|
|
2919
|
+
z.object({
|
|
2920
|
+
data: z.optional(z.boolean()),
|
|
2921
|
+
merged: z.optional(z.boolean()),
|
|
2893
2922
|
}),
|
|
2894
|
-
|
|
2895
|
-
data: z.optional(z.boolean()),
|
|
2896
|
-
merged: z.optional(z.boolean())
|
|
2897
|
-
}))
|
|
2923
|
+
),
|
|
2898
2924
|
});
|
|
2899
2925
|
|
|
2900
2926
|
/**
|
|
@@ -2903,20 +2929,21 @@ export const getRenderRequest = z.object({
|
|
|
2903
2929
|
export const getRenderResponse = renderresponseRenderResponseSchema;
|
|
2904
2930
|
|
|
2905
2931
|
export const getTemplatesRequest = z.object({
|
|
2906
|
-
|
|
2907
|
-
|
|
2908
|
-
|
|
2932
|
+
body: z.optional(z.never()),
|
|
2933
|
+
path: z.optional(z.never()),
|
|
2934
|
+
query: z.optional(z.never()),
|
|
2909
2935
|
});
|
|
2910
2936
|
|
|
2911
2937
|
/**
|
|
2912
2938
|
* The list of templates stored against a users account
|
|
2913
2939
|
*/
|
|
2914
|
-
export const getTemplatesResponse =
|
|
2940
|
+
export const getTemplatesResponse =
|
|
2941
|
+
templatelistresponseTemplateListResponseSchema;
|
|
2915
2942
|
|
|
2916
2943
|
export const postTemplateRequest = z.object({
|
|
2917
|
-
|
|
2918
|
-
|
|
2919
|
-
|
|
2944
|
+
body: templateTemplateSchema,
|
|
2945
|
+
path: z.optional(z.never()),
|
|
2946
|
+
query: z.optional(z.never()),
|
|
2920
2947
|
});
|
|
2921
2948
|
|
|
2922
2949
|
/**
|
|
@@ -2925,11 +2952,15 @@ export const postTemplateRequest = z.object({
|
|
|
2925
2952
|
export const postTemplateResponse = templateresponseTemplateResponseSchema;
|
|
2926
2953
|
|
|
2927
2954
|
export const deleteTemplateRequest = z.object({
|
|
2928
|
-
|
|
2929
|
-
|
|
2930
|
-
|
|
2931
|
-
|
|
2932
|
-
|
|
2955
|
+
body: z.optional(z.never()),
|
|
2956
|
+
path: z.object({
|
|
2957
|
+
id: z
|
|
2958
|
+
.string()
|
|
2959
|
+
.regex(
|
|
2960
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
2961
|
+
),
|
|
2962
|
+
}),
|
|
2963
|
+
query: z.optional(z.never()),
|
|
2933
2964
|
});
|
|
2934
2965
|
|
|
2935
2966
|
/**
|
|
@@ -2938,24 +2969,33 @@ export const deleteTemplateRequest = z.object({
|
|
|
2938
2969
|
export const deleteTemplateResponse = z.void();
|
|
2939
2970
|
|
|
2940
2971
|
export const getTemplateRequest = z.object({
|
|
2941
|
-
|
|
2942
|
-
|
|
2943
|
-
|
|
2944
|
-
|
|
2945
|
-
|
|
2972
|
+
body: z.optional(z.never()),
|
|
2973
|
+
path: z.object({
|
|
2974
|
+
id: z
|
|
2975
|
+
.string()
|
|
2976
|
+
.regex(
|
|
2977
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
2978
|
+
),
|
|
2979
|
+
}),
|
|
2980
|
+
query: z.optional(z.never()),
|
|
2946
2981
|
});
|
|
2947
2982
|
|
|
2948
2983
|
/**
|
|
2949
2984
|
* The template details including the [Edit](#tocs_edit)
|
|
2950
2985
|
*/
|
|
2951
|
-
export const getTemplateResponse =
|
|
2986
|
+
export const getTemplateResponse =
|
|
2987
|
+
templatedataresponseTemplateDataResponseSchema;
|
|
2952
2988
|
|
|
2953
2989
|
export const putTemplateRequest = z.object({
|
|
2954
|
-
|
|
2955
|
-
|
|
2956
|
-
|
|
2957
|
-
|
|
2958
|
-
|
|
2990
|
+
body: templateTemplateSchema,
|
|
2991
|
+
path: z.object({
|
|
2992
|
+
id: z
|
|
2993
|
+
.string()
|
|
2994
|
+
.regex(
|
|
2995
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
2996
|
+
),
|
|
2997
|
+
}),
|
|
2998
|
+
query: z.optional(z.never()),
|
|
2959
2999
|
});
|
|
2960
3000
|
|
|
2961
3001
|
/**
|
|
@@ -2964,9 +3004,9 @@ export const putTemplateRequest = z.object({
|
|
|
2964
3004
|
export const putTemplateResponse = templateresponseTemplateResponseSchema;
|
|
2965
3005
|
|
|
2966
3006
|
export const postTemplateRenderRequest = z.object({
|
|
2967
|
-
|
|
2968
|
-
|
|
2969
|
-
|
|
3007
|
+
body: templaterenderTemplateRenderSchema,
|
|
3008
|
+
path: z.optional(z.never()),
|
|
3009
|
+
query: z.optional(z.never()),
|
|
2970
3010
|
});
|
|
2971
3011
|
|
|
2972
3012
|
/**
|
|
@@ -2975,11 +3015,11 @@ export const postTemplateRenderRequest = z.object({
|
|
|
2975
3015
|
export const postTemplateRenderResponse = queuedresponseQueuedResponseSchema;
|
|
2976
3016
|
|
|
2977
3017
|
export const probeRequest = z.object({
|
|
2978
|
-
|
|
2979
|
-
|
|
2980
|
-
|
|
2981
|
-
|
|
2982
|
-
|
|
3018
|
+
body: z.optional(z.never()),
|
|
3019
|
+
path: z.object({
|
|
3020
|
+
url: z.string(),
|
|
3021
|
+
}),
|
|
3022
|
+
query: z.optional(z.never()),
|
|
2983
3023
|
});
|
|
2984
3024
|
|
|
2985
3025
|
/**
|
|
@@ -2988,11 +3028,15 @@ export const probeRequest = z.object({
|
|
|
2988
3028
|
export const probeResponse = proberesponseProbeResponseSchema;
|
|
2989
3029
|
|
|
2990
3030
|
export const deleteAssetRequest = z.object({
|
|
2991
|
-
|
|
2992
|
-
|
|
2993
|
-
|
|
2994
|
-
|
|
2995
|
-
|
|
3031
|
+
body: z.optional(z.never()),
|
|
3032
|
+
path: z.object({
|
|
3033
|
+
id: z
|
|
3034
|
+
.string()
|
|
3035
|
+
.regex(
|
|
3036
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
3037
|
+
),
|
|
3038
|
+
}),
|
|
3039
|
+
query: z.optional(z.never()),
|
|
2996
3040
|
});
|
|
2997
3041
|
|
|
2998
3042
|
/**
|
|
@@ -3001,11 +3045,15 @@ export const deleteAssetRequest = z.object({
|
|
|
3001
3045
|
export const deleteAssetResponse = z.void();
|
|
3002
3046
|
|
|
3003
3047
|
export const getAssetRequest = z.object({
|
|
3004
|
-
|
|
3005
|
-
|
|
3006
|
-
|
|
3007
|
-
|
|
3008
|
-
|
|
3048
|
+
body: z.optional(z.never()),
|
|
3049
|
+
path: z.object({
|
|
3050
|
+
id: z
|
|
3051
|
+
.string()
|
|
3052
|
+
.regex(
|
|
3053
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
3054
|
+
),
|
|
3055
|
+
}),
|
|
3056
|
+
query: z.optional(z.never()),
|
|
3009
3057
|
});
|
|
3010
3058
|
|
|
3011
3059
|
/**
|
|
@@ -3014,22 +3062,27 @@ export const getAssetRequest = z.object({
|
|
|
3014
3062
|
export const getAssetResponse = assetresponseAssetResponseSchema;
|
|
3015
3063
|
|
|
3016
3064
|
export const getAssetByRenderIdRequest = z.object({
|
|
3017
|
-
|
|
3018
|
-
|
|
3019
|
-
|
|
3020
|
-
|
|
3021
|
-
|
|
3065
|
+
body: z.optional(z.never()),
|
|
3066
|
+
path: z.object({
|
|
3067
|
+
id: z
|
|
3068
|
+
.string()
|
|
3069
|
+
.regex(
|
|
3070
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
3071
|
+
),
|
|
3072
|
+
}),
|
|
3073
|
+
query: z.optional(z.never()),
|
|
3022
3074
|
});
|
|
3023
3075
|
|
|
3024
3076
|
/**
|
|
3025
3077
|
* Get one or more assets by render id
|
|
3026
3078
|
*/
|
|
3027
|
-
export const getAssetByRenderIdResponse =
|
|
3079
|
+
export const getAssetByRenderIdResponse =
|
|
3080
|
+
assetrenderresponseAssetRenderResponseSchema;
|
|
3028
3081
|
|
|
3029
3082
|
export const postServeAssetRequest = z.object({
|
|
3030
|
-
|
|
3031
|
-
|
|
3032
|
-
|
|
3083
|
+
body: transferTransferSchema,
|
|
3084
|
+
path: z.optional(z.never()),
|
|
3085
|
+
query: z.optional(z.never()),
|
|
3033
3086
|
});
|
|
3034
3087
|
|
|
3035
3088
|
/**
|
|
@@ -3038,9 +3091,9 @@ export const postServeAssetRequest = z.object({
|
|
|
3038
3091
|
export const postServeAssetResponse = transferresponseTransferResponseSchema;
|
|
3039
3092
|
|
|
3040
3093
|
export const getSourcesRequest = z.object({
|
|
3041
|
-
|
|
3042
|
-
|
|
3043
|
-
|
|
3094
|
+
body: z.optional(z.never()),
|
|
3095
|
+
path: z.optional(z.never()),
|
|
3096
|
+
query: z.optional(z.never()),
|
|
3044
3097
|
});
|
|
3045
3098
|
|
|
3046
3099
|
/**
|
|
@@ -3049,22 +3102,27 @@ export const getSourcesRequest = z.object({
|
|
|
3049
3102
|
export const getSourcesResponse = sourcelistresponseSourceListResponseSchema;
|
|
3050
3103
|
|
|
3051
3104
|
export const postSourceRequest = z.object({
|
|
3052
|
-
|
|
3053
|
-
|
|
3054
|
-
|
|
3105
|
+
body: sourceSourceSchema,
|
|
3106
|
+
path: z.optional(z.never()),
|
|
3107
|
+
query: z.optional(z.never()),
|
|
3055
3108
|
});
|
|
3056
3109
|
|
|
3057
3110
|
/**
|
|
3058
3111
|
* The queued source file details
|
|
3059
3112
|
*/
|
|
3060
|
-
export const postSourceResponse =
|
|
3113
|
+
export const postSourceResponse =
|
|
3114
|
+
queuedsourceresponseQueuedSourceResponseSchema;
|
|
3061
3115
|
|
|
3062
3116
|
export const deleteSourceRequest = z.object({
|
|
3063
|
-
|
|
3064
|
-
|
|
3065
|
-
|
|
3066
|
-
|
|
3067
|
-
|
|
3117
|
+
body: z.optional(z.never()),
|
|
3118
|
+
path: z.object({
|
|
3119
|
+
id: z
|
|
3120
|
+
.string()
|
|
3121
|
+
.regex(
|
|
3122
|
+
/^[0-9a-zA-Z]{8}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{12}$/,
|
|
3123
|
+
),
|
|
3124
|
+
}),
|
|
3125
|
+
query: z.optional(z.never()),
|
|
3068
3126
|
});
|
|
3069
3127
|
|
|
3070
3128
|
/**
|
|
@@ -3073,11 +3131,15 @@ export const deleteSourceRequest = z.object({
|
|
|
3073
3131
|
export const deleteSourceResponse = z.void();
|
|
3074
3132
|
|
|
3075
3133
|
export const getSourceRequest = z.object({
|
|
3076
|
-
|
|
3077
|
-
|
|
3078
|
-
|
|
3079
|
-
|
|
3080
|
-
|
|
3134
|
+
body: z.optional(z.never()),
|
|
3135
|
+
path: z.object({
|
|
3136
|
+
id: z
|
|
3137
|
+
.string()
|
|
3138
|
+
.regex(
|
|
3139
|
+
/^[0-9a-zA-Z]{8}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{12}$/,
|
|
3140
|
+
),
|
|
3141
|
+
}),
|
|
3142
|
+
query: z.optional(z.never()),
|
|
3081
3143
|
});
|
|
3082
3144
|
|
|
3083
3145
|
/**
|
|
@@ -3086,9 +3148,9 @@ export const getSourceRequest = z.object({
|
|
|
3086
3148
|
export const getSourceResponse = sourceresponseSourceResponseSchema;
|
|
3087
3149
|
|
|
3088
3150
|
export const getUploadSignedUrlRequest = z.object({
|
|
3089
|
-
|
|
3090
|
-
|
|
3091
|
-
|
|
3151
|
+
body: z.optional(z.never()),
|
|
3152
|
+
path: z.optional(z.never()),
|
|
3153
|
+
query: z.optional(z.never()),
|
|
3092
3154
|
});
|
|
3093
3155
|
|
|
3094
3156
|
/**
|
|
@@ -3097,25 +3159,31 @@ export const getUploadSignedUrlRequest = z.object({
|
|
|
3097
3159
|
export const getUploadSignedUrlResponse = uploadresponseUploadResponseSchema;
|
|
3098
3160
|
|
|
3099
3161
|
export const postGenerateAssetRequest = z.object({
|
|
3100
|
-
|
|
3101
|
-
|
|
3102
|
-
|
|
3162
|
+
body: generatedAssetGeneratedAssetSchema,
|
|
3163
|
+
path: z.optional(z.never()),
|
|
3164
|
+
query: z.optional(z.never()),
|
|
3103
3165
|
});
|
|
3104
3166
|
|
|
3105
3167
|
/**
|
|
3106
3168
|
* The generated asset details
|
|
3107
3169
|
*/
|
|
3108
|
-
export const postGenerateAssetResponse =
|
|
3170
|
+
export const postGenerateAssetResponse =
|
|
3171
|
+
generatedAssetResponseGeneratedAssetResponseSchema;
|
|
3109
3172
|
|
|
3110
3173
|
export const getGeneratedAssetRequest = z.object({
|
|
3111
|
-
|
|
3112
|
-
|
|
3113
|
-
|
|
3114
|
-
|
|
3115
|
-
|
|
3174
|
+
body: z.optional(z.never()),
|
|
3175
|
+
path: z.object({
|
|
3176
|
+
id: z
|
|
3177
|
+
.string()
|
|
3178
|
+
.regex(
|
|
3179
|
+
/^[0-9a-zA-Z]{8}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{12}$/,
|
|
3180
|
+
),
|
|
3181
|
+
}),
|
|
3182
|
+
query: z.optional(z.never()),
|
|
3116
3183
|
});
|
|
3117
3184
|
|
|
3118
3185
|
/**
|
|
3119
3186
|
* The generated asset details
|
|
3120
3187
|
*/
|
|
3121
|
-
export const getGeneratedAssetResponse =
|
|
3188
|
+
export const getGeneratedAssetResponse =
|
|
3189
|
+
generatedAssetResponseGeneratedAssetResponseSchema;
|