# PostWire API reference

> Publish one idea as a native post on each network, schedule it, and get told when it goes out. JSON over HTTPS at `https://postwire.io`. Every endpoint has a copyable example in curl, Node and Python.

Source: https://postwire.io/docs/ · Base URL: https://postwire.io · OpenAPI: https://postwire.io/openapi.json

## Quick start

1. **Get a key.** Sign up at [postwire.io](/dashboard.html?from=docs) and open **API & MCP**. Keys start with `pw_live_`. The Free plan includes the API.
2. **Connect a network.** Telegram, Bluesky, Mastodon, Discord, WordPress, Dev.to, Hashnode, Slack and Nostr with `POST /api/connect`; TikTok, YouTube, Instagram, Facebook Pages and LinkedIn with OAuth (`POST /api/oauth/{platform}/url`). Or in the dashboard.
3. **Publish.** One request, every network you name:

```bash
curl -X POST "https://postwire.io/api/post" \
  -H "Authorization: Bearer $POSTWIRE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "platforms": [
    "bluesky",
    "telegram"
  ],
  "text": "Hello from the PostWire API"
}'
```

```js
const res = await fetch("https://postwire.io/api/post", {
  method: "POST",
  headers: { Authorization: `Bearer ${process.env.POSTWIRE_API_KEY}`, "Content-Type": "application/json" },
  body: JSON.stringify({
    "platforms": [
      "bluesky",
      "telegram"
    ],
    "text": "Hello from the PostWire API"
  }),
});
console.log(res.status, await res.json());
```

```python
import os, requests

r = requests.post(
    "https://postwire.io/api/post",
    headers={"Authorization": f"Bearer {os.environ['POSTWIRE_API_KEY']}"},
    json={
        "platforms": ["bluesky", "telegram"],
        "text": "Hello from the PostWire API",
    },
)
print(r.status_code, r.json())
```

## Authentication

Send the key in `Authorization: Bearer pw_live_…` (or `X-API-Key: pw_live_…`). A missing or wrong key answers 401. Publishing needs a verified email and a full-access key, otherwise 403. If PostWire cannot check a key because of its own outage it answers 503 `auth_unavailable`, never 401: retry, do not throw the key away.

Keys can be created with an expiry and revoked at once: see [Account, keys and billing](/docs/account/). `GET /api/platforms`, `GET /api/plans` and `GET /api/status` need no key.

## One result per network

Publishing answers 200 with `posted` (networks that went out) and `results[]`, one entry per network, each with `ok` and, when it did not go out, `error` and a machine-readable `code`. One network failing never fails the request or the others. A request-level problem (bad JSON, nothing connected, a network connected in two brands without `brand_id`) answers 4xx before anything is sent.

A post counts once **per network** that published: one idea to three networks is three of the month's posts. Networks refused before sending (not connected, held by the plan, media missing) spend nothing.

## Pages

| Page | What is in it |
|---|---|
| [Publish](/docs/publishing/) | Publish one post to one or many networks now, and check a post's status. |
| [Schedule and queue](/docs/scheduling/) | Queue posts for a time or for the next free slot, edit and cancel them, and fill a week from one topic. |
| [Bulk upload, recurring posts and RSS](/docs/automation/) | A month of posts from one CSV, checked row by row and scheduled whole or not at all; posts that repeat; RSS feeds that become posts. |
| [AI writing](/docs/ai-writing/) | Write a native post per network from one idea, without publishing. |
| [Media](/docs/media/) | Upload photos and videos up to 1 GB and get a URL to publish with. |
| [Networks and connections](/docs/connections/) | List networks, connect accounts (yours or your clients'), check and move connections. |
| [Brands](/docs/brands/) | Group each business's accounts and publish as that brand. |
| [Analytics (What works)](/docs/analytics/) | Your best posts against your own median, the patterns behind them, and drafts modelled on a winner. |
| [Coach (results and next move)](/docs/coach/) | What happened to your posts this week, your goal and streak, the one next move, today's next best post and a first-line check. |
| [Link-in-bio page](/docs/bio/) | One public page per brand for the link in your profiles, with its views and the clicks on each link. |
| [Webhook endpoints](/docs/webhooks-api/) | Register the URLs PostWire calls when a post publishes or fails. |
| [Account, keys and billing](/docs/account/) | Sign up, read usage and limits, manage API keys and the plan. |
| [Teams](/docs/teams/) | Invite people by email with a role and, if you want, only some brands; switch between workspaces. |
| [X (Twitter) credits](/docs/x/) | Post to X as a pay-per-use add-on of the paid plans: what each post uses, what is left, and top-ups. |
| [Approvals, limits and activity](/docs/approvals/) | Make posts wait for a person, give each API key and AI app its own limits, and see who did what. |
| [Service status](/docs/status/) | The data behind the public status page, without an API key. |
| [Network options](/docs/network-options/) | Every option per network: TikTok privacy and labels, YouTube privacy and tags, Instagram and Facebook post types, a thread and a first comment on X, Bluesky and Mastodon, LinkedIn first comment and documents, alt text. |
| [Errors, limits and idempotency](/docs/errors/) | Error shape, result codes, request rate limits, network rate limits, retries without duplicates. |
| [Webhooks guide](/docs/webhooks/) | Events, signature verification in Node.js and Python, retries. |
| [Schema changelog](/docs/schema-changelog/) | Every change to the API schema, by date, generated from the spec's history. |

## Plans and limits

From `GET /api/plans`, the same table the billing code reads. A post counts once per network. Every paid plan can be billed monthly or yearly at 20% off (`interval: "year"` on `POST /api/billing/checkout`, `?interval=year` on `GET /api/billing/upgrade-link`).

| Plan | Price | Billed yearly | Posts a month | Posts a day | Brands | AI drafts a day | AI drafts a month (about) | Networks per post | Scheduled at a time |
|---|---|---|---|---|---|---|---|---|---|
| Free | $0 | — | 10 | 20 | 1 | 5 | ~20 | 2 | 3 |
| Starter | $19/month | $182.40/year ($15.20/month) | 1,000 | 200 | 3 | 60 | ~30 | all | up to 1,000 |
| Pro | $29/month | $278.40/year ($23.20/month) | unlimited (fair use 10,000) | 500 | 10 | 300 | ~60 | all | up to 5,000 |
| Agency | $99/month | $950.40/year ($79.20/month) | unlimited (fair use 50,000) | 2,000 | 50 | 1,500 | ~150 | all | up to 20,000 |
| Scale | $299/month | $2870.40/year ($239.20/month) | unlimited (fair use 150,000) | 7,500 | 200 | 5,000 | ~330 | all | up to 50,000 |

Every plan includes the REST API, the MCP server, webhooks and TikTok. See [pricing](/pricing/).

## Fair use: every limit

"Unlimited posts" on Pro, Agency and Scale has a published ceiling that no honest customer meets, and these are the only limits. They are per workspace, enforced on the server, and each one answers with its own `code`, the number and when it resets (see [errors and limits](/docs/errors/)). `GET /api/usage` and `GET /api/me` show today's posts and the month's media against them.

| Limit | Free | Starter | Pro | Agency | Scale |
|---|---|---|---|---|---|
| Posts a month | 10 | 1,000 | unlimited, fair use 10,000 | unlimited, fair use 50,000 | unlimited, fair use 150,000 |
| Posts a day (UTC) | 20 | 200 | 500 | 2,000 | 7,500 |
| Scheduled posts waiting (queued + held) | 50 | 1,000 | 5,000 | 20,000 | 50,000 |
| Largest file | 100 MB | 1 GB | 1 GB | 1 GB | 1 GB |
| AI drafts a day | 5 | 60 | 300 | 1,500 | 5,000 |
| AI drafts a month (about; extra in AI credit packs) | ~20 | ~30 | ~60 | ~150 | ~330 |
| Media uploaded a month | 0.5 GB | 4 GB | 15 GB | 40 GB | 120 GB |
| Media sent to networks a month | 1 GB | 6 GB | 15 GB | 45 GB | 140 GB |
| Webhook endpoints | 2 | 5 | 10 | 25 | 50 |
| API requests a minute, per key | 60 | 120 | 300 | 600 | 1,200 |
| Publishes at once | 2 | 3 | 5 | 10 | 20 |

A sudden spike — more posts in one hour than 10 times the workspace's usual hour, and never less than a quarter of its day — pauses publishing until the hour ends (`throttled`); scheduled posts keep their place. Uploaded media is deleted the day after the last scheduled post that uses it is published, and 7 days after upload when no post uses it (2 days on the Free plan; a post sent right away counts as used once every network took it, so its files go the next day; 30 days at most, never while a scheduled post still waits for it). X posts use X credits on top of these.

## Machine-readable

- OpenAPI 3.0: [/openapi.json](/openapi.json).
- Every page of this reference as Markdown: add `.md` (for example [/docs/publishing.md](/docs/publishing.md)), or use the Markdown link at the top of each page.
- MCP server for Claude, ChatGPT and other agents: [/mcp/](/mcp/). For AI crawlers: [/llms.txt](/llms.txt).
