Works with all AI agents

Connect your AI agent

Choose your assistant and connect in seconds.

Add to Claude

Works on every Claude plan, including free. Full Claude guide

  1. 1

    Add to Claude

    One click from Claude’s connector directory.

  2. 2

    Sign up or sign in

    Takes seconds, then you’re sent straight back.

  3. 3

    Ask Claude

    “Plan and schedule my posts for next week.”

PostEverywhere LinkedIn API Guide

PostEverywhere API reference for LinkedIn: request fields, media rules and examples for text, images, video and PDF carousels on profiles and pages.

Publish text posts, image posts, videos, and PDF carousel documents to LinkedIn profiles and company pages. PostEverywhere handles LinkedIn's multi-step media upload and UGC post creation through a single API call. For a general overview of all supported platforms, see the Introduction.

Connect your LinkedIn account to PostEverywhere

Connect LinkedIn from the dashboard with OAuth, or headlessly from code: mint a connect link and hand it to the account owner - no dashboard session needed. Both flows are covered in Connecting Accounts.

What you can post to LinkedIn

Content Type Media Required Description
Text post None Plain text post with no media attachments.
Image post Image(s) Post with one or more images. Supports JPEG, PNG, WebP, and HEIC.
Video post Video (MP4) Native video post uploaded directly to LinkedIn.
PDF carousel Document (PDF) A PDF uploaded as a document post. LinkedIn displays each page as a swipeable carousel slide.

LinkedIn is one of the most versatile platforms, supporting images, videos, and PDF documents in a single API.

LinkedIn-specific options in the API

Use the platform_content.linkedin object to customise your LinkedIn post:

{
  "platform_content": {
    "linkedin": {
      "content": "LinkedIn-specific text (max 3000 chars)",
      "settings": {
        "visibility": "PUBLIC",
        "firstComment": "First comment text"
      }
    }
  }
}

Settings Reference

Setting Type Default Description
content string N/A Override the default text with a LinkedIn-specific version. Max 3,000 characters.
settings.visibility string "PUBLIC" Who can see the post. See values below.
settings.firstComment string N/A Text posted as the first comment after publishing. Useful for adding links or CTAs.

Visibility Options

Value Description
PUBLIC Visible to everyone on LinkedIn, including non-connections.
CONNECTIONS Visible only to your 1st-degree connections.
LOGGED_IN_MEMBERS Visible to any logged-in LinkedIn user, but not in public search.

Publish to LinkedIn: a working request

Schedule a LinkedIn Post with a PDF Carousel

curl -X POST https://app.posteverywhere.ai/api/v1/posts \
  -H "Authorization: Bearer $POSTEVERYWHERE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "content": "Default caption for other platforms",
    "account_ids": [2275],
    "media_ids": ["a7b8c9d0-e1f2-3456-7890-abcdef012345"],
    "scheduled_for": "2026-04-16T08:30:00Z",
    "timezone": "America/New_York",
    "platform_content": {
      "linkedin": {
        "content": "I spent the last 6 months analyzing what makes content go viral on LinkedIn.\n\nHere are the 10 patterns I found (swipe through the carousel):\n\n1. Hook in the first line\n2. Use data, not opinions\n3. One idea per slide\n...\n\nDrop a comment if you want the full PDF.",
        "settings": {
          "visibility": "PUBLIC",
          "firstComment": "Download the full report here: https://example.com/report"
        }
      }
    }
  }'

Schedule a Connections-Only Text Post

curl -X POST https://app.posteverywhere.ai/api/v1/posts \
  -H "Authorization: Bearer $POSTEVERYWHERE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "content": "Thinking about our next product direction.",
    "account_ids": [2275],
    "scheduled_for": "2026-04-16T12:00:00Z",
    "timezone": "America/Chicago",
    "platform_content": {
      "linkedin": {
        "content": "I have been reflecting on what our customers actually need vs. what we assumed they wanted.\n\nThe gap is bigger than expected.\n\nMore soon — would love your thoughts in the comments.",
        "settings": {
          "visibility": "CONNECTIONS"
        }
      }
    }
  }'

LinkedIn limits: characters, media and video

Requirement Limit
Post text length 3,000 characters
First comment length 1,250 characters
Image formats JPEG, PNG, WebP, HEIC
Image max file size 20 MB
Video format MP4 (H.264)
Video max file size 4 GB
Video duration 3 seconds - 10 minutes
Document format PDF
Document max file size 20 MB
PDF carousel pages Up to 300 pages (practical limit ~20 for engagement)
Recommended image ratio 1.91:1 (landscape) or 1:1 (square)

Getting better results on LinkedIn

  • Use PDF carousels for high engagement. LinkedIn's algorithm favors carousel documents because they increase dwell time. Upload a multi-page PDF and each page becomes a swipeable slide. Keep it to 8-12 slides for optimal engagement.
  • Put links in firstComment, not the post body. LinkedIn's algorithm deprioritizes posts with external links in the main text. Use firstComment to add your link after publishing: this keeps your reach high while still driving traffic.
  • Write longer, value-driven posts. LinkedIn rewards posts between 1,000-2,000 characters. Use the full 3,000-character limit to tell a story or share insights. The first line is your hook, make it count.

Common questions about posting to LinkedIn

Upload a PDF file using the Upload Media endpoint, then pass the returned UUID in the media_ids array in your Create Post request. LinkedIn automatically displays each page of the PDF as a swipeable carousel slide. Keep carousels to 8-12 slides for best engagement.

Can I post to LinkedIn company pages, not just personal profiles?

Yes. Connect your LinkedIn company page as a social account in PostEverywhere, then use the company page's account_id when creating a post. The API supports both personal profiles and company pages.

What is the firstComment setting used for on LinkedIn?

The firstComment field posts a reply to your own post immediately after publishing. This is commonly used to add external links or CTAs. LinkedIn's algorithm deprioritizes posts that contain links in the main body, so placing links in the first comment preserves your organic reach.

What is the maximum character limit for LinkedIn posts?

LinkedIn posts support up to 3,000 characters. Posts between 1,000 and 2,000 characters tend to perform best. The first line of your post is your hook -- it appears before the "see more" fold, so make it count.

Why didn't my LinkedIn post get a rich link card?

A rich card requires four things to land in this order: (1) we extract a URL from your post body, (2) the URL responds with HTML, (3) we find an Open Graph title in that HTML, and (4) we successfully fetch the og:image, convert it to JPEG, and upload it to LinkedIn under 5 MB. If any step fails, we fall back to a plain text post that still contains the URL. Common failures: the page blocks bots (returns 403/empty body to our user-agent), has no og:image, or serves an image that fails to download. Carousels and image posts bypass the card pipeline entirely: LinkedIn shows the attached media instead.

Yes. We detect both explicit URLs (https://example.com/blog/foo) and bare URLs (example.com/blog/foo) as long as the host has at least one dot, the TLD is 2-10 alphabetic characters, and at least one path segment follows the host. Only the first URL in the post becomes the card (LinkedIn renders one card per post).

Can I edit a LinkedIn post after it's published?

No. PATCH /v1/posts/:id only accepts posts in scheduled or draft status. Once LinkedIn has accepted the post, it becomes published and the API returns 400 invalid_post_status. LinkedIn's own UGC API does not allow third-party tools to edit a published post's text: you must edit it on LinkedIn directly, or delete and recreate.

Other platforms you can publish to

  • X (Twitter) -- professional commentary and thought leadership
  • Facebook -- similar post formats with image, video, and link support
  • Threads -- short-form text posts for conversation

Related: LinkedIn media requirements · testing posts safely · scheduling LinkedIn posts with an API · social media API for developers · generate captions with AI