# OmniHuman 1.5 API

> OmniHuman 1.5 — high-quality AI video generation.

- **Provider**: ByteDance
- **Model id**: `omnihuman-1-5`
- **Modality**: video
- **Price**: 15.22 credits /sec

## Overview

OmniHuman 1.5 is called in two steps: create a generation task, then poll the task until the result is ready.

## Authentication

All requests require a Bearer Token in the request header:

```
Authorization: Bearer YOUR_API_KEY
```

## Create Task

`POST https://you.bot/api/v1/generate`

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| modelId | string | Yes | Model id: `omnihuman-1-5` |
| input | object | Yes | Input parameters object (see below) |
| callbackUrl | string | No | https URL we POST the finished task to. Signed with `X-Webhook-Signature` once you create a webhook signing key in Dashboard → Settings |

### input object parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| image_url | string | Yes | Portrait image URL, supports any aspect ratio with subjects including people/pets/anime, etc. (image URL) |
| mask_url | string | No | Optional. One or more mask image URLs, to pick which subject in the image speaks. Leave empty to let the model choose. |
| audio_url | string | Yes | Audio URL. Duration must be < 60 seconds (recommended ≤15 seconds; exceeding this will cause degradation). (image URL) |
| prompt | string | No | Prompt text, limited to Chinese/English/Japanese/Korean/Spanish/Indonesian, recommended ≤300 characters. Max 1000 characters. (example: Make the person in the photo speak the audio naturally with warm, friendly gestures.) |
| output_resolution | string | No | Output video resolution, default 1080. (options: 720 \| 1080) (default: 1080) |
| pe_fast_mode | boolean | No | Fast mode, sacrifices some quality to speed up generation. (true/false) (default: false) |
| seed | number | No | Random seed. Default is -1 (random). When using the same positive integer and keeping all other parameters identical, the result will be highly consistent (with very high probability). (default: -1) |

### Request example

```json
{
  "modelId": "omnihuman-1-5",
  "input": {
    "image_url": "https://you.bot/examples/grok-imagine-text-to-image.jpg",
    "mask_url": "example",
    "audio_url": "https://you.bot/examples/suno-v4-5.mp3",
    "prompt": "Make the person in the photo speak the audio naturally with warm, friendly gestures.",
    "output_resolution": "1080",
    "pe_fast_mode": false,
    "seed": -1
  }
}
```

### Response example

```json
{
  "taskId": "281e5b0…f39b9",
  "creditsCharged": 76.11
}
```

## Query Task

`GET https://you.bot/api/v1/task/{taskId}?model=omnihuman-1-5`

When `state` is `success`, the output is in `resultUrls`: `{ "state": "success", "resultUrls": [ ... ] }`. (Text models return inline in the create response.)

## Error Codes

| Code | Description |
|------|-------------|
| 200 | Request successful |
| 400 | Invalid request parameters |
| 401 | Authentication failed — check API Key |
| 402 | Insufficient account balance |
| 403 | IP not allowed for this key, or the key is restricted to other models |
| 404 | Task not found, or it has expired |
| 409 | Duplicate request — an identical submit arrived moments ago. Nothing was charged; retry is safe |
| 413 | Payload too large — see the character and file-size limits for this model |
| 429 | Rate limit exceeded — retry after the Retry-After header |
| 500 | Internal server error |
| 504 | Upstream timed out — nothing was delivered; retry is safe |
