threads-mcp-server
Provides tools for interacting with the Meta Threads API, including publishing posts, retrieving profiles and insights, deleting posts, and making arbitrary Graph API calls.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@threads-mcp-server Show me my recent Threads posts."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
threads-mcp-server
A Model Context Protocol server for the Meta Threads API.
MIT licensed.
Install
npm install -g @nasdigitaluk/threads-mcpRelated MCP server: meta-threads-mcp
Configuration
{
"env": {
"THREADS_ACCESS_TOKEN": "your-long-lived-token",
"THREADS_USER_ID": "your-numeric-id"
}
}THREADS_USER_ID is optional — it just defaults the user_id argument. threads_get_profile with user_id: "me" will tell you yours.
Getting a token: the Threads app dashboard has a built-in User Token Generator, much simpler than a full OAuth redirect flow. It only works once the Threads account is set to public — otherwise it silently produces nothing useful rather than saying why.
⚠️ The token goes in a header, not the URL
Meta's own examples put access_token=... in the query string, and the server this replaces followed them. That puts the credential in access logs, proxy logs and browser history for every single request.
Here it is an Authorization: Bearer header, and there is a test asserting no request URL contains access_token.
Publishing is two calls, and the wait is the interesting part
Threads publishing is: create a container, wait for it to process, then publish it. Meta's guidance is to wait in between — longer for an image, because Meta fetches and processes it from a URL you supply.
The server this replaces waited a flat 30 seconds for text and 45 for an image, blocking the whole tool call regardless of whether the container was ready. That is slower than necessary in the common case and, on a slow image fetch, still not long enough.
This one polls the container's own status instead, and:
publishes as soon as it reports
FINISHED;refuses to publish a container reporting
ERRORorEXPIRED, passing Meta's own reason through — publishing a broken container is how you get a post that is not there, reported as a success;is bounded by attempts as well as by the clock, so a fast-responding status endpoint cannot turn the wait into a request storm;
falls back to waiting out the budget if Threads never returns a
statusfield at all. That field is not guaranteed on every container type, and degrading to the old blind wait is better than refusing to publish something that would have been fine.
An image must be a public http(s) URL that Threads can fetch server-side. A local file path can never work, so it is rejected at validation rather than sixty seconds later.
What is NOT covered, and why that is stated rather than hidden
Meta publishes no machine-readable spec for the Threads API. Every other server in this family checks its catalogue against the provider's own document and fails the build when the provider adds an endpoint; that is not possible here.
So this server does not claim complete coverage. It wraps the operations that are verified working, and ships threads_call as a documented passthrough onto the rest of https://graph.threads.net/v1.0 — replies, conversations, publishing limits, mentions, reposts and anything Meta adds next. That is an honest position rather than a catalogue that quietly goes stale.
Tools
Tool | |
| A profile. |
| Publish. Immediately public, no draft state. |
| Your recent posts with permalinks. |
| Views, likes, replies, reposts, quotes. |
| Delete your own post. Irreversible. |
| Anything else on the Graph API. |
Posting is a write rather than destructive — it can be deleted — but everyone who saw it still saw it, and the tool description says so. Deleting is destructive. threads_call reaches deletes, so it is destructive too.
After publishing, threads_get_my_posts is worth calling: it is how you confirm what actually went out, rather than assuming the container-then-publish sequence succeeded.
Read-only and no-destructive modes
MCP_READ_ONLY=1 refuse anything that changes state
MCP_NO_DESTRUCTIVE=1 allow posting, refuse deletesTesting
npm test # 11 tests
SMOKE_ENV='{"THREADS_ACCESS_TOKEN":"x"}' npm run smoke # real MCP over stdioThe smoke test runs with no credentials and no private task board reachable, and every assertion is about the server's own behaviour — nothing in it touches Meta or needs an account.
Built on
@nasdigitaluk/mcp-server-core.
Licence
MIT.
Available Tools
6 toolsthreads_callA
Call any Threads Graph API endpoint directly, for anything the tools above do not cover. Meta publishes no machine-readable spec for Threads, so this server does not claim a complete catalogue — this passthrough is how you reach the rest of the API without waiting for a tool to be written for it. Paths are relative to https://graph.threads.net/v1.0.
Inputs: path (required), query, method.
threads_create_postA
Publish to Threads. This is immediately public and there is no draft state — the only undo is threads_delete_post, and everyone who saw it still saw it.
An image is fetched by Threads from the URL you give, server-side, so it must be a publicly reachable http(s) URL. A local file path cannot work here.
Inputs: text (required), user_id, image_url, reply_to_id, +1 more.
threads_delete_postA
Delete one of your own posts. Irreversible.
Inputs: post_id (required).
threads_get_my_postsC
Your recent posts with their permalinks. Worth calling after publishing: it is how you confirm what actually went out rather than assuming the two-step container-and- publish sequence succeeded.
Inputs: limit, user_id.
threads_get_post_insightsC
Engagement on one of your posts: views, likes, replies, reposts, quotes.
Inputs: post_id (required).
threads_get_profileC
A Threads profile. Pass user_id='me' for the authenticated account, which is also how you find your own numeric id.
Inputs: fields, user_id.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 6 tools
Each tool targets a distinct operation: profile retrieval, post creation, listing posts, insights, deletion, and a generic passthrough. The generic 'call' tool is clearly scoped as a fallback for endpoints not covered, so there is no meaningful overlap or confusion.
All tool names follow a consistent 'threads_verb_noun' pattern, such as threads_get_profile, threads_create_post, and threads_delete_post. The naming is uniform, descriptive, and predictable across the set.
With six tools, the server covers the core Threads operations without being bloated. This is a well-scoped number for the apparent domain and leaves room for the generic passthrough to handle edge cases.
The tool set covers the essential profile, post creation/deletion, listing, and insights workflows. The inclusion of a generic call tool ensures that any missing or future Threads API endpoints remain accessible, so there are no dead ends.
Maintenance
Related MCP Connectors
Hosted X (Twitter) MCP server for Claude, ChatGPT and Cursor, with each action switched per account.
Hosted MCP server for DataLikers — Instagram & TikTok data API. 51 tools: Instagram user search by demographics (gender/age/race/country/city), profiles, bulk lookup, engagement, posts & reels, comments, hashtags, locations, stories, highlights, music, business accounts, top users; TikTok users, videos, comments, hashtags, playlists and top charts. Streamable HTTP, Bearer API key. Free tier: 100 requests on signup at https://datalikers.com/p/1by27bwg
MCP server for QPost — lets AI agents publish video and image posts to YouTube, TikTok, Instagram.
Social media MCP server: your Instagram, TikTok, YouTube, LinkedIn and Threads history for your AI.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceA stdio MCP server for the official Threads API, enabling publishing, reading, moderation, insights, discovery, locations, and setup diagnostics.2MIT
- AlicenseAqualityDmaintenanceUnofficial MCP server for Meta's Threads API. Enables LLMs like Claude to publish posts, manage replies, and track insights through the Model Context Protocol.15MIT
- FlicenseAqualityDmaintenanceMCP server for the Threads API, enabling profile management, content reading, publishing, replies, and discovery through 26 tools.26-
- AlicenseAqualityCmaintenanceCustom MCP server for Threads (Meta) — post, reply, and read insights via the official free Threads API.59 npmMIT