|
549 | 549 | }, |
550 | 550 | "/api/content": { |
551 | 551 | "patch": { |
552 | | - "description": "Apply edits to content — trim, crop, resize, overlay text, or add an audio track. Accepts video, image, or audio input. Pass a `template` for a preset edit pipeline, or build your own with an `operations` array.", |
| 552 | + "description": "Apply edits to content — trim, crop, resize, overlay text, or add an audio track. Accepts video or audio input. Pass a `template` for a preset edit pipeline, or build your own with an `operations` array.", |
553 | 553 | "security": [ |
554 | 554 | { |
555 | 555 | "apiKeyAuth": [] |
|
2103 | 2103 | "minItems": 1, |
2104 | 2104 | "description": "Audio file URLs to transcribe" |
2105 | 2105 | }, |
| 2106 | + "language": { |
| 2107 | + "type": "string", |
| 2108 | + "default": "en", |
| 2109 | + "description": "Language code for transcription (e.g. en, es, fr). Defaults to en." |
| 2110 | + }, |
| 2111 | + "chunk_level": { |
| 2112 | + "type": "string", |
| 2113 | + "enum": [ |
| 2114 | + "none", |
| 2115 | + "segment", |
| 2116 | + "word" |
| 2117 | + ], |
| 2118 | + "default": "word", |
| 2119 | + "description": "Granularity of timestamp chunks. Defaults to word-level." |
| 2120 | + }, |
| 2121 | + "diarize": { |
| 2122 | + "type": "boolean", |
| 2123 | + "default": false, |
| 2124 | + "description": "Enable speaker diarization. Defaults to false." |
| 2125 | + }, |
2106 | 2126 | "model": { |
2107 | 2127 | "type": "string", |
2108 | 2128 | "description": "fal.ai model ID. Defaults to fal-ai/whisper" |
|
2112 | 2132 | "ContentCreateAudioResponse": { |
2113 | 2133 | "type": "object", |
2114 | 2134 | "required": [ |
2115 | | - "songUrl", |
| 2135 | + "audioUrl", |
2116 | 2136 | "fullLyrics", |
2117 | 2137 | "segments", |
2118 | 2138 | "segmentCount" |
2119 | 2139 | ], |
2120 | 2140 | "properties": { |
2121 | | - "songUrl": { |
| 2141 | + "audioUrl": { |
2122 | 2142 | "type": "string", |
2123 | | - "description": "URL of the transcribed song" |
| 2143 | + "description": "URL of the transcribed audio" |
2124 | 2144 | }, |
2125 | 2145 | "fullLyrics": { |
2126 | 2146 | "type": "string", |
|
2163 | 2183 | }, |
2164 | 2184 | "ContentCreateEditRequest": { |
2165 | 2185 | "type": "object", |
2166 | | - "description": "Must provide at least one input (video_url, image_url, or audio_url)", |
| 2186 | + "description": "Must provide at least one input (video_url or audio_url)", |
2167 | 2187 | "properties": { |
2168 | 2188 | "video_url": { |
2169 | 2189 | "type": "string", |
2170 | 2190 | "format": "uri", |
2171 | 2191 | "description": "Input video URL" |
2172 | 2192 | }, |
2173 | | - "image_url": { |
2174 | | - "type": "string", |
2175 | | - "format": "uri", |
2176 | | - "description": "Input image URL" |
2177 | | - }, |
2178 | 2193 | "audio_url": { |
2179 | 2194 | "type": "string", |
2180 | 2195 | "format": "uri", |
|
2359 | 2374 | }, |
2360 | 2375 | "description": "Optional reference image URLs to guide generation" |
2361 | 2376 | }, |
| 2377 | + "num_images": { |
| 2378 | + "type": "integer", |
| 2379 | + "minimum": 1, |
| 2380 | + "maximum": 4, |
| 2381 | + "default": 1, |
| 2382 | + "description": "Number of images to generate (1-4)" |
| 2383 | + }, |
| 2384 | + "aspect_ratio": { |
| 2385 | + "type": "string", |
| 2386 | + "enum": ["auto", "21:9", "16:9", "3:2", "4:3", "5:4", "1:1", "4:5", "3:4", "2:3", "9:16", "4:1", "1:4", "8:1", "1:8"], |
| 2387 | + "default": "auto", |
| 2388 | + "description": "Aspect ratio of the generated image" |
| 2389 | + }, |
| 2390 | + "resolution": { |
| 2391 | + "type": "string", |
| 2392 | + "enum": ["0.5K", "1K", "2K", "4K"], |
| 2393 | + "default": "1K", |
| 2394 | + "description": "Output resolution" |
| 2395 | + }, |
2362 | 2396 | "model": { |
2363 | 2397 | "type": "string", |
2364 | | - "description": "fal.ai model ID. Defaults to fal-ai/nano-banana-pro/edit" |
| 2398 | + "description": "fal.ai model ID. Defaults to fal-ai/nano-banana-2" |
2365 | 2399 | } |
2366 | 2400 | } |
2367 | 2401 | }, |
2368 | 2402 | "ContentCreateImageResponse": { |
2369 | 2403 | "type": "object", |
2370 | 2404 | "required": [ |
2371 | | - "imageUrl" |
| 2405 | + "imageUrl", |
| 2406 | + "images" |
2372 | 2407 | ], |
2373 | 2408 | "properties": { |
2374 | 2409 | "imageUrl": { |
2375 | 2410 | "type": "string", |
2376 | 2411 | "format": "uri", |
2377 | | - "description": "URL of the generated image" |
| 2412 | + "description": "URL of the first generated image" |
| 2413 | + }, |
| 2414 | + "images": { |
| 2415 | + "type": "array", |
| 2416 | + "items": { |
| 2417 | + "type": "string", |
| 2418 | + "format": "uri" |
| 2419 | + }, |
| 2420 | + "description": "URLs of all generated images. Contains one element when num_images is 1." |
2378 | 2421 | } |
2379 | 2422 | } |
2380 | 2423 | }, |
|
2551 | 2594 | "color": { |
2552 | 2595 | "type": "string", |
2553 | 2596 | "description": "Text color as a CSS color value", |
2554 | | - "example": "#FFFFFF" |
| 2597 | + "example": "white" |
2555 | 2598 | }, |
2556 | 2599 | "borderColor": { |
2557 | 2600 | "type": "string", |
2558 | 2601 | "description": "Text border/stroke color as a CSS color value", |
2559 | | - "example": "#000000" |
| 2602 | + "example": "black" |
2560 | 2603 | }, |
2561 | 2604 | "maxFontSize": { |
2562 | 2605 | "type": "number", |
2563 | 2606 | "description": "Maximum font size in pixels", |
2564 | | - "example": 48 |
| 2607 | + "example": 42 |
2565 | 2608 | } |
2566 | 2609 | } |
2567 | 2610 | }, |
|
2584 | 2627 | "video" |
2585 | 2628 | ], |
2586 | 2629 | "description": "Whether the input is an image or video" |
| 2630 | + }, |
| 2631 | + "upscale_factor": { |
| 2632 | + "type": "number", |
| 2633 | + "minimum": 1, |
| 2634 | + "maximum": 4, |
| 2635 | + "default": 2, |
| 2636 | + "description": "Upscale multiplier (1-4x). Defaults to 2x." |
| 2637 | + }, |
| 2638 | + "target_resolution": { |
| 2639 | + "type": "string", |
| 2640 | + "enum": [ |
| 2641 | + "720p", |
| 2642 | + "1080p", |
| 2643 | + "1440p", |
| 2644 | + "2160p" |
| 2645 | + ], |
| 2646 | + "description": "Target output resolution. When provided, overrides upscale_factor with a resolution-based upscale." |
2587 | 2647 | } |
2588 | 2648 | } |
2589 | 2649 | }, |
|
2602 | 2662 | }, |
2603 | 2663 | "ContentCreateVideoRequest": { |
2604 | 2664 | "type": "object", |
| 2665 | + "required": [ |
| 2666 | + "image_url" |
| 2667 | + ], |
2605 | 2668 | "properties": { |
2606 | 2669 | "template": { |
2607 | 2670 | "type": "string", |
|
2626 | 2689 | "image_url": { |
2627 | 2690 | "type": "string", |
2628 | 2691 | "format": "uri", |
2629 | | - "description": "Image URL. Used as the first frame (animate), style reference (reference), start frame (first-last), or face source (lipsync)" |
| 2692 | + "description": "Required. Image URL used as the input frame. The underlying model (fal-ai/veo3.1/fast/image-to-video) requires an image — text-only prompt mode is not supported. Generate an image first via POST /api/content/image if needed." |
2630 | 2693 | }, |
2631 | 2694 | "end_image_url": { |
2632 | 2695 | "type": "string", |
|
2692 | 2755 | "ContentCreateVideoResponse": { |
2693 | 2756 | "type": "object", |
2694 | 2757 | "required": [ |
2695 | | - "videoUrl" |
| 2758 | + "videoUrl", |
| 2759 | + "mode" |
2696 | 2760 | ], |
2697 | 2761 | "properties": { |
2698 | 2762 | "videoUrl": { |
2699 | 2763 | "type": "string", |
2700 | 2764 | "format": "uri", |
2701 | 2765 | "description": "URL of the generated video" |
| 2766 | + }, |
| 2767 | + "mode": { |
| 2768 | + "type": "string", |
| 2769 | + "enum": [ |
| 2770 | + "prompt", |
| 2771 | + "animate", |
| 2772 | + "reference", |
| 2773 | + "extend", |
| 2774 | + "first-last", |
| 2775 | + "lipsync" |
| 2776 | + ], |
| 2777 | + "description": "The resolved video generation mode (explicit or inferred from inputs)" |
2702 | 2778 | } |
2703 | 2779 | } |
2704 | 2780 | }, |
|
0 commit comments