TikTok Ads MCP server
Make sense of your TikTok advertising.
Explore campaign performance, inspect native assets and prepare changes from your MCP client.
Watch the film · What's new · Install · Tool reference · Try hosted getmcpads
The film shows hosted getmcpads with sample data. Its MCP Apps, from creative galleries and alerts to Google Sheets exports and bulk launches, belong to the hosted product. This repository provides the standalone native API tools.
35 read tools · 29 write tools, disabled by default.
Run locally with your own platform credentials and a client that supports stdio MCP, such as Claude Desktop, Claude Code or Cursor. Your requests go directly to the platform. For managed connections, including supported ChatGPT setups, use the hosted option.
What's new
v2.0.1: Native tools and security update · September 20, 2026
- Preserve exact unquoted 64-bit IDs in read, write and verification responses.
- Fix campaign field selection and default list limits.
- Update native write validation for budgets, schedules, targeting and readback. Add carousel music, uploaded-video readiness, CTA portfolio and custom identity tools.
- Require Node.js 22.12 or newer and check Node 22/24 in CI.
- Update vulnerable dependencies and regenerate the MCP catalog.
Full changelog · Source synchronization details · All releases
Upgrade notes
Requires Node.js 22.12 or newer. CI covers Node 22 and 24. Version 2.0.1 drops Node 18 and 20 support. Read the current tool schemas before reusing saved arguments. Writes remain optional and require explicit confirmation. Hosted creative integrations and MCP Apps UI are outside this release.
Install this release
This is a GitHub source release. npm and MCP Registry versions are published separately. The commands below select this exact version; unpinned npx examples later in this document select the version currently available on npm.
git clone --branch v2.0.1 --depth 1 https://github.com/get-mcp-ads/tiktok-ads-mcp-server.git
cd tiktok-ads-mcp-server
npm ci
npm run build
Configure your MCP client to run node with the absolute path to dist/cli.js and the platform credentials documented below.
Prefer a managed connection? Use TikTok Ads with hosted getmcpads. Connect your account, select the data your assistant may access and use the hosted MCP connection. See the site for current features and plans.
What you get
The query planner
TikTok rejects many metric and dimension combinations, and its error messages rarely say why. This server encodes the compatibility matrix, so it splits an impossible request into several valid API calls and merges the results instead of failing.
tiktok_validate_query lets the model check a combination before spending a call on it.
One trap this server handles for you
TikTok answers HTTP 200 even when the call failed. The applicative code field is what
decides. A client that trusts the HTTP status reports imaginary successes back to the model,
which then reasons on data that was never returned. Every call here checks code first.
Getting a token
TikTok needs two values, not one: an access token and the App ID it belongs to.
- Create a developer app on the TikTok for Business developer portal.
- Note the App ID and App Secret from the app's page.
- Authorize the advertiser accounts you want to reach. TikTok grants access per advertiser, so an account you skip here stays invisible to the server no matter what the token allows.
- Complete the OAuth authorization flow to exchange the returned
auth_codefor an access token. TikTok's long-lived tokens do not expire on a fixed schedule, but they are revoked when the authorization is withdrawn. - Put the token in
TIKTOK_ACCESS_TOKENand the App ID inTIKTOK_APP_ID.
📖 TikTok API for Business documentation
Run tiktok_health_check as your first call. It verifies the credentials, lists the
advertiser accounts you can actually reach, and reports what is missing, without printing
your token.
Which permissions?
Setup
Claude Desktop
~/Library/Application Support/Claude/claude_desktop_config.json (macOS)
or %APPDATA%\Claude\claude_desktop_config.json (Windows):
{
"mcpServers": {
"tiktok-ads": {
"command": "npx",
"args": ["-y", "@getmcpads/tiktok-ads-mcp-server"],
"env": {
"TIKTOK_ACCESS_TOKEN": "your-token-here",
"TIKTOK_APP_ID": "your-app-id-here"
}
}
}
}
Restart Claude Desktop. Ask it: "list my TikTok advertiser accounts".
Claude Code
claude mcp add tiktok-ads --env TIKTOK_ACCESS_TOKEN=your-token --env TIKTOK_APP_ID=your-app-id -- npx -y @getmcpads/tiktok-ads-mcp-server
Cursor
.cursor/mcp.json in your project, same shape as the Claude Desktop config above.
From source
git clone https://github.com/get-mcp-ads/tiktok-ads-mcp-server.git
cd tiktok-ads-mcp-server
npm install && npm run build
cp .env.example .env # then fill in your credentials
npm start
Configuration
Check your setup at any time:
npm run doctor
Writes, and why they preview first
Write tools are disabled by default. Enable them with TIKTOK_ENABLE_WRITES=1.
When enabled, every write tool returns a preview and changes nothing:
// tiktok_update_adgroup_budget { advertiserId: "7...", adGroupId: "1...", budget: 50 }
{
"applied": false,
"action": "tiktok_update_adgroup_budget",
"change": { "advertiser": "7...", "adGroup": "1...", "newBudget": 50,
"budgetMode": "BUDGET_MODE_DAY" },
"message": "Preview only, nothing was changed. Repeat the same call with confirm: true to apply this change to the live account."
}
Only a second call carrying confirm: true touches the live account.
This is deliberate. An assistant composes these calls, and it can pick the wrong advertiser, the wrong campaign, or the wrong order of magnitude on a budget. A mandatory preview makes the mistake visible before it costs money, and gives a human the stopping point the protocol does not guarantee on its own.
One further guardrail: tiktok_create_campaign always creates the campaign DISABLE.
There is no option to create it running.
Tools
Every tool is listed below. See server-card.json for complete parameter and output schemas.
Disabled by default. Calls preview unless explicitly confirmed. Check the configuration and exact schema before use.
Security
The server holds a credential that can read, and optionally modify, live ad accounts. Concretely:
- The token is never logged. Debug output prints
Access-Token: [redacted]. - Requests go only to
business-api.tiktok.com, and only under/open_api/v1.3/. Any other host or path is refused rather than called. Covered by tests. - Redirects are refused once a token is attached, so a redirect cannot forward your credential elsewhere.
- Mutating and OAuth endpoints are blocked on the generic read paths. Covered by tests.
- No telemetry. The server makes no network call other than to the TikTok Business API.
You can verify this by grepping the source for
fetch.
Full policy and reporting instructions: SECURITY.md.
Looking for a managed, multi-platform version?
Try hosted TikTok Ads if you want to use this source without operating a local server. getmcpads also connects advertising, Search Console and GA4 through one MCP URL. Source availability and plan limits are listed on the site; connecting an account is still required.
- Follow the TikTok Ads connection guide.
- Select the account or property your assistant may read.
- Connect Claude, ChatGPT or Codex.
- Try a read-only review: “Compare campaign delivery and conversion trends over complete periods. State missing data and do not change anything.”
See the current hosted tool catalogue and pricing before choosing a paid plan. This Apache 2.0 adapter remains independently useful with your own credentials.
Contributing
Issues and pull requests are welcome. See CONTRIBUTING.md. Please read SECURITY.md before reporting anything security-related.
Licence
Apache License 2.0. See also NOTICE.
TikTok and TikTok for Business are trademarks of ByteDance Ltd. and its affiliates. This project is not affiliated with, endorsed by, or sponsored by TikTok or ByteDance. It is an independent client of a public API.
MCP contracts and desktop bundle
Every tool declares read/write annotations, parameter descriptions and a structured output schema. Successful calls expose the payload as structuredContent.result; errors retain isError: true. The generated server card contains definitions only.
Run npm run bundle -- /path/to/output to build a .mcpb desktop bundle from the current catalog. Credentials are entered locally during installation. Write tools remain disabled unless explicitly enabled.
More from getmcpads
Meta Ads · Google Ads · Google Analytics 4 · Google Search Console · Pinterest Ads · X Ads
Maintained by Emmanuel at getmcpads. Questions: [email protected].
