> ## Documentation Index
> Fetch the complete documentation index at: https://docs.crazyrouter.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 통합 비디오 API

> Crazyrouter의 통합 비디오 생성 인터페이스로, 여러 모델을 통합된 형식으로 호출할 수 있습니다

> 업데이트: 2026-06-06

# 통합 비디오 API

Crazyrouter는 통합된 비디오 생성 인터페이스를 제공하며, 여러 비디오 모델을 동일한 API 형식으로 호출할 수 있습니다.

<Note>
  `Seedance`는 현재 통합 `/v1/video/*` 프로토콜 사용을 더 이상 권장하지 않습니다. 네이티브 `/volc/v1/contents/generations/tasks`를 사용하세요. [Seedance](/ko/video/seedance)를 참고하세요.
</Note>

## 지원 모델

| 모델                   | 설명                     |
| -------------------- | ---------------------- |
| `veo-3.1-fast`       | Google Veo 3.1 Fast    |
| `veo-3.1-quality`    | Google Veo 3.1 Quality |
| `wan2.2-t2v-plus`    | Wan 텍스트→비디오            |
| `wan2.5-t2v-preview` | Wan 텍스트→비디오            |

***

## 비디오 생성

```
POST /v1/video/create
```

### 요청 파라미터

| 파라미터           | 타입      | 필수  | 설명                                      |
| -------------- | ------- | --- | --------------------------------------- |
| `model`        | string  | 예   | 모델 이름                                   |
| `prompt`       | string  | 예   | 비디오 설명 프롬프트                             |
| `aspect_ratio` | string  | 아니오 | 화면 비율: `16:9`, `9:16`, `1:1`            |
| `size`         | string  | 아니오 | 비디오 크기, 예: `1280x720`                   |
| `images`       | array   | 아니오 | 현재 공개된 이미지→비디오 기능은 일반적으로 이미지 URL 1개를 전달 |
| `duration`     | integer | 아니오 | 비디오 길이(초)                               |

### 요청 예시

<CodeGroup>
  ```bash cURL theme={null}
  curl -X POST https://api.crazyrouter.com/v1/video/create \
    -H "Content-Type: application/json" \
    -H "Authorization: Bearer YOUR_API_KEY" \
    -d '{
      "model": "veo-3.1-quality",
      "prompt": "황금빛 리트리버가 해변에서 뛰어다니는 모습, 슬로우 모션, 영화 같은 화질",
      "aspect_ratio": "16:9"
    }'
  ```

  ```python Python theme={null}
  import requests

  response = requests.post(
      "https://api.crazyrouter.com/v1/video/create",
      headers={
          "Content-Type": "application/json",
          "Authorization": "Bearer YOUR_API_KEY"
      },
      json={
          "model": "veo-3.1-quality",
          "prompt": "황금빛 리트리버가 해변에서 뛰어다니는 모습, 슬로우 모션, 영화 같은 화질",
          "aspect_ratio": "16:9"
      }
  )

  data = response.json()
  task_id = data["task_id"]
  print(f"작업 ID: {task_id}")
  ```
</CodeGroup>

### 생성 응답

```json theme={null}
{
  "task_id": "video_task_abc123",
  "status": "processing"
}
```

***

## 이미지→비디오

`images` 파라미터에 참조 이미지를 전달합니다.

```bash cURL theme={null}
curl -X POST https://api.crazyrouter.com/v1/video/create \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "model": "wan-ai/wan2.1-i2v-14b-720p",
    "prompt": "사진 속 인물이 미소를 짓고 손을 흔들기 시작함",
    "images": ["https://example.com/portrait.jpg"],
    "aspect_ratio": "16:9"
  }'
```

***

## 작업 조회

```
GET /v1/video/query?id={task_id}
```

### 요청 예시

```bash cURL theme={null}
curl "https://api.crazyrouter.com/v1/video/query?id=video_task_abc123" \
  -H "Authorization: Bearer YOUR_API_KEY"
```

### 조회 응답(처리 중)

```json theme={null}
{
  "code": "success",
  "message": "",
  "data": {
    "task_id": "video_task_abc123",
    "status": "processing",
    "url": ""
  }
}
```

### 조회 응답(완료됨)

```json theme={null}
{
  "code": "success",
  "message": "",
  "data": {
    "task_id": "video_task_abc123",
    "status": "SUCCESS",
    "url": "https://media.crazyrouter.com/task-artifacts/example.mp4",
    "artifact_url": "https://media.crazyrouter.com/task-artifacts/example.mp4"
  }
}
```

### 작업 상태

| 상태           | 설명   |
| ------------ | ---- |
| `queued`     | 대기 중 |
| `processing` | 처리 중 |
| `SUCCESS`    | 완료됨  |
| `failed`     | 실패   |

***

## 전체 프로세스 예시

```python Python theme={null}
import requests
import time

API_KEY = "YOUR_API_KEY"
BASE_URL = "https://api.crazyrouter.com"
headers = {
    "Content-Type": "application/json",
    "Authorization": f"Bearer {API_KEY}"
}

# 1. 비디오 작업 생성
resp = requests.post(f"{BASE_URL}/v1/video/create", headers=headers, json={
    "model": "veo-3.1-quality",
    "prompt": "황금빛 리트리버가 해변에서 뛰어다니는 모습, 슬로우 모션",
    "aspect_ratio": "16:9"
})
task_id = resp.json()["task_id"]
print(f"작업 생성됨: {task_id}")

# 2. 상태 폴링 조회
while True:
    resp = requests.get(f"{BASE_URL}/v1/video/query?id={task_id}", headers=headers)
    result = resp.json().get("data", resp.json())
    status = result["status"]
    print(f"상태: {status}")

    if status == "SUCCESS":
        print(f"비디오 주소: {result.get('artifact_url') or result.get('url')}")
        break
    elif status == "failed":
        print("비디오 생성 실패")
        break

    time.sleep(10)
```

<Note>
  비디오 생성은 일반적으로 1\~5분이 소요되며, 폴링 간격은 10초를 권장합니다.
</Note>
