# Requests

## Get a video translation request

`client.videoTranslate.requests.retrieve(stringid, RequestOptionsoptions?): RequestRetrieveResponse`

**get** `/v1/video-translate/requests/{id}`

Returns an account-owned request by UUID or exact reference ID (requests of other accounts return 404). Completed artifact URLs are freshly signed on every read; SRT content is never returned.

### Parameters

- `id: string`

### Returns

- `RequestRetrieveResponse`

  - `id: string`

  - `config: Config`

    The request config as returned by the API. SRT content is replaced by metadata, `speaker_voices` keys are canonical speaker IDs, and other keys are returned unchanged.

    - `source_srt?: SourceSrt`

      Public description of a supplied SRT. The subtitle content is never returned.

      - `supplied: true`

        - `true`

      - `file_name?: string`

      - `language?: string`

    - `speaker_voices?: Record<string, string>`

    - `target_srts?: Record<string, TargetSrts>`

      - `supplied: true`

        - `true`

      - `file_name?: string`

      - `language?: string`

    - `tts_model?: "eleven_v4" | "eleven_multilingual_v2"`

      The explicitly selected text-to-speech model. Omitted when the request used the default.

      - `"eleven_v4"`

      - `"eleven_multilingual_v2"`

  - `created_at: string`

  - `disable_background_audio: boolean`

    Whether background audio was disabled for this request.

  - `disable_lip_sync: boolean`

    Whether lip sync was disabled for this request.

  - `formality: boolean`

  - `model: "expressive" | "classic"`

    Product speech model selected for the request.

    - `"expressive"`

    - `"classic"`

  - `status: "queued" | "uploading" | "processing" | 2 more`

    - `"queued"`

    - `"uploading"`

    - `"processing"`

    - `"completed"`

    - `"failed"`

  - `target_languages: Array<string>`

  - `error_message?: string`

    Present only when failed. A safe, bounded description, for example SRT or speaker validation errors found after the video was processed.

  - `finished_at?: string`

  - `outputs?: Record<string, Outputs>`

    Present only when completed, keyed by requested target language. URLs are signed on every read.

    - `audio: string`

    - `srt: string`

    - `video: string`

  - `reference_id?: string`

  - `source_language?: string`

    Explicit source language, or the detected one once processing starts.

  - `started_at?: string`

  - `webhook_url?: string`

    The configured terminal callback URL, when supplied.

### Example

```typescript
import Chamelaion from 'chamelaion';

const client = new Chamelaion({
  bearerToken: process.env['CHAMELAION_BEARER_TOKEN'], // This is the default and can be omitted
});

const request = await client.videoTranslate.requests.retrieve('x');

console.log(request.id);
```

#### Response

```json
{
  "id": "4c98dd00-a982-47d9-a8d6-e1f0b35a8944",
  "reference_id": "customer-job-42",
  "source_language": "en",
  "target_languages": [
    "de",
    "fr"
  ],
  "disable_background_audio": false,
  "disable_lip_sync": false,
  "formality": false,
  "config": {
    "source_srt": {
      "file_name": "interview.srt",
      "language": "en",
      "supplied": true
    },
    "target_srts": {
      "de": {
        "file_name": "target-de.srt",
        "language": "de",
        "supplied": true
      }
    },
    "speaker_voices": {
      "0": "21m00Tcm4TlvDq8ikWAM",
      "1": "AZnzlk1XvdvUeBnXmlld"
    }
  },
  "status": "completed",
  "created_at": "2026-10-07T12:00:00Z",
  "started_at": "2026-10-07T12:00:01Z",
  "finished_at": "2026-10-07T12:04:00Z",
  "outputs": {
    "de": {
      "video": "https://storage.example/signed/de.mp4",
      "audio": "https://storage.example/signed/de.wav",
      "srt": "https://storage.example/signed/de.srt"
    },
    "fr": {
      "video": "https://storage.example/signed/fr.mp4",
      "audio": "https://storage.example/signed/fr.wav",
      "srt": "https://storage.example/signed/fr.srt"
    }
  }
}
```

## List video translation requests

`client.videoTranslate.requests.list(RequestListParamsquery?, RequestOptionsoptions?): RequestListResponse`

**get** `/v1/video-translate/requests`

Returns the authenticated account's requests, newest first (`created_at` descending, then `id` descending), always paginated. `pagination.total` counts every request matching the filters. Responses use the same shape as `GET /v1/video-translate/requests/{id}`.

### Parameters

- `query: RequestListParams`

  - `created_from?: string`

    Inclusive lower bound on `created_at` (RFC 3339). Must not be after `created_to`.

  - `created_to?: string`

    Inclusive upper bound on `created_at` (RFC 3339).

  - `limit?: number`

    Page size. Non-integers and values below 1 are rejected with 400; values above 100 are clamped to 100.

  - `offset?: number`

    Number of items to skip. Non-integers and negative values are rejected with 400.

  - `reference_id?: string`

    Filter requests by exact `reference_id`.

  - `source_language?: string`

    Filter by the explicit or detected source language (supported language code).

  - `status?: "queued" | "uploading" | "processing" | 2 more`

    Filter by request status.

    - `"queued"`

    - `"uploading"`

    - `"processing"`

    - `"completed"`

    - `"failed"`

  - `target_language?: string`

    Return requests whose `target_languages` contain this supported language code.

### Returns

- `RequestListResponse`

  - `data: Array<Data>`

    - `id: string`

    - `config: Config`

      The request config as returned by the API. SRT content is replaced by metadata, `speaker_voices` keys are canonical speaker IDs, and other keys are returned unchanged.

      - `source_srt?: SourceSrt`

        Public description of a supplied SRT. The subtitle content is never returned.

        - `supplied: true`

          - `true`

        - `file_name?: string`

        - `language?: string`

      - `speaker_voices?: Record<string, string>`

      - `target_srts?: Record<string, TargetSrts>`

        - `supplied: true`

          - `true`

        - `file_name?: string`

        - `language?: string`

      - `tts_model?: "eleven_v4" | "eleven_multilingual_v2"`

        The explicitly selected text-to-speech model. Omitted when the request used the default.

        - `"eleven_v4"`

        - `"eleven_multilingual_v2"`

    - `created_at: string`

    - `disable_background_audio: boolean`

      Whether background audio was disabled for this request.

    - `disable_lip_sync: boolean`

      Whether lip sync was disabled for this request.

    - `formality: boolean`

    - `model: "expressive" | "classic"`

      Product speech model selected for the request.

      - `"expressive"`

      - `"classic"`

    - `status: "queued" | "uploading" | "processing" | 2 more`

      - `"queued"`

      - `"uploading"`

      - `"processing"`

      - `"completed"`

      - `"failed"`

    - `target_languages: Array<string>`

    - `error_message?: string`

      Present only when failed. A safe, bounded description, for example SRT or speaker validation errors found after the video was processed.

    - `finished_at?: string`

    - `outputs?: Record<string, Outputs>`

      Present only when completed, keyed by requested target language. URLs are signed on every read.

      - `audio: string`

      - `srt: string`

      - `video: string`

    - `reference_id?: string`

    - `source_language?: string`

      Explicit source language, or the detected one once processing starts.

    - `started_at?: string`

    - `webhook_url?: string`

      The configured terminal callback URL, when supplied.

  - `pagination: Pagination`

    - `limit: number`

      Applied page size.

    - `offset: number`

      Applied result offset.

    - `total: number`

      Total number of matching records.

### Example

```typescript
import Chamelaion from 'chamelaion';

const client = new Chamelaion({
  bearerToken: process.env['CHAMELAION_BEARER_TOKEN'], // This is the default and can be omitted
});

const requests = await client.videoTranslate.requests.list();

console.log(requests.data);
```

#### Response

```json
{
  "data": [
    {
      "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
      "config": {
        "source_srt": {
          "supplied": true,
          "file_name": "file_name",
          "language": "language"
        },
        "speaker_voices": {
          "foo": "string"
        },
        "target_srts": {
          "foo": {
            "supplied": true,
            "file_name": "file_name",
            "language": "language"
          }
        },
        "tts_model": "eleven_v4"
      },
      "created_at": "2019-12-27T18:11:19.117Z",
      "disable_background_audio": true,
      "disable_lip_sync": true,
      "formality": true,
      "model": "expressive",
      "status": "queued",
      "target_languages": [
        "string"
      ],
      "error_message": "error_message",
      "finished_at": "2019-12-27T18:11:19.117Z",
      "outputs": {
        "foo": {
          "audio": "https://example.com",
          "srt": "https://example.com",
          "video": "https://example.com"
        }
      },
      "reference_id": "reference_id",
      "source_language": "source_language",
      "started_at": "2019-12-27T18:11:19.117Z",
      "webhook_url": "https://example.com"
    }
  ],
  "pagination": {
    "limit": 1,
    "offset": 0,
    "total": 0
  }
}
```

## Domain Types

### Request Retrieve Response

- `RequestRetrieveResponse`

  - `id: string`

  - `config: Config`

    The request config as returned by the API. SRT content is replaced by metadata, `speaker_voices` keys are canonical speaker IDs, and other keys are returned unchanged.

    - `source_srt?: SourceSrt`

      Public description of a supplied SRT. The subtitle content is never returned.

      - `supplied: true`

        - `true`

      - `file_name?: string`

      - `language?: string`

    - `speaker_voices?: Record<string, string>`

    - `target_srts?: Record<string, TargetSrts>`

      - `supplied: true`

        - `true`

      - `file_name?: string`

      - `language?: string`

    - `tts_model?: "eleven_v4" | "eleven_multilingual_v2"`

      The explicitly selected text-to-speech model. Omitted when the request used the default.

      - `"eleven_v4"`

      - `"eleven_multilingual_v2"`

  - `created_at: string`

  - `disable_background_audio: boolean`

    Whether background audio was disabled for this request.

  - `disable_lip_sync: boolean`

    Whether lip sync was disabled for this request.

  - `formality: boolean`

  - `model: "expressive" | "classic"`

    Product speech model selected for the request.

    - `"expressive"`

    - `"classic"`

  - `status: "queued" | "uploading" | "processing" | 2 more`

    - `"queued"`

    - `"uploading"`

    - `"processing"`

    - `"completed"`

    - `"failed"`

  - `target_languages: Array<string>`

  - `error_message?: string`

    Present only when failed. A safe, bounded description, for example SRT or speaker validation errors found after the video was processed.

  - `finished_at?: string`

  - `outputs?: Record<string, Outputs>`

    Present only when completed, keyed by requested target language. URLs are signed on every read.

    - `audio: string`

    - `srt: string`

    - `video: string`

  - `reference_id?: string`

  - `source_language?: string`

    Explicit source language, or the detected one once processing starts.

  - `started_at?: string`

  - `webhook_url?: string`

    The configured terminal callback URL, when supplied.

### Request List Response

- `RequestListResponse`

  - `data: Array<Data>`

    - `id: string`

    - `config: Config`

      The request config as returned by the API. SRT content is replaced by metadata, `speaker_voices` keys are canonical speaker IDs, and other keys are returned unchanged.

      - `source_srt?: SourceSrt`

        Public description of a supplied SRT. The subtitle content is never returned.

        - `supplied: true`

          - `true`

        - `file_name?: string`

        - `language?: string`

      - `speaker_voices?: Record<string, string>`

      - `target_srts?: Record<string, TargetSrts>`

        - `supplied: true`

          - `true`

        - `file_name?: string`

        - `language?: string`

      - `tts_model?: "eleven_v4" | "eleven_multilingual_v2"`

        The explicitly selected text-to-speech model. Omitted when the request used the default.

        - `"eleven_v4"`

        - `"eleven_multilingual_v2"`

    - `created_at: string`

    - `disable_background_audio: boolean`

      Whether background audio was disabled for this request.

    - `disable_lip_sync: boolean`

      Whether lip sync was disabled for this request.

    - `formality: boolean`

    - `model: "expressive" | "classic"`

      Product speech model selected for the request.

      - `"expressive"`

      - `"classic"`

    - `status: "queued" | "uploading" | "processing" | 2 more`

      - `"queued"`

      - `"uploading"`

      - `"processing"`

      - `"completed"`

      - `"failed"`

    - `target_languages: Array<string>`

    - `error_message?: string`

      Present only when failed. A safe, bounded description, for example SRT or speaker validation errors found after the video was processed.

    - `finished_at?: string`

    - `outputs?: Record<string, Outputs>`

      Present only when completed, keyed by requested target language. URLs are signed on every read.

      - `audio: string`

      - `srt: string`

      - `video: string`

    - `reference_id?: string`

    - `source_language?: string`

      Explicit source language, or the detected one once processing starts.

    - `started_at?: string`

    - `webhook_url?: string`

      The configured terminal callback URL, when supplied.

  - `pagination: Pagination`

    - `limit: number`

      Applied page size.

    - `offset: number`

      Applied result offset.

    - `total: number`

      Total number of matching records.
