Publish a new post on the connected account's feed
https://myagentmail.com/linkedin/postsCreates a feed post on the connected LinkedIn account. Text is required; an inline image is optional. The endpoint handles the underlying three-step LinkedIn upload flow (register upload → PUT bytes → create share) so the customer just sends one JSON request.
Visibility:
ANYONE(default) — public on the feed.CONNECTIONS— visible to 1st-degree connections only.
Image:
Pass an image.dataUrl (full data URL with embedded mime + base64) for
the simplest agent shape, OR a separate image.base64 + image.contentType.
Accepts image/png, image/jpeg, image/gif, image/webp up to ~10 MB.
Quota: 1 connection_request slot per call (shared outbound-write
bucket).
Request body
Content-Type: application/json
sessionIdrequired string | |
textrequired string | Post commentary. LinkedIn caps at 3000 characters. |
visibility"ANYONE" | "CONNECTIONS" | enum: "ANYONE" | "CONNECTIONS" default: "ANYONE" |
imageobject | Optional inline image. Pass either `dataUrl` (preferred — embeds mime + base64 in one field) or `base64` + `contentType`. |
dataUrlstring | Full data URL, e.g. "data:image/png;base64,iVBORw0KG..." |
base64string | Bare base64-encoded bytes (no `data:` prefix). |
contentType"image/png" | "image/jpeg" | "image/gif" | "image/webp" | Required when using `base64`. Ignored when using `dataUrl`. enum: "image/png" | "image/jpeg" | "image/gif" | "image/webp" |
altTextstring | Accessibility alt-text on the rendered post. |
filenamestring |
Responses
okboolean | |
shareUrnstring | |
shareIdstring | |
postUrlstring | format: uri |
mediaUrnstring | Set when an image was uploaded. |
Authentication
Send your API key in the X-API-Key header (or Authorization: Bearer <key>). Any prefix accepted by this endpoint — tk_, wk_, ak_, or sa_ — is documented in the key prefix table.