---
title: "Schedule Social Media Posts with Codex (MCP Setup)"
description: "Connect OpenAI Codex to PostNext with two commands and schedule posts to X, Instagram, LinkedIn, TikTok and Threads from the CLI, IDE or desktop app."
url: "https://postnext.io/ai-agents/codex"
language: "en-GB"
---

# Schedule social media posts with Codex

Connect OpenAI Codex to PostNext with two commands and schedule posts to X, Instagram, LinkedIn, TikTok and Threads from the CLI, IDE or desktop app.

Human version: [https://postnext.io/ai-agents/codex](https://postnext.io/ai-agents/codex)

Codex

Add PostNext to Codex once. The CLI, the IDE extension and the desktop app share the setup, so every Codex surface can draft and schedule posts.

[Get started free](https://postnext.io/signup?plan=free&source=ai-agent-codex)

1. **Add the server** Run the first command. Codex saves PostNext in config.toml.
2. **Sign in** Run codex mcp login postnext and approve the PostNext sign-in in your browser.
3. **Or use the desktop app** Open Settings, then MCP servers, then Add server. Choose Streamable HTTP, paste the URL, save, restart and select Authenticate.
4. **Ask for posts** Ask Codex to draft and schedule posts from your repo, notes or release history.

Terminal

```
codex mcp add postnext --url https://mcp.postnext.io/api
codex mcp login postnext
```

## Connect PostNext to Codex

**Setup time**

About 1 minute

**Sign-in**

OAuth, or an API key from a variable

Codex on ChatGPT Plus or higher, or an API key

Steps checked against the OpenAI documentation on 18 November 2026. [Read the OpenAI guide](https://learn.chatgpt.com/docs/extend/mcp)

ChatGPT connects to the same PostNext server. [How to schedule social media posts from ChatGPT](https://postnext.io/ai-agents/chatgpt)

Codex

Summarise the commits since the last tag into a release post for X and LinkedIn. Save both as drafts.

Every Friday at 16:00, write a weekly changelog post from merged pull requests and save it as a PostNext draft.

Turn README.md into three short posts that each explain one feature. Schedule them across next week.

## Then ask Codex

Codex uses the PostNext tools. Your posts go out at the set time, even after you close Codex. Until then, each one waits on your [social media calendar](https://postnext.io/features/scheduling).

## You decide what goes out

- Drafts first
- No social passwords shared
- Access you can remove

Supported channels[X (Twitter)](https://postnext.io/mcp/x) [Instagram](https://postnext.io/mcp/instagram) [LinkedIn](https://postnext.io/mcp/linkedin) [TikTok](https://postnext.io/mcp/tiktok) [Threads](https://postnext.io/mcp/threads) [YouTube](https://postnext.io/channels/youtube) [Bluesky](https://postnext.io/channels)

## Questions about Codex and PostNext

Setup, plans, approvals and what Codex can do.

### Can Codex post to social media?

Yes. With PostNext added as an MCP server, Codex can draft posts, schedule them and read their results. PostNext publishes each post through the network's official API.

### Which Codex plans work?

Codex runs in the CLI, IDE and desktop app on ChatGPT Plus, Pro, Business and Enterprise, and Free and Go get the desktop app as it rolls out. The CLI can also sign in with an API key.

### Does Codex ask before it schedules?

Codex has an approval mode for each MCP server. Set it to prompt or writes so Codex asks before tools that change your account.

### Can Codex post every week?

Yes. Codex scheduled tasks run unattended with your default sandbox settings and can use MCP servers. Ask them to save drafts, so you can check posts before they go live.

### Is Codex the same as ChatGPT?

No. Codex is OpenAI's coding agent. ChatGPT is the chat assistant and adds PostNext from its Plugins page. ChatGPT on the web does not read your local Codex config.

### Does this cost extra?

No. MCP access is included with every PostNext plan. Your plan's limits (AI credits, posts a month, channels, storage) apply over MCP as they do in the app, and a few assistant tools, listed above, need a paid plan.

### How do I revoke access?

Disconnect from your AI client's settings, or open your account page on PostNext and remove the client. Tokens also auto-expire after 30 days of inactivity.

## Social media posting from Codex

Connect once. Then ask Codex to plan, write and schedule your posts.

[Get started free](https://postnext.io/signup?plan=free&source=ai-agent-codex)
