Create a signed video download URL
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({index: 1, ttl_seconds: 2})
};
fetch('https://api.phaseo.ai/v1/videos/{video_id}/download_url', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.phaseo.ai/v1/videos/{video_id}/download_url"
payload = {
"index": 1,
"ttl_seconds": 2
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)curl --request POST \
--url https://api.phaseo.ai/v1/videos/{video_id}/download_url \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"index": 1,
"ttl_seconds": 2
}
'package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.phaseo.ai/v1/videos/{video_id}/download_url"
payload := strings.NewReader("{\n \"index\": 1,\n \"ttl_seconds\": 2\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.phaseo.ai/v1/videos/{video_id}/download_url")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"index\": 1,\n \"ttl_seconds\": 2\n}")
.asString();<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.phaseo.ai/v1/videos/{video_id}/download_url",
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([
'index' => 1,
'ttl_seconds' => 2
]),
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;
}require 'uri'
require 'net/http'
url = URI("https://api.phaseo.ai/v1/videos/{video_id}/download_url")
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 \"index\": 1,\n \"ttl_seconds\": 2\n}"
response = http.request(request)
puts response.read_body{
"download_url": "<string>",
"expires_at": 123
}Video
Video download URL (Beta)
Issue a temporary signed download URL for a completed video generation.
POST
/
videos
/
{video_id}
/
download_url
Create a signed video download URL
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({index: 1, ttl_seconds: 2})
};
fetch('https://api.phaseo.ai/v1/videos/{video_id}/download_url', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.phaseo.ai/v1/videos/{video_id}/download_url"
payload = {
"index": 1,
"ttl_seconds": 2
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)curl --request POST \
--url https://api.phaseo.ai/v1/videos/{video_id}/download_url \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"index": 1,
"ttl_seconds": 2
}
'package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.phaseo.ai/v1/videos/{video_id}/download_url"
payload := strings.NewReader("{\n \"index\": 1,\n \"ttl_seconds\": 2\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.phaseo.ai/v1/videos/{video_id}/download_url")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"index\": 1,\n \"ttl_seconds\": 2\n}")
.asString();<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.phaseo.ai/v1/videos/{video_id}/download_url",
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([
'index' => 1,
'ttl_seconds' => 2
]),
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;
}require 'uri'
require 'net/http'
url = URI("https://api.phaseo.ai/v1/videos/{video_id}/download_url")
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 \"index\": 1,\n \"ttl_seconds\": 2\n}"
response = http.request(request)
puts response.read_body{
"download_url": "<string>",
"expires_at": 123
}Optional request fields let you choose:
The public video routes are currently mounted but temporarily disabled, so this route currently returns
501 not_implemented.ttl_secondsfor link lifetimedispositionasattachmentorinlineindexwhen a generation has multiple outputs
download_urlexpires_at
Authorizations
Bearer token authentication
Path Parameters
The ID of the video generation request.
Body
application/json
Last modified on May 19, 2026
Was this page helpful?
⌘I