mirror of
https://github.com/snapotter-hq/SnapOtter.git
synced 2026-08-03 07:46:42 +02:00
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.
2.2 KiB
2.2 KiB
description, i18n_source_hash, i18n_provenance, i18n_output_hash
| description | i18n_source_hash | i18n_provenance | i18n_output_hash |
|---|---|---|---|
| 檢視、編輯或移除音訊中繼資料標籤(ID3)。 | 0717018e11cb | human | d6159db82b94 |
音訊中繼資料
檢視、編輯或移除音訊中繼資料標籤,例如標題、演出者與專輯(ID3 及類似的標籤格式)。
API 端點
POST /api/v1/tools/audio/audio-metadata
接受包含一個音訊檔案與一個 JSON settings 欄位的 multipart form data。
參數
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| strip | boolean | No | false |
移除所有現有的中繼資料標籤 |
| title | string | No | - | 設定標題標籤(最多 500 個字元) |
| artist | string | No | - | 設定演出者標籤(最多 500 個字元) |
| album | string | No | - | 設定專輯標籤(最多 500 個字元) |
範例請求
編輯中繼資料標籤:
curl -X POST http://localhost:1349/api/v1/tools/audio/audio-metadata \
-H "Authorization: Bearer si_your-api-key" \
-F "file=@audio.mp3" \
-F 'settings={"title": "My Song", "artist": "Artist Name", "album": "Album Name"}'
移除所有中繼資料:
curl -X POST http://localhost:1349/api/v1/tools/audio/audio-metadata \
-H "Authorization: Bearer si_your-api-key" \
-F "file=@audio.mp3" \
-F 'settings={"strip": true}'
範例回應
{
"jobId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"downloadUrl": "/api/v1/download/a1b2c3d4-e5f6-7890-abcd-ef1234567890/audio.mp3",
"originalSize": 4500000,
"processedSize": 4480000,
"metadata": {
"container": "mp3",
"durationS": 245.3,
"bitrateKbps": 192,
"tags": {
"title": "My Song",
"artist": "Artist Name",
"album": "Album Name"
}
}
}
附註
- 回應包含一個
metadata物件,內含容器格式、時長、位元率與目前的標籤。 - 當
strip為true時,所有標籤欄位都會被忽略,且每個現有標籤都會被移除。 - 只有你提供的標籤會被更新;未指定的標籤維持不變。
- 輸出格式與輸入格式相同。