引言
2026 年视频生成 API 的门槛已大幅下降。从 Runway 到可灵(Kling),从开源 CogVideoX 到云端 Stable Video Diffusion,免费层已能产出可用的短视频片段。本文盘点当前可免费调用的视频生成服务,覆盖文生视频、图生视频、视频编辑三大场景,给出端点、配额与选型建议。
主要方案
| 服务 |
端点/方式 |
文生视频 |
图生视频 |
免费配额 |
| Runway Gen-3 Alpha |
api.runwayml.com/v1 |
✅ |
✅ |
125 credits/月(约3-5段) |
| 可灵 Kling |
api.klingai.com/v1/videos |
✅ |
✅ |
每日66点,约5段 |
| CogVideoX |
HuggingFace / 自部署 |
✅ |
❌ |
开源,HF 免费推理 |
| Stable Video Diffusion |
Replicate / fal.ai |
❌ |
✅ |
Replicate 免费层 |
| Pika |
api.pika.art/v1 |
✅ |
✅ |
每日免费生成额度 |
| Luma Dream Machine |
api.lumalabs.ai |
✅ |
✅ |
30 generations/月 |
调用示例:可灵 Kling
import requests, time
KLING_KEY = "your-api-key"
headers = {"Authorization": f"Bearer {KLING_KEY}", "Content-Type": "application/json"}
# 文生视频
resp = requests.post("https://api.klingai.com/v1/videos/text2video", headers=headers, json={
"model_name": "kling-v1",
"prompt": "一只橘猫在窗台上打哈欠,阳光透过窗帘洒在它身上,电影感",
"duration": "5",
"mode": "std"
})
task_id = resp.json()["data"]["task_id"]
# 轮询结果
while True:
r = requests.get(f"https://api.klingai.com/v1/videos/text2video/{task_id}", headers=headers)
status = r.json()["data"]["task_status"]
if status == "succeed":
video_url = r.json()["data"]["task_result"]["videos"][0]["url"]
break
time.sleep(3)
print(f"Video ready: {video_url}")
调用示例:Runway Gen-3
import requests
resp = requests.post("https://api.runwayml.com/v1/generate", headers={
"Authorization": "Bearer key-xxx",
"Content-Type": "application/json"
}, json={
"mode": "gen3a_turbo",
"prompt": "Aerial drone shot of a futuristic city at sunset, cinematic",
"duration": 5,
"watermark": False
})
task = resp.json()
print(f"Task ID: {task['id']} — poll for result")
开源自部署:CogVideoX
# 用 diffusers 本地运行 CogVideoX-5B(需 24GB+ VRAM)
pip install diffusers transformers accelerate
python -c "
from diffusers import CogVideoXPipeline
import torch
pipe = CogVideoXPipeline.from_pretrained(
'THUDM/CogVideoX-5b', torch_dtype=torch.bfloat16
).to('cuda')
# 启用 VAE 切片节省显存
pipe.vae.enable_slicing()
video = pipe(
prompt='a panda playing guitar on a beach, cinematic',
num_frames=49, guidance_scale=6.0
).frames[0]
"
选型建议
- 快速原型/中文场景:可灵 Kling 中文理解最好,每日免费额度充足。
- 英文/国际化:Runway Gen-3 品质最高,但免费配额较少。
- 完全免费/可定制:CogVideoX 开源自部署,零 API 成本,但需要 GPU。
- 图生视频:Stable Video Diffusion 在 Replicate 上免费可用,适合将静态图转动态。
- 视频编辑/风格化:Pika 和 Luma 均有免费层,适合添加特效、风格迁移。
注意事项
- 生成时间:视频生成通常需要 30 秒到 5 分钟,务必用异步轮询模式。
- 水印:免费层多数带水印,商用需付费去水印。
- 分辨率:免费层通常 720p 以下,付费层可达 1080p/4K。
- NSFW 审核:所有平台均有严格的内容审核,prompt 避免敏感词。
- 成本控制:自部署 CogVideoX 需 GPU 成本,但无 API 调用次数限制。
Introduction
The barrier to video generation APIs has dropped dramatically in 2026. From Runway to Kling, from open-source CogVideoX to cloud-hosted Stable Video Diffusion, free tiers can now produce usable short video clips. This article surveys the free-callable video generation services, covering text-to-video, image-to-video, and video editing across three scenarios, with endpoints, quotas, and selection guidance.
Major Options
| Service |
Endpoint/Method |
Text-to-Video |
Image-to-Video |
Free Quota |
| Runway Gen-3 Alpha |
api.runwayml.com/v1 |
✅ |
✅ |
125 credits/month (~3-5 clips) |
| Kling |
api.klingai.com/v1/videos |
✅ |
✅ |
66 points/day, ~5 clips |
| CogVideoX |
HuggingFace / self-host |
✅ |
❌ |
Open source, free HF inference |
| Stable Video Diffusion |
Replicate / fal.ai |
❌ |
✅ |
Replicate free tier |
| Pika |
api.pika.art/v1 |
✅ |
✅ |
Daily free generations |
| Luma Dream Machine |
api.lumalabs.ai |
✅ |
✅ |
30 generations/month |
Call Example: Kling
import requests, time
KLING_KEY = "your-api-key"
headers = {"Authorization": f"Bearer {KLING_KEY}", "Content-Type": "application/json"}
# Text-to-video
resp = requests.post("https://api.klingai.com/v1/videos/text2video", headers=headers, json={
"model_name": "kling-v1",
"prompt": "An orange cat yawning on a windowsill, sunlight filtering through curtains, cinematic",
"duration": "5",
"mode": "std"
})
task_id = resp.json()["data"]["task_id"]
# Poll for result
while True:
r = requests.get(f"https://api.klingai.com/v1/videos/text2video/{task_id}", headers=headers)
status = r.json()["data"]["task_status"]
if status == "succeed":
video_url = r.json()["data"]["task_result"]["videos"][0]["url"]
break
time.sleep(3)
print(f"Video ready: {video_url}")
Call Example: Runway Gen-3
import requests
resp = requests.post("https://api.runwayml.com/v1/generate", headers={
"Authorization": "Bearer key-xxx",
"Content-Type": "application/json"
}, json={
"mode": "gen3a_turbo",
"prompt": "Aerial drone shot of a futuristic city at sunset, cinematic",
"duration": 5,
"watermark": False
})
task = resp.json()
print(f"Task ID: {task['id']} — poll for result")
Open-Source Self-Hosted: CogVideoX
# Run CogVideoX-5B locally with diffusers (needs 24GB+ VRAM)
pip install diffusers transformers accelerate
python -c "
from diffusers import CogVideoXPipeline
import torch
pipe = CogVideoXPipeline.from_pretrained(
'THUDM/CogVideoX-5b', torch_dtype=torch.bfloat16
).to('cuda')
pipe.vae.enable_slicing()
video = pipe(
prompt='a panda playing guitar on a beach, cinematic',
num_frames=49, guidance_scale=6.0
).frames[0]
"
Selection Guidance
- Quick prototypes / Chinese prompts: Kling has the best Chinese understanding and generous daily free quota.
- English / international: Runway Gen-3 delivers the highest quality, but free quota is limited.
- Fully free / customizable: CogVideoX is open-source and self-hostable with zero API cost, but requires a GPU.
- Image-to-video: Stable Video Diffusion is free on Replicate, ideal for animating static images.
- Video editing / stylization: Pika and Luma both offer free tiers for adding effects and style transfer.
Caveats
- Generation time: Video generation typically takes 30 seconds to 5 minutes. Always use async polling.
- Watermarks: Free tiers usually include watermarks; commercial use requires paid de-watermarking.
- Resolution: Free tiers are usually under 720p; paid tiers reach 1080p/4K.
- NSFW filtering: All platforms enforce strict content moderation. Avoid sensitive terms in prompts.
- Cost control: Self-hosting CogVideoX incurs GPU cost but has no API call limits.