Skip to content
Docs

List a profile's or a company's posts

GETdirect.lempile.com/api/v1/users/{identifier}/posts

A member's posts, newest first (20 a LinkedIn call; me for the account's own), or with is_company=true a company page's (identifier = its id or universal name).

Authentication

X-API-KEY header·A Lempile Direct key, one per workspace, made in Lempile's dashboard.

Path parameters

  • identifierstringrequired

    The person: provider id (ACo…), public identifier, urn:li:fsd_profile:…, a profile URL (URL-encoded) or me.

Query parameters

  • account_idstringrequired

    The account that reads: a Lempile LinkedIn account id (GET /accounts lists them).

  • limitinteger

    Items per page: 1 to 100 (default 10).

    Default10≥ 1 · ≤ 100
  • cursorstring

    A cursor a previous page gave.

  • is_companyboolean

    true: identifier is a company.

    Defaultfalse

Responses

200

OK

›

application/json

  • objectstringrequired
    AlwaysPostList
  • itemsarray of Postrequired
    ›Show fields
    • objectstringrequired
      AlwaysPost
    • providerstringrequired
      AlwaysLINKEDIN
    • idstringrequired

      The post's activity id (digits).

    • social_idstringrequired

      urn:li:activity:<id>: what comments and reactions take as post_id.

    • share_urlstringrequired
    • titlestring
    • textstringrequired
    • datestringrequired

      LinkedIn's relative date, e.g. 2d.

    • parsed_datetimestringrequired

      The post's time (ISO 8601), from its id.

    • reaction_counterintegerrequired
    • comment_counterintegerrequired
    • repost_counterintegerrequired
    • impressions_counterintegerrequired

      0 unless LinkedIn shows it to the account.

    • authorPostAuthorrequired
      ›Show fields
      • public_identifierstring | nullrequired
      • idstring | nullrequired
      • namestring | nullrequired
      • is_companybooleanrequired
      • headlinestring
      • profile_picture_urlstring
    • permissionsobjectrequired
      ›Show fields
      • can_reactbooleanrequired
      • can_sharebooleanrequired
      • can_post_commentsbooleanrequired
    • is_repostbooleanrequired

      true on a plain repost (no words of its own): the post is then the reposted one as LinkedIn shows it (id, social_id, text, author, counts), and repost_id, reposted_by and repost_parsed_datetime are the repost's. A repost with words is the reposter's own post (false), with repost_content.

    • attachmentsarray of PostAttachmentrequired
      ›Show fields
      • idstring | nullrequired
      • typestringrequired
        One ofimgvideo
      • urlstring | null
      • url_expires_atinteger | null

        When url stops working, in milliseconds since 1970.

      • sizeobject
        ›Show fields
        • widthintegerrequired
        • heightintegerrequired
      • durationinteger | null

        A video's length in seconds.

      • mimetypestring
      • file_sizeinteger | null
      • gifboolean
      • unavailablebooleanrequired
      • stickerboolean
    • mentionsarray of objectrequired

      People and pages named in the text.

      ›Show fields
      • startintegerrequired
      • lengthintegerrequired
      • urlstringrequired
    • user_reactedstring

      The account's own reaction (LinkedIn's name: LIKE, PRAISE…), when it reacted.

    • reposted_byPostAuthor
      ›Show fields
      • public_identifierstring | nullrequired
      • idstring | nullrequired
      • namestring | nullrequired
      • is_companybooleanrequired
      • headlinestring
      • profile_picture_urlstring
    • repost_idstring

      A plain repost: the repost's own activity id (what POST /posts answered as post_id, and what DELETE /posts/{post_id} takes to undo it).

    • repost_contentobject

      The post shared: the reposted post, on a plain repost and on a repost with words.

      ›Show fields
      • idstringrequired
      • datestringrequired
      • parsed_datetimestringrequired
      • textstringrequired
      • authorPostAuthorrequired
        ›Show fields
        • public_identifierstring | nullrequired
        • idstring | nullrequired
        • namestring | nullrequired
        • is_companybooleanrequired
        • headlinestring
        • profile_picture_urlstring
      • attachmentsarray of PostAttachmentrequired
        ›Show fields
        • idstring | nullrequired
        • typestringrequired
          One ofimgvideo
        • urlstring | null
        • url_expires_atinteger | null

          When url stops working, in milliseconds since 1970.

        • sizeobject
          ›Show fields
          • widthintegerrequired
          • heightintegerrequired
        • durationinteger | null

          A video's length in seconds.

        • mimetypestring
        • file_sizeinteger | null
        • gifboolean
        • unavailablebooleanrequired
        • stickerboolean
    • repost_parsed_datetimestring

      A plain repost: when it was reposted.

  • pagingobjectrequired
    ›Show fields
    • page_countintegerrequired
  • cursorstring | nullrequired

    The next page's cursor, or null on the last page. Opaque: send it back as cursor.

400

A required parameter missing (errors/missing_parameters), or one that isn't valid (errors/invalid_parameters, errors/invalid_url, errors/content_too_large).

›

application/json

  • titlestringrequired

    A short title, e.g. Too many requests.

  • detailstringrequired

    What happened, in plain words. Never an account's data.

  • typestringrequired

    Unipile's error type: errors/<kind>. Branch on this, not on detail.

  • statusintegerrequired

    The HTTP status again.

  • retry_afterinteger

    Seconds to wait before trying this account again. Only on 429; the Retry-After header carries the same value.

401

errors/missing_credentials: the X-API-KEY header is missing, wrong or revoked. errors/disconnected_account: LinkedIn signed the account out (or asks it for a security check); reconnect it.

›

application/json

  • titlestringrequired

    A short title, e.g. Too many requests.

  • detailstringrequired

    What happened, in plain words. Never an account's data.

  • typestringrequired

    Unipile's error type: errors/<kind>. Branch on this, not on detail.

  • statusintegerrequired

    The HTTP status again.

  • retry_afterinteger

    Seconds to wait before trying this account again. Only on 429; the Retry-After header carries the same value.

404

errors/resource_not_found: an unknown or removed account, an account of another workspace (answered exactly the same), or nothing on LinkedIn with this id.

›

application/json

  • titlestringrequired

    A short title, e.g. Too many requests.

  • detailstringrequired

    What happened, in plain words. Never an account's data.

  • typestringrequired

    Unipile's error type: errors/<kind>. Branch on this, not on detail.

  • statusintegerrequired

    The HTTP status again.

  • retry_afterinteger

    Seconds to wait before trying this account again. Only on 429; the Retry-After header carries the same value.

429

errors/too_many_requests: LinkedIn asked the account to slow down (it rests 15 minutes), its daily calls or writes are used up, or it's busy with other calls. Wait retry_after seconds.

›

application/json

  • titlestringrequired

    A short title, e.g. Too many requests.

  • detailstringrequired

    What happened, in plain words. Never an account's data.

  • typestringrequired

    Unipile's error type: errors/<kind>. Branch on this, not on detail.

  • statusintegerrequired

    The HTTP status again.

  • retry_afterinteger

    Seconds to wait before trying this account again. Only on 429; the Retry-After header carries the same value.

500

errors/provider_error: LinkedIn answered something Direct couldn't read (nothing was written). errors/unexpected_error: Direct failed.

›

application/json

  • titlestringrequired

    A short title, e.g. Too many requests.

  • detailstringrequired

    What happened, in plain words. Never an account's data.

  • typestringrequired

    Unipile's error type: errors/<kind>. Branch on this, not on detail.

  • statusintegerrequired

    The HTTP status again.

  • retry_afterinteger

    Seconds to wait before trying this account again. Only on 429; the Retry-After header carries the same value.

503

errors/network_down: the account's proxy or browser server didn't answer. Nothing was sent.

›

application/json

  • titlestringrequired

    A short title, e.g. Too many requests.

  • detailstringrequired

    What happened, in plain words. Never an account's data.

  • typestringrequired

    Unipile's error type: errors/<kind>. Branch on this, not on detail.

  • statusintegerrequired

    The HTTP status again.

  • retry_afterinteger

    Seconds to wait before trying this account again. Only on 429; the Retry-After header carries the same value.

504

errors/request_timeout: LinkedIn didn't answer in time. On a write: an unknown outcome (it may have been sent); it's never retried and its Idempotency-Key never writes again.

›

application/json

  • titlestringrequired

    A short title, e.g. Too many requests.

  • detailstringrequired

    What happened, in plain words. Never an account's data.

  • typestringrequired

    Unipile's error type: errors/<kind>. Branch on this, not on detail.

  • statusintegerrequired

    The HTTP status again.

  • retry_afterinteger

    Seconds to wait before trying this account again. Only on 429; the Retry-After header carries the same value.

Was this page helpful?