---
title: "Template To Video"
method: POST
path: "/v1/video/template2video"
tags: ["AI Video"]
---

# Template To Video

`POST /v1/video/template2video`

## Request

- Base URL: `https://api.domoai.com`
- URL: `https://api.domoai.com/v1/video/template2video`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/domoai/apis/domoai-enterprise-api/docs/v1/video/template2video/post.ts> (a function with typed inputs; its response is checked against the schema)

## Request body

- CreateTemplate2VideoTaskIn
  - `callback_url` string, uri, nullable: Callback notification URL for task results. If configured, the server will actively send notifications when the task status changes. The message schema of the notification can be found in the [Callback Protocol](/api-reference/callback/callback-protocol) section.
  - `prompt` string
  - `template` 'kissing_screen' | 'looping_animation' | 'hug' | 'groove_dance' | 'kiss' | 'french_kiss' | '360_view' | 'zoom_in' | 'zoom_out' | 'crane_up', required
  - `images` ImageInput[], required: Array of input images. Currently supports only one image. Multiple images may be supported in the future.
    - `domoai_uri` string, nullable
    - `bytes_base64_encoded` string, nullable
  - `seconds` integer, required: Output video duration in seconds.
  - `aspect_ratio` '16:9' | '9:16' | '1:1' | '4:3' | '3:4'

## Response `200`

Successful Response

- DomoOutTaskOut
  - `code` integer
  - `data` TaskOut, required
    - `task_id` string, uuid, required

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/domoai/apis/domoai-enterprise-api.md) - [All operations](https://skmtc.dev/domoai/apis/domoai-enterprise-api/llms.txt) - [OpenAPI document](https://skmtc.dev/domoai/apis/domoai-enterprise-api/revisions/287d41982970?raw)
