Grok Task Query
curl --request GET \
--url https://zx1.deepwl.net/v1/videos/{task_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"task_id": "<string>"
}
'import requests
url = "https://zx1.deepwl.net/v1/videos/{task_id}"
payload = { "task_id": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.get(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({task_id: '<string>'})
};
fetch('https://zx1.deepwl.net/v1/videos/{task_id}', 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://zx1.deepwl.net/v1/videos/{task_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_POSTFIELDS => json_encode([
'task_id' => '<string>'
]),
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://zx1.deepwl.net/v1/videos/{task_id}"
payload := strings.NewReader("{\n \"task_id\": \"<string>\"\n}")
req, _ := http.NewRequest("GET", 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.get("https://zx1.deepwl.net/v1/videos/{task_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"task_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://zx1.deepwl.net/v1/videos/{task_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"task_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "video_abc123",
"object": "video",
"model": "grok-video-3",
"status": "processing",
"progress": 42,
"created_at": 1735689600,
"completed_at": 0,
"expires_at": 1735776000,
"seconds": "6",
"size": "720P",
"remixed_from_video_id": "",
"error": {
"message": "",
"code": ""
},
"video_url": ""
}
{
"id": "video_abc123",
"object": "video",
"model": "grok-video-3",
"status": "completed",
"progress": 100,
"created_at": 1735689600,
"completed_at": 1735689900,
"expires_at": 1735776000,
"seconds": "6",
"size": "720P",
"remixed_from_video_id": "",
"error": {
"message": "",
"code": ""
},
"video_url": "https://example.com/video.mp4"
}
{
"id": "video_abc123",
"object": "video",
"model": "grok-video-3",
"status": "failed",
"progress": 100,
"created_at": 1735689600,
"completed_at": 1735689700,
"expires_at": 1735776000,
"seconds": "6",
"size": "720P",
"remixed_from_video_id": "",
"error": {
"message": "Content policy violation",
"code": "content_policy"
},
"video_url": ""
}
OpenAI Format
Grok Task Query
Query Grok video task progress, results, and error information using GET /v1/videos/{task_id}.
GET
https://zx1.deepwl.net
/
v1
/
videos
/
{task_id}
Grok Task Query
curl --request GET \
--url https://zx1.deepwl.net/v1/videos/{task_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"task_id": "<string>"
}
'import requests
url = "https://zx1.deepwl.net/v1/videos/{task_id}"
payload = { "task_id": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.get(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({task_id: '<string>'})
};
fetch('https://zx1.deepwl.net/v1/videos/{task_id}', 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://zx1.deepwl.net/v1/videos/{task_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_POSTFIELDS => json_encode([
'task_id' => '<string>'
]),
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://zx1.deepwl.net/v1/videos/{task_id}"
payload := strings.NewReader("{\n \"task_id\": \"<string>\"\n}")
req, _ := http.NewRequest("GET", 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.get("https://zx1.deepwl.net/v1/videos/{task_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"task_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://zx1.deepwl.net/v1/videos/{task_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"task_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "video_abc123",
"object": "video",
"model": "grok-video-3",
"status": "processing",
"progress": 42,
"created_at": 1735689600,
"completed_at": 0,
"expires_at": 1735776000,
"seconds": "6",
"size": "720P",
"remixed_from_video_id": "",
"error": {
"message": "",
"code": ""
},
"video_url": ""
}
{
"id": "video_abc123",
"object": "video",
"model": "grok-video-3",
"status": "completed",
"progress": 100,
"created_at": 1735689600,
"completed_at": 1735689900,
"expires_at": 1735776000,
"seconds": "6",
"size": "720P",
"remixed_from_video_id": "",
"error": {
"message": "",
"code": ""
},
"video_url": "https://example.com/video.mp4"
}
{
"id": "video_abc123",
"object": "video",
"model": "grok-video-3",
"status": "failed",
"progress": 100,
"created_at": 1735689600,
"completed_at": 1735689700,
"expires_at": 1735776000,
"seconds": "6",
"size": "720P",
"remixed_from_video_id": "",
"error": {
"message": "Content policy violation",
"code": "content_policy"
},
"video_url": ""
}
Grok Task Query
OpenAI-format query entry point. If the task was submitted viaPOST /v1/video/create, please use Query Task.
After a Grok series task is submitted, poll the status via GET /v1/videos/{task_id}.
- The API path is
GET /v1/videos/{task_id}. - After the task is completed, the result URL can usually be read from
video_urloroutput.url. - If directly downloading
video_urlfails, fall back toGET /v1/videos/{task_id}/content.
Method and Path
GET /v1/videos/{task_id}
Request Example
curl https://zx1.deepwl.net/v1/videos/video_abc123 \
-H "Authorization: Bearer YOUR_API_KEY"
import requests
resp = requests.get(
"https://zx1.deepwl.net/v1/videos/video_abc123",
headers={"Authorization": "Bearer YOUR_API_KEY"},
timeout=30,
)
print(resp.json())
const response = await fetch("https://zx1.deepwl.net/v1/videos/video_abc123", {
headers: {
Authorization: "Bearer YOUR_API_KEY",
},
});
console.log(await response.json());
Response Example
{
"id": "video_abc123",
"object": "video",
"model": "grok-video-3",
"status": "processing",
"progress": 42,
"created_at": 1735689600,
"completed_at": 0,
"expires_at": 1735776000,
"seconds": "6",
"size": "720P",
"remixed_from_video_id": "",
"error": {
"message": "",
"code": ""
},
"video_url": ""
}
{
"id": "video_abc123",
"object": "video",
"model": "grok-video-3",
"status": "completed",
"progress": 100,
"created_at": 1735689600,
"completed_at": 1735689900,
"expires_at": 1735776000,
"seconds": "6",
"size": "720P",
"remixed_from_video_id": "",
"error": {
"message": "",
"code": ""
},
"video_url": "https://example.com/video.mp4"
}
{
"id": "video_abc123",
"object": "video",
"model": "grok-video-3",
"status": "failed",
"progress": 100,
"created_at": 1735689600,
"completed_at": 1735689700,
"expires_at": 1735776000,
"seconds": "6",
"size": "720P",
"remixed_from_video_id": "",
"error": {
"message": "Content policy violation",
"code": "content_policy"
},
"video_url": ""
}
Authentication
Authorization: Bearer YOUR_API_KEY
Path Parameters
string
required
Video task ID.
Response
string
Task ID.
string
Task status. Common values include
processing, failed, and completed.integer
Progress percentage.
integer
Completion timestamp.
integer
Result expiration timestamp.
string
Output duration.
string
Output resolution tier.
string
Video URL. When completed, this field will be read first, or
output.url will be read for compatibility.object
Failure reason object.
Polling Recommendations
The implementation will obtain the result URL in the following order:output.urlvideo_urlurldetail.url
GET /v1/videos/{task_id}/content
Related APIs
⌘I