# Api18.dev — Centaurus 1.0 — Text to Video (LLM-ready) You are integrating the "centaurus-1.0-text-to-video" model from Api18.dev, a REST API for AI media generation. Use ONLY the parameters documented here. All requests are JSON over HTTPS. ## Endpoint & auth - Base URL: https://api18.dev - Easiest: POST https://api18.dev/v1/generate?wait=true (routes by model, waits, returns the finished job) - Also works: POST /v1/video/generations - Auth header: Authorization: Bearer api18_xxxxxxxxxxxxxxxx - Output type: video - Pricing: $0.20/s @ 720p · $0.30/s @ 1080p (× duration) - Cinematic text-to-video with crisp detail, stable motion and strong instruction-following. 720p/1080p, multiple aspect ratios, 2–15s clips. ## Flow Recommended (one call, no polling): POST to /v1/generate?wait=true with the body below; the response is the finished job and the output is at data[0].url. Async alternative: POST without ?wait=true, then poll GET /v1/jobs/{id} every ~3s until status is completed or failed; read data[].url. Files are temporary. ## Parameters - `model` · string · REQUIRED — The model id. Options: "centaurus-1.0-text-to-video". - `prompt` · string · REQUIRED — What to generate. Max 2500 characters. - `resolution` · string · optional — Output resolution. Options: 720p, 1080p. Default: 720p. - `aspect_ratio` · string · optional — Frame shape. Options: 16:9, 9:16, 1:1, 4:3, 3:4. Default: 16:9. - `duration` · integer · optional — Clip length in seconds. Options: 2–15. Default: 5. - `seed` · integer · optional — Reproducible results. Omit for a random seed. - `negative_prompt` · string · optional — Things to avoid in the output. - `enable_prompt_expansion` · boolean · optional — Auto-expand a short prompt into a richer script. Default: false. ## Request body { "model": "centaurus-1.0-text-to-video", "prompt": "A cinematic shot of a city street at night, neon reflections on wet pavement, slow dolly-in", "resolution": "720p", "aspect_ratio": "16:9", "duration": 5 } ## curl curl -X POST "https://api18.dev/v1/generate?wait=true" \ -H "Authorization: Bearer $API18_KEY" \ -H "Content-Type: application/json" \ -d '{"model":"centaurus-1.0-text-to-video","prompt":"A cinematic shot of a city street at night, neon reflections on wet pavement, slow dolly-in","resolution":"720p","aspect_ratio":"16:9","duration":5}' # → returns the finished job; the output URL is at .data[0].url ## JavaScript const res = await fetch("https://api18.dev/v1/generate?wait=true", { method: "POST", headers: { Authorization: `Bearer ${process.env.API18_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ "model": "centaurus-1.0-text-to-video", "prompt": "A cinematic shot of a city street at night, neon reflections on wet pavement, slow dolly-in", "resolution": "720p", "aspect_ratio": "16:9", "duration": 5 }), }); const job = await res.json(); console.log(job.data[0].url); // the generated video ## Python import os, requests KEY = os.environ["API18_KEY"] job = requests.post( "https://api18.dev/v1/generate?wait=true", headers={"Authorization": f"Bearer {KEY}"}, json={'model': "centaurus-1.0-text-to-video", 'prompt': "A cinematic shot of a city street at night, neon reflections on wet pavement, slow dolly-in", 'resolution': "720p", 'aspect_ratio': "16:9", 'duration': 5}, ).json() print(job["data"][0]["url"]) # the generated video ## Job response shape { "id", "object": "generation", "model", "output_kind", "status", "created_at", "completed_at", "expires_at", "retention_days", "error", "cost_usd", "input", "timings": { "inference_ms" }, "urls": { "get" }, "data": [ { "url" } ] } ## Errors (JSON: { error: { type, message } }) - 401 invalid_api_key · 400 invalid_request · 402 insufficient_balance - 402 paid_balance_required (promo credit can't be used on the API; add paid balance) - 404 model_not_found / job_not_found · 502 generation_unavailable (retry)