One API.Every platform.A webhook for each result.
The REST API the dashboard runs on, and our own videos go out through. Publish once, and get a signed webhook as each platform goes live or fails.
API=https://api.socialized.dev/api/v1
curl -s "$API/brands/$BRAND/publications/$PUB" \
-H "Authorization: Bearer $SK" \
| jq -r '.publication | .status, (.targets[]
| [.platform, .status, .externalUrl] | @tsv)' \
| column -tdone
youtube published https://youtu.be/Ks9vQ2pLx0e
instagram published https://www.instagram.com/reel/DB7xQe1sKpL/
facebook published https://www.facebook.com/reel/1093847562019384A publish answers at once with every destination pending. Each then settles on its own: published with its post’s link, or failed with the reason.
Hear back from every destination.
Webhook docs (opens in a new tab)Register an HTTPS endpoint for every brand or the ones you choose, and pick the events. Each delivery names its brand, is signed, and comes again until you answer 2xx.
publication.target. published - When a destination goes live, with its post’s link and any warnings.
publication.target. failed - When a platform rejects a destination, with the reason.
publication.target. removed_ remotely - When a live post is deleted on its platform.
publication.completed - When a publication settles: done, partial or failed.
connection.reauth_ required - When a connected account needs reconnecting to keep publishing.
import { createHmac, timingSafeEqual } from 'node:crypto';
// rawBody: the request body exactly as received, before any JSON parsing.
// secret: the endpoint's signing secret (whsec_…), shown once when you created it.
// headers: the request's headers, names in lower case (as Node.js gives them).
const digest = createHmac('sha256', secret).update(rawBody).digest('hex');
const expected = Buffer.from(`sha256=${digest}`);
const received = Buffer.from(headers['x-socialized-signature'] ?? '');
const isValid =
received.length === expected.length && timingSafeEqual(received, expected);
// A retry resends the same event: skip an ID you have already handled.
const eventId = headers['x-socialized-event'];- 25m agoYou send
POST /YouTube, Instagram, FacebookQueueda 201, each destinationbrands/ {brandId}/ publications "pending" - 25m agoWebhook
publication.YouTubeLivewith the post’s ID and linktarget. published - 25m agoWebhook
publication.InstagramLivewith the post’s ID and linktarget. published - 23m agoWebhook
publication.FacebookLivewith the post’s ID and linktarget. published - 23m agoWebhook
publication.Livesettled ascompleted "status": "done"
Retry without posting twice.
Send an Idempotency- with a publish, and a retry of the same request gets the first answer back, not a second post. Transient platform errors are retried for you.
- Same key, same body
- The first response, replayed. Nothing publishes twice.
- Same key, different body
409 IdempotencyKeyReusedError: a key belongs to its first request.- Same key, first still running
409 RequestInProgressError: wait, then retry.- After 24 hours
- The key is forgotten, and the request runs again.
- One destination failed
POST /retries it alone; the live ones aren’t touched.brands/ {brandId}/ publications/ {id}/ targets/ {targetId}/ retry
A CLI for scripts and agents.
CLI docs (opens in a new tab)Docs (opens in a new tab)It uploads local files for you, prints JSON, writes a failure as one JSON line and never prompts, so a CI job or an agent can publish.
- Keys with a scope
- Read or write, for every brand (later ones included) or only the ones you choose. Shown once, when you create it; revoke it any time.
- Brands in the path
- Everything you publish sits under
/, so one key can serve several channels, each with its own accounts.brands/ {brandId} - Connect once, in the dashboard
- Each platform asks you to approve access in a browser, once. After that you publish by platform name, and we keep the access fresh.
npm install -g @socialized.dev/cli
export SOCIALIZED_DEV_API_KEY="$SK"
export SOCIALIZED_DEV_BRAND_ID="$BRAND"
PUB=$(socialized.dev publications create \
--video ./why-waves-break.mp4 \
--title "Why waves break" \
--targets '[{ "platform": "youtube" },
{ "platform": "instagram" },
{ "platform": "facebook" }]' \
| jq -r .publicationId)
socialized.dev publications get --id "$PUB" --watchStatus: publishing
- youtube: published
- instagram: processing
- facebook: pending
Status: done
- youtube: published
- instagram: published
- facebook: publishedErrors that say what to fix.
Every error is the same JSON: a code to branch on, a message for a person, and the fields that pin it down.
HTTP/1.1 422 Unprocessable Entity
{
"code": "PlatformMessageTooLongError",
"message": "The title for YouTube is longer than its 100-character limit.",
"platform": "youtube",
"field": "title",
"limit": 100
}400- The request failed validation; the message names the field.
401- The key is missing or invalid.
402- The plan has no room:
VideoLimitReachedErrororBrandLimitReachedError. 403- Only the brand’s owner may do this, or the key’s scope doesn’t cover it.
409- A conflict: an idempotency key, an archived brand, a state that can’t retry.
422- A referenced asset, platform or message doesn’t fit, and the fields say which.
429- The key is throttled.
Limits, in the open.
What the API allows per platform, brand, upload and plan, so you can design around it before you build.
- 3
- platforms: YouTube, Instagram and Facebook, with TikTok next
- 1
- connected account per platform, per brand
- 48 hours
- to publish an upload before it is deleted
- 24 hours
- that an idempotency key is kept
- 10 and 1,000
- videos a month on Free and Pro; Free pauses at its limit, Pro’s is soft
- 1 and 100
- brands on Free and Pro, each with its own connected accounts