Definition

The social infrastructure
for AI agents.

A social media API for AI agents is not a scheduler with a REST wrapper. It is the layer an agent acts through: observe, publish, engage and measure, with one response shape, retries that cannot double-post, capabilities it can read at runtime, and approvals the same agent cannot bypass. PostLake is that layer. REST for LangGraph and CrewAI. A hosted MCP server for Claude, Cursor and ChatGPT. Agent skills for coding agents. Official TypeScript SDK: postlake. Same accounts underneath.

Get started free →

Free tier. No card · one API for every network · full MCP access

In shortPostLake is the social infrastructure for AI agents, and the social media posting API they call: one REST contract and a hosted MCP server. Claude, Cursor, ChatGPT or your own agent observes, publishes, engages and measures across every major network without nine platform SDKs.

When this guide is for you

You need a citable definition of a social media API built for agents, not a dashboard with an API bolted on.

Before you start

Same setup the docs quickstart uses. Do this once:

  1. Sign up at app.postlake.dev and verify your email (unlocks free credits).
  2. On Channels, create a profile (e.g. my-brand) and connect at least one account. Bluesky is the fastest first channel: no app review. Instagram/TikTok/Facebook need each platform's review before API posting.
  3. Account menu → API Keys → create a key (sk_live_…). It shows once; treat it like a password.

Give any MCP client the posting API

This is the whole agent setup. Paste it into Claude, Cursor, ChatGPT or any MCP host. The agent gets publish, schedule, media and analytics as tools, not nine platform SDKs.

{
  "mcpServers": {
    "postlake": {
      "url": "https://api.postlake.dev/mcp"
    }
  }
}

Make it work

Tool-specific glue on top of the shared setup above:

  1. Decide how the agent talks to PostLake: MCP (OAuth, no key in chat), agent skills (npx skills add postlake/postlake-mcp --all), or REST with a Bearer key in your runtime.
  2. Connect the social accounts the agent may use under one profile. Bluesky is the fastest smoke test.
  3. Tell the agent to publish with create_post / POST /v1/posts and to always read targets[]. Partial success is normal.
  4. Send an Idempotency-Key (or let MCP do it) so a retry never double-posts.
  5. Close the loop with get_analytics / GET /v1/analytics so the agent can decide what to post next.

Read the response (don't skip this)

You get one Post with an overall state and a targets[] array. One entry per account. Always check each target; partial success is normal.

{
  "id": "post_a1b2c3",
  "state": "partial",
  "targets": [
    { "platform": "bluesky",  "state": "published", "url": "https://bsky.app/…" },
    { "platform": "linkedin", "state": "failed",
      "error": { "type": "invalid_request", "message": "…", "retryable": false } }
  ]
}

Where the post goes

Same rules as the docs. Pick one addressing style:

See Publishing: where to post.

Do more (same API)

Pitfalls specific to this path

Want zero wrapper code? Connect the hosted MCP server (https://api.postlake.dev/mcp) over OAuth. Same accounts and responses as this API path. Agents overview.

Common questions

What is a social media API for AI agents?

The social infrastructure an agent acts through: observe, publish, engage and measure, without per-platform SDKs. One response shape, safe retries, runtime capabilities, and approvals. PostLake is that layer, plus a hosted MCP server.

How is that different from a social media posting API?

A posting API publishes. Infrastructure also lets the agent read, engage, validate, wait for approval, and recover from partial failure. PostLake is both: the posting API agents call, and the control layer they operate through.

Which AI agents can use PostLake?

Any MCP client (Claude, Cursor, ChatGPT, Gemini, Copilot) and any agent framework that can call HTTPS (LangGraph, CrewAI, AutoGen, custom).

Where do I start?

Free tier, no card. Connect MCP at https://api.postlake.dev/mcp or follow the agents hub. Docs: https://docs.postlake.dev/mcp.md

Go deeper in the docs

These guides stay short on purpose. Canonical behaviour lives here:

Also: Media · Errors · MCP · Analytics

Related guides

All guides · Full docs · llms.txt · Markdown

Stuck? The docs are the source of truth, start at Publishing.

Open the dashboard →