10 DAYS ONLY · $500 VALUE Top 100 Viral Hooks + Repurpose Engine (Claude Skills) Start free → Start free →
OpenAI Codex

OpenAI Codex Social Media MCP Setup

OpenAI Codex connects to a social media MCP server through a form rather than a JSON block. Choose the streamable HTTP server type, set the URL to https://mcp.blotato.com/mcp, leave the bearer token field blank, and add blotato-api-key as a header with your key as the value. Codex can also take the same entry in config.toml.

Endpoint https://mcp.blotato.com/mcp API key header

Updated August 2026

How to connect OpenAI Codex to social media

  1. Connect your social accounts in Blotato, then copy your API key from Settings then API.
  2. In Codex, add an MCP server and choose the streamable HTTP server type.
  3. Set the URL to https://mcp.blotato.com/mcp.
  4. Leave the bearer token environment variable blank. This field is not how Blotato authenticates.
  5. Under Headers, set the key to blotato-api-key and paste your full API key as the value, then save.
Form fields, or the equivalent config.toml entry
# Form: choose "streamable HTTP"
URL:                    https://mcp.blotato.com/mcp
Bearer token env var:   (leave blank)
Header key:             blotato-api-key
Header value:           YOUR_API_KEY

Codex asks for a form rather than JSON: choose the streamable HTTP server type, set the URL, leave the bearer token blank, and add blotato-api-key as a header.

How do I know it worked?

Ask OpenAI Codex to list your connected accounts. It calls blotato_list_accounts and returns your platforms, which confirms both the connection and the authentication in one step. If you see your accounts, setup is done.

First prompt to run
What social media accounts do I have connected?
An AI agent answering "what social accounts do i have connected?" by calling Blotato and listing 10 connected social media accounts across Twitter, Bluesky, Instagram, Threads, LinkedIn, Facebook, YouTube, Pinterest, and TikTok
The reply you are looking for: the agent calls Blotato and lists every connected account. Here it returns 10 accounts across all nine platforms.

Worth knowing before you rely on it: analytics prompts only return data for X, Instagram, Facebook, Threads, and Bluesky. The other four platforms publish normally but report no metrics yet.

What to ask OpenAI Codex once it is connected

Ship the release notes to X and LinkedIn when the build passes.
Codex puts blotato_create_post at the end of the task it is already running. The publishing step lives in the same agent session as the work that produced it, rather than in a separate tool you switch to afterwards.
Did that actually publish?
blotato_create_post returns a postSubmissionId rather than a finished post, because publishing is async. blotato_get_post_status resolves it to published, scheduled, or failed with an error message, which is the check worth building into any script.
Pull my recent posts so I can see what we already covered.
blotato_list_posts returns them, which is the cheapest way to stop an agent rewriting a topic it published last week.

What breaks, and how to fix it

The Codex-specific mistake is filling in the bearer token field because it is the obvious one. Blotato does not authenticate that way, and a key in that slot returns an auth error while the header sits empty. The other is dropping a trailing equals sign when copying the key, since the equals is part of the key and losing it produces a 401 invalid API key.

What is different about OpenAI Codex

Codex is the only client here that asks for a form instead of JSON, which is why the config everyone pastes between Cursor and Antigravity does not transfer. It is also frequently confused with ChatGPT: they are different OpenAI products with different connection models, and Codex has no Developer mode requirement or tier gate.

Vendor documentation: OpenAI Codex MCP setup. For how a client discovers and calls tools once connected, see the MCP client concepts reference.

FAQ

OpenAI Codex social media FAQs

01 Can OpenAI Codex post to social media?
Yes. OpenAI Codex cannot reach a social account on its own, because it has no platform credentials. Connecting it to Blotato's hosted MCP server at https://mcp.blotato.com/mcp gives it tools to publish and schedule across nine platforms: X, LinkedIn, Facebook, Instagram, TikTok, YouTube, Threads, Bluesky, and Pinterest. OpenAI Codex authenticates with api key header.
02 How do I connect OpenAI Codex to social media?
OpenAI Codex connects to a social media MCP server through a form rather than a JSON block. Choose the streamable HTTP server type, set the URL to https://mcp.blotato.com/mcp, leave the bearer token field blank, and add blotato-api-key as a header with your key as the value. Codex can also take the same entry in config.toml.
03 How do I set up OpenAI Codex for social media?
Setting up OpenAI Codex for social media takes one connection. Connect your social accounts in Blotato, then give OpenAI Codex the hosted MCP endpoint https://mcp.blotato.com/mcp and authenticate with api key header. For OpenAI Codex specifically that means: form fields, or the equivalent config.toml entry. Once it loads, OpenAI Codex can publish and schedule to X, LinkedIn, Facebook, Instagram, TikTok, YouTube, Threads, Bluesky, and Pinterest from a plain-language prompt.
04 What is the best way to manage social media with OpenAI Codex?
Let OpenAI Codex do the drafting and decision making, and let a publishing layer hold the accounts and the schedule. The thing that makes this work on OpenAI Codex in particular: Codex is the only client here that asks for a form instead of JSON, which is why the config everyone pastes between Cursor and Antigravity does not transfer. It is also frequently confused with ChatGPT: they are different OpenAI products with different connection models, and Codex has no Developer mode requirement or tier gate.
05 What goes wrong when connecting OpenAI Codex?
The Codex-specific mistake is filling in the bearer token field because it is the obvious one. Blotato does not authenticate that way, and a key in that slot returns an auth error while the header sits empty. The other is dropping a trailing equals sign when copying the key, since the equals is part of the key and losing it produces a 401 invalid API key.
06 Does OpenAI Codex need to be running for a scheduled post to go out?
No. Scheduling runs on Blotato rather than inside OpenAI Codex. Once the agent queues a post, it publishes at the scheduled time whether or not OpenAI Codex, your terminal, or your laptop is on. This is the practical difference between an agent that drafts and a system that runs unattended.
07 What can I ask OpenAI Codex to do once it is connected?
"Ship the release notes to X and LinkedIn when the build passes." Codex puts blotato_create_post at the end of the task it is already running. The publishing step lives in the same agent session as the work that produced it, rather than in a separate tool you switch to afterwards. "Did that actually publish?" blotato_create_post returns a postSubmissionId rather than a finished post, because publishing is async. blotato_get_post_status resolves it to published, scheduled, or failed with an error message, which is the check worth building into any script. "Pull my recent posts so I can see what we already covered." blotato_list_posts returns them, which is the cheapest way to stop an agent rewriting a topic it published last week.
08 How much does it cost to connect OpenAI Codex?
Starter is $29/mo flat for 20 connected accounts, and the price does not scale with posting volume. API and MCP access is not part of the 7-day trial: generating a key activates the paid Starter plan, so plan on subscribing rather than trialing it.

Connecting a different agent?

Same endpoint, same accounts, one setup per client. The AI agents for social media hub covers what all of them share, including every tool your agent can call.