1

I'm trying to get post analytics (impressions, likes, comments, repost) counts via LinkedIn API

I have following permissions with my 3 legged token

email,openid,profile,r_basicprofile,r_organization_admin,r_organization_social,rw_organization_admin,w_organization_social

Now I've tried fetching impression details through /socialMetadata

curl -X GET 'https://api.linkedin.com/rest/socialMetadata?id=urn%3Ali%3Ashare%3A${postId}' \
-H 'Authorization: Bearer $TOKEN' \
-H 'LinkedIn-Version: 202506' \
-H 'X-Restli-Protocol-Version: 2.0.0' 

Response:

{
  "status": 404,
  "code": "RESOURCE_NOT_FOUND",
  "message": "No virtual resource found"
}

Another thing I tried with /organizationalEntityShareStatistics as well

curl -X GET 'https://api.linkedin.com/rest/organizationalEntityShareStatistics?organizationalEntity=urn%3Ali%3Aorganization%3A${orgId}&ugcPosts=urn%3Ali%3AugcPost%3A${postId}' \
-H 'Authorization: Bearer $TOKEN' \
-H 'LinkedIn-Version: 202506' \           
-H 'X-Restli-Protocol-Version: 2.0.0'

Response:

{
  "status": 404,
  "code": "RESOURCE_NOT_FOUND",
  "message": "No virtual resource found"
}

I've also tried changing ugc to shares and changing urn to share as well, But still same 404 error.

Only the, /socialMetadata and /socialActions are working.But, its just giving me likes and comments count and not the impressions count.

Is there anything I'm doing wrong

2

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.