LinkedIn

Lightweight, dependency-free, in-memory fake of the LinkedIn API for testing code that publishes posts and reads member profiles.

Default port: 4799

Quick start

import { LinkedinServer } from "./services/linkedin/src/server.js";

const server = new LinkedinServer(4799);
await server.start();
// ... run your app/tests ...
await server.stop();

Point your LinkedIn client (or raw fetch) at http://127.0.0.1:4799:

const res = await fetch("http://127.0.0.1:4799/v2/ugcPosts", {
  method: "POST",
  headers: {
    Authorization: "Bearer parlel-test-token",
    "Content-Type": "application/json",
    "X-Restli-Protocol-Version": "2.0.0",
  },
  body: JSON.stringify({
    author: "urn:li:person:parlelMember001",
    lifecycleState: "PUBLISHED",
    specificContent: {
      "com.linkedin.ugc.ShareContent": {
        shareCommentary: { text: "Hello from parlel!" },
        shareMediaCategory: "NONE",
      },
    },
    visibility: { "com.linkedin.ugc.MemberNetworkVisibility": "PUBLIC" },
  }),
});
const { id } = await res.json(); // urn:li:ugcPost:<id>

Implemented operations

All /v2/* and /rest/* routes require Authorization: Bearer <token> (any non-empty token accepted). The X-Restli-Protocol-Version header is accepted. State is in-memory and ephemeral; created posts are captured.

Service & inspection operations (parlel extensions)

Access via MCP / preview URL

When run inside a Daytona sandbox, this HTTP service is auto-exposed at the sandbox's preview URL. Send requests to the preview URL with the x-daytona-preview-token header to reach the service from outside the sandbox. The MCP layer surfaces the same endpoints described above.

Surface coverage

This emulator faithfully replicates the API surface most application code and agents exercise. Anything below the supported lines is either an intentional design choice for a fast, zero-cost local emulator (✓ By design) or a candidate for a future release (⟳ Roadmap) — never a silent inaccuracy.

Legend: ✅ fully supported · ◐ accepted (stored, not strictly enforced) · ✓ by design · ⟳ on the roadmap.

FeatureStatus
ugcPosts create✅ Supported
/rest/posts create✅ Supported
/v2/me profile✅ Supported
/v2/userinfo OpenID✅ Supported
x-restli-id response header✅ Supported
Bearer token validity / scope enforcement✓ By design — Any non-empty credential is accepted — no real secrets needed
Media / image / video asset upload⟳ Roadmap
Organization / company page posting⟳ Roadmap
Real publishing to LinkedIn⟳ Roadmap — Intentionally unsupported (fake captures only)
<!-- parlel:testenv:start -->

Configuration — test.env

Copy these into your test.env (used by the bridge sidecar flow). Tokens are Parlel's seeded test credentials — any non-empty value is accepted by the emulator, so you rarely need to change them. Swap in real credentials only when pointing at the live service in prod.env.

LINKEDIN_ACCESS_TOKEN=parlel
LINKEDIN_BASE_URL=http://parlel-bridge:4799
<!-- parlel:testenv:end -->