Documentation Index

Fetch the complete documentation index at: https://cloudinary.com/documentation/llms.txt

Use this file to discover all available pages before exploring further.

v0.1.1OAS 3.0.3

Image to Video API (Beta)

Download OpenAPI Document

Use the Image to Video API to generate videos from images using AI, and to manage reusable prompts. You provide a source image and a text prompt describing the motion or scene, and Cloudinary generates a video and saves it to your product environment. See the Image to Video Add-on guide for the Console-based workflow.

The API supports Basic Authentication using your Cloudinary API Key and API Secret (which can be found in the API Keys page of your Cloudinary Console).

Note: The Image to Video API is currently in development and is available as a Public Beta — endpoints, parameters, and response payloads may change before the general access release. We value your feedback, so please feel free to share any thoughts with us.

Video Generate

Generate a video from an image and poll the generation job.

Create a video generation job

Submits an image and prompt for video generation and returns a job you can poll for the result.

Body Required application/json

A JSON object with the source image, prompt, and generation options.

ImageToVideoGeneratePayload
  • prompt stringRequired

    Video description prompt.

  • image_asset_id stringRequired

    Cloudinary asset ID of the input image for image-to-video generation.

  • aspect_ratio string

    Video aspect ratio. auto resolves based on image dimensions (defaults to landscape). 16:9 = landscape, 9:16 = portrait.

    default "auto"
    enum "auto" "16:9" "9:16"
  • resolution string

    Video resolution. 1080p is only supported with a duration of 8 seconds.

    default "720p"
    enum "720p" "1080p"
  • duration integer

    Video duration in seconds.

    default 8
    enum 4 6 8
  • generate_audio boolean

    Whether to generate audio. Enabling audio consumes twice as many credits.

    default false
  • enhance_prompt booleannullable

    Whether to let Cloudinary automatically enhance the prompt.

    default true
  • last_frame_image_asset_id string

    Cloudinary asset ID of the last frame image.

  • reference_image_asset_ids string[]

    Cloudinary asset IDs of reference images.

    max items 2

Responses

201 Video generation job created
application/json
ImageToVideoGenerateWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • data ImageToVideoGenerateResponseRequired
    ShowHide child attributes of data
    • job_id stringRequired
      example "550e8400e29b41d4a716446655440000"
    • status stringRequired
      example "pending"
      enum "pending" "completed" "failed"
    • asset_id string

      Cloudinary asset ID of the generated video (present when completed).

    • public_id string

      Cloudinary public ID of the generated video (present when completed).

    • resource_type string

      Cloudinary resource type of the generated video (present when completed).

    • delivery_type string

      Cloudinary delivery type of the generated video (present when completed).

    • url string

      HTTPS URL of the generated video (present when completed).

    • message string

      Error message when generation has failed.

400 Bad request - validation or safety error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
401 Authentication error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
500 Internal server error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
POST/image_to_video/generate
curl -X POST 'https://api.cloudinary.com/v2/video/CLOUD_NAME/image_to_video/generate' \
  -u 'API_KEY:API_SECRET' \
  -H 'Content-Type: application/json' \
  -d '{
  "prompt": "A serene beach at sunset with gentle waves rolling in",
  "image_asset_id": "0a1b2c3d4e5f60718293a4b5c6d7e8f9",
  "aspect_ratio": "16:9",
  "resolution": "1080p",
  "duration": 8,
  "generate_audio": true
}'
Response
{
  "request_id": "6ec0bd7f11c043da975e2a8ad9ebae0b",
  "data": {
    "job_id": "550e8400e29b41d4a716446655440000",
    "status": "pending"
  }
}

Poll a video generation job

Returns the current status of a generation job. When the status is completed, the response includes the generated video's asset details and delivery URL.

Path parameters

  • jobId stringRequired

    The video generation job ID returned from the create endpoint.

Responses

200 Job status (pending, completed, or failed)
application/json
ImageToVideoGenerateWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • data ImageToVideoGenerateResponseRequired
    ShowHide child attributes of data
    • job_id stringRequired
      example "550e8400e29b41d4a716446655440000"
    • status stringRequired
      example "pending"
      enum "pending" "completed" "failed"
    • asset_id string

      Cloudinary asset ID of the generated video (present when completed).

    • public_id string

      Cloudinary public ID of the generated video (present when completed).

    • resource_type string

      Cloudinary resource type of the generated video (present when completed).

    • delivery_type string

      Cloudinary delivery type of the generated video (present when completed).

    • url string

      HTTPS URL of the generated video (present when completed).

    • message string

      Error message when generation has failed.

401 Authentication error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
403 Authorization error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
404 Job not found
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
GET/image_to_video/generate/{jobId}
curl 'https://api.cloudinary.com/v2/video/CLOUD_NAME/image_to_video/generate/{jobId}' \
  -u 'API_KEY:API_SECRET'
Response
{
  "request_id": "6ec0bd7f11c043da975e2a8ad9ebae0b",
  "data": {
    "job_id": "550e8400e29b41d4a716446655440000",
    "status": "completed",
    "asset_id": "9f8e7d6c5b4a30291807a6b5c4d3e2f1",
    "public_id": "image-to-video/beach_sunset",
    "resource_type": "video",
    "delivery_type": "upload",
    "url": "https://res.cloudinary.com/demo/video/upload/v1/image-to-video/beach_sunset.mp4"
  }
}

Get a list of image to video prompts

Returns all saved image-to-video prompts for your product environment.

Responses

200 A list of image to video prompts
application/json
ImageToVideoPromptsWrappedResponse
  • request_id string
  • data ImageToVideoPromptResponse[]
    ShowHide child attributes of data
    Items ImageToVideoPromptResponse
    • id string
    • display_name string
    • prompt string
    • created_at integer
      format int64 Signed 64-bit integer
    • updated_at integer
      format int64 Signed 64-bit integer
400 Bad request
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
401 Authentication error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
500 Internal server error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
GET/image_to_video/prompts
curl 'https://api.cloudinary.com/v2/video/CLOUD_NAME/image_to_video/prompts' \
  -u 'API_KEY:API_SECRET'
Response
{
  "request_id": "6ec0bd7f11c043da975e2a8ad9ebae0b",
  "data": [
    {
      "id": "a1b2c3d4e5f6",
      "display_name": "Beach sunset",
      "prompt": "A serene beach at sunset with gentle waves rolling in",
      "created_at": 1781000000,
      "updated_at": 1781000000
    }
  ]
}

Create an image to video prompt

Saves a reusable prompt with a display name so you can apply it to future generations.

Body application/json

A JSON object with the prompt text and its display name.

ImageToVideoPromptCreatePayload
  • display_name stringRequired

    A human-readable name for the prompt.

    max length 255
  • prompt stringRequired

    The prompt text describing the motion or scene to generate.

    max length 1000

Responses

201 Created image to video prompt
application/json
ImageToVideoPromptWrappedResponse
  • request_id string
  • data ImageToVideoPromptResponse
    ShowHide child attributes of data
    • id string
    • display_name string
    • prompt string
    • created_at integer
      format int64 Signed 64-bit integer
    • updated_at integer
      format int64 Signed 64-bit integer
400 Bad request
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
401 Authentication error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
500 Internal server error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
POST/image_to_video/prompts
curl -X POST 'https://api.cloudinary.com/v2/video/CLOUD_NAME/image_to_video/prompts' \
  -u 'API_KEY:API_SECRET' \
  -H 'Content-Type: application/json' \
  -d '{
  "display_name": "Beach sunset",
  "prompt": "A serene beach at sunset with gentle waves rolling in"
}'
Response
{
  "request_id": "6ec0bd7f11c043da975e2a8ad9ebae0b",
  "data": {
    "id": "a1b2c3d4e5f6",
    "display_name": "Beach sunset",
    "prompt": "A serene beach at sunset with gentle waves rolling in",
    "created_at": 1781000000,
    "updated_at": 1781000000
  }
}

Get an image to video prompt

Returns a single saved prompt by its ID.

Path parameters

  • promptId stringRequired

    The ID of the image-to-video prompt.

Responses

200 An image to video prompt
application/json
ImageToVideoPromptWrappedResponse
  • request_id string
  • data ImageToVideoPromptResponse
    ShowHide child attributes of data
    • id string
    • display_name string
    • prompt string
    • created_at integer
      format int64 Signed 64-bit integer
    • updated_at integer
      format int64 Signed 64-bit integer
400 Bad request
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
401 Authentication error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
404 Not found
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
500 Internal server error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
GET/image_to_video/prompts/{promptId}
curl 'https://api.cloudinary.com/v2/video/CLOUD_NAME/image_to_video/prompts/{promptId}' \
  -u 'API_KEY:API_SECRET'
Response
{
  "request_id": "6ec0bd7f11c043da975e2a8ad9ebae0b",
  "data": {
    "id": "a1b2c3d4e5f6",
    "display_name": "Beach sunset",
    "prompt": "A serene beach at sunset with gentle waves rolling in",
    "created_at": 1781000000,
    "updated_at": 1781000000
  }
}

Delete an image to video prompt

Permanently deletes a saved prompt by its ID.

Path parameters

  • promptId stringRequired

    The ID of the image-to-video prompt.

Responses

200 Deleted
application/json
MessageWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • data objectRequired
    ShowHide child attributes of data
    • message string
400 Bad request
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
401 Authentication error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
404 Not found
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
500 Internal server error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
DEL/image_to_video/prompts/{promptId}
curl -X DELETE 'https://api.cloudinary.com/v2/video/CLOUD_NAME/image_to_video/prompts/{promptId}' \
  -u 'API_KEY:API_SECRET'
Response
{
  "request_id": "6ec0bd7f11c043da975e2a8ad9ebae0b",
  "data": {
    "message": "Prompt deleted"
  }
}

Update an image to video prompt

Updates the display name and/or prompt text of a saved prompt.

Path parameters

  • promptId stringRequired

    The ID of the image-to-video prompt.

Body application/json

A JSON object with the fields to update (display name and/or prompt text).

ImageToVideoPromptUpdatePayload
  • display_name stringnullable

    A human-readable name for the prompt.

    max length 255
  • prompt stringnullable

    The prompt text describing the motion or scene to generate.

    max length 1000

Responses

200 Updated image to video prompt
application/json
ImageToVideoPromptWrappedResponse
  • request_id string
  • data ImageToVideoPromptResponse
    ShowHide child attributes of data
    • id string
    • display_name string
    • prompt string
    • created_at integer
      format int64 Signed 64-bit integer
    • updated_at integer
      format int64 Signed 64-bit integer
400 Bad request
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
401 Authentication error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
404 Not found
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
500 Internal server error
application/json
ErrorWrappedResponse
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string
PATCH/image_to_video/prompts/{promptId}
curl -X PATCH 'https://api.cloudinary.com/v2/video/CLOUD_NAME/image_to_video/prompts/{promptId}' \
  -u 'API_KEY:API_SECRET' \
  -H 'Content-Type: application/json' \
  -d '{
  "display_name": "Beach sunset (golden hour)",
  "prompt": "A serene beach during golden hour with gentle waves"
}'
Response
{
  "request_id": "6ec0bd7f11c043da975e2a8ad9ebae0b",
  "data": {
    "id": "a1b2c3d4e5f6",
    "display_name": "Beach sunset (golden hour)",
    "prompt": "A serene beach during golden hour with gentle waves",
    "created_at": 1781000000,
    "updated_at": 1781009999
  }
}

Models

ImageToVideoGeneratePayload

Show schema
object
  • prompt stringRequired

    Video description prompt.

  • image_asset_id stringRequired

    Cloudinary asset ID of the input image for image-to-video generation.

  • aspect_ratio string

    Video aspect ratio. auto resolves based on image dimensions (defaults to landscape). 16:9 = landscape, 9:16 = portrait.

    default "auto"
    enum "auto" "16:9" "9:16"
  • resolution string

    Video resolution. 1080p is only supported with a duration of 8 seconds.

    default "720p"
    enum "720p" "1080p"
  • duration integer

    Video duration in seconds.

    default 8
    enum 4 6 8
  • generate_audio boolean

    Whether to generate audio. Enabling audio consumes twice as many credits.

    default false
  • enhance_prompt booleannullable

    Whether to let Cloudinary automatically enhance the prompt.

    default true
  • last_frame_image_asset_id string

    Cloudinary asset ID of the last frame image.

  • reference_image_asset_ids string[]

    Cloudinary asset IDs of reference images.

    max items 2

ImageToVideoGenerateResponse

Show schema
object
  • job_id stringRequired
    example "550e8400e29b41d4a716446655440000"
  • status stringRequired
    example "pending"
    enum "pending" "completed" "failed"
  • asset_id string

    Cloudinary asset ID of the generated video (present when completed).

  • public_id string

    Cloudinary public ID of the generated video (present when completed).

  • resource_type string

    Cloudinary resource type of the generated video (present when completed).

  • delivery_type string

    Cloudinary delivery type of the generated video (present when completed).

  • url string

    HTTPS URL of the generated video (present when completed).

  • message string

    Error message when generation has failed.

ImageToVideoGenerateWrappedResponse

Show schema
object
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • data ImageToVideoGenerateResponseRequired
    ShowHide child attributes of data
    • job_id stringRequired
      example "550e8400e29b41d4a716446655440000"
    • status stringRequired
      example "pending"
      enum "pending" "completed" "failed"
    • asset_id string

      Cloudinary asset ID of the generated video (present when completed).

    • public_id string

      Cloudinary public ID of the generated video (present when completed).

    • resource_type string

      Cloudinary resource type of the generated video (present when completed).

    • delivery_type string

      Cloudinary delivery type of the generated video (present when completed).

    • url string

      HTTPS URL of the generated video (present when completed).

    • message string

      Error message when generation has failed.

ImageToVideoPromptResponse

Show schema
object
  • id string
  • display_name string
  • prompt string
  • created_at integer
    format int64 Signed 64-bit integer
  • updated_at integer
    format int64 Signed 64-bit integer

ImageToVideoPromptWrappedResponse

Show schema
object
  • request_id string
  • data ImageToVideoPromptResponse
    ShowHide child attributes of data
    • id string
    • display_name string
    • prompt string
    • created_at integer
      format int64 Signed 64-bit integer
    • updated_at integer
      format int64 Signed 64-bit integer

ImageToVideoPromptsWrappedResponse

Show schema
object
  • request_id string
  • data ImageToVideoPromptResponse[]
    ShowHide child attributes of data
    Items ImageToVideoPromptResponse
    • id string
    • display_name string
    • prompt string
    • created_at integer
      format int64 Signed 64-bit integer
    • updated_at integer
      format int64 Signed 64-bit integer

ImageToVideoPromptCreatePayload

Show schema
object
  • display_name stringRequired

    A human-readable name for the prompt.

    max length 255
  • prompt stringRequired

    The prompt text describing the motion or scene to generate.

    max length 1000

ImageToVideoPromptUpdatePayload

Show schema
object
  • display_name stringnullable

    A human-readable name for the prompt.

    max length 255
  • prompt stringnullable

    The prompt text describing the motion or scene to generate.

    max length 1000

MessageWrappedResponse

Show schema
object
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • data objectRequired
    ShowHide child attributes of data
    • message string

ErrorWrappedResponse

Show schema
object
  • request_id stringRequired
    example "6ec0bd7f11c043da975e2a8ad9ebae0b"
  • error objectRequired
    ShowHide child attributes of error
    • message string