Last updated: October 27, 2026
Post to X from DeepSeek Harness
DeepSeek Harness (dsh) has no X tools of its own, but it ships an MCP client. Add one @deepseek-ai/dsh-mcp-client entry pointing at https://mcp.opentweet.io/mcp with your ot_ key, and the agent can publish, schedule and thread on X with 43 tools. No X developer account, no OAuth code.
DeepSeek released Harness on August 13, 2026 as an MIT-licensed, open-source alternative to the harness behind Claude Code and Codex. It is still a developer preview with breaking changes, so the config below is pinned to what the main branch documents on October 27, 2026.
7-day free trial with a few limits, or pay now for full limits.
Setup in three steps
Get an OpenTweet key
Sign up, connect your X account with a normal X login and create an API key. It starts with ot_. Export it as OPENTWEET_API_KEY so the key never sits in YAML.
Add one MCP client entry
DeepSeek Harness connects to MCP servers through its own plugin, @deepseek-ai/dsh-mcp-client, one plugin instance per server, configured in a Cordis patch file.
Start dsh and post
Discovery runs in the background. Once the mcp__opentweet__ tools appear, ask for a post, a thread or a week of scheduled posts.
The cordis.patch.yml entry
dsh is built on Cordis, and everything, including MCP servers, is a plugin instance. Add this to $DSH_HOME/cordis.patch.yml (DSH_HOME defaults to ~/.dsh) to load it in every profile:
# ~/.dsh/cordis.patch.yml (merge into the file if it already exists)
- insert:
- id: mcp-opentweet
name: '@deepseek-ai/dsh-mcp-client'
config:
serverName: opentweet
transport: streamable-http
url: https://mcp.opentweet.io/mcp
headers:
Authorization: !!js '`Bearer ${process.env.OPENTWEET_API_KEY}`'The header uses dsh's !!js tag to read the key from the environment, which is the pattern the dsh-mcp-client README uses. For one profile only, put the entry in $DSH_HOME/profiles/web/cordis.patch.yml (or headless). Then start dsh:
export OPENTWEET_API_KEY=ot_your_key
npx @deepseek-ai/dsh web
# or, for one run only:
dsh web --patch ./opentweet.cordis.ymlMerge, do not overwrite
The dsh MCP guide warns that your patch file may already hold other patches. Add the entry to it rather than copying a new file over it.Discovery is asynchronous. Wait until tools named mcp__opentweet__opentweet_create_tweet, mcp__opentweet__opentweet_schedule_tweet and the rest appear before your first prompt. If the server drops, the client reconnects with backoff (10 attempts by default) and re-syncs the tool list.
Things to ask it
- "Read the last three commits and post a short changelog thread to X."
- "Write five posts from docs/launch.md and schedule them at my best times this week."
- "Which of my posts did best last month? Write two more on that topic as drafts."
- "Add my top ten posts to the evergreen queue with a 30-day cooldown."
Tools that only read (analytics, lists) and tools that write (publish, schedule, delete) are both exposed. If you want a person to approve every post, keep dsh's approval policy on ask, or tell the agent to create drafts and review them in OpenTweet.
Post on a schedule with dsh headless
dsh headless answers one task, prints the result and exits (see the CLI help), which makes it easy to run from cron. --approval-policy never lets that run call tools without asking:
# crontab: one post every weekday at 15:00 UTC
0 15 * * 1-5 OPENTWEET_API_KEY=ot_... dsh --profile headless --approval-policy never \
"Read CHANGELOG.md, write one X post about the newest entry and publish it with OpenTweet" >> dsh-x.log 2>&1Or let OpenTweet hold the schedule
You do not need dsh running at post time. Ask the agent once for a week of posts with times, and OpenTweet publishes each one when it is due. That avoids giving an unattended agent permission to post.Prefer a skill? Use ~/.agents/skills
dsh reads the Agent Skills format. Its filesystem provider scans .dsh/skills and .agents/skills in the project, then ~/.dsh/skills and ~/.agents/skills. Put this in ~/.agents/skills/post-to-x/SKILL.md and Codex and Gemini CLI pick up the same file:
---
name: post-to-x
description: Publish or schedule posts on X (Twitter) through the OpenTweet API. Use when the user asks to tweet, post to X, or schedule a post.
---
# Post to X
Send requests to https://opentweet.io with the header
`Authorization: Bearer $OPENTWEET_API_KEY`. Never print the key.
- Publish now: POST /api/v1/posts {"text": "...", "publish_now": true}
- Schedule: POST /api/v1/posts {"text": "...", "scheduled_date": "<ISO 8601 UTC>"}
- Thread: POST /api/v1/posts {"text": "first tweet", "is_thread": true, "thread_tweets": ["second", "third"], "publish_now": true}
Rules: one idea per post, under 280 characters unless the user has X Premium,
show the text to the user before publishing unless they said "post now".A skill calls the REST API with the agent's shell tool. The MCP entry gives typed tools and more of them. Many people run both: MCP for the tools, a short skill for voice and posting rules. More agents and folders on the agent skills page.
Frequently asked questions
Can DeepSeek Harness post to X (Twitter)?
Not out of the box. dsh ships no X tools, but it ships an MCP client, @deepseek-ai/dsh-mcp-client, that connects to any Streamable HTTP MCP server. Point one instance at https://mcp.opentweet.io/mcp with an ot_ bearer key and the agent gets 43 tools to publish, schedule and thread on X.
Where do I add an MCP server in DeepSeek Harness?
In a Cordis patch file. Use $DSH_HOME/cordis.patch.yml (DSH_HOME defaults to ~/.dsh) for every profile, $DSH_HOME/profiles/<name>/cordis.patch.yml for one profile such as web or headless, or pass a file for a single run with dsh web --patch <path>. Merge the new entry into an existing file instead of overwriting it.
What are the tool names in dsh?
The MCP client exposes each tool as mcp__<serverName>__<tool>. With serverName opentweet, the posting tool is mcp__opentweet__opentweet_create_tweet. Server names must match [A-Za-z0-9_-]{1,32}.
Can dsh post on a schedule without me watching?
Yes, two ways. Run dsh headless "task" from cron: it answers one task and exits, and --approval-policy never skips approvals for that run. Or keep the agent interactive and have it schedule posts with a scheduled_date; OpenTweet publishes them at that time whether dsh is running or not.
Does DeepSeek Harness read SKILL.md files?
Yes. The filesystem skill provider scans .dsh/skills and .agents/skills in the project, then ~/.dsh/skills and ~/.agents/skills for the user. ~/.agents/skills is the same shared folder Codex and Gemini CLI read, so one posting skill serves all three.
Do I need an X developer account or X API key?
No. You log in to X once in OpenTweet and use an ot_ key. X API fees are included in the plan: $19.99/mo, or $29/mo with 10 link posts a day.
Does it work with DeepSeek V4 and other models in dsh?
Yes. MCP tools are model-agnostic, so the same entry works whichever provider the session uses: DeepSeek, Anthropic, OpenAI or a custom OpenAI-compatible endpoint.
Keep exploring
Other agents and harnesses that post to X with the same key.
Agent skills for X
One SKILL.md for dsh, Claude Code, Codex, Hermes and more.
Claude Code integration
The same tools from the agent dsh is compared with most.
Codex integration
Post to X from Codex CLI and the Codex app.
Hermes Agent integration
Another open-source agent, set up in config.yaml.
Give any MCP agent a Twitter tool
The general recipe for MCP clients.
OpenTweet MCP server
All 43 tools, documented.
Give DeepSeek Harness an X account
One YAML entry, 43 tools, scheduling included. No X developer account.
7-day free trial with a few limits, or pay now for full limits.