social SDK

/ˈsoʊ·ʃəl ˌɛs·diː·ˈkeɪ/ · noun

  1. 1. a typed toolkit for building social features into your app.
  2. 2. the route from your code to every platform, with a real answer from each.
Read the quickstart or just bun add @opencoredev/social-sdk

shoutout to our sponsors

your app social.posts.publish({ content, targets: everywhere , }) posted ✓ posted ✓ upload processing… posted ✓ needs a photo! queued posted ✓ each destination reports back on its own. no rolled-up "all good." your app social.posts.publish({ content, targets: everywhere , }) posted ✓ posted ✓ upload processing… posted ✓ needs a photo! queued posted ✓ each destination reports back on its own. no rolled-up "all good."

What you get back

One result per platform. Not a boolean. The actual state: "published", "processing", "failed", and more, with the reason when there is one.

The types know what each account can do. A text-only post aimed at Instagram fails in your editor, not in production.

import { createSocial } from "@opencoredev/social-sdk";

  const social = createSocial({ backend });

  const result = await social.posts.publish({
    content: { text: "we drew our landing page" },
    targets: accounts.map((account) => ({ account })),
  });

  for (const o of result.outcomes) {
    // "published" | "processing" | "failed" | ...
    console.log(o.account.platform, o.state);
  }
import { createSocial }
    from "@opencoredev/social-sdk";

  const social =
    createSocial({ backend });

  const result =
    await social.posts.publish({
      content: { text: "we drew this" },
      targets: accounts.map(
        (account) => ({ account }),
      ),
    });

  for (const o of result.outcomes) {
    // published | processing | failed
    console.log(
      o.account.platform, o.state);
  }
← typed end to end, mocks included

Everything it does.

Publishing

Explicit targets, explicit accounts, one outcome per destination.

no double posts

Reads & analytics

Typed references to native content, plus platform analytics products where available. Metrics say "unavailable" when they are.

no wrong data

Comments & messages

Replies, reactions, conversations, and native platform operations, with capability declarations for normalized routes and explicit authorization for native access.

where platforms allow

Deterministic testing

A mock backend that behaves like the real ones, so CI never touches a live network.

runs offline
don't want to manage tokens yourself? take a managed route: Zernio Post for Me PostFast Postiz

open source, MIT licensed, and on npm today. if it saves you a weekend, star it on GitHub. logos and colors live on the brand page.