Media files object

9 endpoints on 8 platforms return the Media files object with the same 29 fields, so code written for one platform reads the others unchanged. A call costs $0.0020 to $0.0200.

Stable object · Updated 2026-11-21Open in ChatGPTOpen in Claude

Fields

A field the platform cannot give is left out of the item and named in meta.unavailable. It is never filled with a guess or a zero.

post_id text

ID of the post the files belong to: the same as the detail endpoint's id

type text

Content format: video, or image (a picture post or photo set): video image

title text

Title; the caption where the platform has no separate title

author object

Author

author.id text

Author's account ID

author.name text

Author's display name

duration number

Length of the video, in seconds; a picture post has none

files list of object

Every file, one entry each: the video in each quality, the audio, the cover, each picture, the subtitles

files[].kind text

What the file is: video, audio (the background music, or a sound track served apart from the picture), cover, image (a picture of the post), subtitle: video audio cover image subtitle

files[].index integer

Place of a picture in the post, from 1; null for other files

files[].quality text

Quality, as the platform names it or by the short side in pixels, such as 720p or 1080p; null where there is none

files[].width integer

Width, in pixels

files[].height integer

Height, in pixels

files[].codec text

Codec, such as h264, h265, h266, av1 or aac; ByteDance's own BVC2 (Douyin, TikTok) is bytevc2, which many players cannot play, so pick an h264 or h265 file for a common format; null where the platform does not say: h264 h265 h266 av1 aac bytevc2

files[].bitrate integer

Bit rate, in bits a second

files[].size integer

File size, in bytes

files[].format text

File format: mp4, m4s (Bilibili's separate picture and sound streams), mp3, m4a, jpeg, png, webp, heic, gif, kvif (Kuaishou's image format) or srt; null where the address does not say: mp4 m4s mp3 m4a jpeg png webp heic gif kvif srt

files[].duration number

Length of an audio or video file, in seconds

files[].title text

Name of the background music; null for other files

files[].lang text

Language code of the subtitles, such as zh-CN or en-US

files[].watermark yes/no

Whether the file carries the platform's watermark

files[].url link

Address of the file

files[].backup_urls list of link standard

Other addresses of the same file, for when the main one fails

files[].expires_at time

When the address expires, as its signature says; null where the signature does not say. Once it has, call again for new addresses

files[].headers object

Request headers the address has to be fetched with, keyed by the header's name in lower case; absent on platforms whose addresses need none

files[].headers.referer text

The Referer to send

files[].stable_url link

The platform's play address, which redirects to the file's address of the moment and lasts longer than url; null where there is none

files[].live object

The video of a live photo; null for a picture that is not one

files[].live.url link

Address of the live photo's video

files[].live.duration number

Length of the live photo's video, in seconds

decrypt object

How to decrypt the files, where they are encrypted; null where they are not

decrypt.method text

The method. isaac64_xor_head: seed ISAAC64 with key, take each 64-bit output as 8 big-endian bytes for a key stream as long as bytes says, and XOR it over the start of the file; the rest is left as it is: isaac64_xor_head

decrypt.key text

The key, good only for the addresses of the same answer

decrypt.bytes integer

How many bytes at the start of the file are encrypted

What a platform cannot give

A platform stands against a field when none of its endpoints gives it.

FieldNot available on
titleBilibili
author.idBilibili
author.nameBilibili
files[].indexWeChat ChannelsBilibili
files[].qualityInstagram
files[].codecInstagramWeChat ChannelsKuaishou
files[].bitrateInstagramWeChat Channels
files[].sizeInstagramBilibili
files[].durationBilibili
files[].titleInstagramXiaohongshu (RedNote)WeChat ChannelsBilibiliWeiboKuaishou
files[].langTikTokInstagramDouyinWeChat ChannelsBilibiliWeiboKuaishou
files[].watermarkInstagramWeChat ChannelsBilibiliKuaishou
files[].backup_urlsInstagramWeChat ChannelsWeibo
files[].expires_atXiaohongshu (RedNote)WeChat ChannelsKuaishou
files[].headers.refererTikTokInstagramDouyinXiaohongshu (RedNote)WeChat ChannelsWeiboKuaishou
files[].stable_urlTikTokInstagramXiaohongshu (RedNote)WeChat ChannelsBilibiliWeiboKuaishou
files[].live.urlTikTokInstagramWeChat ChannelsBilibiliWeiboKuaishou
files[].live.durationTikTokInstagramWeChat ChannelsBilibiliWeiboKuaishou
decrypt.methodTikTokInstagramDouyinXiaohongshu (RedNote)BilibiliWeiboKuaishou
decrypt.keyTikTokInstagramDouyinXiaohongshu (RedNote)BilibiliWeiboKuaishou
decrypt.bytesTikTokInstagramDouyinXiaohongshu (RedNote)BilibiliWeiboKuaishou
One endpoint may still leave out a field another gives: each endpoint's page lists what it cannot give, and every answer says so in meta.unavailable.

Endpoints that return Media files

The number beside each platform is how many of its endpoints return it.

EndpointPathPrice
TikTok video downloader, no watermarkGET/v1/tiktok/videos/media/get$0.0020
Instagram video and photo downloaderGET/v1/instagram/posts/media/get$0.0020
Douyin video downloader, no watermarkGET/v1/douyin/videos/media/get$0.0020
RedNote (Xiaohongshu) video downloaderGET/v1/xiaohongshu/videos/media/get$0.0200
WeChat Channels video downloadGET/v1/wechat_channels/videos/media/get$0.0200
Bilibili video downloaderGET/v1/bilibili/videos/media/get$0.0020
Weibo video and image downloaderGET/v1/weibo/posts/media/get$0.0020
Kuaishou video downloaderGET/v1/kuaishou/videos/media/get$0.0020

Example

One item from tiktok.videos.media.get, as recorded 2026-10-12 18:45 UTC. Names, text, IDs and links are examples; the figures are as recorded.

Media files · tiktok.videos.media.get
{
  "post_id": "7576723593279365074",
  "type": "video",
  "title": "I tried weekend hiking for 30 days. Here is what happened",
  "author": { "id": "6797150316661954559", "name": "Hannah Weiss" },
  "duration": 89.373,
  "files": [
    {
      "kind": "video",
      "index": null,
      "quality": "720p",
      "width": 720,
      "height": 1280,
      "codec": "h265",
      "bitrate": 334473,
      "size": 3736653,
      "format": "mp4",
      "duration": 89.373,
      "title": null,
      "watermark": false,
      "url": "https://www.tiktok.com/@northside_coffee/video/7390042224677822398",
      "backup_urls": [
        "https://www.tiktok.com/@hannah.w.photo/video/7449784160616781997"
      ],
      "expires_at": "2026-10-13T00:47:02.000Z"
    },
    {
      "kind": "video",
      "index": null,
      "quality": "540p",
      "width": 576,
      "height": 1024,
      "codec": "h265",
      "bitrate": 254642,
      "size": 2844805,
      "format": "mp4",
      "duration": 89.373,
      "title": null,
      "watermark": false,
      "url": "https://www.tiktok.com/@maya.makes/video/7540639198878317897",
      "backup_urls": [
        "https://www.tiktok.com/@fieldnotes_studio/video/7210306615796042888"
      ],
      "expires_at": "2026-10-13T00:47:02.000Z"
    },
    // … 2 more
  ]
}

The whole response is on the endpoint's page →

Related

Other objects