> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.beatapi.io/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.beatapi.io/_mcp/server.

# 영상 분석

POST https://api.beatapi.io/v1/video-analysis/tasks
Content-Type: application/json

업로드한 MP4 또는 MOV를 standard 또는 deep 타임스탬프 인식 멀티모달 추론으로 분석합니다.

입력이 로컬 파일이면 [로컬 입력을 업로드](/quick-guide#upload-an-input-file)하고 반환된 `data.url`을 사용하세요. `data.id`를 저장하고, [작업을 폴링](/quick-guide#get-task-status)하며, [오류 및 재시도 정책](/quick-guide#errors-and-retry-policy)을 따르세요.

Reference: https://docs.beatapi.io/api-reference/workflow-api/video-analysis

## Authentication

- `Authorization` header (bearer token, required) — API 키를 `Authorization: Bearer <BEATAPI_API_KEY>`로 보내세요.

## Servers

- `https://api.beatapi.io` (Direct, default)
- `https://api.beatapi.io` (API)

## Request

### Headers

- `Idempotency-Key` (string, optional) — 재시도용 키입니다(선택 사항). 정규화된 같은 요청에 같은 키를 다시 쓰면 접수된 작업을 반환합니다.

### Body (application/json)

This endpoint expects a VideoAnalysisTaskCreateRequest.

- `video_url` (string, required) — 현재 계정에서 POST /v1/files가 반환한 BeatAPI 호스팅 MP4 또는 MOV 입력 URL입니다. 검증된 최대 길이는 600초입니다.
- `prompt` (string, required) — 분석 지시문입니다. 시간 정밀도가 중요하면 타임스탬프가 있는 출력을 요청하세요.
- `analysis_depth` (enum, optional, default: standard) — standard는 저비용 기본 경로이고, deep은 더 높은 추론 경로를 사용합니다.
  - Allowed values: `standard`, `deep`
- `max_output_tokens` (integer, optional, default: 2048) — 요청한 답변 한도입니다. 모델이 보고하는 출력 사용량에는 이 값을 넘는 숨은 추론 토큰이 포함될 수 있으며, BeatAPI는 그 차이를 감사용으로 기록하고 작업 보류 금액 안에서 실제 보고된 사용량으로 정산합니다.

## Response

### 201

비동기 처리를 위해 분석이 접수되었습니다.

- `data` (Task, required) — 접수되었거나 현재의 BeatAPI 작업 상태입니다.

## Errors

### 400 Bad Request Error

JSON 형식이 잘못되었거나, 이 엔드포인트가 받지 않는 필드·값·조합이 있거나(`bad_request`, 메시지에 해당 필드가 표시됨), 입력이 콘텐츠 검수에서 거부되었습니다(`content_policy_violation`). 그대로 재시도할 수 없습니다.

- `error` (ErrorError, required) — 구조화된 BeatAPI 오류입니다. 프로그램 로직에는 `code`(또는 `retryable`)를 사용하고, 지원 요청용으로 `request_id`를 보관하세요.

### 401 Unauthorized Error

API 키가 없거나(`missing_api_key`), 키가 잘못되었거나 만료, 비활성화, 소진되었습니다(`invalid_api_key`, 메시지에 원인이 표시됨). `Authorization: Bearer <key>` 형식으로 보내세요. 키는 `sk-` 접두사가 있어도 없어도 동작합니다. 재시도할 수 없습니다.

- `error` (ErrorError, required) — 구조화된 BeatAPI 오류입니다. 프로그램 로직에는 `code`(또는 `retryable`)를 사용하고, 지원 요청용으로 `request_id`를 보관하세요.

### 402 Payment Required Error

잔액이 부족합니다(`insufficient_credits`). 계정 잔액이 0이거나 이 요청의 가격보다 적습니다. 충전한 뒤 다시 보내세요. 충전 전에는 재시도할 수 없습니다.

- `error` (ErrorError, required) — 구조화된 BeatAPI 오류입니다. 프로그램 로직에는 `code`(또는 `retryable`)를 사용하고, 지원 요청용으로 `request_id`를 보관하세요.

### 403 Forbidden Error

이 키나 계정으로는 이 호출을 할 수 없습니다(`forbidden`). 예를 들어 무료 크레딧으로 쓸 수 없는 모델(충전하면 사용 가능), 키의 IP 허용 목록 밖에서 보낸 요청, 키의 그룹에 속하지 않은 모델이 해당합니다. 재시도할 수 없습니다.

- `error` (ErrorError, required) — 구조화된 BeatAPI 오류입니다. 프로그램 로직에는 `code`(또는 `retryable`)를 사용하고, 지원 요청용으로 `request_id`를 보관하세요.

### 409 Conflict Error

`Idempotency-Key`가 24시간 안에 다른 요청 본문이나 경로에 이미 사용되었거나, 이 키를 사용한 첫 요청이 아직 처리 중입니다(`idempotency_conflict`). 그대로 재시도할 수 없습니다.

- `error` (ErrorError, required) — 구조화된 BeatAPI 오류입니다. 프로그램 로직에는 `code`(또는 `retryable`)를 사용하고, 지원 요청용으로 `request_id`를 보관하세요.

### 429 Too Many Requests Error

요청이 너무 많습니다(`rate_limit_exceeded`, 무료 모델 한도 포함). `Retry-After`(또는 `error.retry_after_seconds`)에 표시된 초만큼 기다린 뒤 재시도할 수 있습니다.

- `error` (ErrorError, required) — 구조화된 BeatAPI 오류입니다. 프로그램 로직에는 `code`(또는 `retryable`)를 사용하고, 지원 요청용으로 `request_id`를 보관하세요.

### 500 Internal Server Error

예상하지 못한 내부 오류입니다(`internal_error`). 재시도할 수 있으며, 문제가 계속되면 지원 요청 시 `request_id`를 함께 알려 주세요.

- `error` (ErrorError, required) — 구조화된 BeatAPI 오류입니다. 프로그램 로직에는 `code`(또는 `retryable`)를 사용하고, 지원 요청용으로 `request_id`를 보관하세요.

### 503 Service Unavailable Error

요청을 완료하지 못했습니다(`processing_unavailable`, `processing_timeout`, `processing_failed` 또는 `result_transfer_failed`). 과금되지 않았습니다. 백오프를 적용해 재시도할 수 있습니다. 503에는 `Retry-After` 헤더도 `retry_after_seconds`도 없습니다. BeatAPI는 502나 504를 반환하지 않습니다.

- `error` (ErrorError, required) — 구조화된 BeatAPI 오류입니다. 프로그램 로직에는 `code`(또는 `retryable`)를 사용하고, 지원 요청용으로 `request_id`를 보관하세요.

## Types

### Task

- `id` (string, required) — 폴링과 지원 요청에 쓰는 안정적인 BeatAPI 작업 ID입니다.
- `object` (enum, required) — 객체 구분자이며 항상 `task`입니다.
  - Allowed values: `task`
- `task_kind` (enum, required) — 어떤 기능 필드가 있는지 결정하는 공개 작업 계열입니다. `data`는 작업으로 실행되는 데이터 기능(`data:web.research`)이며 `POST /v1/capabilities/run`으로 폴링합니다.
  - Allowed values: `workflow`, `effect`, `image`, `video`, `data`
- `capability_id` (string, required) — 작업 접수 시 선택된 안정적인 BeatAPI 워크플로, 이펙트, 생성 모델 또는 데이터 기능 ID(예: `web.research`)입니다.
- `capability_version` (integer, required) — 항상 `1`.
- `status` (enum, required) — 현재 작업 수명 주기 상태입니다. `succeeded` 또는 `failed`에서 폴링을 멈추세요. Music Video는 수동 조치가 필요할 수도 있습니다.
  - Allowed values: `queued`, `processing`, `storyboard_ready`, `requires_action`, `editing`, `composing`, `succeeded`, `failed`
- `stage` (enum, required) — 항상 `status`를 반복합니다. 호환성을 위해 유지되며, `status`를 읽으세요.
  - Allowed values: `queued`, `processing`, `storyboard_ready`, `requires_action`, `editing`, `composing`, `succeeded`, `failed`
- `created_at` (integer, required) — BeatAPI가 작업을 접수한 Unix 타임스탬프입니다.
- `updated_at` (integer, required) — 최근 작업 업데이트의 Unix 타임스탬프입니다.
- `completed_at` (integer, required, nullable) — 종료 Unix 타임스탬프이며, 작업 진행 중에는 null입니다.
- `output` (TaskOutput, required, nullable) — 작업이 성공할 때까지 출력은 null입니다.
- `usage` (TaskUsage, required) — 이 작업의 USD 보류, 정산, 환불 금액과 선택적인 과금 길이입니다.
- `request_id` (string, required) — 로그와 BeatAPI 지원 요청용으로 보관할 상관관계 ID입니다.
- `error_code` (string, required, nullable) — 기계가 읽을 수 있는 종료 실패 코드이며, 기록된 작업 실패가 없으면 null입니다.
- `error_message` (string, required, nullable) — 사람이 읽을 수 있는 종료 실패 상세 내용이며, 기록된 작업 실패가 없으면 null입니다.
- `workflow` (enum, optional) — 워크플로 작업에 있으며, 선택된 BeatAPI 워크플로를 식별합니다.
  - Allowed values: `music-video`, `ecommerce-video`, `video-analysis`
- `effect_id` (string, optional) — 이펙트 작업에 있으며, 선택된 안정적인 이펙트 ID입니다.
- `effect_version` (integer, optional) — 이펙트 작업에 있으며, 처리에 사용된 변경 불가능한 이펙트 버전입니다.
- `media_type` (enum, optional) — task_kind가 image 또는 video일 때 있습니다.
  - Allowed values: `image`, `video`
- `model` (string, optional) — 안정적인 BeatAPI 모델 별칭입니다. 내부 실행 라우팅과 독립적입니다.
- `storyboard` (Storyboard, optional) — 사용 가능한 경우 Music Video 스토리보드 메타데이터입니다.
- `poll_after_seconds` (integer, optional) — 작업 실행 중에 있으며, 다음 상태 조회까지 기다릴 시간입니다(이미지는 5, 영상과 이펙트는 8, 워크플로와 데이터 작업은 10). 고정 간격 대신 이 값을 따르세요. 종료된 작업에는 없습니다.
- `typical_seconds` (TaskTypicalSeconds, optional) — 작업 실행 중이고 최근 완료 건이 충분할 때 있으며, 이 작업의 모델이 최근 이 게이트웨이에서 수락부터 성공까지 걸린 시간입니다. 변화 없이 `p90`를 넘기면 작업이 오래 실행되는 것이며, 그 이후의 예상 완료 시간은 없습니다.
- `retryable` (boolean, optional) — 실패한 작업에 있으며, 다시 제출하면 성공할 수 있는지 여부입니다. 작업이 BeatAPI 측에서 실패했거나 시간이 초과되면 true(실패한 작업은 과금되지 않음), 콘텐츠나 잘못된 입력으로 거부되면 false입니다. 코드와 재시도 가능 여부의 규칙은 오류 형식과 같습니다.

### ErrorError

구조화된 BeatAPI 오류입니다. 프로그램 로직에는 `code`(또는 `retryable`)를 사용하고, 지원 요청용으로 `request_id`를 보관하세요.

- `code` (enum, required) — 기계가 읽을 수 있는 안정적인 오류 코드입니다. `unauthorized`는 401의 레거시 이름입니다. 2026-09-29부터 401은 `missing_api_key` 또는 `invalid_api_key`이지만 `unauthorized`가 여전히 나타날 수 있으며, `invalid_api_key`처럼 처리하세요. `result_expired`는 `operation: "result"`가 있는 `POST /v1/capabilities/run`에서만 반환됩니다.
  - Allowed values: `bad_request`, `missing_api_key`, `invalid_api_key`, `unauthorized`, `forbidden`, `not_found`, `insufficient_credits`, `idempotency_conflict`, `rate_limit_exceeded`, `content_policy_violation`, `processing_unavailable`, `processing_failed`, `processing_timeout`, `result_transfer_failed`, `result_expired`, `not_implemented`, `realtime_disabled`, `realtime_capacity_unavailable`, `realtime_session_expired`, `origin_not_allowed`, `invalid_client_secret`, `transport_not_allowed`, `internal_error`
- `message` (string, required) — 원인을 설명하는 영어 문장입니다. `bad_request`에서는 필드 이름을 명시합니다. 파싱용이 아니라 사람과 로그를 위한 문장입니다.
- `request_id` (string, required) — BeatAPI 지원 요청용으로 보관할 상관관계 ID입니다.
- `retryable` (boolean, optional) — 같은 호출을 다시 하면 성공할 수 있는지 여부입니다. 공개 표의 모든 코드에 있으며, 표에 없는 코드에서만 빠질 수 있습니다. rate_limit_exceeded, internal_error, processing_unavailable, processing_timeout, processing_failed, result_transfer_failed, realtime_capacity_unavailable은 true입니다. 요청, 키 또는 잔액을 먼저 바꿔야 하는 경우(bad_request, content_policy_violation, missing_api_key, invalid_api_key, unauthorized, insufficient_credits, forbidden, not_found, idempotency_conflict, result_expired, not_implemented, realtime_disabled 및 기타 realtime 자격 증명 코드)는 false입니다.
- `retry_after_seconds` (integer, optional) — 재시도 전에 기다릴 초 수입니다. 429 `rate_limit_exceeded`에서만 전송되며, 같은 값이 `Retry-After` 헤더로도 전송됩니다. 다른 코드에는 없습니다.
- `docs` (string, optional) — 오류 대처 방법을 알려 주는 공개 Skill 페이지입니다. 기능 엔드포인트(`/v1/capabilities/search`, `/v1/capabilities/inspect`, `/v1/capabilities/run`)가 응답한 오류에만 있으며, 다른 엔드포인트에는 없습니다.

### TaskOutput

작업이 성공할 때까지 출력은 null입니다.

- TaskOutput0
- TaskOutput1
- TaskOutput2

### TaskUsage

- `credits_reserved` (double, required) — 이 작업에 보류된 USD 금액입니다. 호환성을 위해 필드 이름을 유지하며, 1 Credit은 $1 USD입니다.
- `credits_charged` (double, required) — 청구된 USD 금액입니다. 실패한 작업은 보류 금액이 반환되므로 `0`입니다.
- `credits_settled` (double, required) — 작업 성공 후 정산된 USD 금액입니다.
- `credits_refunded` (double, required) — 실패한 작업 후 반환된 USD 금액입니다. 실패한 작업에서 `credits_reserved`는 생성 시 보류된 금액, `credits_charged`와 `credits_settled`는 `0`, `credits_refunded`는 반환된 금액입니다.
- `billable_duration_seconds` (integer, optional) — USD 계산에 사용된, 서버가 감지했거나 요청에서 선언한 과금 길이입니다.

### Storyboard

- `shots` (list of StoryboardShot, required) — 순서가 지정된 Music Video 스토리보드 샷입니다. 스토리보드 생성이 끝나기 전에는 배열이 비어 있을 수 있습니다.

### TaskTypicalSeconds

작업 실행 중이고 최근 완료 건이 충분할 때 있으며, 이 작업의 모델이 최근 이 게이트웨이에서 수락부터 성공까지 걸린 시간입니다. 변화 없이 `p90`를 넘기면 작업이 오래 실행되는 것이며, 그 이후의 예상 완료 시간은 없습니다.

- `p50` (integer, required) — 중앙값(초)입니다.
- `p90` (integer, required) — 90번째 백분위수(초)입니다.
- `samples` (integer, required) — 수치의 근거가 된 완료 작업 수입니다.
- `window` (string, required) — 측정 기간이며, 예를 들어 `7d`입니다.

### TaskOutput0

- `media` (list of TaskOutputOneOf0MediaItems, required) — BeatAPI가 호스팅하는 결과 자산입니다.
- `r2_url` (string, required, deprecated) — 지원 중단 — media[0].url을 읽으세요. 주 자산(영상, 없으면 첫 번째 이미지)의 URL을 다시 담은 값으로 해당 media[].url과 같으며, URL 하나만 읽는 클라이언트를 위해서만 유지됩니다.

### TaskOutput1

- `text` (string, required) — 완료된 영상 분석 텍스트입니다.
- `usage` (TaskOutputOneOf1Usage, required) — 최종 USD 정산에 사용된 측정 토큰 사용량입니다.
- `finish_reason` (string, required, nullable) — 모델이 생성을 멈춘 이유입니다.

### TaskOutput2

데이터 작업의 결과입니다. 기능 자체의 결과 객체이며, 예를 들어 `research_notes`와 `sources`가 있는 `web.research`입니다(보기 사용 시: `items`).

- `object` (string, required) — 결과 종류이며, 예를 들어 `web.research`입니다.

### StoryboardShot

- `id` (string, required) — BeatAPI 샷 ID입니다. 미디어 조회, 편집, 합성 작업에 이 ID를 사용하세요.
- `index` (integer, required) — 스토리보드에서 0부터 시작하는 샷 순서입니다.
- `status` (enum, required) — 이 스토리보드 샷의 현재 수명 주기 상태입니다.
  - Allowed values: `queued`, `processing`, `storyboard_ready`, `requires_action`, `editing`, `composing`, `succeeded`, `failed`
- `created_at` (integer, required) — 샷 레코드가 생성된 Unix 타임스탬프입니다.
- `updated_at` (integer, required) — 샷 레코드가 마지막으로 변경된 Unix 타임스탬프입니다.
- `duration_seconds` (integer, optional) — 계획되었거나 생성된 샷 길이(초)입니다.
- `prompt` (string, optional) — 이 샷 생성에 사용된 크리에이티브 지시문입니다.
- `lyric_text` (string, optional) — 사용 가능한 경우 이 샷에 맞춘 가사 구간입니다.
- `media` (StoryboardShotMedia, optional) — 샷 미디어가 실체화되었거나 샷 편집이 끝난 뒤에만 있습니다.

### TaskOutputOneOf0MediaItems

- `type` (enum, required) — 결과 자산 종류입니다.
  - Allowed values: `image`, `video`
- `url` (string, required) — BeatAPI가 호스팅하는 HTTPS 결과 URL입니다.
- `mime_type` (string, required) — 결과 자산 MIME 타입입니다.

### TaskOutputOneOf1Usage

최종 USD 정산에 사용된 측정 토큰 사용량입니다.

- `input_tokens` (integer, required) — 프롬프트와 영상 입력이 소비한 토큰입니다.
- `output_tokens` (integer, required) — 표시되는 출력과 모델 추론이 소비한 토큰입니다.
- `total_tokens` (integer, required) — 측정된 입력·출력 토큰 합계입니다.

### StoryboardShotMedia

샷 미디어가 실체화되었거나 샷 편집이 끝난 뒤에만 있습니다.

- `type` (string, optional) — 실체화된 샷의 호스팅 미디어 종류입니다.
- `url` (string, optional) — 실체화된 샷의 BeatAPI 호스팅 HTTPS URL입니다.
- `mime_type` (string, optional) — 호스팅된 샷 미디어의 MIME 타입입니다.

## Examples

**Request**

```json
{
  "video_url": "https://files.beatapi.io/u/input.mp4",
  "prompt": "Return a timestamped action summary and identify every scene transition.",
  "analysis_depth": "standard",
  "max_output_tokens": 2048
}
```

**Response**

```json
{
  "data": {
    "id": "task_va8K2qA",
    "object": "task",
    "task_kind": "workflow",
    "capability_id": "video-analysis",
    "capability_version": 1,
    "status": "queued",
    "stage": "queued",
    "created_at": 1787385600,
    "updated_at": 1787385600,
    "completed_at": null,
    "output": null,
    "usage": {
      "credits_reserved": 0.01,
      "credits_charged": 0.01,
      "credits_settled": 0,
      "credits_refunded": 0,
      "billable_duration_seconds": 60
    },
    "request_id": "req_va123",
    "error_code": null,
    "error_message": null,
    "workflow": "video-analysis"
  }
}
```

**SDK Code**

```python 영상 분석
import requests

url = "https://api.beatapi.io/v1/video-analysis/tasks"

payload = {
    "video_url": "https://files.beatapi.io/u/input.mp4",
    "prompt": "Return a timestamped action summary and identify every scene transition.",
    "analysis_depth": "standard",
    "max_output_tokens": 2048
}
headers = {
    "Idempotency-Key": "video-analysis-cus_123-01",
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript 영상 분석
const url = 'https://api.beatapi.io/v1/video-analysis/tasks';
const options = {
  method: 'POST',
  headers: {
    'Idempotency-Key': 'video-analysis-cus_123-01',
    Authorization: 'Bearer <token>',
    'Content-Type': 'application/json'
  },
  body: '{"video_url":"https://files.beatapi.io/u/input.mp4","prompt":"Return a timestamped action summary and identify every scene transition.","analysis_depth":"standard","max_output_tokens":2048}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go 영상 분석
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.beatapi.io/v1/video-analysis/tasks"

	payload := strings.NewReader("{\n  \"video_url\": \"https://files.beatapi.io/u/input.mp4\",\n  \"prompt\": \"Return a timestamped action summary and identify every scene transition.\",\n  \"analysis_depth\": \"standard\",\n  \"max_output_tokens\": 2048\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Idempotency-Key", "video-analysis-cus_123-01")
	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby 영상 분석
require 'uri'
require 'net/http'

url = URI("https://api.beatapi.io/v1/video-analysis/tasks")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Idempotency-Key"] = 'video-analysis-cus_123-01'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"video_url\": \"https://files.beatapi.io/u/input.mp4\",\n  \"prompt\": \"Return a timestamped action summary and identify every scene transition.\",\n  \"analysis_depth\": \"standard\",\n  \"max_output_tokens\": 2048\n}"

response = http.request(request)
puts response.read_body
```

```java 영상 분석
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.beatapi.io/v1/video-analysis/tasks")
  .header("Idempotency-Key", "video-analysis-cus_123-01")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"video_url\": \"https://files.beatapi.io/u/input.mp4\",\n  \"prompt\": \"Return a timestamped action summary and identify every scene transition.\",\n  \"analysis_depth\": \"standard\",\n  \"max_output_tokens\": 2048\n}")
  .asString();
```

```php 영상 분석
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.beatapi.io/v1/video-analysis/tasks', [
  'body' => '{
  "video_url": "https://files.beatapi.io/u/input.mp4",
  "prompt": "Return a timestamped action summary and identify every scene transition.",
  "analysis_depth": "standard",
  "max_output_tokens": 2048
}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
    'Idempotency-Key' => 'video-analysis-cus_123-01',
  ],
]);

echo $response->getBody();
```

```csharp 영상 분석
using RestSharp;

var client = new RestClient("https://api.beatapi.io/v1/video-analysis/tasks");
var request = new RestRequest(Method.POST);
request.AddHeader("Idempotency-Key", "video-analysis-cus_123-01");
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"video_url\": \"https://files.beatapi.io/u/input.mp4\",\n  \"prompt\": \"Return a timestamped action summary and identify every scene transition.\",\n  \"analysis_depth\": \"standard\",\n  \"max_output_tokens\": 2048\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift 영상 분석
import Foundation

let headers = [
  "Idempotency-Key": "video-analysis-cus_123-01",
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [
  "video_url": "https://files.beatapi.io/u/input.mp4",
  "prompt": "Return a timestamped action summary and identify every scene transition.",
  "analysis_depth": "standard",
  "max_output_tokens": 2048
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.beatapi.io/v1/video-analysis/tasks")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```