Skip to main content
GET
/
api
/
v1
/
posts
Get LinkedIn posts from a profile
curl --request GET \
  --url https://api.fetchin.io/api/v1/posts \
  --header 'X-API-Key: <api-key>'
[
  {
    "urn": "urn:li:activity:7123456789012345678",
    "text": "Excited to announce our new initiative...",
    "publishedAt": "2024-01-15T10:30:00Z",
    "numberOfLikes": 127,
    "numberOfComments": 15,
    "numberOfReposts": 8,
    "imageUrl": "https://media.licdn.com/dms/image/...",
    "videoUrl": null,
    "carouselPdfUrl": null,
    "profile": {
      "urn": "urn:li:fsd_profile:ACoAAABCDEF",
      "name": "William Gates",
      "headline": "Co-chair, Bill & Melinda Gates Foundation",
      "url": "https://www.linkedin.com/in/williamhgates",
      "imageUrl": "https://media.licdn.com/dms/image/..."
    }
  },
  {
    "urn": "urn:li:activity:7123456789012345679",
    "text": "Reflecting on the past year and looking forward...",
    "publishedAt": "2024-01-10T14:20:00Z",
    "numberOfLikes": 89,
    "numberOfComments": 7,
    "numberOfReposts": 3,
    "imageUrl": null,
    "videoUrl": "https://dms.licdn.com/playlist/...",
    "carouselPdfUrl": null,
    "profile": {
      "urn": "urn:li:fsd_profile:ACoAAABCDEF",
      "name": "William Gates",
      "headline": "Co-chair, Bill & Melinda Gates Foundation",
      "url": "https://www.linkedin.com/in/williamhgates",
      "imageUrl": "https://media.licdn.com/dms/image/..."
    }
  }
]

Endpoint

GET /api/v1/posts

Authentication

Include your API key in the request header:
X-API-Key: your-api-key-here

Parameters

profileUrlOrUrn
string
required
LinkedIn profile URL or URN.Examples:
  • https://www.linkedin.com/in/username
  • urn:li:member:123456789
count
integer
default:"10"
Number of posts to fetch.
  • Minimum: 1
  • Maximum: 50
  • Default: 10

Response

posts
array
Array of LinkedIn posts

Example Request

curl -X GET "https://api.fetchin.io/api/v1/posts?profileUrlOrUrn=https://www.linkedin.com/in/williamhgates&count=5" \
  -H "X-API-Key: your-api-key-here"

Example Response

[
  {
    "urn": "urn:li:activity:7123456789012345678",
    "text": "Excited to announce our new initiative...",
    "publishedAt": "2024-01-15T10:30:00Z",
    "numberOfLikes": 127,
    "numberOfComments": 15,
    "numberOfReposts": 8,
    "imageUrl": "https://media.licdn.com/dms/image/...",
    "videoUrl": null,
    "carouselPdfUrl": null,
    "profile": {
      "urn": "urn:li:fsd_profile:ACoAAABCDEF",
      "name": "William Gates",
      "headline": "Co-chair, Bill & Melinda Gates Foundation",
      "url": "https://www.linkedin.com/in/williamhgates",
      "imageUrl": "https://media.licdn.com/dms/image/..."
    }
  },
  {
    "urn": "urn:li:activity:7123456789012345679",
    "text": "Reflecting on the past year and looking forward...",
    "publishedAt": "2024-01-10T14:20:00Z",
    "numberOfLikes": 89,
    "numberOfComments": 7,
    "numberOfReposts": 3,
    "imageUrl": null,
    "videoUrl": "https://dms.licdn.com/playlist/...",
    "carouselPdfUrl": null,
    "profile": {
      "urn": "urn:li:fsd_profile:ACoAAABCDEF",
      "name": "William Gates",
      "headline": "Co-chair, Bill & Melinda Gates Foundation",
      "url": "https://www.linkedin.com/in/williamhgates",
      "imageUrl": "https://media.licdn.com/dms/image/..."
    }
  }
]

Notes

This endpoint counts as 1 request toward your monthly quota, regardless of the count parameter value. Failed requests (errors) do not count against your quota.
Posts are returned in reverse chronological order (newest first).
Cache results when possible to avoid redundant requests for the same profile.

Authorizations

X-API-Key
string
header
required

Query Parameters

profileUrlOrUrn
string
required

LinkedIn profile URL or URN

Example:

"https://www.linkedin.com/in/username"

count
integer
default:10

Number of posts to fetch (default: 10)

Required range: 1 <= x <= 50

Response

Successfully fetched posts

urn
string
Example:

"urn:li:activity:1234567890"

text
string
Example:

"This is a LinkedIn post content..."

publishedAt
string<date-time>
numberOfLikes
integer
numberOfComments
integer
numberOfReposts
integer
imageUrl
string
videoUrl
string
profile
object