permission error while making ugc video post on linkedin

最后都变了- 提交于 2019-11-27 03:26:30

问题


I am trying to create video post on linkedin with new ugc endpoint

there are two steps to create this type of post

1). Upload video asset on linkedin server (done)
2). make post request to ugc endpoint with request body

I have successfully uploaded the video but getting authentication error for ugc post request. error is

{
    "message": "urn:li:developerApplication:<id1> does not have permission to create ugc posts with author: li:member:<id2>",
    "status": 401
}

I am passing the request body as suggested in the linkedin api docs.

{
  "author": "urn:li:person:<id>",
  "lifecycleState": "PUBLISHED",
  "specificContent": {
    "com.linkedin.ugc.ShareContent": {
      "media": [
        {
          "title": {
            "attributes": [],
            "text": "Sample Video Create"
          },
          "description": {
            "attributes": [],
            "text": "Sample Description"
          },
          "media": "urn:li:digitalmediaAsset:<asset_id>",
          "thumbnails": [],
          "status": "READY"
        }
      ],
      "shareCommentary": {
        "attributes": [],
        "text": "Some share text"
      },
      "shareMediaCategory": "VIDEO"
    }
  },
  "visibility": {
    "com.linkedin.ugc.MemberNetworkVisibility": "PUBLIC"
  },
  "targetAudience": {
    "targetedEntities": [
      {
        "locations": [
          "urn:li:country:us"
        ]
      }
    ]
  }
}

Please suggest how I can solve this problem. From error message it seems like I am not providing some permission. But I am not sure where I am making mistake.


回答1:


This is the response I got from the LinkedIn Developer Support:

"Hi Ervin,

Creating video UGC posts is currently a whitelisted feature. There is currently hold on whitelisting new apps for video.

You may continue to create UGC posts that are not video though.

I'll put this on hold until I have more information on when we can whitelist apps again.

Best, Alex"



来源:https://stackoverflow.com/questions/51878672/permission-error-while-making-ugc-video-post-on-linkedin

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!