DEV Community

Xinyue Zhan
Xinyue Zhan

Posted on

The cloud studio asks for 'format' as a JSON object

#ai

On a review call I showed a colleague how I get output formats, durations and limits out of the video services we depend on, without keeping two browser tabs open for the whole afternoon. These are the checks I run from a shell.

What you can pull from each service

  • Output format and resolution. The CDN URLs in the model metadata usually carry the codec and dimensions, for example a video.mp4 with a Content-Type of video/mp4 and a resolution in the filename. The model listing rarely shows it, so extract the URL and read the headers.
  • Duration and frame count. When there is an ffprobe-friendly URL, ffprobe -v error -show_entries format=duration -of csv=p=0 <url> takes a second and is the only number I trust across providers.
  • Limits. Most services return their limits in a short 429 body or a rate-limit header. Capture the raw response once instead of retrying blindly; a steady cadence of timed calls invites throttling, so add a delay of a few seconds when you can.

A small runner

Keep one script that loops over a list of endpoints, and prints a table at the end:

for svc in kling4 seedance wan; do
  status=$(curl -s -o /tmp/$svc.json -w '%{http_code}' https://$svc.example/api/...)
  printf '%-10s %s\n' "$svc" "$status"
  sleep 3
done
Enter fullscreen mode Exit fullscreen mode

Run it from whatever your real account is, so the results describe what a customer sees, not what a test harness sees. For accounts with a dashboard, also check the usage page, because the API totals and the dashboard totals disagree more often than you would think.

Where the notes live

The wait times, the Korean-UI quirks and the per-model credits all end up in one markdown file, next to notes from the other services in github.com/barasel200-bit/uvicorn-teardown-notes, and I update it after every test run.

Why bother

The point is not to benchmark every service. It is to notice when a limit changes before a customer does, and to know which check to rerun after an upgrade. Ten minutes of shell work per month saved us twice this quarter already.

Top comments (0)