api/schema: add youtubeVideoContainer

This commit is contained in:
wukko 2025-06-20 14:23:16 +06:00
parent 4da95e0a2b
commit 2396462c5c
No known key found for this signature in database
GPG Key ID: 3E30B3F26C7B4AA2
2 changed files with 14 additions and 9 deletions

View File

@ -26,6 +26,10 @@ export const apiSchema = z.object({
["h264", "av1", "vp9"] ["h264", "av1", "vp9"]
).default("h264"), ).default("h264"),
youtubeVideoContainer: z.enum(
["auto", "mp4", "webm", "mkv"]
).default("auto"),
videoQuality: z.enum( videoQuality: z.enum(
["max", "4320", "2160", "1440", "1080", "720", "480", "360", "240", "144"] ["max", "4320", "2160", "1440", "1080", "720", "480", "360", "240", "144"]
).default("1080"), ).default("1080"),

View File

@ -82,8 +82,9 @@ all keys except for `url` are optional. value options are separated by `/`.
#### service-specific options #### service-specific options
| key | type | description/value | default | | key | type | description/value | default |
|:-----------------------|:----------|:--------------------------------------------------|:--------| |:------------------------|:----------|:--------------------------------------------------|:--------|
| `youtubeVideoCodec` | `string` | `h264 / av1 / vp9` | `h264` | | `youtubeVideoCodec` | `string` | `h264 / av1 / vp9` | `h264` |
| `youtubeVideoContainer` | `string` | `auto / mp4 / webm / mkv` | `auto` |
| `youtubeDubLang` | `string` | any valid language code, such as: `en` or `zh-CN` | *none* | | `youtubeDubLang` | `string` | any valid language code, such as: `en` or `zh-CN` | *none* |
| `convertGif` | `boolean` | convert twitter gifs to the actual GIF format | `true` | | `convertGif` | `boolean` | convert twitter gifs to the actual GIF format | `true` |
| `allowH265` | `boolean` | allow H265/HEVC videos from tiktok/xiaohongshu | `false` | | `allowH265` | `boolean` | allow H265/HEVC videos from tiktok/xiaohongshu | `false` |