# Luma Ray 3.2 Image to Video

> Luma Ray 3.2 animates a source image into cinematic motion guided by a text prompt, preserving the starting frame's look while controlling resolution, duration, and seamless looping.


## Overview

- **Endpoint**: `https://fal.run/luma/agent/ray/v3.2/image-to-video`
- **Model ID**: `luma/agent/ray/v3.2/image-to-video`
- **Category**: image-to-video
- **Kind**: inference
**Tags**: stylized, transform, lipsync



## Pricing

For **5s** video your request will cost **$0.50** for **540p**, **$1** for **720p** and **$2** for **1080p**. For **10s**, **$1** at **540p**, **$2** at **720p** and **$4** at **1080p**. For **$1** you can run this model approximately **2** times (**540p/5s**).

For more details, see [fal.ai pricing](https://fal.ai/pricing).

## API Information

This model can be used via our HTTP API or more conveniently via our client libraries.
See the input and output schema below, as well as the usage examples.


### Input Schema

The API accepts the following input parameters:


- **`prompt`** (`string`, _required_):
  Text prompt describing the motion/scene to generate.
  - Examples: "Low-angle shot of a majestic tiger prowling through a snowy landscape, leaving paw prints on the white blanket."

- **`image_url`** (`string`, _required_):
  URL of the source image the video starts from.
  - Examples: "https://storage.googleapis.com/falserverless/gallery/example_inputs_liuyifei.png"

- **`aspect_ratio`** (`AspectRatioEnum`, _optional_):
  Aspect ratio of the generated video. Default value: `"16:9"`
  - Default: `"16:9"`
  - Options: `"3:1"`, `"2:1"`, `"21:9"`, `"16:9"`, `"4:3"`, `"3:2"`, `"1:1"`, `"3:4"`, `"2:3"`, `"9:16"`, `"1:2"`, `"1:3"`
  - Examples: "16:9"

- **`resolution`** (`ResolutionEnum`, _optional_):
  Resolution of the generated video (720p costs 2x, 1080p 4x). Default value: `"540p"`
  - Default: `"540p"`
  - Options: `"540p"`, `"720p"`, `"1080p"`

- **`duration`** (`DurationEnum`, _optional_):
  Duration of the generated video (10s costs 2x). Default value: `"5s"`
  - Default: `"5s"`
  - Options: `"5s"`, `"10s"`

- **`loop`** (`boolean`, _optional_):
  Whether the video should loop seamlessly. Not supported for 10s videos.
  - Default: `false`

- **`reference_image_urls`** (`list<string>`, _optional_):
  Optional list of reference image URLs used to guide the generation.
  - Array of string



**Required Parameters Example**:

```json
{
  "prompt": "Low-angle shot of a majestic tiger prowling through a snowy landscape, leaving paw prints on the white blanket.",
  "image_url": "https://storage.googleapis.com/falserverless/gallery/example_inputs_liuyifei.png"
}
```

**Full Example**:

```json
{
  "prompt": "Low-angle shot of a majestic tiger prowling through a snowy landscape, leaving paw prints on the white blanket.",
  "image_url": "https://storage.googleapis.com/falserverless/gallery/example_inputs_liuyifei.png",
  "aspect_ratio": "16:9",
  "resolution": "540p",
  "duration": "5s"
}
```


### Output Schema

The API returns the following output format:

- **`video`** (`File`, _required_):
  The generated video.



**Example Response**:

```json
{
  "video": {
    "url": "",
    "content_type": "image/png",
    "file_name": "z9RV14K95DvU.png",
    "file_size": 4404019
  }
}
```


## Usage Examples

### cURL

```bash
curl --request POST \
  --url https://fal.run/luma/agent/ray/v3.2/image-to-video \
  --header "Authorization: Key $FAL_KEY" \
  --header "Content-Type: application/json" \
  --data '{
     "prompt": "Low-angle shot of a majestic tiger prowling through a snowy landscape, leaving paw prints on the white blanket.",
     "image_url": "https://storage.googleapis.com/falserverless/gallery/example_inputs_liuyifei.png"
   }'
```

### Python

Ensure you have the Python client installed:

```bash
pip install fal-client
```

Then use the API client to make requests:

```python
import fal_client

def on_queue_update(update):
    if isinstance(update, fal_client.InProgress):
        for log in update.logs:
           print(log["message"])

result = fal_client.subscribe(
    "luma/agent/ray/v3.2/image-to-video",
    arguments={
        "prompt": "Low-angle shot of a majestic tiger prowling through a snowy landscape, leaving paw prints on the white blanket.",
        "image_url": "https://storage.googleapis.com/falserverless/gallery/example_inputs_liuyifei.png"
    },
    with_logs=True,
    on_queue_update=on_queue_update,
)
print(result)
```

### JavaScript

Ensure you have the JavaScript client installed:

```bash
npm install --save @fal-ai/client
```

Then use the API client to make requests:

```javascript
import { fal } from "@fal-ai/client";

const result = await fal.subscribe("luma/agent/ray/v3.2/image-to-video", {
  input: {
    prompt: "Low-angle shot of a majestic tiger prowling through a snowy landscape, leaving paw prints on the white blanket.",
    image_url: "https://storage.googleapis.com/falserverless/gallery/example_inputs_liuyifei.png"
  },
  logs: true,
  onQueueUpdate: (update) => {
    if (update.status === "IN_PROGRESS") {
      update.logs.map((log) => log.message).forEach(console.log);
    }
  },
});
console.log(result.data);
console.log(result.requestId);
```


## Additional Resources

### Documentation

- [Model Playground](https://fal.ai/models/luma/agent/ray/v3.2/image-to-video)
- [API Documentation](https://fal.ai/models/luma/agent/ray/v3.2/image-to-video/api)
- [OpenAPI Schema](https://fal.ai/api/openapi/queue/openapi.json?endpoint_id=luma/agent/ray/v3.2/image-to-video)

### fal.ai Platform

- [Platform Documentation](https://docs.fal.ai)
- [Python Client](https://docs.fal.ai/clients/python)
- [JavaScript Client](https://docs.fal.ai/clients/javascript)
