TikTok
TikTok 影片資訊、用戶個人檔案與搜尋。
- 每次請求最多回傳 50 部影片
- 影片下載 URL 會快速過期
- 快速端點(
/videos/:id、/users/:username):2-5 秒 - 較慢端點(
/search、/comments、/videos):20-40 秒 — 這些使用無頭瀏覽器自動化;請設定較長的逾時時間(60 秒以上)
影片
GET /tiktok/videos/:videoId — 4 credits
依影片 ID 取得 TikTok 影片資訊。
| 參數 | 類型 | 必填 | 預設 | 說明 |
|---|---|---|---|---|
videoId | string | 是 | — | TikTok 影片 ID |
cURL
curl -H "x-api-key: sk_oms_xxx" \
https://api.omniscrape.dev/tiktok/videos/7234567890123456789回應
{
"id": "7614295022346784030",
"url": "https://www.tiktok.com/@tiktok/video/7614295022346784030",
"title": "#filmtok LOCK IN, we caught up with your faves...",
"description": "#filmtok LOCK IN, we caught up with your faves...",
"author": "tiktok",
"authorId": "107955",
"duration": 88,
"views": 72400,
"likes": 2346,
"comments": 538,
"shares": 222,
"saves": 192,
"createdAt": "2026-03-06T23:53:48.000Z",
"thumbnail": "https://...",
"music": "original sound"
}用戶
GET /tiktok/users/:username — 2 credits
取得 TikTok 用戶資訊及近期影片。
注意: 部分用戶的
videos陣列可能為空。請使用/tiktok/users/:username/videos來可靠地取得用戶影片。
| 參數 | 類型 | 必填 | 預設 | 說明 |
|---|---|---|---|---|
username | string | 是 | — | TikTok 用戶名稱 |
cURL
curl -H "x-api-key: sk_oms_xxx" \
https://api.omniscrape.dev/tiktok/users/cooluser回應
{
"username": "tiktok",
"displayName": "TikTok",
"verified": true,
"avatarUrl": "https://...",
"bio": "One TikTok can make a big impact",
"followers": 93144898,
"following": 3,
"hearts": 455040412,
"videoCount": 1412,
"videos": [
{
"id": "7614295022346784030",
"url": "https://www.tiktok.com/@tiktok/video/7614295022346784030",
"title": "#filmtok LOCK IN, we caught up with your faves...",
"description": "#filmtok LOCK IN, we caught up with your faves...",
"author": "tiktok",
"authorId": "107955",
"duration": 88,
"views": 72400,
"likes": 2344,
"comments": 538,
"shares": 222,
"saves": 192,
"createdAt": "2026-03-06T23:53:48+00:00",
"thumbnail": "",
"music": "original sound"
}
// ... more videos
]
}GET /tiktok/users/:username/videos — 2 credits
取得 TikTok 用戶的影片列表。
**注意:**此端點通常需要 5-15 秒。請使用至少 30 秒的逾時時間。
| 參數 | 類型 | 必填 | 預設 | 說明 |
|---|---|---|---|---|
username | string | 是 | — | TikTok 用戶名稱 |
count | integer | 否 | 30 | 影片數量(最多 50) |
cURL
curl -H "x-api-key: sk_oms_xxx" \
"https://api.omniscrape.dev/tiktok/users/cooluser/videos?count=10"回應
{
"username": "tiktok",
"displayName": "tiktok",
"videos": [
{
"id": "7614295022346784030",
"url": "https://www.tiktok.com/@tiktok/video/7614295022346784030",
"title": "#filmtok LOCK IN, we caught up with your faves...",
"description": "#filmtok LOCK IN, we caught up with your faves...",
"author": "tiktok",
"authorId": "107955",
"duration": 88,
"views": 72400,
"likes": 2344,
"comments": 538,
"shares": 222,
"saves": 192,
"createdAt": "2026-03-06T23:53:48+00:00",
"thumbnail": "",
"music": "original sound"
}
// ... more videos
]
}留言
GET /tiktok/videos/:videoId/comments — 3 credits
取得 TikTok 影片的留言。
**注意:**此端點使用瀏覽器自動化,通常需要 20-40 秒。請使用至少 60 秒的逾時時間。
| 參數 | 類型 | 必填 | 預設 | 說明 |
|---|---|---|---|---|
videoId | string | 是 | — | TikTok 影片 ID |
cursor | string | 否 | — | 前一次回應的分頁游標 |
cURL
curl -H "x-api-key: sk_oms_xxx" \
https://api.omniscrape.dev/tiktok/videos/7234567890123456789/comments回應
{
"videoId": "7614295022346784030",
"commentCount": 538,
"comments": [
{
"text": "This is amazing!",
"author": "filmfan42",
"authorId": "6812345678901234567",
"likes": 120,
"replies": 5,
"createdAt": "2026-03-07T01:15:00+00:00"
}
// ... more comments
],
"cursor": "50",
"hasMore": true
}搜尋
GET /tiktok/videos/search — 2 credits per item (default 20 items)
依關鍵字搜尋 TikTok 影片。
**注意:**此端點使用瀏覽器自動化,通常需要 20-40 秒。請使用至少 60 秒的逾時時間。
| 參數 | 類型 | 必填 | 預設 | 說明 |
|---|---|---|---|---|
q | string | 是 | — | 搜尋關鍵字 |
count | integer | 否 | 20 | 結果數量(最多 30) |
cURL
curl -H "x-api-key: sk_oms_xxx" \
"https://api.omniscrape.dev/tiktok/videos/search?q=cooking&count=10"回應
{
"keyword": "cooking",
"videos": [
{
"id": "7608955538445045014",
"url": "https://www.tiktok.com/@courtneys_bites/video/7608955538445045014",
"title": "Crispy Japanese long fries! the crisp is perfec...",
"description": "Crispy Japanese long fries! the crisp is perfec...",
"author": "courtneys_bites",
"authorId": "6801555983929328646",
"duration": 60,
"views": 1300000,
"likes": 45800,
"comments": 165,
"shares": 11100,
"saves": 21900,
"createdAt": "2026-02-20T14:33:41+00:00",
"thumbnail": "https://...",
"music": "Storytelling"
}
// ... more videos
]
}字幕
GET /tiktok/videos/:videoId/subtitles — 4 credits
取得 TikTok 影片的字幕/標題。回傳 WebVTT 解析的段落(含時間戳)和完整文字。支援 40 多種語言。
| 參數 | 類型 | 必填 | 預設 | 說明 |
|---|---|---|---|---|
videoId | string | 是 | — | TikTok 影片 ID |
language | string | 否 | en | 字幕語言代碼(例如 en、ja、ko、zh-Hans) |
cURL
curl -H "x-api-key: sk_oms_xxx" \
"https://api.omniscrape.dev/tiktok/videos/7234567890123456789/subtitles?language=en"回應
{
"videoId": "7614295022346784030",
"title": "#filmtok LOCK IN, we caught up with your faves...",
"language": "en",
"isAutoGenerated": true,
"availableLanguages": ["zh-Hans", "vi", "en", "ja", "ko", "fr", "de", "es"],
"segments": [
{
"start": 0.14,
"end": 1.86,
"text": "Ethan Hawke is standing right behind me."
},
{
"start": 1.861,
"end": 3.621,
"text": "He's like my obsession, you know,"
}
// ... 更多段落
],
"fullText": "Ethan Hawke is standing right behind me. He's like my obsession, you know, in a normal way, not in a creepy way..."
}Last updated on