PostPilot
Click on "Install 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., "@PostPilotPrepare a tweet about today's product launch for my review."
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.
PostPilot is an open-source ChatGPT plugin that connects a user's X account and lets ChatGPT draft, validate, review, publish, list, and delete posts through a remote MCP server.
Safety first: PostPilot never publishes from a draft alone.
prepare_postbinds the exact text to a short-lived, single-use approval token.publish_postrejects changed text, expired approvals, reused approvals, and approvals belonging to another account.
What it includes
Streamable HTTP MCP endpoint at
/mcpX OAuth 2.0 Authorization Code + PKCE
ChatGPT-compatible OAuth discovery and dynamic client registration
Per-tool OAuth security declarations and account-linking challenges
Resource-bound access tokens with issuer, audience, expiry, and scope verification
Least-privilege X scopes:
tweet.read tweet.write users.read offline.accessWeighted X character validation using
twitter-textExact-text, expiring, single-use publishing approvals
Tools for account lookup, validation, staging, publishing, recent posts, and deletion
Helmet, strict request limits, secret redaction, timeouts, typed validation, health checks
Tests, linting, type checking, CI, Dependabot, CodeQL, Docker, and deployment template
Security, privacy, contribution, architecture, setup, and submission documentation
A current
.codex-plugin/plugin.jsonmanifest with branded install metadataA domain-verification endpoint, release notes, and reviewer-ready evaluation cases
Related MCP server: postlayer-connect
Why PostPilot
Giving a model access to a public social account demands a stronger boundary than “call the post API.” PostPilot deliberately separates writing from publishing:
ChatGPT drafts or validates content.
prepare_postcreates a signed approval capability bound to the exact text, account, and optional reply target.The user reviews the exact staged text.
Only explicit approval allows
publish_post.The capability expires after ten minutes and cannot be reused.
Changing even one character invalidates the approval.
Architecture
flowchart TD
U["User in ChatGPT"] --> C["ChatGPT MCP client"]
C -->|"OAuth + tool calls"| P["PostPilot MCP server"]
P -->|"PKCE authorization"| X["X API"]
P --> A["Exact-text approval gate"]
A -->|"Confirmed publish"| XPostPilot is the authorization server from ChatGPT's perspective and an OAuth client of X. This broker pattern lets ChatGPT receive a PostPilot-scoped bearer token without exposing X tokens to the model or widget.
MCP tools
Tool | Effect | Confirmation behavior |
| Local validation | No account or confirmation |
| Reads linked identity | OAuth required |
| Stages exact content | Does not publish |
| Creates a post | Exact, single-use approval required |
| Reads recent posts | OAuth required |
| Deletes a post | Explicit |
Every tool advertises explicit readOnlyHint, destructiveHint, and openWorldHint values. Shared server instructions reinforce the required prepare → review → publish sequence.
Example conversations
“Check whether this announcement fits on X.”
PostPilot calls validate_post, calculates X's weighted character length, and reports the remaining space without publishing.
“Prepare ‘PostPilot is now live’ for my review.”
PostPilot stages the exact text and asks for confirmation. It does not publish at this stage.
“I approve that exact post. Publish it.”
PostPilot verifies the account, signature, expiry, content digest, reply target, and unused token ID before calling X.
Local setup
Create an app in the X Developer Console and enable OAuth 2.0.
Add
http://localhost:8787/oauth/x/callbackas a callback URL for local development.Copy
.env.exampleto.env, fill in the X client ID, optional confidential-client secret, and a random signing secret.Install and run:
npm install
npm run devExpose port 8787 with a temporary HTTPS tunnel for development only.
In ChatGPT, enable Developer mode, create a draft plugin, and use
https://YOUR_HOST/mcp.
For production, read deployment, X setup, and ChatGPT setup.
Connect from ChatGPT
After deployment, verify these public URLs before adding the server:
URL | Expected result |
| JSON with |
| MCP resource and authorization-server metadata |
| OAuth endpoints, PKCE, and dynamic registration metadata |
| Streamable HTTP MCP endpoint |
Then open ChatGPT → Settings → Security and login, enable Developer mode, open ChatGPT Plugins, select +, and enter https://YOUR_HOST/mcp. validate_post works without authentication; the account-specific tools trigger ChatGPT's OAuth linking interface and then redirect the user through X authorization.
ChatGPT and Codex plugin packaging
PostPilot includes the required manifest at .codex-plugin/plugin.json, branded assets, starter prompts, capability metadata, legal links, and submission evaluation cases.
The repository cannot contain a production .app.json ID before the MCP connection is registered because ChatGPT generates that plugin_asdk_app... identifier. To complete local installation:
Deploy the MCP server or expose it temporarily over HTTPS.
Register the
/mcpURL in ChatGPT Developer mode.Copy the generated
plugin_asdk_app...technical ID.Create
.app.jsonusing that registered ID and add"apps": "./.app.json"to the manifest.Refresh plugin metadata and test in a new conversation.
For a public directory submission, use the production HTTPS endpoint and submission portal rather than a temporary tunnel. See the submission dossier.
Configuration
Variable | Required | Purpose |
| No | HTTP port; defaults to |
| Production | Canonical HTTPS origin used in OAuth metadata. |
| Yes | X OAuth 2.0 application client ID. |
| Confidential clients | X OAuth client secret. |
| Yes | Exact X callback ending in |
| Yes | 32+ character secret for access and approval tokens. |
| Production | Comma-separated CORS origins. |
| Submission | Exact domain-verification token from the plugin portal. |
| No | Pino log level. |
Security properties
OAuth 2.0 authorization code flow with PKCE on both trust boundaries.
One-time authorization codes bound to client, redirect URI, challenge, and expiry.
Exact-text approval capabilities signed with HS256.
Single-use approval identifiers and ten-minute expiry.
Server-side validation and authorization for protected tools.
Authorization headers, OAuth codes, and refresh tokens redacted from logs.
Outbound X requests use TLS, timeouts, and bounded error bodies.
Publishing and deletion are explicitly marked destructive and open-world.
Read SECURITY.md before deploying or reporting a vulnerability.
Required production work
The default MemoryStore is intentionally suitable only for one-process development. Before public deployment, implement the Store interface with encrypted, durable storage and atomic single-use approval consumption. Refresh-token rotation should be added to the X client for long-lived connections. See architecture.
This limitation is why v0.3.0 is a developer release, not a claim that the hosted public service is already production-ready.
Commands
npm run check # lint, types, tests
npm run validate:plugin
npm run build
npm startRepository layout
.codex-plugin/plugin.json Plugin package and install metadata
assets/ Logo and composer icon
docs/ Architecture, deployment, legal, and submission guides
evals/ Positive and negative submission cases
src/index.ts HTTP transport and server bootstrap
src/mcp.ts Tools, schemas, instructions, and annotations
src/oauth.ts ChatGPT ↔ PostPilot ↔ X OAuth broker
src/security.ts PKCE, JWT access, and approval binding
src/store.ts Replaceable persistence interface
src/x-client.ts Minimal typed X API clientRelease policy
PostPilot uses semantic versioning. See CHANGELOG.md for release notes. Tool names and schemas should remain backward compatible within a major version.
Responsible use
Users remain responsible for content they publish and for compliance with X's rules, developer agreement, applicable law, and OpenAI plugin policies. PostPilot must not be used for spam, platform manipulation, impersonation, harassment, or evading rate limits.
Status
Version 0.3.0 implements the remote Streamable HTTP MCP, ChatGPT OAuth discovery, per-tool security and output schemas, runtime account-linking challenges, resource-bound bearer tokens, valid square branding assets, and automated package validation required for Developer mode testing. Before public submission, complete the operator-controlled items in the upload checklist.
Support PostPilot
If PostPilot is useful to you, you can support its maintenance through GitHub Sponsors or thanks.dev. The repository's .github/FUNDING.yml exposes both options through GitHub's Sponsor button.
License
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseBqualityDmaintenanceAn MCP server that allows Claude to create, manage and publish X/Twitter posts directly through the chat interface.Last updated561MIT
- AlicenseAqualityCmaintenanceA local MCP server that enables AI assistants to post to social media platforms (LinkedIn, X, Bluesky, Mastodon, Reddit, etc.) using your own app credentials, with encrypted token storage and no middleman.Last updated5MIT
- Alicense-qualityAmaintenanceA local-first MCP server for social publishing on X (Twitter), enabling draft management, scheduling, and posting via CLI or AI agents.Last updated395MIT
- Alicense-qualityDmaintenanceMCP server that enables AI agents to schedule and publish posts to 13+ social platforms via PostBolt's API with zero code.Last updated48MIT
Related MCP Connectors
Connect any AI agent to 11+ social platforms: schedule, publish & track posts via hosted MCP.
FastMCP server for posting formatted content to X (Twitter) — Tollbooth-monetized, DPYC-native
Publish, schedule, and manage social media posts across major platforms via the Postproxy API.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/theworker02/postpilot'
If you have feedback or need assistance with the MCP directory API, please join our Discord server