Build a Douyin Competitor Monitor and Social Listening Agent (2026): One SandBase Key

Build a Douyin competitor monitor and brand listening agent with one SandBase key—account watch, hot search, keyword search, and LLM briefs. Public data only.

Douyin monitor agent: accounts + keywords

The Douyin open-platform tab will not monitor a competitor. They will not install your app, so the token never arrives. A finished Lark monitor, or a Douyin MCP on a second key, is the other door people open. SandBase already has two nearby tutorials. Neither is this job.

A Douyin competitor monitor agent here is two loops on one SANDBASE_API_KEY. Loop A watches named accounts. Loop B reads the hot-search board and keyword video search, then asks a model which rows are the brand. Public reads only. Structured JSON versus a scraper versus official OAuth is the social data API guide. Start there, then build.

Key takeaway

  • Watch accounts on a daily snapshot. Listen to hot search and keywords on a short poll. Combining them is normal. Using a 15-minute cadence for both will burn the shared free allowance before lunch.
  • On 2026-11-08 the Douyin hub header read 319 of 319 endpoints. Profile, first-page posts, hot search, and keyword search are the minimal set. Batch play statistics are a separate, higher price.
  • Skill or MCP is the path inside Claude Code, Cursor, or Codex. REST is POST /v1/api/<vendor>/<path>, and the payload is outputs[0].data. The July cron post is the long account-watch script. Do not paste it again.
  • This is not a Douyin partnership. It does not post, message, or read owner analytics. A push product or a Lark SaaS still wins when you do not want to own the poll.

SandBase Douyin hub with the header 319 of 319 endpoints SandBase Douyin hub — 319 of 319 endpoints for public profiles, posts, hot search, and search.

What you are building

Loop A answers what those accounts published since yesterday. Loop B answers whether the brand or the category showed up somewhere you were not already watching. Both are read-only. The output is a Markdown brief, a webhook, or both.

Loop A, account watchLoop B, listening
QuestionWhat changed on these competitors?Did the brand or category surface?
Input you keepA list of sec_user_id valuesBrand and category keywords, plus the hot-search board
Cadence that fits the free poolOnce a dayA handful of polls, not every 15 minutes
SandBase callsProfile, then the first page of posts. Play stats only for new idsHot-search list, then keyword video search
Model stepSummarize the deltaClassify brand versus noise, then alert

Run A alone when the watchlist is the product. Run B alone when you have keywords and no account ids yet. Run both when the brief should say “they posted” and “the board moved.” A miss on the board is not a failed account fetch.

Loop A: competitor account watch

Resolve each competitor to a sec_user_id. Fetch the profile, then the first page of posts. Diff that page against yesterday’s snapshot. Ask for play statistics only on new ids. Send the delta to a model.

The tested cron, snapshots included, is Build a Douyin Competitor Monitor Agent. That is the deep account-watch sample. This page does not reprint it. In a coding agent the same two calls are discover, inspect, then one small run. Install is the Skill and MCP guide.

SandBase user-post-videos reference showing POST, a price of $0.001, and a required sec_user_id douyin/app-v3/user-post-videos — POST, sec_user_id, $0.001, first 100 eligible calls/day free (shared per org).

Loop B: brand and keyword listening

douyin/app-v3/hot-search-list with {} is the main board. Optional board_type and board_sub_type select other boards. The reference says to send board_type as a string. Keyword hits go through douyin/search/video-search-v2. Pre-filter on the keyword, then let the model label brand, category, or ignore. Alert on the first two.

SandBase hot-search-list reference showing POST, a price of $0.001, and no required parameters douyin/app-v3/hot-search-list — empty body defaults to the main hot-search board at $0.001 with the same free-allowance line.

douyin/app-v3/brand-hot-search-list is not that search. On 2026-11-08 it took no input and described brand-board categories. Open its detail link before you pass a category id. This article did not call the detail route.

This is also not the Douyin half of Build a Social Listening Agent: Weibo + Douyin. That agent pairs Weibo hot search with douyin/billboard/hot-account-list, a ranked creator list. A hot-search board is a ranked topic list. Rising creators belong on the billboard tutorial. Words belong here.

douyin/search/general-search-v2 is the mixed-card alternative. Its reference that day described video and image-post cards in business_data[], at $0.01, with the free-allowance sentence. The unversioned path douyin/search/general-search returned HTTP 404. Use a versioned id.

Prerequisites and boundaries

You need a SandBase key for REST, or a browser sign-in if the coding agent follows the Skill. The Skill line is not a shell command, and the key does not go in chat:

Text
set up https://www.sandbase.ai/SKILL.md

SKILL.md, retrieved 2026-11-08, says discovery and inspection are free, only a run spends the balance, and you should not assume every API shares the daily free allowance. Client install stays in the Skill guide. The AI tools page is the same door.

Pricing that day: eligible data APIs share 100 free calls per organization per day, reset at 00:00 UTC. Catalog search and reading a schema or price are $0. A failed model or API call is not charged. Build is pay per call, no subscription. Agent sandboxes were $0 for now, with fair-use caps, and any change is announced first. Models sit outside the data allowance. The Start plan is $0 plus starter credits. This article does not invent that credit. The homepage is the one balance. SandBase does not own Douyin.

This agentDouyin Open Platform
Who can be readPublic profiles, public posts, public boardsAccounts that authorized your app
CredentialOne SandBase key, or the Skill’s browser sign-inA reviewed app, then a user token
ActionsNoneWhatever that app’s scopes allow, including post and message paths
Use it whenCompetitor public monitoring and topic listeningYour own accounts, or users who logged into your app

Do not rebuild the JSON-versus-scraper-versus-OAuth table from the social data guide. Cookie, guest-session, device-registration, and “open the app to send a private message” routes are on the hub. They are not the default monitor.

Resolve competitor ids

A profile URL often already holds the id. Copy the path segment that starts with MS4wLjABAAAA. Do not pass a display name, a numeric uid, or a video id into douyin/app-v3/user-profile. That reference’s FAQ, retrieved 2026-11-08, says those are different inputs.

With only a name, use douyin/search/user-search-v2. Optional keyword and cursor (0 on page one), $0.001, and the free-allowance sentence is on the page. Its field table describes data.user_list[].user_id as a long string starting with MS4w. Several accounts can share a nick_name, so match the name and keep user_id. The next page sends data.cursor while data.has_more is true. That rule is the reference’s. This article did not re-run a search. The longer walkthrough is Douyin User Search API. douyin/creator/user-search returns a numeric-style user_id and a short_id, not the MS4w string, so it does not replace v2 here.

douyin/web/sec-user-id requires url, at $0.001, and includes the free-allowance sentence. Its published sample sent a video URL and got that URL back unchanged. The note says to send a profile or homepage URL when you want a sec_user_id. douyin/web/all-sec-user-id batches profile URLs (required body array, same price and allowance sentence). douyin/web/encrypt-uid-to-sec-user-id converts a uid the reference calls a short_id. Prefer the segment you can see. Spend a resolve call when the link is short or the id is not in the path.

Minimal dual loop on SandBase

Catalog pages show a GET listing. Calls use the Model API:

POST https://api.sandbase.ai/v1/api/<vendor>/<path>

The body is that endpoint’s parameters only. A completed call puts the business payload on outputs[0].data. If status is not completed, or that field is missing, fail the cycle. A run id is not the payload. The helper below is the documented envelope. It was not executed for this article. No API key was available in this writing environment, and none was requested.

Python
import os
import requests

def call_api(model: str, params: dict) -> dict:
    response = requests.post(
        f"https://api.sandbase.ai/v1/api/{model}",
        headers={
            "Authorization": f"Bearer {os.environ['SANDBASE_API_KEY']}",
            "Content-Type": "application/json",
        },
        json=params,
        timeout=90,
    )
    response.raise_for_status()
    body = response.json()
    outputs = body.get("outputs") or []
    if body.get("status") != "completed" or not outputs or outputs[0].get("data") is None:
        raise RuntimeError(
            f"SandBase call did not complete: {body.get('status')} {body.get('error')}"
        )
    return outputs[0]["data"]

Path 1: Skill or MCP

Paste the Skill line into Claude Code, Cursor, or Codex, finish the browser sign-in, and start a new session so the tools load. Then ask for a bounded cycle, not a 200-line agent:

Text
Discover a Douyin user profile tool and a Douyin hot search tool.
Inspect each one and read the price and whether it shares the daily free data allowance.
Do not run anything until I confirm.
Then run one profile for this sec_user_id and one hot-search list with an empty body.
Summarize what changed. Do not invent fields that were not in the output.

sandbase_discover and sandbase_inspect are the free steps. sandbase_run is the paid one. Inspect before every new endpoint, including ones this page names, because a reference and a later inspect can diverge. The Skill guide covers client ids, connect, and the raw MCP URL. This page does not.

Path 2: REST

These ids were live on 2026-11-08. Prices are the reference “Facts” lines that day. Re-open the page before you scale.

LoopEndpointBody that matches the referenceList priceFree-allowance sentence on that page
Adouyin/app-v3/user-profilesec_user_id required$0.001Yes, shared 100 per organization per UTC day
Adouyin/app-v3/user-post-videossec_user_id required. Optional count (do not exceed 20), max_cursor (0 on page one), sort_type (0 latest, 1 hottest)$0.001Yes
A, optionaldouyin/app-v3/multi-video-statisticsaweme_ids required, comma-separated, 50 or fewer$0.025No. The FAQ says the call is billed from the balance
Bdouyin/app-v3/hot-search-list{} for the main board. Optional board_type, board_sub_type$0.001Yes
Bdouyin/search/video-search-v2keyword, cursor (0 first). Other filters are optional$0.01Yes
Iddouyin/search/user-search-v2keyword, cursor$0.001Yes

The catalog map is Douyin Public Data API on SandBase. Field paths for one creator’s videos are in Douyin creator video research. Rising accounts are in Douyin billboard monitoring.

A first cycle, not executed here. count: 5 is the post reference’s teaching example, not a maximum. Store the raw data. Diff ids yourself. The July post already has a snapshot layout from a 2026-10-01 run.

Python
# Not executed in this article. Inspect price and free_quota before you point this at a real watchlist.
profile = call_api("douyin/app-v3/user-profile", {"sec_user_id": sec_user_id})
posts = call_api(
    "douyin/app-v3/user-post-videos",
    {"sec_user_id": sec_user_id, "max_cursor": 0, "count": 5, "sort_type": 0},
)
hot = call_api("douyin/app-v3/hot-search-list", {})
videos = call_api("douyin/search/video-search-v2", {"keyword": keyword, "cursor": 0})

Send new ids to multi-video-statistics as one comma-separated string only if you accept $0.025 and no free-allowance line. The July post saw a post list whose play count was zero while the statistics call filled plays in. That was one window on 2026-10-01. A missing count is unknown until you compare the two payloads.

The model call uses the same key at https://api.sandbase.ai/v1, on a model you already inspected. It should quote ids from the payload and say “no change” when the diff is empty. A smooth brief with no ids is a failed cycle.

Path 3: sandbox, or a clock you already run

Use the same key for a sandbox when you want dedupe or a JSONL append outside the chat. Pricing said agent sandboxes were free for now. The sandbox page is an E2B-compatible workspace per run. SDK mapping is the one-key stack and the free E2B alternative. The sandbox does not replace the Douyin calls.

The pricing FAQ says that after you build an agent you can test it, publish it as an API, or schedule it. The agents page opened here is hosted Sessions, not a cron form this article used. Until you have used that schedule, keep cron or GitHub Actions, as the July post does. Hosted Sessions versus OpenAI sandboxes are the OpenAI Agents API path.

Cost sketch

Arithmetic on the published allowance, not a bill this article ran. The 100 free calls are shared by every eligible data API in the organization, not reserved for Douyin.

Eight accounts once a day, profile plus one post page, is 16 calls. If those references stay eligible, that is 16 of the 100. One statistics batch for new ids is $0.025 from the first call, because that page does not list the allowance. Six hot-search polls plus eight keyword searches add 14 eligible calls. Past the allowance, each keyword call is listed at $0.01, ten times the profile price. The sketch is 30 or 31 data calls, if the rest of the org is quiet.

The Weibo-plus-Douyin listener polls every 15 minutes and says so. The same cadence on Douyin hot search is 96 eligible calls before any account. That is a choice, and a poor default on a shared 100. Keyword search on that clock spends the pool, then bills $0.01 a call.

The model brief is separate, one short completion per cycle, priced on the model card. This page does not quote a daily token figure. Failed calls are not charged. Re-checking free_quota with inspect stays $0.

Xingtu and other kol-* routes were not re-priced in this pass. The July note that some of them sit outside the allowance is a lead, not a current quote. Inspect before you add them.

SandBase, managed monitors, and Douyin MCPs

Nobody on this list is a fake product. They sell different shapes of the same morning.

Own the loop?Models on the same key?What you are buying
SandBaseYes. You write the diff, the classifier, and the clockYes. Data, the brief, and an optional sandbox share one balanceA catalog plus a key. The Douyin hub is the surface
MediaClaw Douyin monitoringNo. You set rulesNot this productOn 2026-11-08 the page said the tracker follows competitor publishing and engagement, then pushes AI summaries to Lark
DataXAPI competitor monitoringPartly. Their page says the “what is new” step is still yoursTheir balance, not SandBase’sA skill across 17 platforms. The example run was 2 calls, at most $0.0040, one call per account. A failed call is not charged
TikHub MCPYou still write the agentTheir keyThe page said 990+ tools across 16 platforms. The Douyin API is the Douyin surface, including billboards and Xingtu
Qovia Douyin MCPYou still write the agentTheir key14 live endpoints, including search and the hot-search board, for Claude Code, Cursor, and VS Code. A new account gets 50 trial calls
WellbyteYou subscribe to changesTheir key. The page also offers MCPRealtime push into Kafka, a webhook, or S3, billed on successful delivery. Their homepage figures that day were 38 platforms, 895 endpoints, and 212 under Douyin

Use SandBase when the brief and the data should share one key and you can live with a poll. Use MediaClaw for Lark rules without a script. Use DataXAPI when you want their account fetch and will compute the delta. Use TikHub or Qovia when that MCP is already the repo standard. Use Wellbyte when a change should arrive without polling. Use the open platform when you must act as an account. This is a fit table, not a rank.

Boundaries

Public data, best effort. The reference promises the envelope. A field missing from one payload is unknown. The hot-search reference warns that some rows have heat 0 and no rank. Do not alert on a zero you have not checked.

The first run has no snapshot, so every video looks new. Write the snapshot and send the brief on the second run. Do not repeat a completed call to be sure. That second success is a second charge. Stay inside each platform’s terms. Do not store cookies or run a logged-in device as the monitor. 319 of 319 was the hub header on 2026-11-08, the same figure the social data guide recorded earlier that day. It will move.

FAQ

How do I build a Douyin competitor monitor agent?

Use public Douyin reads and one vendor key. OAuth does not unlock a competitor who will not authorize you. Resolve sec_user_id, fetch the profile, fetch the first post page, diff yesterday, and optionally batch play stats for new videos. On SandBase that key is also the model key. Discover and inspect are free. The July competitor-monitor tutorial is the full cron. Skill setup is the Skill guide. On 2026-11-08, profile and posts were $0.001 with the free-allowance sentence. douyin/app-v3/multi-video-statistics was $0.025 without it.

How do I add Douyin social listening, not only competitor accounts?

Add a loop that ignores the watchlist. Poll douyin/app-v3/hot-search-list with {}, and run douyin/search/video-search-v2 for brand and category terms. Pre-filter, then classify. The Weibo-plus-Douyin tutorial’s Douyin source is the hot-account billboard, not this topic board. On 2026-11-08 hot search was $0.001 and video search was $0.01, both with the free-allowance sentence. Still best-effort public data, not a Douyin partnership.

When should I use SandBase instead of MediaClaw, TikHub, Qovia, or official Douyin APIs?

Use SandBase when the loop stays in your repo, the model shares the key, and polling is acceptable. Use MediaClaw for Lark summaries. Use DataXAPI when you want their account fetch and will compute the delta. Use TikHub or Qovia when their MCP is already the standard. Use Wellbyte when push beats a clock. Use Douyin Open Platform to post, message, or read data an account owner authorized.

What to do next

Open the Douyin hub, inspect one endpoint, and run a single profile or a single empty-body hot search only after that page still shows the allowance you expect. The decision among JSON, scraping, and OAuth stays in the social data API guide. The long account script stays in the July competitor monitor. Cross-platform listening stays in the Weibo and Douyin agent. The catalog stays on the Douyin hub post. The coding-agent install stays in the Skill guide. The shared key, including the sandbox, stays in the one-key stack.