MCP tool
create_post
Create a post
Creates or changes something · and, like everything an agent creates, it is mailed to the project — and in copilot mode waits for a human in the approval queue.
What it does
Create a post to connected accounts — X/Twitter, Instagram, LinkedIn, Facebook, TikTok, YouTube, Threads, Bluesky, Pinterest. CREATING IT SENDS IT: no scheduled_at publishes now, one publishes then; a project may hold it instead (status says). The answer carries message and approval_link or preview_link. accounts takes each account's ref. Media is media_ids, files (attachments from this conversation) or media_pending: true, which holds the post until the picture arrives — the reply's upload_url takes a POST of the file (upload_curl), or the person adds it in the card; then it goes out on its own unless the project holds agent posts. "next_slot" takes the queue; is_draft saves without sending. Undo: update_post or delete_post before it goes out; take_down_post after, where networks allow.
Arguments
| Name | Type | Required | What it is |
|---|---|---|---|
| caption | string | No | The post text. Optional only where no destination prints one: a story, or X/Instagram/LinkedIn publishing media alone. WRITE IT TO FIT EVERY TARGET: one destination over its own limit refuses the WHOLE post and nothing goes out anywhere — X is 280 as X counts it, and list_accounts gives each account its caption_chars_available. Words the person wrote are theirs: where they do not fit, say so and ask, never quietly shorten them. |
| accounts | array | No | Where it posts: each account's ref from list_accounts ("x:someone"). LIST EVERY ACCOUNT THIS POST GOES TO — one post, many accounts; a platform that needs different words gets them in platform_configurations.<platform>.caption, never a post of its own. A person reads this request before approving it, and the ref is what they can check. A ref matching nothing refuses the whole post. |
| social_account_ids | array | No | Deprecated name for accounts. |
| media_ids | array | No | Media ids from upload_media; first is the carousel lead. |
| files | array | No | Files the user attached to this conversation, as the host hands them over, in post order. They are attached after media_ids. |
| media_pending | boolean | No | The picture is still to come: the person adds it in the approval card. Lets a post for Instagram, TikTok, YouTube or Pinterest be created without media; it goes out once the media is on it (or, on a project that holds agent posts, can be approved then). |
| scheduled_at | union | No | ISO 8601 with Z or an offset, or "next_slot" for the project's own posting schedule (get_project shows queue). Omit to publish now — or, on a project that holds agent posts, as soon as it is approved. |
| is_draft | boolean | No | Save as a draft: visible in xpost, publishing nowhere until a person sends it. |
| platform_configurations | record | No | Per-platform options keyed by platform: caption is that platform's own text (so one post can say it differently on X and on Instagram), placement picks "reels"/"stories" where offered. Which keys each account takes is what get_posting_rules answers. Example: {"instagram": {"placement": "stories"}, "x": {"caption": "the short one"}} |
| idempotency_key | string | No | Your own id for THIS request, unique to it (not to the subject). A retry with the same key returns the post the first call made, as repeated: true, instead of a second post. |
Calling it
Any MCP client calls this by name once the connector is added. The address is the same for every tool:
https://xpost.to/api/mcp
A client that has signed in sends the tool name and its arguments:
{
"name": "create_post",
"arguments": {
"caption": "…",
"accounts": []
}
}The other tools
Back to the MCP connector · What the MCP server is · Connect your assistant