---
agent:
  instructions: "Use this search API to find relevant Cook Studio content (product, pricing, FAQ, blog articles, example videos) with keywords or natural-language queries instead of crawling pages. Results are returned in Markdown."
  endpoint: "https://cookstudio.ai/.well-known/search?q={query}"
  method: "GET"
  documentation: "https://developers.cloudflare.com/ai-search/how-to/search-for-agents/"
title: "Generations"
description: "One model, one output: a video clip, an image, a voiceover or a music track."
---
# Generations

One model, one output. Use it for a single clip, image, voiceover or track; use [Videos](https://cookstudio.ai/docs/videos) for a finished, edited video.

```bash
curl https://app.cookstudio.ai/api/v1/generations -H "Authorization: Bearer $KEY" -H "Content-Type: application/json" \
  -d '{"model": "gpt-image-25", "prompt": "A red fox in fresh snow, golden hour", "aspect_ratio": "16:9"}'
# → 201 {"id": "a91e…", "status": "running", "credits": 3, …}

curl https://app.cookstudio.ai/api/v1/generations/a91e… -H "Authorization: Bearer $KEY"                  # → "status": "done"
curl -o fox.png https://app.cookstudio.ai/api/v1/generations/a91e…/file -H "Authorization: Bearer $KEY"
```

## By type

| Type | Measure | Models |
| --- | --- | --- |
| Video clip | `seconds` + required start frame `image` | 7 |
| Image | `count` | 17 |
| Voiceover | characters of `prompt` | 9 |
| Music | `seconds` | 4 |

Every model's allowed values are on its page under [Models](https://cookstudio.ai/docs/models).

## Start frames

Video models animate a start image. Send it inline, raw base64 without a `data:` prefix, image/png, image/jpeg, image/webp, about 150 KB at most (the whole body must stay under 300 KB):

```json
{"model": "veo-31", "prompt": "Slow dolly-in, waves crashing", "image": {"mime_type": "image/jpeg", "base64": "<raw base64, no data: prefix>"}}
```

## Results

Poll [`GET /generations/{id}`](https://cookstudio.ai/docs/reference/get-generation) every few seconds. Status: `running`, `done`, `failed`. A failed generation is refunded in full and `error_type` says whether the input, the model or our side failed.

Canonical: https://cookstudio.ai/docs/generations
