---
title: LTX Video صوت إلى فيديو | RunAPI
description: أنشئ فيديو من الصوت باستخدام LTX 2.5 Fast، مع صورة مصدر اختيارية.
url: https://runapi.ai/ar/docs/api/ltx-video/audio-to-video.md
canonical: https://runapi.ai/ar/docs/api/ltx-video/audio-to-video
locale: ar
---

> نسخة HTML: https://runapi.ai/ar/docs/api/ltx-video/audio-to-video
> فهرس الموقع للوكلاء: https://runapi.ai/llms.txt

# LTX Video صوت إلى فيديو

## نظرة عامة

استخدم نقطة نهاية تحويل الصوت إلى فيديو مع نموذج مدعوم. استخدم معرّف Task المُعاد لاسترجاع حالته، أو وفّر callback_url لعمليات التسليم الموثقة أدناه.

### البدء السريع

1. أنشئ مفتاح API واضبطه كـ RUNAPI_API_KEY.
2. اختر نموذجاً مدعوماً وأرسل طلب POST يطابق مخطط ذلك النموذج.
3. احفظ معرّف المهمة المُعاد، ثم استطلع الحالة حتى تبلغ حالة نهائية أو تعالج عمليات الاستدعاء الموثقة أدناه.

## نقطة النهاية

POST /api/v1/ltx_video/audio_to_video

عنوان URL الأساسي: https://runapi.ai

إصدار API: v1

المصادقة: Authorization: Bearer YOUR_API_TOKEN

## النماذج المدعومة

افتح صفحة النموذج للاطلاع على التسعير الحالي وحدود المعدل وتفاصيل الاستخدام التجاري.

- [ltx-2.5-fast-audio-to-video](https://runapi.ai/ar/models/ltx-video/ltx-2.5-fast-audio-to-video)

## مخطط الطلب

تعتمد الحقول والقيم المسموح بها على النموذج المحدد. عند التوفير، يستقبل callback_url عمليات تسليم المهمة الموثّقة أدناه.

### ltx-2.5-fast-audio-to-video

```json
{
  "callback_url": {
    "description": "عنوان URL لرد اتصال RunAPI لتلقي النتيجة النهائية للمهمة.",
    "type": "string"
  },
  "duration_seconds": {
    "description": "مدة اختيارية للفيديو الناتج بالثواني، ويمكن أن تتضمن كسورًا عشرية. لا يمكن أن تتجاوز مدة الصوت المصدر. احذفها لاستخدام مدة الصوت، بحد أقصى 20 ثانية أو 10 ثوانٍ عند استخدام 1440p أو 48/50 fps. تُحسب التكلفة من مدة الفيديو الناتج بدقة 0.01 ثانية. يورد توثيق موفر الخدمة حدّين أدنيين متعارضين هما 2 و6 ثوانٍ؛ ولم يُتحقق من القبول باختبار فعلي.",
    "max": 20,
    "min": 2,
    "type": "number"
  },
  "fps": {
    "default": 24,
    "description": "عدد الإطارات في الثانية. يقتصر معدل 48/50 fps على 10 ثوانٍ. لا يؤثر معدل الإطارات على السعر لكل ثانية.",
    "enum": [
      24,
      25,
      48,
      50
    ],
    "type": "integer"
  },
  "model": {
    "description": "معرّف نموذج LTX 2.5.",
    "required": true,
    "type": "string"
  },
  "output_resolution": {
    "default": "1080p",
    "description": "دقة الفيديو الناتج. يقتصر Fast بدقة 1440p على 10 ثوانٍ.",
    "enum": [
      "720p",
      "1080p",
      "1440p"
    ],
    "type": "string"
  },
  "prompt": {
    "description": "وصف الفيديو، من 1 إلى 5,000 حرف.",
    "length": true,
    "max": 5000,
    "min": 1,
    "required": true,
    "type": "string"
  },
  "seed": {
    "description": "بذرة عشوائية اختيارية.",
    "max": 2147483647,
    "min": 0,
    "type": "integer"
  },
  "source_audio_url": {
    "description": "عنوان URL عبر HTTP(S) لملف صوتي بصيغة MP3 أو WAV أو M4A أو AAC أو OGG أو FLAC، بمدة لا تقل عن 2 ثانية وحجم لا يتجاوز 50 MB. يتحقق موفر الخدمة من الملف البعيد. يحتفظ الفيديو الناتج بالمسار الصوتي.",
    "required": true,
    "type": "string"
  },
  "source_image_url": {
    "description": "عنوان URL عبر HTTP(S) لإطار أول اختياري بصيغة JPG أو PNG أو WEBP، بحجم لا يتجاوز 10 MB. يتحقق موفر الخدمة من الملف البعيد ويستنتج منه نسبة أبعاد الفيديو الناتج.",
    "type": "string"
  }
}
```

#### القواعد الشرطية

تسري هذه المتطلبات عندما تتطابق جميع الشروط المدرجة.

- **عندما**: `model` = `ltx-2.5-fast-audio-to-video`; **غير مقبول**: `aspect_ratio`

## إنشاء قبول

HTTP 202 - POST /api/v1/ltx_video/audio_to_video

### مخطط الاستجابة

```json
{
  "properties": {
    "id": {
      "type": "string"
    },
    "status": {
      "enum": [
        "processing"
      ],
      "type": "string"
    },
    "task_replayed": {
      "type": "boolean"
    }
  },
  "required": [
    "id",
    "status"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "id": "tsk_reference_demo",
  "status": "processing"
}
```

## الاستطلاع قيد المعالجة

HTTP 200 - GET /api/v1/ltx_video/audio_to_video/:id

### مخطط الاستجابة

```json
{
  "properties": {
    "id": {
      "type": "string"
    },
    "status": {
      "enum": [
        "processing"
      ],
      "type": "string"
    }
  },
  "required": [
    "id",
    "status"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "id": "tsk_reference_demo",
  "status": "processing"
}
```

## اكتمل الاستطلاع

HTTP 200 - GET /api/v1/ltx_video/audio_to_video/:id

### مخطط الاستجابة

```json
{
  "properties": {
    "first_frame_image_url": {
      "type": "string",
      "x-runapi-generated-media": true
    },
    "id": {
      "type": "string"
    },
    "last_frame_image_url": {
      "type": "string",
      "x-runapi-generated-media": true
    },
    "status": {
      "enum": [
        "completed"
      ],
      "type": "string"
    },
    "usage": {
      "properties": {
        "cost": {
          "type": "number"
        }
      },
      "required": [
        "cost"
      ],
      "type": "object",
      "unevaluatedProperties": false
    },
    "videos": {
      "items": {
        "properties": {
          "url": {
            "type": "string",
            "x-runapi-generated-media": true
          }
        },
        "required": [
          "url"
        ],
        "type": "object",
        "unevaluatedProperties": false
      },
      "type": "array"
    }
  },
  "required": [
    "id",
    "status",
    "videos",
    "usage"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "id": "tsk_reference_demo",
  "status": "completed",
  "usage": {
    "cost": 0.05
  },
  "videos": [
    {
      "url": "https://file.runapi.ai/reference-video.mp4"
    }
  ]
}
```

## فشل الاستطلاع

HTTP 200 - GET /api/v1/ltx_video/audio_to_video/:id

### مخطط الاستجابة

```json
{
  "properties": {
    "error": {
      "type": "string"
    },
    "id": {
      "type": "string"
    },
    "status": {
      "enum": [
        "failed"
      ],
      "type": "string"
    }
  },
  "required": [
    "id",
    "status",
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "error": "Task processing failed.",
  "id": "tsk_reference_demo",
  "status": "failed"
}
```

## استدعاء العميل: مكتمل

HTTP 200 - POST callback_url

### مخطط الاستجابة

```json
{
  "properties": {
    "first_frame_image_url": {
      "type": "string",
      "x-runapi-generated-media": true
    },
    "id": {
      "type": "string"
    },
    "last_frame_image_url": {
      "type": "string",
      "x-runapi-generated-media": true
    },
    "status": {
      "enum": [
        "completed"
      ],
      "type": "string"
    },
    "usage": {
      "properties": {
        "cost": {
          "type": "number"
        }
      },
      "required": [
        "cost"
      ],
      "type": "object",
      "unevaluatedProperties": false
    },
    "videos": {
      "items": {
        "properties": {
          "url": {
            "type": "string",
            "x-runapi-generated-media": true
          }
        },
        "required": [
          "url"
        ],
        "type": "object",
        "unevaluatedProperties": false
      },
      "type": "array"
    }
  },
  "required": [
    "id",
    "status",
    "videos",
    "usage"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "id": "tsk_reference_demo",
  "status": "completed",
  "usage": {
    "cost": 0.05
  },
  "videos": [
    {
      "url": "https://file.runapi.ai/reference-video.mp4"
    }
  ]
}
```

## استدعاء العميل: فشل

HTTP 200 - POST callback_url

### مخطط الاستجابة

```json
{
  "properties": {
    "error": {
      "oneOf": [
        {
          "type": "string"
        },
        {
          "properties": {
            "code": {
              "type": "string"
            },
            "limit_cents": {
              "type": "integer"
            },
            "message": {
              "type": "string"
            },
            "reset_at": {
              "format": "date-time",
              "type": [
                "string",
                "null"
              ]
            },
            "used_cents": {
              "type": "integer"
            },
            "window": {
              "enum": [
                "1h",
                "1d",
                "7d",
                "daily",
                "weekly",
                "monthly",
                "lifetime"
              ],
              "type": "string"
            }
          },
          "required": [
            "code",
            "message"
          ],
          "type": "object",
          "unevaluatedProperties": false
        }
      ]
    },
    "id": {
      "type": "string"
    },
    "status": {
      "enum": [
        "failed"
      ],
      "type": "string"
    }
  },
  "required": [
    "id",
    "status",
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "error": {
    "code": "generation_failed",
    "message": "Task processing failed."
  },
  "id": "tsk_reference_demo",
  "status": "failed"
}
```

## الأخطاء

HTTP 401 - POST /api/v1/ltx_video/audio_to_video

### مخطط الاستجابة

```json
{
  "properties": {
    "error": {
      "description": "رسالة خطأ قابلة للقراءة البشرية.",
      "type": "string"
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "error": "Authentication required"
}
```

## الأخطاء

HTTP 401 - GET /api/v1/ltx_video/audio_to_video/:id

### مخطط الاستجابة

```json
{
  "properties": {
    "error": {
      "description": "رسالة خطأ قابلة للقراءة البشرية.",
      "type": "string"
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "error": "Authentication required"
}
```

## الأخطاء

HTTP 400 - POST /api/v1/ltx_video/audio_to_video

### مخطط الاستجابة

```json
{
  "oneOf": [
    {
      "properties": {
        "error": {
          "description": "رسالة خطأ قابلة للقراءة البشرية.",
          "type": "string"
        }
      },
      "required": [
        "error"
      ],
      "type": "object",
      "unevaluatedProperties": false
    },
    {
      "properties": {
        "error": {
          "description": "ملخص التحقق القابل للقراءة البشرية.",
          "type": "string"
        },
        "errors": {
          "additionalProperties": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "description": "رسائل التحقق مفتاحها حقل الطلب العام، مع مصفوفة من السلاسل القابلة للقراءة البشرية لكل حقل.",
          "type": "object"
        }
      },
      "required": [
        "error",
        "errors"
      ],
      "type": "object",
      "unevaluatedProperties": false
    }
  ]
}
```

### مثال على الاستجابة

```json
{
  "error": "model must be one of: ltx-2.5-fast-audio-to-video"
}
```

## الأخطاء

HTTP 402 - POST /api/v1/ltx_video/audio_to_video

### مخطط الاستجابة

```json
{
  "properties": {
    "error": {
      "description": "رسالة خطأ قابلة للقراءة البشرية.",
      "type": "string"
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "error": "Insufficient balance"
}
```

## الأخطاء

HTTP 429 - POST /api/v1/ltx_video/audio_to_video

### مخطط الاستجابة

```json
{
  "properties": {
    "error": {
      "description": "رسالة خطأ قابلة للقراءة البشرية.",
      "type": "string"
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "error": "API key credit limit exceeded"
}
```

## الأخطاء

HTTP 409 - POST /api/v1/ltx_video/audio_to_video

### مخطط الاستجابة

```json
{
  "properties": {
    "error": {
      "description": "رسالة خطأ قابلة للقراءة البشرية.",
      "type": "string"
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "error": "The request uses features that are not supported for the selected model"
}
```

## الأخطاء

HTTP 429 - POST /api/v1/ltx_video/audio_to_video

### مخطط الاستجابة

```json
{
  "properties": {
    "error": {
      "description": "رسالة خطأ قابلة للقراءة البشرية.",
      "type": "string"
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "error": "Rate limit reached. Please retry later."
}
```

## الأخطاء

HTTP 503 - POST /api/v1/ltx_video/audio_to_video

### مخطط الاستجابة

```json
{
  "properties": {
    "error": {
      "description": "رسالة خطأ قابلة للقراءة البشرية.",
      "type": "string"
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "error": "Service under maintenance, please try again later"
}
```

## الأخطاء

HTTP 503 - POST /api/v1/ltx_video/audio_to_video

### مخطط الاستجابة

```json
{
  "properties": {
    "error": {
      "description": "رسالة خطأ قابلة للقراءة البشرية.",
      "type": "string"
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "error": "The request timed out"
}
```

## الأخطاء

HTTP 404 - GET /api/v1/ltx_video/audio_to_video/:id

### مخطط الاستجابة

```json
{
  "properties": {
    "error": {
      "description": "رسالة خطأ قابلة للقراءة البشرية.",
      "type": "string"
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### مثال على الاستجابة

```json
{
  "error": "Task with id 'tsk_reference_demo' not found"
}
```

## نماذج الأكواد المولَّدة

استخدم cURL مباشرةً، أو ثبّت SDK للغة البرمجة التي تستخدمها. كل نموذج يُرسل الطلب الذي تم التحقق من صحته كما هو موضح في هذا المرجع.

### curl

```curl
curl -X POST https://runapi.ai/api/v1/ltx_video/audio_to_video \
  -H 'Authorization: Bearer YOUR_API_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"model":"ltx-2.5-fast-audio-to-video","prompt":"A natural speaking portrait.","source_audio_url":"https://cdn.runapi.ai/public/samples/voice.mp3","output_resolution":"720p","duration_seconds":2.01,"fps":24}'
```

### javascript

#### التثبيت

```bash
npm install @runapi.ai/ltx-video
```

```javascript
import { LtxVideoClient } from "@runapi.ai/ltx-video";

const client = new LtxVideoClient({ apiKey: process.env.RUNAPI_API_KEY });
const task = await client.audioToVideo.create({
  "model": "ltx-2.5-fast-audio-to-video",
  "prompt": "A natural speaking portrait.",
  "source_audio_url": "https://cdn.runapi.ai/public/samples/voice.mp3",
  "output_resolution": "720p",
  "duration_seconds": 2.01,
  "fps": 24
});
```

### python

#### التثبيت

```bash
pip install runapi-ltx-video
```

```python
import os
from runapi.ltx_video import LtxVideoClient

client = LtxVideoClient(api_key=os.environ["RUNAPI_API_KEY"])
task = client.audio_to_video.create(
  model="ltx-2.5-fast-audio-to-video",
  prompt="A natural speaking portrait.",
  source_audio_url="https://cdn.runapi.ai/public/samples/voice.mp3",
  output_resolution="720p",
  duration_seconds=2.01,
  fps=24
)
```

### go

#### التثبيت

```bash
go get github.com/runapi-ai/ltx-video-sdk/go@latest
```

```go
package main

import (
  "context"
  "log"
  "os"

  "github.com/runapi-ai/core-sdk/go/option"
  ltxvideo "github.com/runapi-ai/ltx-video-sdk/go/ltxvideo"
)

func main() {
  client, err := ltxvideo.NewClient(option.WithAPIKey(os.Getenv("RUNAPI_API_KEY")))
  if err != nil {
    log.Fatal(err)
  }

  task, err := client.AudioToVideo.Create(context.Background(), ltxvideo.AudioToVideoParams{
    Model: ltxvideo.AudioToVideoModel("ltx-2.5-fast-audio-to-video"),
    Prompt: "A natural speaking portrait.",
    SourceAudioURL: "https://cdn.runapi.ai/public/samples/voice.mp3",
    OutputResolution: "720p",
    DurationSeconds: func(value float64) *float64 { return &value }(2.01),
    FPS: func(value int) *int { return &value }(24),
  })
  if err != nil {
    log.Fatal(err)
  }
  _ = task
}
```

### ruby

#### التثبيت

```bash
gem install runapi-ltx-video
```

```ruby
require "runapi/ltx_video"

client = RunApi::LtxVideo::Client.new(api_key: ENV.fetch("RUNAPI_API_KEY"))
task = client.audio_to_video.create(
  model: "ltx-2.5-fast-audio-to-video",
  prompt: "A natural speaking portrait.",
  source_audio_url: "https://cdn.runapi.ai/public/samples/voice.mp3",
  output_resolution: "720p",
  duration_seconds: 2.01,
  fps: 24
)
```

### java

#### التثبيت

```kotlin
implementation("ai.runapi:runapi-ltx-video")
```

```java
import ai.runapi.ltxvideo.LtxVideoClient;
import ai.runapi.ltxvideo.types.AudioToVideoParams;
import ai.runapi.core.polling.TaskCreateResponse;

public final class Example {
  public static void main(String[] args) {
    LtxVideoClient client = LtxVideoClient.builder()
        .apiKey(System.getenv("RUNAPI_API_KEY"))
        .build();
    TaskCreateResponse task = client.audioToVideo().create(
        AudioToVideoParams.builder()
        .model("ltx-2.5-fast-audio-to-video")
        .prompt("A natural speaking portrait.")
        .sourceAudioUrl("https://cdn.runapi.ai/public/samples/voice.mp3")
        .outputResolution("720p")
        .durationSeconds(2.01)
        .fps(24)
            .build()
    );
  }
}
```

### php

#### التثبيت

```bash
composer require runapi-ai/ltx-video
```

```php
<?php

require __DIR__ . '/vendor/autoload.php';

use RunApi\Core\ClientOptions;
use RunApi\LtxVideo\LtxVideoClient;

$client = new LtxVideoClient(new ClientOptions(apiKey: getenv('RUNAPI_API_KEY')));
$task = $client->audioToVideo->create([
  "model" => "ltx-2.5-fast-audio-to-video",
  "prompt" => "A natural speaking portrait.",
  "source_audio_url" => "https://cdn.runapi.ai/public/samples/voice.mp3",
  "output_resolution" => "720p",
  "duration_seconds" => 2.01,
  "fps" => 24
]);
```

## الأدلة ذات الصلة

- [المصادقة](https://runapi.ai/ar/docs/guides/authentication.md)
- [البدء السريع](https://runapi.ai/ar/docs/guides/task-api/quickstart.md)

---

## المزيد من RunAPI

- [الرئيسية](https://runapi.ai/ar/.md)
- [كتالوج النماذج](https://runapi.ai/ar/models.md)
- [الأسعار](https://runapi.ai/ar/pricing.md)
- [مزودو الخدمة](https://runapi.ai/ar/models)
- [معرض المطالبات](https://runapi.ai/ar/prompts.md)
- [التوثيق](https://runapi.ai/ar/docs/guides)
- [حزم SDK](https://runapi.ai/ar/sdk.md)
- [CLI](https://runapi.ai/ar/cli.md)
- [خادم MCP](https://runapi.ai/ar/mcp.md)
- [x402](https://runapi.ai/ar/x402.md)
- [Claude Code مقابل Cursor](https://runapi.ai/ar/claude-code-vs-cursor.md)
- [إعداد Cursor API](https://runapi.ai/ar/cursor-api-setup.md)
- [RunAPI مقابل OpenRouter](https://runapi.ai/ar/openrouter-alternative.md)
- [المؤسسات](https://runapi.ai/ar/contact.md)
- [برنامج الإحالة](https://runapi.ai/ar/referral-program.md)
- [اتصل بنا](https://runapi.ai/ar/contact.md)
- [الشروط](https://runapi.ai/ar/terms.md)
- [الخصوصية](https://runapi.ai/ar/privacy.md)
- [فهرس الموقع للوكلاء](https://runapi.ai/llms.txt)

التواصل: contact@runapi.ai

## البيانات المنظمة

```json
[
  {
    "@context": "https://schema.org",
    "inLanguage": "ar",
    "@type": "WebSite",
    "name": "RunAPI",
    "url": "https://runapi.ai/ar",
    "potentialAction": {
      "@type": "SearchAction",
      "target": {
        "@type": "EntryPoint",
        "urlTemplate": "https://runapi.ai/ar/models?q={search_term_string}"
      },
      "query-input": "required name=search_term_string"
    }
  },
  {
    "@context": "https://schema.org",
    "inLanguage": "ar",
    "@type": "Organization",
    "name": "RunAPI",
    "url": "https://runapi.ai/ar",
    "logo": {
      "@type": "ImageObject",
      "url": "https://runapi.ai/icon.svg"
    },
    "sameAs": [
      "https://github.com/runapi-ai"
    ]
  },
  {
    "@context": "https://schema.org",
    "inLanguage": "ar",
    "@type": "TechArticle",
    "headline": "LTX Video صوت إلى فيديو",
    "description": "أنشئ فيديو من الصوت باستخدام LTX 2.5 Fast، مع صورة مصدر اختيارية.",
    "url": "https://runapi.ai/ar/docs/api/ltx-video/audio-to-video",
    "mainEntityOfPage": "https://runapi.ai/ar/docs/api/ltx-video/audio-to-video"
  }
]
```
