Developers
Postfig works with the AI assistant you already use. Connect it once, then ask ChatGPT or Claude to draft, schedule or publish posts to the accounts you’ve connected in Postfig. There’s a plain HTTP API too.
ChatGPT and Claude
Postfig is a remote MCP server at https://app.postfig.app/mcp. Add it where your assistant keeps its connectors, then sign in to Postfig when it asks and choose what it may do. You can disconnect it at any time from Postfig’s account menu, under AI assistants & API.
- ChatGPT: in Settings, open the connectors (apps) section and add a custom connector with the URL above.
- Claude (web and desktop): Settings → Connectors → Add custom connector, with the URL above.
- Claude Code:
then runclaude mcp add --transport http postfig https://app.postfig.app/mcp/mcpin Claude Code to sign in.
Remote connectors can’t read files on your computer. Give them a link to a photo or video, or an image the assistant generated, and it will fetch it for you.
Files from your computer: the local server
Being published to npm. Until the package appears there, use the connector above.
For Claude Code, Claude Desktop, Cursor and other MCP clients that run on your machine, @postfig/mcp adds one tool,add_media_from_file, which sends a photo or video straight from your disk. It needs an API key, which you make in Postfig’s account menu under AI assistants & API. The key stays on your computer.
claude mcp add postfig --env POSTFIG_API_KEY=pf_… -- npx -y @postfig/mcpClaude Desktop and Cursor take the same thing as JSON:
{
"mcpServers": {
"postfig": {
"command": "npx",
"args": ["-y", "@postfig/mcp"],
"env": { "POSTFIG_API_KEY": "pf_…" }
}
}
}What the assistant can do
| Tool | What it does |
|---|---|
list_channels | The accounts connected to your workspace. |
platform_rules | Caption limits and media rules per platform. |
add_media_from_url, add_media, add_media_from_file | Add a photo or video from a link, inline, or from your disk (local server only). |
create_post | Draft, schedule, or publish now, with per-platform captions and settings. Checks every platform’s rules first; dry_run only checks. |
get_post, list_posts | Status, results and links. |
publish_post, delete_post | Publish an existing post now; delete a draft or scheduled post. |
Reading tools are marked read-only; publishing and deleting aren’t, so assistants ask before doing them, and deleting is marked destructive.
The API
Everything above is also an HTTP API at https://app.postfig.app/api/v1, with an API key or OAuth token as a Bearer token. Requests and responses are JSON, except uploads, which send the file as the request body.
| Request | Does | Needs |
|---|---|---|
GET /me | Your workspace and what the token may do. | |
GET /channels | Connected accounts, with the ids posts use. | channels:read |
POST /media | Upload a file (its bytes as the body, with Content-Type; optional X-Name, X-Width, X-Height, X-Duration). Up to 100 MB. | media:write |
POST /media/from-url | { "url": "https://…" }: fetch a public file. | media:write |
POST /posts | Create a post (below). | posts:write |
GET /posts, GET /posts/:id | List (?status=, ?limit=) or fetch one, with each account’s result. | posts:read |
POST /posts/:id/publish | Publish a draft or scheduled post now. | posts:write |
DELETE /posts/:id | Delete a draft or scheduled post. | posts:write |
A post:
POST /api/v1/posts
Authorization: Bearer pf_…
Content-Type: application/json
{
"caption": "New season, new light.",
"media": ["m_…"],
"channels": "all",
"when": "2026-10-20T09:00:00+01:00",
"overrides": {
"instagram": { "settings": { "shareAs": "reel" } },
"threads": { "caption": "New season. New light.", "settings": { "topic": "Photography" } }
},
"alt": { "m_…": "A window at dawn" }
}when is "draft", "now", or a date-time with an offset. The reply is 201 with the post, or422 with issues, one per problem a platform would have (the caption too long for Threads, no photo for Instagram…). Send "dryRun": true to check without creating. Errors are { "error", "message" }.
Keys, tokens and what they can reach
- Every key and every assistant is limited to the scopes it was given:
channels:read,posts:read,posts:write,media:write. - A key is shown once and stored only as a hash. Revoke it from the account menu; it stops working at once.
- Assistants connect with OAuth 2.1 (PKCE, short-lived tokens) and go through a consent screen. Disconnecting removes their tokens.
- Nothing here can reach the sign-ins of your social accounts, which never leave Postfig’s servers.
Questions: support@postfig.app.