Quick context: I'm part of a small team building Viddra — a unified API that puts 20 AI video models behind one REST key: Kling 3.0, Veo 3.1, Hailuo 2.3, Wan 3.0, Seedance, LTX, and more. Same auth, same request shape, pay-as-you-go, no subscription.
Last week we open-sourced the example code we use internally. This post shows what's inside and how to get your first generated video in about 10 minutes.
What's in the repo
github.com/viddra001/viddra-examples
-
python_text_to_video.py— prompt → MP4, the full happy path -
python_image_to_video.py— first-frame image → animated video -
list_models.py— discover every available model and its price/speed tier at runtime -
node_quickstart.js— the same flow in Node, zero SDK installs -
quickstart.sh— raw curl, if you want to see one request end-to-end
No real keys anywhere — every script reads VIDDRA_API_KEY from the environment.
10-minute quickstart
- Grab a key at viddra.com — signup includes $1 in free credit, no card required
- Then:
git clone https://github.com/viddra001/viddra-examples
cd viddra-examples
export VIDDRA_API_KEY=your_key
python3 examples/python_text_to_video.py
The script polls the generation job, downloads the finished MP4 and prints where it saved. From here, swapping models is one parameter change — model: "kling-3.0" to model: "veo-3.1" and the rest of your code stays identical. That's the whole point of a unified API.
Pricing mental model
No subscription, no seats. You pay per generated second, and prices differ per model: community-tier models run from a few cents per clip, while flagship ones (Veo 3.1, Kling 3.0) cost more. viddra.com/pricing lists the live per-second prices for all 20 models, and list_models.py returns them programmatically if you'd rather check in code.
If you want to compare real outputs before wiring anything, the playground lets you try models with trial credits.
Deeper dives
If you prefer articles to code, we've written a few:
- Hailuo H3 vs Kling 3.0 benchmark — cheapest models, head to head
- Wan 3.0 walkthrough — pricing, features and a working Python example
- Full price table for 20 models — real pricing, working code, $1 free tier
Full disclosure: this is our product, and the repo is ours. Questions about pricing, models, or the API shape — ask in the comments, I'll answer.
Top comments (0)