Files
SnapOtter/apps/docs/zh-TW/tools/video/replace-audio.md
T
SnapOtterandGitHub 4963ab3bbd feat(docs-i18n): translate all documentation into 20 languages
All 181 docs markdown files translated into 20 languages (apps/docs/<locale>/**). Companion to the i18n code PR; admin-merged because the file count exceeds GitHub's per-PR CI trigger limit. Validated by pnpm i18n:check (all surfaces, 0 stale/missing) and a clean all-locale docs build.
2026-07-11 13:52:47 +08:00

1.4 KiB

description, i18n_source_hash, i18n_provenance, i18n_output_hash
description i18n_source_hash i18n_provenance i18n_output_hash
用另一個檔案替換影片的音訊軌。 fabc2a953103 human 1ce24d60f423

Replace Audio

用一個音訊檔案替換影片的音訊軌。同時上傳一個影片和一個音訊檔案。

API Endpoint

POST /api/v1/tools/video/replace-audio

接受包含剛好兩個檔案的 multipart form data:一個影片檔案後接一個音訊檔案。

Parameters

此工具沒有設定參數。以兩個 file 部分上傳一個影片檔案和一個音訊檔案。

Example Request

curl -X POST http://localhost:1349/api/v1/tools/video/replace-audio \
  -H "Authorization: Bearer si_your-api-key" \
  -F "file=@clip.mp4" \
  -F "file=@voiceover.mp3"

Example Response

{
  "jobId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
  "downloadUrl": "/api/v1/download/a1b2c3d4-e5f6-7890-abcd-ef1234567890/clip.mp4",
  "originalSize": 12500000,
  "processedSize": 13100000
}

Notes

  • 必須剛好上傳兩個檔案:第一個必須是影片,第二個必須是音訊檔案。
  • 若音訊檔案比影片長,會被裁剪以符合影片時長。若較短,剩餘的影片則會以靜音播放。
  • 影片串流會直接複製而不重新編碼,因此不會有影片品質損失。