You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

LinkedIn API返回数据不一致:like count统计异常问题问询

Troubleshooting LinkedIn API Returning Incorrect Like Count (0) for Status Updates

Let’s walk through why you might be getting a like-count of 0 from that LinkedIn API endpoint even though the actual post has likes, and how to fix it:

Common Causes & Fixes

  • Mismatched or Invalid Update Key
    Double-check your update-key parameter — for company posts, it should follow the structure UPDATE-<company-id>-<post-id>. Your example (UPDATE-c4822304-6378756278751109120) looks structurally valid, but confirm the post ID matches exactly what’s visible in the post’s URL or LinkedIn’s UI. Even a single character typo here can lead to empty or incorrect stats.

  • Insufficient Access Token Scopes
    LinkedIn’s API requires specific scopes to pull post statistics. Make sure your access token has these enabled:

    • r_organization_social (required for reading company social data)
    • rw_organization_admin (optional, but useful for admin-specific stats)
      You can verify your token’s scopes by decoding it with a JWT tool or checking your OAuth authorization flow. Missing scopes often return incomplete/zeroed data instead of an explicit error message.
  • Date Range & Time Granularity Misalignment
    Your request uses time-granularity=day and start-timestamp=1517443200000 (Jan 31, 2018). If the post was published outside this exact day, the daily stats for that timestamp will show 0. Try removing the start-timestamp temporarily to fetch all available historical stats for the post, or adjust the timestamp to match the post’s actual publication date.

  • Deprecated API Version
    A critical point: the /v1/companies/... endpoint you’re using is from LinkedIn’s sunset V1 API, which was deprecated years ago. V1 endpoints often return incomplete data or stop working entirely now. You should migrate to the supported V2 equivalent endpoint, which uses URNs for identifiers:

    https://api.linkedin.com/v2/organizationalEntityShareStatistics?q=organizationalEntity&organizationalEntity=urn:li:organization:4822304&shares=List(urn:li:share:6378756278751109120)&timeIntervals=(timeGranularityType:DAY,start:1517443200000)
    
  • Data Sync Delay
    LinkedIn’s API can have a 15-30 minute delay between when a post gets likes and when those stats are available via the API. If the post was recently updated, wait a bit and retry the request. Also, clear any local caching for API responses to ensure you’re pulling fresh data.

Quick Validation Checks

  1. Test the same access token with a different post (one you know has confirmed likes). If that returns correct stats, the issue is specific to the original post’s update key or date range.
  2. Use LinkedIn’s internal API Console (if you have access) to re-run the request — this helps rule out formatting issues or token validity problems.

内容的提问来源于stack exchange,提问作者Kranthi Krishna

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.27 04:08:46