---
title: "Generate a video from a prompt"
description: "Run job:video.generate through the looot API: 1 provider, from $0.5 per result. Inputs, prices, output shape and code for curl, JavaScript and Python."
sidebar:
  hidden: true
---

{/* Generated by scripts/generate-api-reference.mjs from data/api-reference.json. Do not edit. */}

Generate a video from a prompt.

Job id `video.generate`, in Generative AI (Media generation). As of 2026-10-01, 1 provider serve it through 1 tool. Run `job:video.generate` and looot picks one of them; with `fallback` on, a miss moves on to the next. See [Jobs](/concepts/jobs).

## Inputs

This job has one tool, so it takes that tool's fields. Any key you send passes through unchanged.

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `input` | object | yes | The model's input as a JSON object. The input schema depends on what model you are running. To see the available inputs, click the "API" tab on the model you are running or get the model version and look at its `openapi_schema` property. For example, [stability-ai/sdxl](https://replicate.com/stability-ai/sdxl) takes `prompt` as an input. Files should be passed as HTTP URLs or data URLs. Use an HTTP URL when: - you have a large file &gt; 256kb - you want to be able to use... |
| `stream` | boolean | no | **This field is deprecated.** Request a URL to receive streaming output using [server-sent events (SSE)](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events). This field is no longer needed as the returned prediction will always have a `stream` entry in its `urls` property if the model supports streaming. |
| `webhook` | string | no | An HTTPS URL for receiving a webhook when the prediction has new output. The webhook will be a POST request where the request body is the same as the response body of the get prediction operation. If there are network problems, we will retry the webhook a few times, so make sure it can be safely called more than once. Replicate will not follow redirects when sending webhook requests to your service, so be sure to specify a... |
| `webhook_events_filter` | array | no | By default, we will send requests to your webhook URL whenever there are new outputs or the prediction has finished. You can change which events trigger webhook requests by specifying `webhook_events_filter` in the prediction request: - `start`: immediately on prediction start - `output`: each time a prediction generates an output (note that predictions can generate multiple outputs) - `logs`: each time log output is generated by a prediction - `completed`: when the prediction reaches a termi... |
| `model_name` | string | yes | Official model to run: minimax/video-01 ($0.5 per output video). |
| `model_owner` | string | yes | Owner of the official model. |

## Providers and prices

| Provider | Tool | Price |
| --- | --- | --- |
| [Replicate HTTP API](/providers/replicate) | [`replicate-video-generate`](/reference/tools/replicate-video-generate) | $0.5 per result |

A call that fails at the provider costs $0. See [What's free](/money/free-and-failures).

## Output

The run's `result` holds the provider's answer. Signed in, `looot inspect replicate-video-generate` prints its fields.

## Run it

Every call needs your API token in `LOOOT_TOKEN`; [Sign in](/get-started/sign-in#use-the-token-in-scripts-and-agents) shows how to get one. Each run also needs a new idempotency key, so a retry never pays twice. With `wait: 30` the answer comes back inline when the run ends within 30 seconds. Otherwise you get the running run back: poll `GET /v1/runs/<runId>`.

Example input with placeholder values:

<CodeGroup>

```bash curl
curl -X POST "https://api.looot.ai/v1/runs" \
  -H "Authorization: Bearer $LOOOT_TOKEN" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"endpointId":"job:video.generate","input":{"model_owner":"<model_owner>","model_name":"<model_name>","input":{"prompt":"Tell me a joke","system_prompt":"You are a helpful assistant"},"webhook":"https://example.com/webhook","webhook_events_filter":["https://example.com/webhook","https://example.com/webhook"]},"wait":30}'
```

```js JavaScript
const response = await fetch("https://api.looot.ai/v1/runs", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.LOOOT_TOKEN}`,
    "Content-Type": "application/json",
    "Idempotency-Key": crypto.randomUUID(),
  },
  body: JSON.stringify({
    endpointId: "job:video.generate",
    input: {
      model_owner: "<model_owner>",
      model_name: "<model_name>",
      input: {
        prompt: "Tell me a joke",
        system_prompt: "You are a helpful assistant",
      },
      webhook: "https://example.com/webhook",
      webhook_events_filter: ["https://example.com/webhook", "https://example.com/webhook"],
    },
    wait: 30,
  }),
});
const run = await response.json();
console.log(run.status, run.result);
```

```python Python
import os
import uuid

import requests

response = requests.post(
    "https://api.looot.ai/v1/runs",
    headers={
        "Authorization": f"Bearer {os.environ['LOOOT_TOKEN']}",
        "Idempotency-Key": str(uuid.uuid4()),
    },
    json={
        "endpointId": "job:video.generate",
        "input": {
            "model_owner": "<model_owner>",
            "model_name": "<model_name>",
            "input": {
                "prompt": "Tell me a joke",
                "system_prompt": "You are a helpful assistant",
            },
            "webhook": "https://example.com/webhook",
            "webhook_events_filter": ["https://example.com/webhook", "https://example.com/webhook"],
        },
        "wait": 30,
    },
    timeout=90,
)
run = response.json()
print(run["status"], run.get("result"))
```

</CodeGroup>

To pin one provider, send its tool id as `endpointId` instead of `job:video.generate`.
