All endpoints
TikTok Music Videos

TikTok Music Videos API

Get the videos using a sound by music URL or numeric music ID. Returns the same fields as User Videos for each video, about 12 per page.

Price: $0.006 per page
Free tier: 50 requests/month
Endpoint
GET /v1/tiktok/music/videos

Parameters

url
TikTok music URL, e.g. https://www.tiktok.com/music/Face-Off-7016547803243022337 (max 500 characters). Provide exactly one of url or music_id.
music_id
Numeric music ID: the number at the end of a music URL, also returned as music_id on every video. Provide exactly one of url or music_id.
pages
Number of pages to fetch, 1-1000 (default: 1). Each page returns up to 12 videos.
get_sentiment
Set to true to add AI emotion analysis (+$0.001/page)

Response fields

videos
Array of videos using the sound
video_id
Numeric video ID
title
Video caption
url
Direct link to the video
date
Publication date and time
date_timestamp
Publication date as a Unix timestamp
author
Author's TikTok username
source
"TikTok"
domain
"tiktok.com"
snippet
Video caption text
region
2-letter region code the video was posted from
play_count
Number of plays/views
likes
Number of likes
comments
Number of comments
shares
Number of shares
downloads
Number of downloads
saves
Number of saves (favorites)
duration
Video duration in seconds (0 for photo posts)
is_ad
Whether the video is an ad
is_pinned
Whether the video is pinned to the author's profile
author_name
Author's display name
author_id
Author's numeric user ID
author_avatar
Author's avatar URL
author_url
Link to the author's profile
cover
Video cover/thumbnail URL
dynamic_cover
Animated cover URL
origin_cover
Original cover frame URL
video_url
Watermark-free playback/download URL (temporary)
video_url_watermarked
Watermarked playback URL (temporary)
size
File size of the watermark-free video in bytes
size_watermarked
File size of the watermarked video in bytes
images
Image URLs for photo posts; empty for videos
music_id
ID of the sound used
music_url
Playback URL of the sound
mentioned_user_ids
Numeric IDs of the users mentioned in the caption
sentiment
Emotion analysis: emotions, dominant_emotion, emotional_intensity, polarity (when get_sentiment=true)
music_id
The sound's numeric ID
pages
Number of pages returned
count
Number of results returned

Example Request

curl "https://apidirect.io/v1/tiktok/music/videos?music_id=7016547803243022337&pages=2"   -H "X-API-Key: YOUR_API_KEY"

Example Response

{
  "videos": [
    {
      "video_id": "7039385772222319878",
      "title": "it's about drive #thebadp1ace",
      "url": "https://www.tiktok.com/@thebadp1ace/video/7039385772222319878",
      "date": "2021-12-08 17:32:01",
      "date_timestamp": 1638984721,
      "author": "thebadp1ace",
      "source": "TikTok",
      "domain": "tiktok.com",
      "snippet": "it's about drive #thebadp1ace",
      "region": "US",
      "play_count": 77202977,
      "likes": 16419428,
      "comments": 60056,
      "shares": 172134,
      "downloads": 101612,
      "saves": 733192,
      "duration": 14,
      "is_ad": false,
      "is_pinned": false,
      "author_name": "ale",
      "author_id": "6911054760808875014",
      "author_avatar": "https://p16-common-sign.tiktokcdn-eu.com/.../avatar.jpeg",
      "author_url": "https://www.tiktok.com/@thebadp1ace",
      "cover": "https://p16-common-sign.tiktokcdn-eu.com/.../cover.jpeg",
      "dynamic_cover": "https://p16-common-sign.tiktokcdn-eu.com/.../dynamic_cover.webp",
      "origin_cover": "https://p16-common-sign.tiktokcdn-eu.com/.../origin_cover.jpeg",
      "video_url": "https://v19.tiktokcdn-eu.com/.../video.mp4",
      "video_url_watermarked": "https://v19.tiktokcdn-eu.com/.../video_wm.mp4",
      "size": 10246341,
      "size_watermarked": 9402354,
      "images": [],
      "music_id": "7016547803243022337",
      "music_url": "https://sf16-music.tiktokcdn-eu.com/.../music.mp3",
      "mentioned_user_ids": []
    }
  ],
  "music_id": "7016547803243022337",
  "pages": 2,
  "count": 24
}

Frequently asked questions

Where do I get the music ID?

It is the number at the end of a TikTok music URL, and every video returned by the other TikTok endpoints carries it as music_id.

Why are the music fields empty?

TikTok does not repeat the sound's metadata on this list. music_id is the requested sound; Music Details returns the title, artist, and video count.

How does pricing work?

You only pay for successful requests. The TikTok Music Videos API costs $0.006 per page. There are no monthly fees or commitments. You get 50 free requests per endpoint every month.

Do I need a credit card to start?

No. You can sign up and use the free tier (50 requests/endpoint/month) without adding a payment method. You only need to add a card when you want to exceed the free tier.

Are there rate limits?

Yes, there's a concurrency limit of 10 simultaneous requests per endpoint per user. If you need more, just get in touch.

Start using the TikTok Music Videos API

Get your API key and start making requests in minutes. 50 requests/month free every month.

Get API Key