one API

How to post on social media
via one API

Post and schedule to 8 social platforms programmatically using one API. Create a key, connect your accounts, and create the post.

the whole flow

Three steps, then it is scheduled

You call PostWing once. PostWing publishes to every account in accounts at the time you set. The post also shows up on your calendar.

  1. 01Create an API key
  2. 02Connect each channel
  3. 03Create one post
01

Create an API key

Open Dashboard → AI & API and create a key. Copy it once. It starts with pw_live_. Send it on every request:

Header

Authorization: Bearer pw_live_…

Every URL below starts at https://postwing.io/api/v2. The same key works for all 8 platforms.

02

Connect each channel

Connect each account once. The simple way is in the dashboard. Open Accounts and finish the login for each channel.

From the API, start one login at a time. The response includes a url. Open it and approve that platform.

Start connect

curl -s -X POST "https://postwing.io/api/v2/accounts/connect" \
  -H "Authorization: Bearer pw_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "platform": "linkedin" }'

platform is one of facebook, instagram, linkedin, pinterest, threads, tiktok, x, or youtube. After the logins, sync once. Copy id from each object. TikTok can come back as tiktok.

Sync

curl -s -X POST "https://postwing.io/api/v2/accounts/sync" \
  -H "Authorization: Bearer pw_live_…"

Already connected in the dashboard? List accounts and copy the same ids:

List accounts

curl -s -X GET "https://postwing.io/api/v2/accounts" \
  -H "Authorization: Bearer pw_live_…"
03

Create one post

One request holds every channel. Send the shared caption, a future time, and each account id in accounts. This call schedules the post. scheduled_at is UTC, and every account uses that same time.

Create one text post for four channels

curl -s -X POST "https://postwing.io/api/v2/posts" \
  -H "Authorization: Bearer pw_live_…" \
  -H "Content-Type: application/json" \
  -d '{
  "caption": "We just shipped a faster way to publish updates.",
  "scheduled_at": "2026-10-12T15:00:00Z",
  "accounts": [
    { "id": "d4e5f6a7-b8c9-0123-def0-234567890123" },
    {
      "id": "e5f6a7b8-c9d0-1234-ef01-345678901234",
      "caption": "Faster publishing, now live."
    },
    { "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890" },
    {
      "id": "b8c9d0e1-f2a3-4567-8901-678901234567",
      "caption": "Faster publishing, now live."
    }
  ]
}'

Those four ids are LinkedIn, X, Facebook, and Threads. Leave caption off an account to use the shared caption. Set caption when that channel needs shorter text. X is about 280 characters. Threads is about 500.

You get back three things that matter:

  • id: the post id, for edits or cancelling later
  • status: scheduled until it publishes
  • accounts: each account, with url once it is live and error if it fails

media

Add an image or a video

Put media on the same request when a channel needs a file. The image or video is shared. Platform rules stay on each account.

Create one image post for three channels

curl -s -X POST "https://postwing.io/api/v2/posts" \
  -H "Authorization: Bearer pw_live_…" \
  -H "Content-Type: application/json" \
  -d '{
  "caption": "New lookbook, now live.",
  "scheduled_at": "2026-10-12T18:00:00Z",
  "accounts": [
    { "id": "b2c3d4e5-f6a7-8901-bcde-f12345678901" },
    { "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890" },
    {
      "id": "f6a7b8c9-d0e1-2345-f012-456789012345",
      "options": {
        "board_id": "1234567890"
      }
    }
  ],
  "media": [
    { "url": "https://cdn.example.com/lookbook.jpg", "type": "image" }
  ]
}'

Those ids are Instagram, Facebook, and Pinterest. Pinterest keeps board_id in its own options. TikTok can use this image too. For a video, send one item with type video. YouTube needs that video plus a title in its options.

The file URL has to be public HTTPS. Videos imported from a URL need to be 100MB or smaller. A file on your computer uses the direct upload URL, covered in the API docs.

Details worth knowing

  • scheduled_at has to be a future time in ISO 8601, usually UTC. Every account uses that time.
  • One POST /posts call schedules every account in accounts. You can still edit or cancel it until it publishes.
  • The same API key posts to Instagram, TikTok, YouTube, LinkedIn, X, Facebook, Pinterest, and Threads.
  • Leave caption off an account to use the shared caption. Set it when that channel needs different text.
  • Instagram and TikTok need media. YouTube needs a video and a title. Pinterest needs media and board_id.
  • The response includes the post id. Use it to edit with PATCH /posts/{id} or cancel with DELETE /posts/{id}.
  • API access is included on every plan, from $9.99/mo. Posts count as normal posts on your account.

questions

Social media API FAQ

Yes. Put each account id in accounts. They publish together at scheduled_at. The call is rejected with the exact field when a channel’s rules are missing, such as media, a YouTube title, or a Pinterest board_id.

ready when you are

Schedule every channel from one API

Create a key, connect your accounts, and create the post.