Overview
Retrieves the current status of a download job. When completed, includes a presigned S3 URL for downloading the file.
Your API key for authentication
Path Parameters
The job UUID returned from POST /jobs
Response
Job status: Pending, Processing, Completed, or Failed
Presigned download URL (only when Completed)
Presigned URL for subtitles (if available)
Error message (only when Failed)
Current processing step: Queued, Downloading, Muxing, Uploading, Finished
Examples
curl -X GET "https://api.tornadoapi.io/jobs/550e8400-e29b-41d4-a716-446655440000" \
-H "x-api-key: sk_your_api_key"
Status Values
| Status | Description |
|---|
Pending | Job is in queue, waiting to be processed |
Processing | Job is actively being downloaded/processed |
Completed | Job finished successfully |
Failed | Job encountered an error |
Processing Steps
| Step | Description |
|---|
Queued | Waiting in queue |
Downloading | Downloading video/audio streams |
Muxing | Combining streams with FFmpeg |
Uploading | Uploading to S3 |
Finished | Complete |
Polling Example
import requests
import time
def wait_for_job(job_id, api_key, timeout=600):
start = time.time()
while time.time() - start < timeout:
response = requests.get(
f"https://api.tornadoapi.io/jobs/{job_id}",
headers={"x-api-key": api_key}
)
data = response.json()
print(f"Status: {data['status']} - {data.get('step', 'N/A')}")
if data["status"] == "Completed":
return data["s3_url"]
elif data["status"] == "Failed":
raise Exception(f"Job failed: {data['error']}")
time.sleep(3)
raise Exception("Timeout waiting for job")
Success Response
{
"id": "550e8400-e29b-41d4-a716-446655440000",
"url": "https://youtube.com/watch?v=dQw4w9WgXcQ",
"status": "Completed",
"s3_url": "https://cdn.example.com/videos/video.mp4?X-Amz-Algorithm=...",
"subtitle_url": null,
"error": null,
"step": "Finished"
}
Error Responses
The presigned s3_url is valid for 24 hours. Download the file before it expires.