Today you manage X Ads from the AdsGPT assistant, on the web and in the mobile app. In Codex it shows as coming soon: AdsGPT already works with Google Ads from Codex and will add X Ads to its MCP server without you reinstalling anything.
X Ads promotes your posts to the audience you choose on X. With AdsGPT you get reports by campaign, line item or promoted post, with impressions, engagements, clicks, likes, reposts, replies and follows; you activate or pause; adjust budgets, bids and targeting; and create reach campaigns with text and image posts.
What you can do with X Ads
Engagement by post
Impressions, engagements, link clicks, likes, reposts and follows for each promoted post.
Budgets and bids
Change the daily or total budget and set a target cost per thousand impressions or X's automatic bid.
Reach campaigns
1 to 5 posts with text, image and link, published as ads only and created paused.
Requirements
- An AdsGPT account with at least one ad platform connected.
- The Codex CLI, the Codex IDE extension or the Codex app.
- A browser to sign in (or a second device, see tips).
Step-by-step setup
Connect X Ads in AdsGPT
- Sign in to app.adsgpt.dev as the organization owner.
- Open Plugins and choose X Ads.
- Sign in with the X account that has access to your ad accounts and authorize AdsGPT.
- Your X Ads accounts show up in AdsGPT and any member can use them from the AdsGPT assistant, as their role allows.
Add AdsGPT to Codex: install the AdsGPT plugin
- Plugin
- Recommended
- Add the marketplace and the plugin:
Terminal codex plugin marketplace add adsgpt-dev/agent-plugins codex plugin add adsgpt@adsgpt - You can also open
/pluginsin Codex, or the Plugins tab in the app, and install AdsGPT fromadsgpt. - Sign in:
Terminal codex mcp login adsgpt - Start a new Codex session.
Add the MCP server only
- MCP server
- Add the server with one command:
Terminal codex mcp add adsgpt --url https://mcp.adsgpt.dev - Or edit
~/.codex/config.toml:~/.codex/config.toml [mcp_servers.adsgpt] url = "https://mcp.adsgpt.dev" - Sign in with
codex mcp login adsgpt.
Example prompts for X Ads
- “Which promoted posts on X got the most engagement last week?”
- “Pause the X line items with a CPM above 8 dollars.”
- “Create an X reach campaign for my product launch in the US.”
Security and approvals
- You sign in with OAuth 2.1: you never copy or share API keys.
- The
ads:readscope comes first;ads:writeis only requested the first time a tool changes something. - Every change shows the current and new value and waits for your approval.
- New campaigns launch paused unless you ask otherwise.
- AdsGPT acts with your role on the account and receives tool calls, never your conversation.
Tips
- On a machine without a browser, run
codex mcp login adsgpt --no-browserand open the printed link on another device. - Combine AdsGPT with Codex tasks: for example, have it build landing pages and then plan the Search campaign for them.
Frequently asked questions
Can I use X Ads in Codex?
Not yet. X Ads already works in the AdsGPT assistant, on the web and in the app, and is coming soon to the MCP server. Until then, Codex lists it as coming soon.
Do I have to connect X Ads inside Codex?
No. X Ads is connected once in AdsGPT and is then available to your organization.
Can my X Ads campaigns be changed without permission?
No. Reads run instantly, but every change shows the current and new value and waits for your approval. New campaigns are created paused.
Can I manage several networks at once?
In the AdsGPT assistant you already work with Google Ads, Meta Ads, TikTok Ads, LinkedIn Ads, X Ads, Reddit Ads, OpenAI Ads and Unity Ads. From Codex, Google Ads is available today and the rest are coming soon. A campaign on several networks is created on each with the same name, so your reports tie them together.
Which X Ads campaigns can I create?
Reach (awareness) campaigns with 1 to 5 text and image posts, targeted by place, language, interests, gender and age. Custom audiences and cards are made in ads.x.com.
What permissions do I need on X?
The account administrator or ad manager role (an analyst only reads) and a funding instrument that can pay.