Social Media Data API
GET /v1/social-media/data/*
Access 800+ endpoints across 16 social media platforms through a single API. Retrieve videos, user profiles, comments, search results, live streams, trending content, and more.
Endpoint
GET https://api.leaper.one/v1/social-media/data/{platform}/{interface}/{action}All query parameters are forwarded to the upstream provider. Responses are returned in their original format.
Quick Start
curl -G "https://api.leaper.one/v1/social-media/data/bilibili/web/fetch_one_video" \
--data-urlencode "url=https://www.bilibili.com/video/BV1GJ411x7h7" \
-H "Authorization: Bearer sk-your-api-key"Supported Platforms
| Platform | Prefix | Endpoints | Features |
|---|---|---|---|
| Douyin | douyin/ | 248 | Video, user, search, live, billboard, creator analytics |
| TikTok | tiktok/ | 109 | Video, user, search, trending, comments, hashtags |
| Bilibili | bilibili/ | 41 | Video, user, search, live, danmaku, subtitles |
| YouTube | youtube/ | 25 | Video, channel, search, comments, playlists |
instagram/ | 52 | Posts, reels, stories, user profiles, search | |
| Twitter/X | twitter/ | 28 | Tweets, user, search, trends, spaces |
weibo/ | 30 | Posts, user, search, trending | |
| Xiaohongshu | xiaohongshu/ | 38 | Notes, user, search |
| Kuaishou | kuaishou/ | 29 | Video, user, search, live |
wechat/ | 8 | Public accounts, video accounts | |
| Threads | threads/ | 11 | Posts, user profiles |
linkedin/ | 4 | Profiles, posts | |
| Zhihu | zhihu/ | 6 | Answers, articles, user |
| Lemon8 | lemon8/ | 8 | Posts, user |
| NetEase Music | netease/ | 12 | Songs, playlists, user |
reddit/ | 9 | Posts, subreddits, comments | |
| Hybrid | hybrid/ | 2 | Auto-detect platform from URL |
For the complete list of all endpoints and their parameters, fetch the OpenAPI spec at GET https://api.leaper.one/openapi.json — it includes every available endpoint with full parameter definitions.
Platform Examples
Bilibili
# Get video details
curl -G "https://api.leaper.one/v1/social-media/data/bilibili/web/fetch_video_detail" \
--data-urlencode "bvid=BV1GJ411x7h7" \
-H "Authorization: Bearer sk-your-api-key"
# Get video play URL (for downloading)
curl -G "https://api.leaper.one/v1/social-media/data/bilibili/web/fetch_video_playurl" \
--data-urlencode "bvid=BV1GJ411x7h7" \
--data-urlencode "cid=171776208" \
-H "Authorization: Bearer sk-your-api-key"
# Get user profile
curl -G "https://api.leaper.one/v1/social-media/data/bilibili/web/fetch_user_profile" \
--data-urlencode "uid=546195" \
-H "Authorization: Bearer sk-your-api-key"
# Search videos
curl -G "https://api.leaper.one/v1/social-media/data/bilibili/web/fetch_general_search" \
--data-urlencode "keyword=programming" \
-H "Authorization: Bearer sk-your-api-key"
# Get video comments
curl -G "https://api.leaper.one/v1/social-media/data/bilibili/web/fetch_video_comments" \
--data-urlencode "bvid=BV1GJ411x7h7" \
-H "Authorization: Bearer sk-your-api-key"
# Get video danmaku (bullet comments)
curl -G "https://api.leaper.one/v1/social-media/data/bilibili/web/fetch_video_danmaku" \
--data-urlencode "cid=171776208" \
-H "Authorization: Bearer sk-your-api-key"
# Get video subtitles
curl -G "https://api.leaper.one/v1/social-media/data/bilibili/web/fetch_video_subtitle" \
--data-urlencode "bvid=BV1GJ411x7h7" \
-H "Authorization: Bearer sk-your-api-key"Key Bilibili endpoints:
| Endpoint | Description |
|---|---|
bilibili/web/fetch_one_video | Get video by URL |
bilibili/web/fetch_video_detail | Get video details by BV ID |
bilibili/web/fetch_video_playurl | Get video play/download URLs |
bilibili/web/fetch_video_comments | Get video comments |
bilibili/web/fetch_video_danmaku | Get bullet comments |
bilibili/web/fetch_video_subtitle | Get subtitles |
bilibili/web/fetch_user_profile | Get user profile |
bilibili/web/fetch_user_post_videos | Get user's uploaded videos |
bilibili/web/fetch_general_search | Search videos |
bilibili/web/fetch_hot_search | Get trending searches |
bilibili/web/fetch_live_room_detail | Get live room info |
bilibili/web/bv_to_aid | Convert BV ID to AV ID |
Douyin
# Get video by share URL
curl -G "https://api.leaper.one/v1/social-media/data/douyin/web/fetch_one_video_by_share_url" \
--data-urlencode "url=https://v.douyin.com/L4FJNR3/" \
-H "Authorization: Bearer sk-your-api-key"
# Get video by aweme_id
curl -G "https://api.leaper.one/v1/social-media/data/douyin/web/fetch_one_video" \
--data-urlencode "aweme_id=7123456789" \
-H "Authorization: Bearer sk-your-api-key"
# Search videos
curl -G "https://api.leaper.one/v1/social-media/data/douyin/web/fetch_general_search_result" \
--data-urlencode "keyword=cooking" \
-H "Authorization: Bearer sk-your-api-key"TikTok
# Get video details
curl -G "https://api.leaper.one/v1/social-media/data/tiktok/web/fetch_post_detail" \
--data-urlencode "aweme_id=7123456789" \
-H "Authorization: Bearer sk-your-api-key"
# Get user profile
curl -G "https://api.leaper.one/v1/social-media/data/tiktok/web/fetch_user_profile" \
--data-urlencode "secUid=MS4wLjABAAAA..." \
-H "Authorization: Bearer sk-your-api-key"
# Search
curl -G "https://api.leaper.one/v1/social-media/data/tiktok/web/fetch_search_video" \
--data-urlencode "keyword=dance" \
-H "Authorization: Bearer sk-your-api-key"YouTube
# Get video info
curl -G "https://api.leaper.one/v1/social-media/data/youtube/web/get_video_info" \
--data-urlencode "video_id=dQw4w9WgXcQ" \
-H "Authorization: Bearer sk-your-api-key"
# Get channel info
curl -G "https://api.leaper.one/v1/social-media/data/youtube/web/get_channel_info" \
--data-urlencode "channel_id=UCuAXFkgsw1L7xaCfnd5JJOw" \
-H "Authorization: Bearer sk-your-api-key"# Get post by URL
curl -G "https://api.leaper.one/v1/social-media/data/instagram/v1/fetch_post_by_url" \
--data-urlencode "url=https://www.instagram.com/p/ABC123/" \
-H "Authorization: Bearer sk-your-api-key"
# Get user profile
curl -G "https://api.leaper.one/v1/social-media/data/instagram/web/fetch_user_info_by_username" \
--data-urlencode "username=instagram" \
-H "Authorization: Bearer sk-your-api-key"Twitter/X
# Get tweet details
curl -G "https://api.leaper.one/v1/social-media/data/twitter/web/fetch_tweet_detail" \
--data-urlencode "tweet_id=1234567890" \
-H "Authorization: Bearer sk-your-api-key"
# Get user profile
curl -G "https://api.leaper.one/v1/social-media/data/twitter/web/fetch_user_profile" \
--data-urlencode "screen_name=elonmusk" \
-H "Authorization: Bearer sk-your-api-key"Hybrid (Auto-detect Platform)
# Auto-detect platform from any social media URL
curl -G "https://api.leaper.one/v1/social-media/data/hybrid/video_data" \
--data-urlencode "url=https://v.douyin.com/L4FJNR3/" \
-H "Authorization: Bearer sk-your-api-key"Response Format
The general response structure is:
{
"code": 200,
"data": {
// Platform-specific data
}
}code: 200 or code: 0 indicates success.
Error Responses
Invalid path (400)
{ "error": { "message": "Invalid path", "type": "invalid_request_error" } }Platform not available (403)
{ "error": { "message": "Platform \"admin\" is not available", "type": "invalid_request_error" } }Upstream timeout (504)
{ "error": { "message": "Upstream request timed out", "type": "server_error" } }Upstream unavailable (503)
{ "error": { "message": "Failed to reach upstream service", "type": "server_error" } }Pricing
$0.01 per successful request. Failed requests (HTTP 4xx/5xx) are not billed.
Comparison with Video Extract
| Feature | Video Extract | Social Media Data API |
|---|---|---|
| Endpoint | GET /v1/social-media/video/extract | GET /v1/social-media/data/* |
| Input | Any social media URL | Platform-specific API path + params |
| Response | Standardized format | Raw upstream response |
| Use case | Quick video download | Full platform API access |
| Scope | Video extraction only | 800+ endpoints across 16 platforms |
| Pricing | $0.01/call | $0.01/call |
Tip: If you just need to download videos from a URL, use Video Extract for its simpler interface and standardized response. Use the Social Media Data API when you need the full range of platform features (user profiles, search, comments, live streams, etc.).
Notes
- All endpoints are GET requests with query string parameters.
- Media URLs (videos, images) are typically time-limited. Download promptly after retrieval.
- Some endpoints may require platform-specific IDs. Use the appropriate search or lookup endpoint first if needed.
- For the complete endpoint catalog with all parameters, import the OpenAPI spec into Postman or Swagger UI.