Download TikTok Music

Extract the audio from a TikTok post. Hand the endpoint a post URL and it answers with a direct, playable link to the track behind that video, with no page scraping and no HTML parsing on your side. The response is deliberately small, just the link itself, which makes this a cheap call to run in bulk when you are archiving the sounds behind a set of videos.

Try on Playground
Endpoint Info
Request Method
:
GET
Request URL
:
https://api.primeapi.co/download-music?url={url}
Required Parameters
:
url
Request Examples
Request Flow
:
Download Music is a single GET call to /download-music, and url has to travel with it in the query string. Swap YOUR_API_KEY for your own key and both snippets below run as they are.
Authentication
:
Header based. Send X-PrimeAPI-Key with every request — there is no OAuth handshake and no token to refresh.
Credits
:
One Download Music call costs 1 credit. Your remaining balance comes back on every response in the X-PrimeAPI-Balance header, so you can watch usage without a second lookup.
cURL
curl -X GET "https://api.primeapi.co/download-music?url=https%3A%2F%2Fwww.tiktok.com%2F%40taylorswift%2Fvideo%2F7312069407369366830" \
  -H "X-PrimeAPI-Key: YOUR_API_KEY"
Python - Requests
import requests

url = "https://api.primeapi.co/download-music?url=https%3A%2F%2Fwww.tiktok.com%2F%40taylorswift%2Fvideo%2F7312069407369366830"
headers = {"X-PrimeAPI-Key": "YOUR_API_KEY"}

response = requests.get(url, headers=headers)

print(response.json())
print("Credits left:", response.headers.get("X-PrimeAPI-Balance"))
Endpoint Response
Example URL
:
https://api.primeapi.co/download-music?url=https%3A%2F%2Fwww.tiktok.com%2F%40taylorswift%2Fvideo%2F7312069407369366830
Content Type
:
JSON
Example Response
{
    "play": "https://sf16-ies-music-va.tiktokcdn.com/obj/ies-music-ttp-dup-us/7312069539162852139.mp3"
}
Related Endpoints

More TikTok Download Endpoints

View all Download Endpoints
Contact
You can contact us via Telegram or Gmail
Telegram Logo
Telegram
@primeapi_co
Gmail Logo
Gmail
primeapico@gmail