Gemini Omni 1.1 동영상 생성 및 편집
curl --request POST \
--url https://toapis.com/v1/videos/generationsimport requests
url = "https://toapis.com/v1/videos/generations"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://toapis.com/v1/videos/generations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://toapis.com/v1/videos/generations",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://toapis.com/v1/videos/generations"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://toapis.com/v1/videos/generations")
.asString();require 'uri'
require 'net/http'
url = URI("https://toapis.com/v1/videos/generations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_bodyGemini Omni Official
Gemini Omni 1.1 동영상 생성 및 편집
공식 Gemini Omni 1.1 Flash Preview로 네 가지 해상도의 3-10초 동영상 생성
POST
/
v1
/
videos
/
generations
Gemini Omni 1.1 동영상 생성 및 편집
curl --request POST \
--url https://toapis.com/v1/videos/generationsimport requests
url = "https://toapis.com/v1/videos/generations"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://toapis.com/v1/videos/generations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://toapis.com/v1/videos/generations",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://toapis.com/v1/videos/generations"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://toapis.com/v1/videos/generations")
.asString();require 'uri'
require 'net/http'
url = URI("https://toapis.com/v1/videos/generations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_bodymodel을 gemini-omni-1.1-flash-preview-official로 지정합니다. 이 프리뷰 모델은 텍스트, 이미지 및 참조 이미지 기반 생성과 동영상 편집을 지원합니다.
중국 본토에서는 예제 도메인을
https://toapis.cn으로 변경할 수 있습니다.매개변수
Authorization: Bearer YOUR_API_KEY
| 필드 | 설명 |
|---|---|
model | gemini-omni-1.1-flash-preview-official |
prompt | 필수. 생성하거나 편집할 내용을 설명합니다. |
duration | 3-10초 정수. 기본값은 6초입니다. |
resolution | 360p / 720p / 1080p / 4K. 기본값은 720p입니다. |
aspect_ratio | 16:9 / 9:16. 기본값은 16:9입니다. 동영상 편집에는 전송하지 않습니다. |
image_urls | 참조 이미지 URL 최대 10개. 입력 동영상과 함께 사용할 수 없습니다. |
video_list | video_url을 포함한 항목 최대 3개. MP4/MOV만 지원하며 각 50 MiB 이하입니다. |
metadata.task | 선택: text_to_video / image_to_video / reference_to_video / edit. 생략하면 모델이 판단합니다. |
요금
USD 기준입니다. 출력은 요청한 초 단위로 과금합니다. 입력 동영상은 서버에서 측정한 시간을 각각 정수 초로 올림하여 $0.006950/초를 추가 과금합니다. 아래는 기본 요금이며 할인은 견적을 따릅니다.| 출력 해상도 | 초당 요금 |
|---|---|
| 360p | $0.027034 |
| 720p | $0.081088 |
| 1080p | $0.121632 |
| 4K | $0.243264 |
요청 예제
curl https://toapis.com/v1/videos/generations \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gemini-omni-1.1-flash-preview-official",
"prompt": "A red paper boat floating on a calm lake at sunrise",
"duration": 3,
"resolution": "360p",
"aspect_ratio": "16:9"
}'
{
"model": "gemini-omni-1.1-flash-preview-official",
"prompt": "Change the sky to a warm sunset",
"duration": 6,
"resolution": "1080p",
"video_list": [{"video_url": "https://example.com/uploaded-video.mp4"}],
"metadata": {"task": "edit"}
}
결과 조회
제출 응답의 작업 id를 사용하여 통합 작업 API에서 상태와 결과를 조회합니다.curl https://toapis.com/v1/videos/generations/TASK_ID \
-H "Authorization: Bearer YOUR_API_KEY"