MCP server reference
What https://calmposts.com/mcp speaks, how clients sign in, which scope each tool needs and which images the server accepts. The steps for a particular client are on that client's page.
Endpoint https://calmposts.com/mcp
Keys and sign-in come from a calmposts workspace, and every plan starts with a free trial. Try it free
Protocol
- MCP over Streamable HTTP, as POST requests to https://calmposts.com/mcp. A request body holds one JSON-RPC message of up to 1 MB, and the answer is a single application/json response.
- The server handles initialize, tools/list, tools/call and ping. It acknowledges notifications/initialized with 202 and an empty body.
- initialize returns the client's own protocolVersion, or 2024-11-05 when the client sends none, along with serverInfo.name calmposts-mcp and a few lines of instructions for the model.
- GET answers 405, because the server opens no stream to the client. A browser that visits the address lands on our integrations page.
- A tool that fails still returns a result. Its isError is true, and the text begins with Error, then the API's code, field and problems. JSON-RPC errors are kept for protocol faults such as an unknown tool name.
- Clients that discover servers by themselves can read the Server Card at /mcp/server-card or /.well-known/mcp.json.
One call with a key, and the start of its answer. The text field holds the tool's result as JSON.
curl -s https://calmposts.com/mcp \
-H "Authorization: Bearer cp_live_…" \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{"jsonrpc":"2.0","id":2,"method":"tools/call","params":{"name":"get_limits","arguments":{}}}'
# {"jsonrpc":"2.0","id":2,"result":{"content":[{"type":"text","text":"{\n \"billing\": {\n \"plan\": …"}]}}Sign-in
An API key travels in the Authorization header as Bearer cp_live_… on every request. The workspace owner creates it under API & MCP and sees it once. It never expires, its scopes limit the tools as the table below shows, and a revoked key fails on its next request.
OAuth starts from a 401. Its WWW-Authenticate header points to /.well-known/oauth-protected-resource, which names the authorization server, described at /.well-known/oauth-authorization-server. The client registers at /oauth/register as a public client without a secret and runs the authorization code flow with PKCE (S256). Redirect URIs may be https, http to localhost, 127.0.0.1 or ::1, or a private-use scheme.
An authorization code is valid for 5 minutes and an access token (cp_oat_) for an hour. The refresh token (cp_ort_) lasts 30 days and changes at every refresh, and sending a spent one again more than a minute later revokes the grant. A client that asks for no particular scope gets all seven, leads:read for the emails visitors leave on gated pages included. A connection made before a scope existed does not have it: connect again to add it.
The consent page accepts only the workspace owner, and only on a plan with API keys. A workspace holds up to 25 connections.
Tools
| Tool | Scope | What it does |
|---|---|---|
list_accounts | accounts:read | Connected channels and each network's rules, such as length (X counts a URL as 23 characters), images and threads. customer_id narrows the list to one customer. |
list_customers | accounts:read | An agency's customers, each with the ids of its channels. |
get_limits | accounts:read | The plan and what is left of it today and this month, the workspace's time zone and each network's limits. |
create_post | posts:write | A post (text) or a thread (parts) for account_ids, with images and videos by URL (media) or uploaded files (media_ids) and overrides for per-account wording. when is draft, queue, at or now. |
list_posts | posts:read | Posts, newest first, filtered by status, account, customer and scheduled time. 20 per page by default, up to 100. |
get_post | posts:read | One post with its parts, channels, status, error, published URL and version. |
update_post | posts:write | Changes the text, accounts or time of a draft or scheduled post, and fields left out stay. Pass the version you read, and a newer edit by someone else returns version_conflict instead of being overwritten. |
delete_post | posts:write | Cancels a scheduled post. A published one stays on the network, and calmposts forgets it. |
get_next_slot | posts:read | The time when=queue would pick for these accounts. Slots are 09:00, 12:00 and 17:00 in the workspace's zone by default. |
retry_post | posts:write | Sends the failed channels again. A thread that stopped halfway goes on from where it stopped. |
get_post_metrics | posts:read | Counts read 1 hour, 24 hours and 7 days after publishing, on plans with analytics. Threads and LinkedIn channels have none. |
create_upload_url | media:write | A one-time URL for a file on the agent's own disk, such as an MP4 it rendered. The agent PUTs the file there without the key, then passes its media_id to create_post or update_post. |
list_gate_pages | gates:read | Gated pages with their status, address and counts for the last 30 days, and how many live pages the plan allows. |
get_gate_page | gates:read | One gated page with its steps, content and counts by day. |
list_gate_leads | leads:read | The email addresses visitors left on a gated page, newest first. Personal data, so it has a scope of its own. |
create_gate_page | gates:write | A gated page as a draft: title, teaser, the steps on X or an email that unlock it, and the content they unlock. |
update_gate_page | gates:write | Changes a gated page, and fields left out stay. steps and content replace the whole list. |
publish_gate_page | gates:write | Puts a gated page on the site. Where agents' posts wait for approval, the page waits too, marked with the agent's name. |
pause_gate_page | gates:write | Takes a published gated page off the site for now. It still counts toward the plan. |
The read tools carry readOnlyHint and idempotentHint. delete_post is marked destructiveHint, and create_post, update_post, retry_post, publish_gate_page and pause_gate_page openWorldHint, so a client can tell which calls change something outside it.
Files by URL also need media:write, and gate_id in create_post needs gates:read. A key whose creator has become a viewer keeps only its read scopes, without leads:read.
Approvals
When the workspace or the key requires approval, which both do by default, create_post returns the post with status pending_approval and its channels awaiting_approval. The answer adds an approval_notice that tells the agent to let you know and not to create the post again.
update_post can still change a held post, and it stays held. An approved post is checked once more and scheduled. A rejected one is canceled.
Gated pages follow the same rule. publish_gate_page then leaves the page a draft, marked with the agent's name, until a person publishes it in calmposts. A post with gate_id waits for such a page and goes out only after it is published.
Images and videos by URL
- https on the default port, without a user name or password in the URL
- public addresses only, checked after DNS on every connection and every redirect
- up to 3 redirects, each to https
- up to 5 MB and 10 seconds per image, 50 MB and 2 minutes per video
- JPEG, PNG, WebP or GIF, and MP4 in media, recognised from the file's bytes
- up to 20 files per part and 40 downloads per call, 4 of them videos, and each network's own image and video limits still apply
- a file on the agent's own disk goes through create_upload_url instead: one file per URL, within 15 minutes, up to 50 MB
Setup in each client
Each client's steps, sign-in and errors are on its own page.
X (Twitter) MCP server overview, with approvals, limits and common errors