【问题标题】:LinkedIn API to post Share using php oauth classLinkedIn API 使用 php oauth 类发布共享
【发布时间】:2012-12-20 05:07:51
【问题描述】:

详情:

  1. 我使用 Manuel Lemos php oauth 类和 login_with_linkedin.php 脚本作为参考。

  2. 我已成功完成 oauth 流程并使用 API 'http://api.linkedin.com/v1/people/~' 检索用户信息

  3. 使用 Post Shares API (http://api.linkedin.com/v1/people/~/shares) 时出现错误

这是我上次尝试失败的相关代码;

// Scope settings

 $client->scope = 'r_fullprofile r_emailaddress r_network rw_nus';

// Call to API (Post)

$success = $client->CallAPI(
  'http://api.linkedin.com/v1/people/~/shares', 
  'POST', array(
      "format"=>"json",
      "comment"=> "Test"
   ), array('FailOnAccessError'=>true), $user);

这是错误信息:

Error: it was not possible to access the API call: it was returned an unexpected response status 401 Response: { "errorCode": 0, "message": "Unknown authentication scheme", "requestId": "8DWA0EBJTB", "status": 401, "timestamp": 1355774186502 }

任何帮助将不胜感激。谢谢。

【问题讨论】:

    标签: php linkedin


    【解决方案1】:

    我也在课程创建者的论坛上发布了同样的问题。 他给了我一个有效的答案。

    答案可以在这里找到: http://www.phpclasses.org/discuss/package/7700/thread/22/

    【讨论】:

      猜你喜欢
      • 2019-03-23
      • 2012-12-30
      • 1970-01-01
      • 2011-12-05
      • 2013-07-08
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多