Fhddos exposes Google’s Veo 3.1 video generation models through a simple async task API. Submit a prompt (and optionally one or more reference images), poll the returned task ID until generation completes, then download the video file. All requests authenticate with your Fhddos Bearer token — no Google Cloud credentials needed.
Set Up Your Environment
export BASE_URL="https://aiapi.fhddos.com"
export TOKEN="your-fhddos-token"
Available Models
| Model | Notes |
|---|
veo-3.1-generate-preview | Standard quality — best visual fidelity |
veo-3.1-fast-generate-preview | Fast generation — ideal for previewing and iteration |
Create a Video Task: POST /v1/videos
All video generation starts with a POST /v1/videos request. The endpoint returns a task object immediately; the actual video renders asynchronously.
Text-to-Video
curl -X POST "$BASE_URL/v1/videos" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"model": "veo-3.1-fast-generate-preview",
"prompt": "A cinematic shot of a lion walking through golden savanna at sunset, dramatic lighting",
"seconds": 6,
"size": "1280x720"
}'
Image-to-Video
Provide one reference image via URL or multipart file upload to anchor the first frame:
JSON (Image URL)
Multipart (File Upload)
curl -X POST "$BASE_URL/v1/videos" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"model": "veo-3.1-generate-preview",
"prompt": "Camera slowly zooms in, cinematic lighting",
"seconds": 6,
"size": "1280x720",
"input_reference": ["https://example.com/scene.jpg"]
}'
curl -X POST "$BASE_URL/v1/videos" \
-H "Authorization: Bearer $TOKEN" \
-F "model=veo-3.1-generate-preview" \
-F "prompt=Camera slowly zooms in, cinematic lighting" \
-F "seconds=6" \
-F "size=1280x720" \
-F "input_reference=@scene.jpg"
First-Frame and Last-Frame Interpolation
Supply two images to generate a smooth transition video between them:
curl -X POST "$BASE_URL/v1/videos" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"model": "veo-3.1-generate-preview",
"prompt": "Smooth cinematic transition between scenes",
"seconds": 6,
"size": "1280x720",
"input_reference": [
"https://example.com/first_frame.jpg",
"https://example.com/last_frame.jpg"
]
}'
Task Creation Response
{
"id": "video_abc123",
"object": "video",
"model": "veo-3.1-fast-generate-preview",
"status": "queued",
"progress": 0,
"created_at": 1761234567
}
Save the id — you’ll need it to poll for results and download the file.
Poll Task Status: GET /v1/videos/{id}
curl "$BASE_URL/v1/videos/{video_id}" \
-H "Authorization: Bearer $TOKEN"
Status Values
| Status | Meaning |
|---|
queued | Request accepted, waiting to start |
in_progress | Video is actively being generated |
completed | Video is ready to download |
failed | Generation failed — check error field |
Completed Task Response
{
"id": "video_abc123",
"object": "video",
"model": "veo-3.1-fast-generate-preview",
"status": "completed",
"progress": 100,
"video_url": "https://storage.example.com/video_abc123.mp4",
"seconds": 6,
"size": "1280x720"
}
Poll every 6–10 seconds to avoid rate limiting. Video generation typically takes 1–5 minutes. Set a maximum timeout of 10 minutes before treating the task as stuck.
Download the Video: GET /v1/videos/{id}/content
Once status is completed, download the video file directly through Fhddos:
curl -L "$BASE_URL/v1/videos/{video_id}/content" \
-H "Authorization: Bearer $TOKEN" \
-o output.mp4
The endpoint supports HTTP range requests, so you can resume partial downloads or stream specific byte ranges:
curl -L "$BASE_URL/v1/videos/{video_id}/content" \
-H "Authorization: Bearer $TOKEN" \
-H "Range: bytes=0-1048575" \
-o chunk.mp4
Request Parameters
| Parameter | Type | Required | Description |
|---|
model | string | ✅ | Model name |
prompt | string | ✅ | Text description of the video |
seconds | integer or string | ❌ | Duration: 4, 6, or 8 (default 6) |
size | string | ❌ | Resolution — see table below |
input_reference | array of strings | ❌ | Reference image URLs (1–3 images) |
Resolution Options
| Resolution | Aspect Ratio | Notes |
|---|
1280x720 | 16:9 landscape | 720p — default |
720x1280 | 9:16 portrait | 720p |
1920x1080 | 16:9 landscape | 1080p — requires seconds: 8 |
1080x1920 | 9:16 portrait | 1080p — requires seconds: 8 |
1080p resolution is only available for 8-second videos. Requesting 1080p with a shorter duration will return a validation error.
Best Practices
- Write specific prompts — describe the scene, camera motion, and lighting explicitly for better results.
- Match reference image orientation — use portrait images for
9:16 output and landscape for 16:9.
- Use the fast model for iteration — prototype with
veo-3.1-fast-generate-preview, then switch to the standard model for final renders.
- Handle
video_url expiry — if the direct URL expires, re-fetch the task to get a refreshed link, or use GET /v1/videos/{id}/content which always resolves through Fhddos.