Connect Ampost to your AI agent
Give Claude Code, Cursor, VS Code, Codex or another MCP client Ampost's publishing tools: one command or one click per client, authenticated with your Ampost API key.
Config files are not shell scripts. If your client does not expand ${AMPOST_API_KEY}, paste the key itself. Some clients (npx arguments, some Windows apps) do not expand variables: the header then arrives empty, and the client opens Ampost's sign-in page instead of using the key.
Works on every plan, Free included
The REST API and MCP need no paid plan and no credit card. Free includes 3 social accounts, 50 posts a month, posts to several platforms at once and 60 read requests a minute; scheduling needs the Pro plan or higher. On Free a social account can be connected in one Ampost workspace only (also for 30 days after it is disconnected), and its 50 posts a month count per social account, whichever workspace publishes. See pricing.
1. Create an API key
In the dashboard, open Settings, API keys and generate a key. The key is shown once, and the page then shows the commands below with your key filled in. Your agent never needs your Ampost password or your social media logins: accounts are connected in the browser.
2. Add Ampost to your client
Fills the key into the commands and enables the one-click buttons. It stays in this browser tab and is not sent anywhere.
For the claude CLI, the Code tab of the Claude desktop app and the Claude Code IDE extensions: they are all Claude Code. Run this in a terminal. --scope user adds Ampost to every project; leave it out to add it to the current project only.
Add with the CLI
claude mcp add --transport http --scope user ampost https://api.ampost.io/mcp --header "Authorization: Bearer amp_live_YOUR_KEY"Or share it with a project; each person sets AMPOST_API_KEY
{
"mcpServers": {
"ampost": {
"type": "http",
"url": "https://api.ampost.io/mcp",
"headers": {
"Authorization": "Bearer ${AMPOST_API_KEY}"
}
}
}
}No claude command (the Code tab of the Claude app): add it to the user config instead
{
"mcpServers": {
"ampost": {
"type": "http",
"url": "https://api.ampost.io/mcp",
"headers": {
"Authorization": "Bearer amp_live_YOUR_KEY"
}
}
}
}- With
.mcp.json,AMPOST_API_KEYmust be set where Claude Code starts. macOS and Linux: in the environment that launches it (a shell profile reaches the terminal, not an app started from the Dock or a menu). Windows:setx AMPOST_API_KEY amp_live_YOUR_KEY, then restart the app or terminal. Without it the header is empty and Claude Code shows "Dynamic Client Registration rejected". - With
.mcp.json, Claude Code first lists Ampost as "Pending approval (runclaudeto approve)": startclaudein the project and approve the server. The--scope usercommand needs no approval. - The Code tab of the Claude desktop app does not put
claudeon PATH (it bundles its own copy). Install the CLI (macOS, Linux:curl -fsSL https://claude.ai/install.sh | bash; Windows PowerShell:irm https://claude.ai/install.ps1 | iex) and run the command above, or merge the~/.claude.jsonentry into that file: top-levelmcpServersfor every project, orprojects.<project path>.mcpServersfor one. Do not use the Claude (app) section for the Code tab. - Start a new session after adding the server.
- Without a key: leave out
--header, then run/mcpin a session, pick Ampost and sign in with your Ampost account in the browser.
Check it: claude mcp list or /mcp in a session shows Ampost as connected. Ask the assistant to call platforms_list. A working setup answers with the platforms Ampost supports (Instagram, Facebook, LinkedIn, TikTok, Threads, X, YouTube, Pinterest, Bluesky, Telegram, Discord) and their rules, such as text limits and media types. The raw result is { "data": [{ "platform": "instagram", "name": "Instagram", "text": { "maxLength": 2200 }, ... }], "pagination": { ... } }.
Click Add to Cursor and confirm in Cursor, or add the server to ~/.cursor/mcp.json (all projects) or .cursor/mcp.json (one project).
Paste your API key above to enable the button.
Or add it to the config file
{
"mcpServers": {
"ampost": {
"url": "https://api.ampost.io/mcp",
"headers": {
"Authorization": "Bearer amp_live_YOUR_KEY"
}
}
}
}- To keep the key out of the file, write
"Authorization": "Bearer ${env:AMPOST_API_KEY}"and setAMPOST_API_KEY.
Check it: Cursor Settings, MCP lists Ampost with its tools. Ask the assistant to call platforms_list. A working setup answers with the platforms Ampost supports (Instagram, Facebook, LinkedIn, TikTok, Threads, X, YouTube, Pinterest, Bluesky, Telegram, Discord) and their rules, such as text limits and media types. The raw result is { "data": [{ "platform": "instagram", "name": "Instagram", "text": { "maxLength": 2200 }, ... }], "pagination": { ... } }.
Needs VS Code 1.102 or later with GitHub Copilot. Click Add to VS Code, or run the command, or add the server to .vscode/mcp.json.
Paste your API key above to enable the button.
Add with the CLI (macOS, Linux)
code --add-mcp '{"name":"ampost","type":"http","url":"https://api.ampost.io/mcp","headers":{"Authorization":"Bearer amp_live_YOUR_KEY"}}'Or add it to the workspace; VS Code asks for the key once and stores it securely
{
"inputs": [
{
"type": "promptString",
"id": "ampost-api-key",
"description": "Ampost API key",
"password": true
}
],
"servers": {
"ampost": {
"type": "http",
"url": "https://api.ampost.io/mcp",
"headers": {
"Authorization": "Bearer ${input:ampost-api-key}"
}
}
}
}- Call tools in agent mode.
Check it: The command MCP: List Servers shows Ampost as running. Ask the assistant to call platforms_list. A working setup answers with the platforms Ampost supports (Instagram, Facebook, LinkedIn, TikTok, Threads, X, YouTube, Pinterest, Bluesky, Telegram, Discord) and their rules, such as text limits and media types. The raw result is { "data": [{ "platform": "instagram", "name": "Instagram", "text": { "maxLength": 2200 }, ... }], "pagination": { ... } }.
The Codex CLI, the IDE extension and the Codex app share ~/.codex/config.toml. Codex reads the key from the AMPOST_API_KEY environment variable.
Add with the CLI
export AMPOST_API_KEY="amp_live_YOUR_KEY"
codex mcp add ampost --url https://api.ampost.io/mcp --bearer-token-env-var AMPOST_API_KEYOr add it to the config file
[mcp_servers.ampost]
url = "https://api.ampost.io/mcp"
bearer_token_env_var = "AMPOST_API_KEY"- Set
AMPOST_API_KEYwhere Codex starts: in your shell profile, or on Windows withsetx AMPOST_API_KEY amp_live_YOUR_KEY, then restart Codex.
Check it: codex mcp list shows Ampost. Ask the assistant to call platforms_list. A working setup answers with the platforms Ampost supports (Instagram, Facebook, LinkedIn, TikTok, Threads, X, YouTube, Pinterest, Bluesky, Telegram, Discord) and their rules, such as text limits and media types. The raw result is { "data": [{ "platform": "instagram", "name": "Instagram", "text": { "maxLength": 2200 }, ... }], "pagination": { ... } }.
For chat in Claude on the web (claude.ai), the desktop app and mobile. Add Ampost as a custom connector: it signs in with your Ampost account, so there is no API key to paste. The Code tab of the app is Claude Code: use the Claude Code section.
Remote MCP server URL
https://api.ampost.io/mcp- Open Settings, Connectors and click Add custom connector. Name it Ampost, paste the URL above and click Add.
- Click Connect. Ampost's sign-in page opens: sign in, choose what Claude may do (every scope, read only, or custom, and optionally some platform sets) and click Allow.
- A connector added on claude.ai also works in the desktop and mobile apps. On Team and Enterprise plans an owner adds it under Organization settings, Connectors first.
- In a chat, turn Ampost on in the tools menu. To disconnect, remove the connector in Claude or click Disconnect in Ampost under Settings, Connected apps.
Check it: Settings, Connectors shows Ampost as connected, and the tools menu of a new chat lists its tools. Ask the assistant to call platforms_list. A working setup answers with the platforms Ampost supports (Instagram, Facebook, LinkedIn, TikTok, Threads, X, YouTube, Pinterest, Bluesky, Telegram, Discord) and their rules, such as text limits and media types. The raw result is { "data": [{ "platform": "instagram", "name": "Instagram", "text": { "maxLength": 2200 }, ... }], "pagination": { ... } }.
ChatGPT adds remote MCP servers as connectors in developer mode, which signs in with your Ampost account. Developer mode is offered on some ChatGPT plans only; menu names can differ slightly between versions.
MCP server URL
https://api.ampost.io/mcp- Open Settings, Apps & Connectors, Advanced settings and turn on Developer mode.
- Back in Apps & Connectors, click Create. Name it Ampost, paste the URL above, choose OAuth as the authentication, confirm that you trust the app and click Create.
- ChatGPT opens Ampost's sign-in page: sign in, choose the access and click Allow.
- In a chat, pick Developer mode in the + menu and turn Ampost on. ChatGPT asks before tools that change something, such as
posts_create.
Check it: Apps & Connectors lists Ampost as connected, and the chat's developer mode menu lists its tools. Ask the assistant to call platforms_list. A working setup answers with the platforms Ampost supports (Instagram, Facebook, LinkedIn, TikTok, Threads, X, YouTube, Pinterest, Bluesky, Telegram, Discord) and their rules, such as text limits and media types. The raw result is { "data": [{ "platform": "instagram", "name": "Instagram", "text": { "maxLength": 2200 }, ... }], "pagination": { ... } }.
Add the server to ~/.config/devin/mcp_config.json (Windows: %APPDATA%\devin\mcp_config.json), then refresh the MCP servers.
Add it to the config file
{
"mcpServers": {
"ampost": {
"serverUrl": "https://api.ampost.io/mcp",
"headers": {
"Authorization": "Bearer amp_live_YOUR_KEY"
}
}
}
}- Older Windsurf installs read
~/.codeium/windsurf/mcp_config.json; the same entry works there.
Check it: The MCP servers panel lists Ampost with its tools. Ask the assistant to call platforms_list. A working setup answers with the platforms Ampost supports (Instagram, Facebook, LinkedIn, TikTok, Threads, X, YouTube, Pinterest, Bluesky, Telegram, Discord) and their rules, such as text limits and media types. The raw result is { "data": [{ "platform": "instagram", "name": "Instagram", "text": { "maxLength": 2200 }, ... }], "pagination": { ... } }.
Any client that supports Streamable HTTP with custom headers works. Some name the root key servers or the URL field serverUrl.
Generic config
{
"mcpServers": {
"ampost": {
"type": "http",
"url": "https://api.ampost.io/mcp",
"headers": {
"Authorization": "Bearer amp_live_YOUR_KEY"
}
}
}
}- A client that supports MCP OAuth can leave out
headers: it then opens Ampost's sign-in page and connects with the access you allow. - A client that only runs local (stdio) servers can use the
mcp-remotebridge:npx -y mcp-remote https://api.ampost.io/mcp --header "Authorization:${AMPOST_AUTH}"withAMPOST_AUTHset toBearer amp_live_YOUR_KEYin the server'senv.
Check it: The client's MCP server list shows Ampost with its tools. Ask the assistant to call platforms_list. A working setup answers with the platforms Ampost supports (Instagram, Facebook, LinkedIn, TikTok, Threads, X, YouTube, Pinterest, Bluesky, Telegram, Discord) and their rules, such as text limits and media types. The raw result is { "data": [{ "platform": "instagram", "name": "Instagram", "text": { "maxLength": 2200 }, ... }], "pagination": { ... } }.
3. Check the connection
Each client tab ends with its check: ask your agent to call platforms_list, which returns the supported platforms and their rules. Then connect a social account with accounts_connect and create a draft with posts_create. Agents find every tool and rule in llms.txt and the MCP server docs.
If it fails
401withUNAUTHORIZED: The key is wrong or revoked. Copy it again without spaces or line breaks, or create a new one in Settings, API keys.- "No API key or access token arrived", or an Ampost sign-in page opens although the config has a key: The key did not arrive, so the client fell back to signing in with OAuth. Signing in works too (the client then shows under Settings, Connected apps). To use the key, check that the
Authorizationheader is in the config; if it uses${AMPOST_API_KEY}, set the variable where the client starts or paste the key itself. 403withINSUFFICIENT_SCOPE: The key or connected app lacks the scope the tool needs (indetails.requiredScope). Create a key with it, or disconnect the app in Settings, Connected apps and connect it again with that access.403withUPGRADE_REQUIRED: The plan does not include that feature, for example scheduling on Free. Upgrade on the pricing page.claude: command not foundin the Code tab of the Claude app: The app bundles its own Claude Code and does not putclaudeon PATH. Install the CLI or edit~/.claude.json, as in the Claude Code section.- Changes not taking effect: Clients load MCP servers at start. Quit and restart the client fully (also from the system tray); in Claude Code and the Claude app, start a new session.
Continue browsing
Related docs
The MCP tool reference, the REST API behind it, and the plans that include API access.