Add AI video generation to a Next.js app: route handlers, spend caps, polling and webhooks
Keep the key on the server, stop strangers from draining your balance, and show the finished clip without a long-running request.
Keep the key on the server, stop strangers from draining your balance, and show the finished clip without a long-running request.
Upload, quote the whole batch, confirm, generate in parallel, and re-run safely without paying twice. Seedance 2.5, Kling 4.0 or Wan 3.0.
A Seedance 2.5 / Kling / Wan / Veo workflow with a budget check, safe retries, and either polling or a webhook resume.
Routing, retries, idempotency keys, and only paying for generations that succeed.
Same models, same settings, five places to buy them. Prices checked 2026-11-05.
One key, one request shape, cheapest route first, and failed generations cost nothing