Mit der REST API können deine Skripte und Apps das tun, was du im Dashboard tust. Sofort posten, planen, Bilder hochladen und prüfen, was rausgegangen ist. Sie spricht JSON über HTTPS und nutzt einen API-Schlüssel.
Einen API-Schlüssel holen
Melde dich an und öffne Einstellungen → API-Schlüssel im Dashboard.
Gib dem Schlüssel einen Namen, zum Beispiel „Release-Skript“, und erstelle ihn.
Kopiere den Schlüssel sofort. Er beginnt mit smcp_ und wird nur einmal angezeigt.
Halte den Schlüssel geheim wie ein Passwort: Wer ihn hat, kann auf deinen Konten posten. Speichere ihn in einer Umgebungsvariable oder in deinen CI-Secrets, nie in deinem Code. Wenn ein Schlüssel nach außen gelangt, lösch ihn an derselben Stelle und erstelle einen neuen.
Verbinde zuerst deine Konten (X und LinkedIn) im Dashboard. Die API postet auf die Konten, die du verbunden hast.
Deine erste Anfrage
Schick den Schlüssel bei jeder Anfrage im Authorization-Header mit:
Das liefert deine Konten, Einstellungen und deinen Tarif. So postest du sofort:
curl https://getsocialmcp.com/api/v1/posts \
-H "Authorization: Bearer $SOCIALMCP_KEY" \
-H "Content-Type: application/json" \
-d '{ "text": "v2.4 is live: faster search and dark mode.", "networks": ["x", "linkedin"] }'
Um den Post stattdessen zu planen, füge eine Uhrzeit mit Zeitzonen-Offset hinzu, zum Beispiel "scheduledAt": "2026-12-01T09:00:00+01:00". Die Antwort zeigt den Post und sein Ergebnis in jedem Netzwerk.
Gut zu wissen
Uhrzeiten: Schick ISO-8601-Zeiten mit Offset oder Z. Antworten nutzen UTC.
Threads auf X: Schick parts statt text, ein Eintrag pro Post im Thread. LinkedIn bekommt die Teile zu einem Post zusammengefasst oder nur den ersten, je nach deinen Einstellungen.
Eine eigene Version pro Netzwerk: Nutze overrides, zum Beispiel einen längeren LinkedIn-Text und einen kurzen X-Thread in derselben Anfrage.
Bilder: Lade sie mit POST /media hoch (eine Datei oder ein https-Link) und gib die zurückgegebene ID in mediaIds mit.
Posting-Zeiten: Mit "postingTime": "next" kommt der Post in den nächsten freien Slot der Posting-Zeiten, die du im Dashboard festgelegt hast.
Keine doppelten Posts: Schick einen idempotencyKey. Wenn dein Skript es mit demselben Schlüssel erneut versucht, bekommst du den ersten Post zurück, und nichts wird doppelt gepostet.
Seiten mit Ergebnissen:GET /posts liefert nextCursor. Gib ihn als cursor mit, um die nächste Seite zu bekommen.
Freigaben: Posts, die du mit deinem eigenen API-Schlüssel erstellst, gehen wie geplant raus. Die Einstellung „Erst hier auf meine Freigabe warten“ gilt nur für KI-Agenten.
Fehler
Jeder Fehler hat dieselbe Form. Entscheide anhand von code; die message ist für Menschen geschrieben und kann sich ändern.
{
"error": {
"code": "too_long",
"message": "Part 1 is 312 characters on X; the limit is 280.",
"details": { }
}
}
Häufige Codes:
invalid_api_key (401): Der Schlüssel ist falsch oder wurde gelöscht.
invalid_request oder too_long (422): Die Anfrage passt nicht. Die Meldung sagt, was du ändern musst.
daily_limit, posting_gap oder monthly_limit (429): Dein Tarif hat zu dieser Zeit keinen Platz mehr. Bei einem vollen Tag oder einem zu nahen Post schlägt details die nächste freie Zeit vor.
plan_no_images und andere plan_-Codes (403): Dein Tarif enthält das nicht. Die Meldung sagt, welcher Tarif es enthält.
dashboard_only (403): Das geht nur im Dashboard, zum Beispiel API-Schlüssel erstellen.
Ein angenommener Post kann später trotzdem in einem Netzwerk fehlschlagen, zum Beispiel wenn ein Netzwerk SocialMCP abmeldet. Das siehst du am Post selbst: Jeder Eintrag in targets hat einen status und, falls er fehlgeschlagen ist, einen error wie reconnect_needed. Prüfe das mit GET /posts/<id>.
Limits
Die API nutzt denselben Tarif und dieselben Limits wie alles andere in SocialMCP: Posts pro Tag und pro Monat, Links auf X, Bilder und ein kurzer Abstand zwischen Posts auf einem Konto. GET /me zeigt deine Limits und was du verbraucht hast.
Maschinenlesbare Spezifikation
Die vollständige OpenAPI-3.1-Spezifikation findest du unter https://getsocialmcp.com/api/v1/openapi.json. Nutze sie, um einen Client in deiner Sprache zu generieren oder die API in Tools wie Postman zu importieren.
Alle Endpunkte, die du mit einem API-Schlüssel aufrufen kannst, direkt aus der API selbst erzeugt. Namen der Endpunkte, Felder und ihre Beschreibungen sind auf Englisch.
Basis-URL: https://getsocialmcp.com/api/v1
Networks
GET/networks
Networks you can post to
Without an API key: the networks open to everyone on SocialMCP. With a key: the networks you can connect and post to, which can include ones still in testing.
Antworten
200Networksobject
401Not signed in, or the API key is wrong
Account
GET/me
Who you are, your settings, connected accounts, and your plan with what you’ve used
422Invalid request (e.g. too long for the network)
POST/login-links
Get a link that opens the dashboard already signed in
Single-use, valid 10 minutes. path is where it opens: /app (calendar), /app?post={id} or /app/settings. Approving agent posts, API keys and agents still need an email sign-in.
403This network is not available (network_unavailable)
Posting times
PUT/posting-times
Set when you usually post
Saves posting times on the given accounts (all connected accounts when none are given). An empty list turns them off. Upcoming posts placed in a time that no longer exists move to the first open posting time from the start of their day (moved); posts left with no posting time keep their time (kept).
409Conflicts with the current state (e.g. account not connected)
422Invalid request (e.g. too long for the network)
GET/posting-times/open
Open posting times in a range
Upcoming posting times that have no post yet, each with the accounts it is open on. Up to about two months at a time.
Parameter
fromstring (date-time)(query)Pflicht
tostring (date-time)(query)Pflicht
Antworten
200Open posting timesobject
401Not signed in, or the API key is wrong
422Invalid request (e.g. too long for the network)
GET/posting-times/next
Where a new post would go
The next open posting time of each account, as POST /posts with postingTime next would use them. Nothing is saved.
Parameter
accountsstring(query)Pflicht
Comma-separated account ids.
unitsinteger(query)
Number of thread parts, on networks that take threads. Default 1.
Antworten
200Next posting timesobject
401Not signed in, or the API key is wrong
404Not found
409Conflicts with the current state (e.g. account not connected)
Posts
POST/posts
Post now or schedule
Checks length and limits for every network before accepting. Each network’s result appears in targets. With postingTime next, accounts whose next open times differ get a post each: the others are in alsoCreated.
One item per post in a thread, on networks that take threads. Other networks get a single post.
networks("x" | "linkedin")[]
Defaults to your default networks (Settings).
accountsstring[]
Specific account ids, instead of networks.
scheduledAtstring (date-time)
ISO 8601 time. Omit to post now. e.g. 2026-11-21T09:00:00Z
postingTime"next" | string (date-time)
Put the post in your posting times: next for each account’s next open one (accounts whose next times differ get a post each), or one open posting time from GET /posting-times/open. e.g. next
overridesobject
A network’s own version of the post. LinkedIn takes a single part.
idempotencyKeystring
Sending the same key again returns the first post instead of posting twice.
Antworten
200Already created with this idempotencyKeyPost + object
One item per post in a thread, on networks that take threads. Other networks get a single post.
networks("x" | "linkedin")[]
Defaults to your default networks (Settings).
accountsstring[]
Specific account ids, instead of networks.
scheduledAtstring (date-time)
ISO 8601 time. Omit to post now. e.g. 2026-11-21T09:00:00Z
postingTime"next" | string (date-time)
Put the post in your posting times: next for each account’s next open one (accounts whose next times differ get a post each), or one open posting time from GET /posting-times/open. e.g. next
overridesobject
A network’s own version of the post. LinkedIn takes a single part.
idempotencyKeystring
Sending the same key again returns the first post instead of posting twice.
PostingTime
timestringPflicht
Time of day, 24-hour, in your timezone. e.g. 09:00