TL;DR
- Call tiktok.comments with a video id and get up to 50 comments back as JSON, with text, likes and reply counts, for $0.001 per call.
- For trending sounds, call tiktok.music-chart-list ($0.001) for TikTok's own music chart, then check any sound with tiktok.sound ($0.00015) to see the videos that use it.
- TikTok Shop has 16 read-only actions from $0.001 per call: hot-selling products, product details, reviews, seller catalogs and search.
- Comments work out to $0.02 per 1,000. 10,000 comments (top 50 on 200 videos) costs about $0.22 including the searches that find the videos.
- Close the loop: generate a clip at $0.05 per second and post it from the agent's own TikTok account. Posting is early access and needs a first $10 top-up.
Tools used in this post
Updated 26 November 2026.
To scrape TikTok comments through an API, call one endpoint with the video's id and get the comments back as JSON: on Naive that is tiktok.comments, $0.001 per call for up to 50 comments, which is $0.02 per 1,000 comments, with no scraper, proxy or TikTok login to maintain. Typical marketplace comment scrapers charge around $0.20 to $0.30 per 1,000. The same key reads TikTok's music chart (tiktok.music-chart-list, $0.001 per call) and TikTok Shop products, so one agent can go from "what are people saying" to "what should we post" in a single run.
Naive is a developer platform that gives an AI agent priced tools (TikTok, Instagram, YouTube and many more data sources, plus video generation) and its own accounts on one API key, CLI or MCP server.
Definitions. A tool is a priced, stateless call that returns JSON, such as tiktok.comments. An action is one endpoint inside a tool. An identity is the name your agent acts as; connected social accounts and approval rules belong to it.
This guide covers comments, sounds and TikTok Shop, what 10,000 comments cost, and how the agent turns a trend into a draft video posted from its own account. If you want the same data inside Claude or ChatGPT without code, read one MCP connector for TikTok, Instagram and YouTube data.
How do you get TikTok comments through an API?
You pass a video id and get the top comments back. The id is the number at the end of a TikTok video URL (tiktok.com/@user/video/7712123066150554911).
import { createNaive } from "@usenaive-sdk/naive";
const naive = createNaive(); // reads NAIVE_API_KEY
const run = await naive.tools.run(
"tiktok.comments",
{ video_id: "7712123066150554911", limit: 50 },
{ wait: true },
);
type Comment = { text?: string; digg_count?: number; likes?: number };
if (run.object === "run" && run.status === "succeeded") {
// Print run.output once to see the full payload; the list can sit under data.comments.
const out = run.output as { comments?: Comment[]; data?: { comments?: Comment[] } | Comment[] };
const comments =
out.comments ?? (Array.isArray(out.data) ? out.data : out.data?.comments) ?? [];
for (const c of comments) console.log(c.digg_count ?? c.likes ?? 0, c.text);
}The same call from a terminal, with each input as --arg key=value:
naive tools run tiktok.comments --arg video_id=7712123066150554911 --arg limit=50Every run returns a run object with its status, its cost_usd and the output. Each comment carries its text, its like count, its reply count and the commenter's public profile. Print run.output once before you build on it, so your code reads the fields as they actually arrive. Comments arrive as the platform ranks them, so the top 50 are the ones most people saw.
More than 50 comments on one video? tiktok.comments takes only video_id and limit and returns the top 50. To page deeper, use tiktok.list-tiktok-comments ($0.002 per call), which pages through a video's comment stream and threaded replies. Read its input schema first:
naive tools get tiktok --endpoint tiktok.list-tiktok-commentsFor the replies under one comment there is also tiktok.list-tiktok-comment-replies ($0.00015 per call). Run naive tools get tiktok to see every TikTok action with its input schema and price.
Which TikTok scraper API actions does an agent use most?
| Action | What it returns | Price |
|---|---|---|
tiktok.comments | Comments on one video, with likes and reply counts (up to 50) | $0.001 / call |
tiktok.list-tiktok-comments | A video's comment stream and replies, paged past the top 50 | $0.002 / call |
tiktok.music-chart-list | TikTok's music chart | $0.001 / call |
tiktok.search | Videos matching a keyword, best matches first | $0.001 / call |
tiktok.hashtag | Top videos for a hashtag (up to 30) | $0.00015 / call |
tiktok.sound | Videos that use one sound | $0.00015 / call |
tiktok.posts | Recent posts for an account, with views, likes and comment counts | $0.00015 / call |
tiktok.profile | Followers, bio, verified flag and latest posts for one account | $0.00015 / call |
tiktok.get-tiktok-trending-feed | TikTok's trending feed of popular posts | $0.00015 / call |
tiktok.get-tiktok-transcript | A video's captions with timed segments | $0.00015 / call |
Those are a handful of the more than 150 TikTok actions in the TikTok tool, all read-only and all billed from the same balance.
Is there a TikTok trending sounds API?
Yes. Start with TikTok's own chart, then check the sounds that matter to you:
| Action | What it returns | Price |
|---|---|---|
tiktok.music-chart-list | TikTok's music chart | $0.001 / call |
tiktok.get-music-search-results-of-specified-keywords | Sounds matching a keyword | $0.001 / call |
tiktok.get-trending-hashtag-list | Trending hashtags | $0.001 / call |
tiktok.get-daily-trending-search-words | Today's trending search words | $0.001 / call |
tiktok.sound | Videos that use one sound | $0.00015 / call |
tiktok.get-tiktok-sound | One sound's details and usage count | $0.00015 / call |
The chart and search actions take the inputs their source expects, so read the live schema before the first call:
naive tools get tiktok --endpoint tiktok.music-chart-list
naive tools run tiktok.music-chart-list --waitA global chart is not your niche. To find the sounds rising in your niche, build the list from posts that are getting views right now:
- Pull popular posts with
tiktok.searchortiktok.hashtagfor your niche, or withtiktok.get-tiktok-trending-feed(runnaive tools get tiktok --endpoint tiktok.get-tiktok-trending-feedfirst for its inputs). - Read each post's sound id at
music.idand count how often each one appears. - Call
tiktok.soundon the top ids and check how recent and how big the videos using each one are.
const search = await naive.tools.run("tiktok.search", { query: "standing desk" }, { wait: true });
type Post = { music?: { id?: string } };
const out = search.object === "run" ? (search.output as { data?: Post[] | { data?: Post[] } }) : {};
const posts = (Array.isArray(out.data) ? out.data : out.data?.data) ?? [];
const counts = new Map<string, number>();
for (const p of posts) {
const id = p.music?.id;
if (id) counts.set(id, (counts.get(id) ?? 0) + 1);
}
const top = [...counts].sort((a, b) => b[1] - a[1]).slice(0, 5);
for (const [sound_id] of top) {
const usage = await naive.tools.run("tiktok.sound", { sound_id }, { wait: true });
console.log(sound_id, usage.object === "run" ? usage.output : usage);
}The same check for one sound from the CLI:
naive tools run tiktok.sound --arg sound_id=7637816438984820737tiktok.sound answers with a page of posts that use the sound, newest included, plus a cursor for the next page. A sound whose posts are mostly from the last few days, with views well above each creator's usual numbers, is rising. A sound whose posts are months old is already done. For one sound's details and usage count in a single call, use tiktok.get-tiktok-sound ($0.00015).
Original sounds (the "original sound - creator" ones) are often the early signal: a creator's voiceover that other people start reusing before it becomes a named trend.
How do you get TikTok Shop products and sales?
The TikTok Shop tool has 16 read-only actions. The ones a product-research agent uses:
| Action | Use it to | Price |
|---|---|---|
tiktok-shop.get-hot-selling-products-list | See what is selling now | $0.001 / call |
tiktok-shop.search-products-list-v1 | Search products by keyword | $0.001 / call |
tiktok-shop.get-product-detail-v3-full-data | Read one product in full | $0.001 / call |
tiktok-shop.get-product-reviews-v2 | Pull a product's reviews | $0.001 / call |
tiktok-shop.get-seller-products-list-v1 | List everything one seller sells | $0.001 / call |
tiktok-shop.search-tiktok-shop | Structured listings for a keyword | $0.01 / call |
tiktok-shop.tiktok-shop-product | A whole product page as structured data | $0.012 / call |
tiktok-shop.tiktok-shop-category-page | A whole category page | $0.036 / call |
These actions take the inputs their source expects, so read the live schema before the first call:
naive tools get tiktok-shop --endpoint tiktok-shop.get-hot-selling-products-listPair the two tools and the agent can answer questions a dashboard cannot: which hot-selling product has comments full of "where do I buy this", and which has comments full of complaints.
How do you score comment sentiment?
Naive returns the comments; your agent's own model scores them. Keep it simple and repeatable:
- Label each comment positive, negative, neutral or question, and weight it by
digg_count, since a comment with 400 likes speaks for more people than one with none. - Pull out the questions. "When is launch day?" or "what desk is that?" is buying intent and a ready-made hook for the next video.
- Track it over time. Store the scores per video and per day, and the agent can tell you when a product's mood turns.
Because the input is plain JSON, this works the same from a script, from an agent framework, or from Claude with the MCP server added. For a larger pipeline across platforms, the same pattern runs on Instagram and YouTube comments; see introducing social data.
How does a trend become a draft video?
Once the agent knows the hook (a question people keep asking) and the sound (one that is rising), it drafts the clip with video generation: a prompt in, a 5, 8, 10 or 15 second clip with sound out, at $0.05 per second.
const clip = await naive.tools.run(
"video.generate",
{ prompt: "close-up of a standing desk rising, morning light, handheld", seconds: "8" },
{ wait: true }, // a render is async; wait polls until it settles
);
console.log(clip); // the finished run's output links the rendered fileAn 8-second clip costs $0.40, a 15-second one $0.75. With wait: true the SDK polls the run until the render finishes; from the CLI, add --wait.
Can the agent post from its own TikTok account?
Yes, through a social account on the agent's identity: you connect the identity's own TikTok account once, and the agent posts as that account. It never touches your personal profile. Social accounts are early access, and posting needs a first $10 top-up.
naive identity create --name creator
naive identity social activate --identity creator
# prints a hosted page; open it and sign in to the TikTok account the agent will post as
naive identity social portal --identity creator --platform tiktok
naive identity social accounts --identity creator # check TikTok is connected# signed in as the owner: hold every post for approval
naive identity rules creator --set social.post=always
naive identity social post --identity creator \
--platform tiktok --message "Does your desk do this?" \
--media-url https://files.example.com/desk.mp4With social.post set to always, each post is held until a person approves it in the app, and the agent sees an approval it can wait on instead of a published post. Leave the rule at never once you trust the loop. The approval rules are covered in the approvals docs, and every social command in the CLI social docs.
What does it cost to scrape 10,000 TikTok comments?
| Step | Calls | Price each | Cost |
|---|---|---|---|
Find about 200 videos with tiktok.search | about 20 | $0.001 | $0.02 |
Pull 50 comments per video with tiktok.comments | 200 | $0.001 | $0.20 |
Check 20 sounds with tiktok.sound | 20 | $0.00015 | $0.003 |
| Total for 10,000 comments | about $0.22 |
That maths assumes breadth: the top 50 comments on each of 200 videos. If you want deep threads on a few videos instead, page with tiktok.list-tiktok-comments at $0.002 per call. Either way the comments themselves cost $0.02 per 1,000, against roughly $0.20 to $0.30 per 1,000 on typical marketplace comment scrapers.
Add a draft video at $0.40 for 8 seconds and the whole research-to-draft job is under a dollar. New accounts get $1 of free credit with no card, which covers this run.
Verified run
Three real calls on production on 2026-11-26, timed from the client, through POST /v1/tools/runs:
| Call | Input | Returned | Time | Cost |
|---|---|---|---|---|
tiktok.search | query "standing desk review" | 13 videos | 5.9 s | $0.001 |
tiktok.comments | one video, limit 20 | 20 comments | 5.9 s | $0.001 |
tiktok.sound | one music id from the search | 19 videos using the sound | 7.1 s | $0.00015 |
Each call is a live read, so expect seconds, not milliseconds. Fan calls out in parallel when you need volume.
What are the platform rules and limits?
- Public data only. Every TikTok and TikTok Shop action reads what anyone can see without logging in. Private accounts, DMs and follower-only content are out of reach, by design.
- Read-only tools. Reading never posts, likes or follows. Writing happens only through a social account you connected to an identity.
- Per-call limits.
tiktok.commentsreturns up to 50 comments per call,tiktok.hashtagup to 30 videos,tiktok.postsup to 100. - Spend limits. Every call is debited from a prepaid balance at the listed price, so a runaway loop stops when the balance does. Check spend with
naive tools runs. - Your use is yours. Store and use the data within TikTok's terms and the privacy law where you operate, especially for anything tied to a named person.
When not to use Naive
- You need TikTok's official research or business APIs. Academic research access and an advertiser's own ad metrics come from TikTok directly.
- You already run a scraper that works. If one platform, one job and a scraper you maintain cover it, adding a second vendor buys little.
- You need firehose volume. Millions of comments a day are cheaper on a dedicated data contract than per call.
- You need private data. Nothing here reads content that is not public.
Naive fits when an agent needs several platforms, AI tools and its own accounts on one key, and you would rather not maintain the scraping.
Get started
- Get a key with $1 free credit, no card: developers.usenaive.ai/signup. Run your first TikTok call free.
- Or hand your agent one line: set up https://usenaive.ai/developers/skill.md
- Or add the MCP server to Claude, ChatGPT or Claude Code:
https://mcp.usenaive.ai/v1/mcp.
Every tool and action is listed with its price in the tools docs, and the whole platform is on the developers page.
FAQ
- Is there an API to scrape TikTok comments?
- Yes. On Naive, tiktok.comments takes a video_id (the number at the end of the video URL) and an optional limit of up to 50, and returns the comments as JSON with text, like counts and reply counts. It costs $0.001 per call from a prepaid balance, and works from the SDK, the CLI or the MCP server.
- Is there a TikTok trending sounds API?
- Yes. On Naive, tiktok.music-chart-list returns TikTok's music chart for $0.001 per call, and tiktok.get-music-search-results-of-specified-keywords finds sounds by keyword. To check a sound, call tiktok.sound with its id (a post's music.id) for $0.00015 and see how many recent videos use it.
- Can I get TikTok Shop trending products and sales data?
- Yes. The tiktok-shop tool has 16 read-only actions, including a hot-selling products list, product details, product reviews, category listings and seller catalogs. Most cost $0.001 per call; full product-page and category-page reads cost $0.012 and $0.036.
- Do I need a TikTok account or developer approval?
- Not to read. Every TikTok read action works on public data with one Naive key and no TikTok login. Posting is different: it needs a TikTok account connected to one of your identities, which is early access and needs a first $10 top-up.
- How much does it cost to scrape 10,000 TikTok comments?
- About $0.22, assuming the top 50 comments on each of 200 videos. That is 200 tiktok.comments calls at $0.001 each ($0.20, or $0.02 per 1,000 comments), plus around 20 tiktok.search calls at $0.001 each to find the videos. Going deeper on a few videos uses tiktok.list-tiktok-comments at $0.002 per page. New accounts get $1 of free credit with no card.
- Can my agent post the video it made to TikTok?
- Yes, from the identity's own connected TikTok account. Create an identity, activate social, connect TikTok once through the hosted connect page, then post with naive identity social post. Set the identity's social.post rule to always if you want to approve each post before it goes out.
- Is there an official TikTok comments API?
- TikTok's official APIs cover approved research access and your own business account's data. They do not give a general developer a simple call for any public video's comments, which is why comment-scraping APIs exist. Naive's tiktok.comments reads public comments with one key and no TikTok developer approval.
- Is it allowed to scrape TikTok comments?
- Naive reads only public data that anyone can see without logging in, never private accounts or DMs. How you store and use the data is your responsibility: follow TikTok's terms and the privacy law where you operate, especially for anything tied to a named person. This is not legal advice.