LinkedIn API
Postproxy publishes feed posts to a LinkedIn personal profile or a company page (organization), including image, video, and document (PDF/slide) posts.
Every request below uses the base URL https://api.postproxy.dev and an Authorization: Bearer YOUR_API_KEY header. Replace YOUR_API_KEY and the example IDs with your own.
Profiles and profile groups
Section titled “Profiles and profile groups”Every post targets one or more profiles. A profile is one connected account — for LinkedIn, a personal profile or a company page (organization). Reference one in a request by its id (the prof_abc123 in the examples below) or by the platform name "linkedin", which selects the group’s LinkedIn profile (a group holds at most one profile per platform). List what’s connected with GET /api/profiles.
Profiles live in profile groups — containers that organize the accounts for one brand, client, or project. List groups with GET /api/profile_groups, and connect a new LinkedIn profile with the Initialize Connection endpoint.
Example: get profiles and profile groups
List the profiles you can post to — GET /api/profiles:
curl -X GET "https://api.postproxy.dev/api/profiles" \ -H "Authorization: Bearer YOUR_API_KEY"{ "data": [ { "id": "prof_abc123", "name": "My Company", "platform": "linkedin", "status": "active", "profile_group_id": "grp_xyz789", "expires_at": null, "post_count": 53, "avatar_url": "https://cdn.postproxy.dev/uploads/avatar_prof_abc123.jpg" } ]}List your profile groups — GET /api/profile_groups:
curl -X GET "https://api.postproxy.dev/api/profile_groups" \ -H "Authorization: Bearer YOUR_API_KEY"{ "data": [ { "id": "grp_xyz789", "name": "Main Brand", "profiles_count": 5 }, { "id": "grp_def456", "name": "Client Project", "profiles_count": 3 } ]}At a glance
Section titled “At a glance”| Platform ID | linkedin |
| Formats | post (default) |
| Character limit | 3,000 |
| Media | Optional |
| Placements | Personal profile + organizations — selected with organization_id |
| Comments | Coming soon |
| Direct messages | No |
| Post chains | No |
Publishing
Section titled “Publishing”Parameters
Section titled “Parameters”| Parameter | Type | Required | Description |
|---|---|---|---|
organization_id | string | No | Post as a company page. Omit to post on the personal profile |
| Media | Max size | Formats | Count | Duration |
|---|---|---|---|---|
| Image | 8 MB | jpg, png, gif | 20 | — |
| Video | 5 GB | mp4, mov, avi | 1 | up to 15 min |
| Document | 100 MB | pdf, doc, docx, ppt, pptx | 1 | — |
- Text-only posts are allowed; media is optional.
- Images and video cannot be mixed.
- A document must be posted on its own — it cannot be combined with images or video. Max 300 pages.
- Minimum image dimensions: 552×276 px.
# Post to the personal profilecurl -X POST "https://api.postproxy.dev/api/posts" \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "post": { "body": "We are excited to share our latest product update!" }, "profiles": ["prof_abc123"], "media": ["https://example.com/image.jpg"], "platforms": { "linkedin": {} } }'# Post to a company pagecurl -X POST "https://api.postproxy.dev/api/posts" \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "post": { "body": "Hiring! We are growing the engineering team." }, "profiles": ["prof_abc123"], "platforms": { "linkedin": { "organization_id": "12345678" } } }'# Document (PDF carousel) — must be the only attachmentcurl -X POST "https://api.postproxy.dev/api/posts" \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "post": { "body": "Our 2026 industry report — free download." }, "profiles": ["prof_abc123"], "media": ["https://example.com/report.pdf"], "platforms": { "linkedin": { "organization_id": "12345678" } } }'Placements
Section titled “Placements”A LinkedIn profile can publish to the personal profile and to any organizations the account administers. List them with the placements endpoint:
- The personal profile is returned with
id: null. - Each organization’s
idis the value you pass asorganization_id.
# List placements (personal profile + organizations)curl "https://api.postproxy.dev/api/profiles/prof_abc123/placements" \ -H "Authorization: Bearer YOUR_API_KEY"Omit organization_id to publish on the personal profile.
Comments
Section titled “Comments”Coming soon. Comment list, reply, hide, and delete support for LinkedIn is in progress. When live, comments will be managed through the Comments API.
Direct messages
Section titled “Direct messages”Not supported.
Postproxy records periodic stat snapshots you can pull as a timeseries; field names pass through from LinkedIn unchanged.
Profile stats
Section titled “Profile stats”Follower and page-view metrics, refreshed roughly every 23 hours and scoped per placement (personal profile + each organization) — pass the placement_id. See the Profile stats endpoint (GET /api/profiles/:id/stats).
Fields: followerCount, shareCount, likeCount, commentCount, clickCount, engagement, allPageViews, overviewPageViews, aboutPageViews, careersPageViews, peoplePageViews, insightsPageViews
# Fetch the stats timeseries for one organization (placement_id is the organization_id)curl "https://api.postproxy.dev/api/profiles/prof_abc123/stats?placement_id=12345678" \ -H "Authorization: Bearer YOUR_API_KEY"Post stats
Section titled “Post stats”Per-post engagement, captured after publish via the Post stats endpoint (GET /api/posts/stats). LinkedIn currently reports impressions only.
Fields: impressions
# Fetch post statscurl "https://api.postproxy.dev/api/posts/stats?post_ids=post_abc123&profiles=linkedin" \ -H "Authorization: Bearer YOUR_API_KEY"Webhooks
Section titled “Webhooks”Subscribe with the Webhooks API:
curl -X POST "https://api.postproxy.dev/api/webhooks" \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "url": "https://example.com/webhooks/postproxy", "events": ["platform_post.published", "platform_post.insights", "profile.stats"] }'Events relevant to LinkedIn:
| Event | When |
|---|---|
post.processed | A post is ready to publish |
platform_post.published | A post was published to the platform |
platform_post.failed | A post failed to publish (retries exhausted) |
platform_post.failed_waiting_for_retry | A publish attempt failed; will retry |
platform_post.insights | New analytics snapshot |
profile.connected / .disconnected | Connection state changed |
profile.stats | New profile stats snapshot — fires once per placement (personal profile + each organization) |
media.failed | A media attachment failed to process |
- Choose the audience with
organization_id: present → company page, absent → personal profile. - Document posts (PDF, DOCX, PPTX) render as LinkedIn’s native multi-page carousel and must be the only attachment.