Turn any text description into cinematic HD video with a single API call. Access Sora, Kling, and Veo models through one unified endpoint.
{
"model_slug": "kling-v2",
"prompt": "A golden sunset over the ocean, cinematic 4K",
"features_selected": {
"aspect_ratio": "16:9",
"duration": "5s"
}
}
// Response
{
"success": true,
"data": {
"task_id": "task_abc123",
"status": "processing",
"estimated_time": 120
}
}
Three simple steps to generate AI videos programmatically.
POST your text description and choose an AI model. Specify aspect ratio, duration, and style.
Use the task_id to check generation progress. Typical generation takes 60-180 seconds.
Once complete, receive a direct download URL for your HD video file.
import requests, time
API_KEY = "ak_your_key_here"
BASE = "https://mobileapi.aienvoy.dev/api/v1"
headers = {"X-API-Key": API_KEY}
# 1. Create video
resp = requests.post(f"{BASE}/content/text-to-video",
headers=headers,
json={
"model_slug": "kling-v2",
"prompt": "Aerial drone shot of a city at night"
}
)
task_id = resp.json()["data"]["task_id"]
# 2. Poll until done
while True:
status = requests.get(
f"{BASE}/content/status/TEXT-TO-VIDEO/{task_id}",
headers=headers
).json()
if status["data"]["status"] == "completed":
print(status["data"]["result_url"])
break
time.sleep(10)
const API_KEY = "ak_your_key_here";
const BASE = "https://mobileapi.aienvoy.dev/api/v1";
const headers = {
"X-API-Key": API_KEY,
"Content-Type": "application/json"
};
// 1. Create video
const res = await fetch(`${BASE}/content/text-to-video`, {
method: "POST",
headers,
body: JSON.stringify({
model_slug: "kling-v2",
prompt: "Aerial drone shot of a city at night"
})
});
const { data } = await res.json();
// 2. Poll until done
const poll = setInterval(async () => {
const s = await fetch(
`${BASE}/content/status/TEXT-TO-VIDEO/${data.task_id}`,
{ headers }
).then(r => r.json());
if (s.data.status === "completed") {
clearInterval(poll);
console.log(s.data.result_url);
}
}, 10000);
# Create text-to-video
curl -X POST \
https://mobileapi.aienvoy.dev/api/v1/content/text-to-video \
-H "X-API-Key: ak_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"model_slug": "kling-v2",
"prompt": "Aerial drone shot of a city at night"
}'
# Check status
curl https://mobileapi.aienvoy.dev/api/v1/content/status/TEXT-TO-VIDEO/task_abc123 \
-H "X-API-Key: ak_your_key_here"
$apiKey = "ak_your_key_here";
$base = "https://mobileapi.aienvoy.dev/api/v1";
$ch = curl_init("$base/content/text-to-video");
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-Key: $apiKey",
"Content-Type: application/json"
],
CURLOPT_POSTFIELDS => json_encode([
"model_slug" => "kling-v2",
"prompt" => "Aerial drone shot of a city at night"
])
]);
$response = json_decode(curl_exec($ch), true);
$taskId = $response["data"]["task_id"];
curl_close($ch);
Choose the best model for your use case. Query available models via GET /api/v1/content/models/TEXT-TO-VIDEO.
OpenAI's flagship video model. Best for photorealistic scenes and complex motion.
Highest QualityFast, high-quality generation with excellent character consistency and cinematic styling.
Best ValueGoogle DeepMind's video model. Excels at natural scenes and smooth transitions.
Fast Generation16:9, 9:16, 1:1, 4:3 — optimized for any platform from TikTok to YouTube.
Generate clips from 3 to 10+ seconds depending on the model selected.
Non-blocking API with task polling. Integrate into any workflow or queue system.
Up to 1080p video output ready for production use and social media publishing.
Calculate token costs before generation with the pricing endpoint.
Built-in safety filters ensure generated content meets platform guidelines.
Let users generate video content within your platform
Auto-generate product demo videos from descriptions
Create visual content for articles and reports at scale
Generate educational videos from lesson plans
Get your free API key and generate your first AI video in under 5 minutes.