# TikTok on Onekey > 39 endpoints for TikTok (0 stable, 39 beta), 1 to 3 credits each. Category: Social networks. One key, one JSON shape. Base URL: https://api.onekey.dev Auth: header `x-api-key: `. Call shape: `GET /v1/{platform}/{endpoint}?{params}`. Every response is `{success, data, metadata, error}`; check `success` first. Cost is in `metadata.credits_charged`. Free when served from cache (0.2 credit for a cached response over 100 KB). Failed and not-found calls are refunded. Status: stable = verified against the live source; beta = not yet verified, fields may be missing. Access: 39 of 39 endpoints are marked "needs a pack" or "may need a pack": free-grant credits reach only the open fetch path; a verified email and a purchased pack unlock the rest. Page: https://onekey.dev/platforms/tiktok Reference (Markdown): https://onekey.dev/docs/api/tiktok.md All docs: https://onekey.dev/llms.txt ## Canonical fields returned Unified-schema fields (same names on every platform), with how many of the 39 mapped TikTok endpoints return each: - `content.text` (string): 27 - `author.username` (string): 25 - `engagement.likes` (integer): 24 - `media.thumbnailUrl` (URL): 22 - `engagement.views` (integer): 21 - `content.createdAt` (ISO 8601 date): 20 - `author.displayName` (string): 19 - `content.id` (string): 19 - `engagement.comments` (integer): 14 - `author.avatarUrl` (URL): 13 - `author.id` (string): 13 - `engagement.shares` (integer): 12 - `entity.id` (string): 9 - `media.durationSeconds` (number): 9 - `content.title` (string): 8 - `entity.name` (string): 7 - `entity.url` (URL): 7 - `content.url` (URL): 6 - `engagement.bookmarks` (integer): 6 - `author.followers` (integer): 5 - `author.verified` (boolean): 4 - `media.url` (URL): 3 - `author.contentCount` (integer): 2 - `author.following` (integer): 2 - `author.url` (URL): 2 - `content.language` (string): 2 - `entity.stats.itemCount` (integer): 2 - `entity.status` (string): 2 - `author.bio` (string): 1 - `author.country` (string): 1 - `entity.description` (string): 1 - `media.audioUrl` (URL): 1 - plus 14 platform-specific fields under `ext.` ## Endpoints ### tiktok.adlibrary_ad Get a TikTok Ad Library ad. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/adlibrary_ad?url=https%3A%2F%2Fwww.tiktok.com%2F%40natgeo%2Fvideo%2F7123456789012345678` with header `x-api-key: YOUR_API_KEY` - Parameters: - `url` (string, optional): Url (URL) - `ad_id` (string, optional): Ad id in the TikTok ad library (alternative to url) - Fields returned: `entity.id`, `author.displayName`, `content.text`, `content.createdAt`, `entity.status`, `media.url`, `entity.url`, `engagement.views`, `engagement.likes` - Reference: https://onekey.dev/docs/api/tiktok/adlibrary_ad.md ### tiktok.adlibrary_search Search the TikTok Ad Library. - Price: 3 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/adlibrary_search?query=coffee` with header `x-api-key: YOUR_API_KEY` - Parameters: - `query` (string, optional): Query - `advertiser_name` (string, optional): Advertiser name (alternative to query) - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `entity.id`, `author.displayName`, `content.text`, `content.createdAt`, `entity.status`, `media.url`, `entity.url`, `engagement.views`, `engagement.likes` - Reference: https://onekey.dev/docs/api/tiktok/adlibrary_search.md ### tiktok.ads_top Top-performing ads board for a market and time window. - Price: 3 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/ads_top` with header `x-api-key: YOUR_API_KEY` - Parameters: - `country` (string, optional, default US): Country - `period` (string, optional, default 7): Period - Fields returned: `entity.id`, `entity.name`, `entity.url`, `engagement.views`, `engagement.likes`, `media.thumbnailUrl`, `ext.rank`, `ext.postCount`, `ext.hotValue`, `ext.ctr` - Reference: https://onekey.dev/docs/api/tiktok/ads_top.md ### tiktok.collection_videos List videos in a TikTok collection. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/collection_videos?url=https%3A%2F%2Fwww.tiktok.com%2F%40natgeo%2Fvideo%2F7123456789012345678` with header `x-api-key: YOUR_API_KEY` - Parameters: - `url` (string, required): Url (URL) - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `content.id`, `content.url`, `content.title`, `content.text`, `content.createdAt`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.views`, `media.thumbnailUrl`, `author.username` - Reference: https://onekey.dev/docs/api/tiktok/collection_videos.md ### tiktok.comment Look up one TikTok comment by URL. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/comment?comment_url=https%3A%2F%2Fwww.tiktok.com%2F%40natgeo%2Fvideo%2F7123456789012345678` with header `x-api-key: YOUR_API_KEY` - Parameters: - `comment_url` (string, required): Comment url (URL) - Fields returned: `content.id`, `content.text`, `content.createdAt`, `engagement.likes`, `engagement.comments`, `author.username`, `author.avatarUrl` - Reference: https://onekey.dev/docs/api/tiktok/comment.md ### tiktok.comment_replies Replies to a TikTok comment. - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/comment_replies?id=6718335390845095173&comment_id=6718335390845095999` with header `x-api-key: YOUR_API_KEY` - Parameters: - `id` (string, required): TikTok video id - `comment_id` (string, required): TikTok comment id - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `content.id`, `content.text`, `content.createdAt`, `author.id`, `author.username`, `author.displayName`, `engagement.likes` - Reference: https://onekey.dev/docs/api/tiktok/comment_replies.md ### tiktok.comments Comments on a TikTok video. - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/comments?id=6718335390845095173` with header `x-api-key: YOUR_API_KEY` - Parameters: - `id` (string, required): TikTok video id - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `content.id`, `content.text`, `content.createdAt`, `author.id`, `author.username`, `author.displayName`, `author.avatarUrl`, `engagement.likes`, `engagement.comments` - Reference: https://onekey.dev/docs/api/tiktok/comments.md ### tiktok.effect_videos List TikTok videos made with an effect. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/effect_videos?effect_id=1234567890` with header `x-api-key: YOUR_API_KEY` - Parameters: - `effect_id` (string, required): Effect id - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `content.id`, `content.url`, `content.title`, `content.text`, `content.createdAt`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.views`, `media.thumbnailUrl`, `author.username` - Reference: https://onekey.dev/docs/api/tiktok/effect_videos.md ### tiktok.effects Get TikTok effects by id. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/effects?ids=1234567890` with header `x-api-key: YOUR_API_KEY` - Parameters: - `ids` (string, required): Ids - Fields returned: `entity.id`, `entity.name`, `entity.url`, `engagement.views`, `engagement.likes`, `media.thumbnailUrl`, `ext.rank`, `ext.postCount`, `ext.hotValue`, `ext.ctr` - Reference: https://onekey.dev/docs/api/tiktok/effects.md ### tiktok.followers Followers of a TikTok user (login-gated on the web: needs a session). - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/followers?sec_uid=MS4wLjABAAAAv7iSuuXDJGDvJkmH_c-cq3Ip0yZ-xRZjgblS5zC4iCtjxzsk5DzLUGe8BHcxZW86` with header `x-api-key: YOUR_API_KEY` - Parameters: - `sec_uid` (string, required): TikTok secUid (from tiktok.profile author.secUid) - `cursor` (string, optional, default 0): Cursor from a previous page - Fields returned: `author.id`, `author.username`, `author.displayName`, `author.avatarUrl`, `author.verified`, `author.followers`, `content.text` - Reference: https://onekey.dev/docs/api/tiktok/followers.md ### tiktok.following Accounts a TikTok user follows (login-gated on the web: needs a session). - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/following?sec_uid=MS4wLjABAAAAv7iSuuXDJGDvJkmH_c-cq3Ip0yZ-xRZjgblS5zC4iCtjxzsk5DzLUGe8BHcxZW86` with header `x-api-key: YOUR_API_KEY` - Parameters: - `sec_uid` (string, required): TikTok secUid (from tiktok.profile author.secUid) - `cursor` (string, optional, default 0): Cursor from a previous page - Fields returned: `author.id`, `author.username`, `author.displayName`, `author.avatarUrl`, `author.verified`, `author.followers`, `content.text` - Reference: https://onekey.dev/docs/api/tiktok/following.md ### tiktok.hashtag TikTok hashtag (challenge) details: id, description, video and view counts. - Price: 1 credit per fresh call. Status: beta. Access: may need a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/hashtag?tag=fyp` with header `x-api-key: YOUR_API_KEY` - Parameters: - `tag` (string, required): TikTok hashtag without # - Fields returned: `entity.id`, `entity.name`, `entity.description`, `entity.stats.itemCount`, `ext.views` - Reference: https://onekey.dev/docs/api/tiktok/hashtag.md ### tiktok.hashtag_videos Videos under a TikTok hashtag (needs the challenge id from tiktok.hashtag). - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/hashtag_videos?challenge_id=229207` with header `x-api-key: YOUR_API_KEY` - Parameters: - `challenge_id` (string, required): TikTok challenge id - `cursor` (string, optional, default 0): Cursor from a previous page - Fields returned: `content.id`, `content.text`, `content.createdAt`, `author.id`, `author.username`, `author.displayName`, `author.avatarUrl`, `engagement.views`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.bookmarks`, `media.thumbnailUrl`, `media.durationSeconds`, `ext.sound` - Reference: https://onekey.dev/docs/api/tiktok/hashtag_videos.md ### tiktok.hashtags_popular Trending hashtag board for a market and time window. - Price: 3 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/hashtags_popular` with header `x-api-key: YOUR_API_KEY` - Parameters: - `country` (string, optional, default US): Country - `period` (string, optional, default 7): Period - Fields returned: `entity.id`, `entity.name`, `entity.url`, `engagement.views`, `engagement.likes`, `media.thumbnailUrl`, `ext.rank`, `ext.postCount`, `ext.hotValue`, `ext.ctr` - Reference: https://onekey.dev/docs/api/tiktok/hashtags_popular.md ### tiktok.location_posts List TikTok videos tagged at a place. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/location_posts?location_id=1234567890` with header `x-api-key: YOUR_API_KEY` - Parameters: - `location_id` (string, required): Location id - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `content.id`, `content.url`, `content.title`, `content.text`, `content.createdAt`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.views`, `media.thumbnailUrl`, `author.username` - Reference: https://onekey.dev/docs/api/tiktok/location_posts.md ### tiktok.music TikTok sound/music details: title, artist, duration, video count. - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/music?id=6841497433143749633` with header `x-api-key: YOUR_API_KEY` - Parameters: - `id` (string, required): TikTok music id - Fields returned: `entity.id`, `entity.name`, `media.durationSeconds`, `media.thumbnailUrl`, `entity.stats.itemCount`, `ext.author` - Reference: https://onekey.dev/docs/api/tiktok/music.md ### tiktok.music_videos Videos that use a TikTok sound. - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/music_videos?id=6841497433143749633` with header `x-api-key: YOUR_API_KEY` - Parameters: - `id` (string, required): TikTok music id - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `content.id`, `content.text`, `content.createdAt`, `author.id`, `author.username`, `author.displayName`, `author.avatarUrl`, `engagement.views`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.bookmarks`, `media.thumbnailUrl`, `media.durationSeconds`, `ext.sound` - Reference: https://onekey.dev/docs/api/tiktok/music_videos.md ### tiktok.oembed TikTok oEmbed for a public video (title, author, thumbnail). - Price: 1 credit per fresh call. Status: beta. Access: may need a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/oembed?handle=scout2015&id=6718335390845095173` with header `x-api-key: YOUR_API_KEY` - Parameters: - `handle` (string, required): TikTok username without @ - `id` (string, required): TikTok video id - Fields returned: `content.text`, `author.displayName`, `author.url`, `media.thumbnailUrl`, `author.username` - Reference: https://onekey.dev/docs/api/tiktok/oembed.md ### tiktok.playlist_videos List videos in a TikTok playlist. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/playlist_videos?playlist_id=1234567890` with header `x-api-key: YOUR_API_KEY` - Parameters: - `playlist_id` (string, optional): Playlist id - `url` (string, optional): Full URL of the TikTok playlist (alternative to playlist_id) - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `content.id`, `content.url`, `content.title`, `content.text`, `content.createdAt`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.views`, `media.thumbnailUrl`, `author.username` - Reference: https://onekey.dev/docs/api/tiktok/playlist_videos.md ### tiktok.post_transcript Get TikTok video transcript. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/post_transcript?url=https%3A%2F%2Fwww.tiktok.com%2F%40natgeo%2Fvideo%2F7123456789012345678` with header `x-api-key: YOUR_API_KEY` - Parameters: - `url` (string, required): Url (URL) - Fields returned: `content.text`, `content.language`, `media.durationSeconds` - Reference: https://onekey.dev/docs/api/tiktok/post_transcript.md ### tiktok.profile TikTok user profile: nickname, bio, followers, following, likes, video count, secUid. - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/profile?handle=tiktok` with header `x-api-key: YOUR_API_KEY` - Parameters: - `handle` (string, required): TikTok username without @ - Fields returned: `author.id`, `author.username`, `author.displayName`, `content.text`, `author.avatarUrl`, `author.verified`, `content.createdAt`, `author.followers`, `author.following`, `engagement.likes`, `author.contentCount`, `ext.secUid` - Reference: https://onekey.dev/docs/api/tiktok/profile.md ### tiktok.profile_full TikTok profile, recent posts, and computed analytics in one call. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/profile_full?handle=natgeo` with header `x-api-key: YOUR_API_KEY` - Parameters: - `handle` (string, optional): Handle - `user_id` (string, optional): Numeric TikTok user id (alternative to handle) - Fields returned: `author.id`, `author.username`, `author.displayName`, `author.bio`, `author.followers`, `author.following`, `author.contentCount`, `author.verified`, `author.avatarUrl`, `author.url`, `ext.recentPosts`, `ext.analytics` - Reference: https://onekey.dev/docs/api/tiktok/profile_full.md ### tiktok.profile_region Get TikTok profile region. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/profile_region?handle=natgeo` with header `x-api-key: YOUR_API_KEY` - Parameters: - `handle` (string, required): Handle - Fields returned: `author.username`, `author.country` - Reference: https://onekey.dev/docs/api/tiktok/profile_region.md ### tiktok.related Videos related to a TikTok video. - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/related?id=6718335390845095173` with header `x-api-key: YOUR_API_KEY` - Parameters: - `id` (string, required): TikTok video id - Fields returned: `content.id`, `content.text`, `content.createdAt`, `author.id`, `author.username`, `author.displayName`, `author.avatarUrl`, `engagement.views`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.bookmarks`, `media.thumbnailUrl`, `media.durationSeconds`, `ext.sound` - Reference: https://onekey.dev/docs/api/tiktok/related.md ### tiktok.search_mentions Search TikTok videos that mention an account (keyword search for @handle). - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/search_mentions?handle=nike` with header `x-api-key: YOUR_API_KEY` - Parameters: - `handle` (string, required): TikTok username of the account, with or without the @ - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `content.id`, `content.text`, `content.createdAt`, `author.username`, `author.displayName`, `engagement.views`, `engagement.likes`, `media.thumbnailUrl` - Reference: https://onekey.dev/docs/api/tiktok/search_mentions.md ### tiktok.search_music Search TikTok sounds. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/search_music?query=coffee` with header `x-api-key: YOUR_API_KEY` - Parameters: - `query` (string, required): Query - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `entity.id`, `entity.name`, `author.displayName`, `media.durationSeconds`, `media.thumbnailUrl`, `media.audioUrl`, `entity.url`, `ext.videoCount` - Reference: https://onekey.dev/docs/api/tiktok/search_music.md ### tiktok.search_suggestions Get TikTok search suggestions. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/search_suggestions?query=coffee` with header `x-api-key: YOUR_API_KEY` - Parameters: - `query` (string, required): Query - Fields returned: `content.text` - Reference: https://onekey.dev/docs/api/tiktok/search_suggestions.md ### tiktok.search_top TikTok top search results. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/search_top?query=coffee` with header `x-api-key: YOUR_API_KEY` - Parameters: - `query` (string, required): Query - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `content.id`, `content.url`, `content.title`, `content.text`, `content.createdAt`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.views`, `media.thumbnailUrl`, `author.username` - Reference: https://onekey.dev/docs/api/tiktok/search_top.md ### tiktok.search_users Search TikTok users by keyword. - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/search_users?q=cooking` with header `x-api-key: YOUR_API_KEY` - Parameters: - `q` (string, required): Search keyword - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `author.id`, `author.username`, `author.displayName`, `author.followers`, `content.text`, `author.avatarUrl` - Reference: https://onekey.dev/docs/api/tiktok/search_users.md ### tiktok.search_videos Search TikTok videos by keyword. - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/search_videos?q=cooking` with header `x-api-key: YOUR_API_KEY` - Parameters: - `q` (string, required): Search keyword - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `content.id`, `content.text`, `content.createdAt`, `author.username`, `author.displayName`, `engagement.views`, `engagement.likes`, `media.thumbnailUrl` - Reference: https://onekey.dev/docs/api/tiktok/search_videos.md ### tiktok.trending TikTok For You / trending feed (anonymous). - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/trending` with header `x-api-key: YOUR_API_KEY` - Parameters: none - Fields returned: `content.id`, `content.text`, `content.createdAt`, `author.id`, `author.username`, `author.displayName`, `author.avatarUrl`, `engagement.views`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.bookmarks`, `media.thumbnailUrl`, `media.durationSeconds`, `ext.sound` - Reference: https://onekey.dev/docs/api/tiktok/trending.md ### tiktok.user_audience Get TikTok user audience demographics. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/user_audience?handle=natgeo` with header `x-api-key: YOUR_API_KEY` - Parameters: - `handle` (string, required): Handle - Fields returned: `author.username`, `ext.audience` - Reference: https://onekey.dev/docs/api/tiktok/user_audience.md ### tiktok.user_liked List the videos a TikTok account has liked. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/user_liked?handle=natgeo` with header `x-api-key: YOUR_API_KEY` - Parameters: - `handle` (string, optional): Handle - `user_id` (string, optional): Numeric TikTok user id (alternative to handle) - `cursor` (string, optional): Opaque cursor from a previous response's `pagination.next_cursor`. Omit for the first page. - Fields returned: `content.id`, `content.url`, `content.title`, `content.text`, `content.createdAt`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.views`, `media.thumbnailUrl`, `author.username` - Reference: https://onekey.dev/docs/api/tiktok/user_liked.md ### tiktok.user_live Get TikTok user live stream. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/user_live?handle=natgeo` with header `x-api-key: YOUR_API_KEY` - Parameters: - `handle` (string, required): Handle - Fields returned: `content.id`, `content.title`, `engagement.views`, `media.url`, `ext.isLive` - Reference: https://onekey.dev/docs/api/tiktok/user_live.md ### tiktok.user_playlists Playlists (collections) of a TikTok user. - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/user_playlists?sec_uid=MS4wLjABAAAAv7iSuuXDJGDvJkmH_c-cq3Ip0yZ-xRZjgblS5zC4iCtjxzsk5DzLUGe8BHcxZW86` with header `x-api-key: YOUR_API_KEY` - Parameters: - `sec_uid` (string, required): TikTok secUid (from tiktok.profile author.secUid) - Fields returned: `content.id`, `content.title`, `media.thumbnailUrl`, `ext.videos` - Reference: https://onekey.dev/docs/api/tiktok/user_playlists.md ### tiktok.user_videos Recent videos posted by a TikTok user. - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/user_videos?sec_uid=MS4wLjABAAAAv7iSuuXDJGDvJkmH_c-cq3Ip0yZ-xRZjgblS5zC4iCtjxzsk5DzLUGe8BHcxZW86` with header `x-api-key: YOUR_API_KEY` - Parameters: - `sec_uid` (string, required): TikTok secUid (from tiktok.profile author.secUid) - `cursor` (string, optional, default 0): Cursor from a previous page - Fields returned: `content.id`, `content.text`, `content.createdAt`, `author.id`, `author.username`, `author.displayName`, `author.avatarUrl`, `engagement.views`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.bookmarks`, `media.thumbnailUrl`, `media.durationSeconds`, `ext.sound` - Reference: https://onekey.dev/docs/api/tiktok/user_videos.md ### tiktok.video A single TikTok video: caption, author, plays, likes, comments, shares. - Price: 2 credits per fresh call. Status: beta. Access: may need a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/video?id=6718335390845095173` with header `x-api-key: YOUR_API_KEY` - Parameters: - `id` (string, required): TikTok video id - Fields returned: `content.id`, `content.text`, `content.createdAt`, `author.id`, `author.username`, `author.displayName`, `author.avatarUrl`, `engagement.views`, `engagement.likes`, `engagement.comments`, `engagement.shares`, `engagement.bookmarks`, `media.thumbnailUrl`, `media.durationSeconds`, `ext.sound` - Reference: https://onekey.dev/docs/api/tiktok/video.md ### tiktok.video_screen_text Get TikTok video on-screen text. - Price: 2 credits per fresh call. Status: beta. Access: needs a pack. Returns: one record. - Request: `GET https://api.onekey.dev/v1/tiktok/video_screen_text?url=https%3A%2F%2Fwww.tiktok.com%2F%40natgeo%2Fvideo%2F7123456789012345678` with header `x-api-key: YOUR_API_KEY` - Parameters: - `url` (string, required): Url (URL) - Fields returned: `content.text`, `content.language` - Reference: https://onekey.dev/docs/api/tiktok/video_screen_text.md ### tiktok.videos_popular Top Videos board for a supported market. - Price: 3 credits per fresh call. Status: beta. Access: needs a pack. Returns: a list. - Request: `GET https://api.onekey.dev/v1/tiktok/videos_popular` with header `x-api-key: YOUR_API_KEY` - Parameters: - `country` (string, optional, default US): Country - Fields returned: `entity.id`, `entity.name`, `entity.url`, `engagement.views`, `engagement.likes`, `media.thumbnailUrl`, `ext.rank`, `ext.postCount`, `ext.hotValue`, `ext.ctr` - Reference: https://onekey.dev/docs/api/tiktok/videos_popular.md ## Sample request ```bash curl "https://api.onekey.dev/v1/tiktok/hashtag?tag=fyp" \ -H "x-api-key: YOUR_API_KEY" ```