# Overview

> diffusr makes ad videos, images and music. Call it from code, or let your AI agent do it. This page is the map.

## What you can make

| Tool | Makes |
| --- | --- |
| `make_video` | A video clip from a prompt, with optional pictures and voice clips |
| `make_image` | An image from a prompt |
| `edit_image` | A changed copy of a picture |
| `recast` | The same clip with a different person or place |
| `make_music` | A song, about a minute |
| `creator_video` | A video of a creator saying your script (gated preview) |
| `run_template` | A ready-made recipe as one job: product ad, video template, talking head, podcast |

Every tool is a REST route and an MCP tool with the same name, the same JSON and the same results.

## The loop every call follows

1. **Price it, free.** Add `"dry_run": true`. Nothing is made, nothing is spent. The answer has the price in credits (1 credit = $0.01) and holds for an hour.
2. **Start it.** Send the same call without `dry_run`, with an `Idempotency-Key` header so a retry never pays twice. You get a job `id` at once.
3. **Wait or be told.** Poll `GET /results/{id}` every 15 to 30 seconds, or pass `callback_url` and we send one signed event when it ends.
4. **Take the file.** When `status` is `SUCCEEDED`, `output.url` is the file.

You are charged when the result is delivered, never more than the price you saw. A failed job costs nothing.

**cURL**

```bash
curl -X POST https://app.diffusr.ai/api/v2/make_video \
  -H "Authorization: Bearer $DIFFUSR_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
  "prompt": "A woman turns to camera on a sunny street, smiles",
  "model": "seedance-2-0-fast",
  "resolution": "720p",
  "duration_sec": 5,
  "aspect_ratio": "9:16",
  "dry_run": true
}'
```

**TypeScript**

```ts
import { Diffusr } from "diffusr";

const d = new Diffusr(); // reads DIFFUSR_KEY
const job = await d.makeVideo({
  prompt: "A woman turns to camera on a sunny street, smiles",
  model: "seedance-2-0-fast",
  resolution: "720p",
  duration_sec: 5,
  aspect_ratio: "9:16",
  dry_run: true,
});
console.log(job); // the price, nothing was made
```

**Python**

```python
from diffusr import Diffusr

d = Diffusr()  # reads DIFFUSR_KEY
job = d.make_video(
    prompt="A woman turns to camera on a sunny street, smiles",
    model="seedance-2-0-fast",
    resolution="720p",
    duration_sec=5,
    aspect_ratio="9:16",
    dry_run=True,
)
print(job)  # the price, nothing was made
```

## Keys

- `dfsr_live_...` runs for real and spends credits.
- `dfsr_test_...` is free: real prices, fake results, nothing charged. Build with this one. See [Test keys](https://diffusr.ai/docs/test-keys).

Make keys on the **Developers** page in the app: https://app.diffusr.ai/developers

## Where to go next

- [Quickstart](https://diffusr.ai/docs/quickstart): key, price, start, result, in five minutes.
- [Prices](https://diffusr.ai/docs/prices): per second and per image, next to other services.
- [Callbacks](https://diffusr.ai/docs/callbacks), [Errors](https://diffusr.ai/docs/errors), [Limits](https://diffusr.ai/docs/limits), [Uploads and media](https://diffusr.ai/docs/uploads), [Templates](https://diffusr.ai/docs/templates).
- [All routes](https://diffusr.ai/docs/reference): one page per route.
- [MCP and skills](https://diffusr.ai/docs/mcp-and-skills): connect an AI agent.

## For AI agents

Every page here has a plain Markdown twin: add `.md` to the address (`/docs/quickstart.md`). The index is [llms.txt](https://diffusr.ai/docs/llms.txt); everything in one file is [llms-full.txt](https://diffusr.ai/docs/llms-full.txt); the OpenAPI 3.1 spec is https://app.diffusr.ai/api/v2/openapi.json.

Source: https://diffusr.ai/docs
