Submit Grok Imagine Video 1.5 task
curl --request POST \
--url https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5 \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"prompt": "Waves crash against a lighthouse at golden hour",
"aspect_ratio": "16:9",
"resolution": "720p",
"duration": 6
}
'import requests
url = "https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5"
payload = {
"prompt": "Waves crash against a lighthouse at golden hour",
"aspect_ratio": "16:9",
"resolution": "720p",
"duration": 6
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
prompt: 'Waves crash against a lighthouse at golden hour',
aspect_ratio: '16:9',
resolution: '720p',
duration: 6
})
};
fetch('https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5', 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://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'prompt' => 'Waves crash against a lighthouse at golden hour',
'aspect_ratio' => '16:9',
'resolution' => '720p',
'duration' => 6
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5"
payload := strings.NewReader("{\n \"prompt\": \"Waves crash against a lighthouse at golden hour\",\n \"aspect_ratio\": \"16:9\",\n \"resolution\": \"720p\",\n \"duration\": 6\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"prompt\": \"Waves crash against a lighthouse at golden hour\",\n \"aspect_ratio\": \"16:9\",\n \"resolution\": \"720p\",\n \"duration\": 6\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"prompt\": \"Waves crash against a lighthouse at golden hour\",\n \"aspect_ratio\": \"16:9\",\n \"resolution\": \"720p\",\n \"duration\": 6\n}"
response = http.request(request)
puts response.read_body{
"code": 0,
"message": "success",
"data": {
"task_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"model_key": "<string>",
"credits_deducted": 1,
"provider_task_id": "<string>",
"provider_key": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}视频生成
提交 Grok Imagine Video 1.5 任务
POST Grok Imagine Video 1.5 文生视频或参考图生视频任务
POST
/
api
/
v1
/
task
/
submit
/
grok-imagine-video-1.5
Submit Grok Imagine Video 1.5 task
curl --request POST \
--url https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5 \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"prompt": "Waves crash against a lighthouse at golden hour",
"aspect_ratio": "16:9",
"resolution": "720p",
"duration": 6
}
'import requests
url = "https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5"
payload = {
"prompt": "Waves crash against a lighthouse at golden hour",
"aspect_ratio": "16:9",
"resolution": "720p",
"duration": 6
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
prompt: 'Waves crash against a lighthouse at golden hour',
aspect_ratio: '16:9',
resolution: '720p',
duration: 6
})
};
fetch('https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5', 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://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'prompt' => 'Waves crash against a lighthouse at golden hour',
'aspect_ratio' => '16:9',
'resolution' => '720p',
'duration' => 6
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5"
payload := strings.NewReader("{\n \"prompt\": \"Waves crash against a lighthouse at golden hour\",\n \"aspect_ratio\": \"16:9\",\n \"resolution\": \"720p\",\n \"duration\": 6\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"prompt\": \"Waves crash against a lighthouse at golden hour\",\n \"aspect_ratio\": \"16:9\",\n \"resolution\": \"720p\",\n \"duration\": 6\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"prompt\": \"Waves crash against a lighthouse at golden hour\",\n \"aspect_ratio\": \"16:9\",\n \"resolution\": \"720p\",\n \"duration\": 6\n}"
response = http.request(request)
puts response.read_body{
"code": 0,
"message": "success",
"data": {
"task_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"model_key": "<string>",
"credits_deducted": 1,
"provider_task_id": "<string>",
"provider_key": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"param": "<string>",
"code": "<string>"
},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"retry_after": 1
}提交任务
prompt 必填。文生视频省略 image_urls;图生视频传 1–7 个公网 HTTP(S) 图片 URL;省略 type 时会自动推断。resolution 为 480p 或 720p(默认),duration 为 6–15 秒(默认 6)。
curl --fail-with-body --silent --show-error \
-X POST https://api.wizzx.ai/api/v1/task/submit/grok-imagine-video-1.5 \
-H "Authorization: Bearer <api_key>" \
-H "Content-Type: application/json" \
--data '{
"prompt": "黄金时刻,海浪拍打灯塔",
"aspect_ratio": "16:9",
"resolution": "720p",
"duration": 6
}'
/pricing 为准。授权
Wizzx API key. This is not a JWT.
请求体
application/json
type is optional and inferred from image_urls: none means text-to-video, 1-7 images means image-to-video. With reference images the output follows the reference image's aspect ratio. Billed per second by resolution; reference images are not billed.
Minimum string length:
1可用选项:
text-to-video, image-to-video Maximum array length:
7Publicly reachable HTTP(S) URL.
Pattern:
^https?://可用选项:
16:9, 9:16, 1:1, 3:2, 2:3 可用选项:
480p, 720p 必填范围:
6 <= x <= 15此页面对您有帮助吗?
