接続からメール、名前、画像を取得しようとしていますが、ユーザーが認証すると、「GET https://api.linkedin.com/v1/people/~/connections:(picture-url,first -name、email-address)?count = 30 403(禁止) "
以下にコードを投稿しています。
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Untitled Document</title>
<script type="text/javascript" src="http://platform.linkedin.com/in.js">
api_key: uey3banalp6s
authentication: true
</script>
<script type="text/javascript">
function loadData() {
IN.API.Connections("me")
.fields(["pictureUrl","firstName","emailAddress"])
.params({"count":30})
.result(function(result) {
profHTML = "";
for (var index in result.values) {
profile = result.values[index]
if (profile.pictureUrl) {
profHTML += "email:" + profile.emailAddress;
profHTML += "name:" + profile.firstName;
profHTML += "<img class=img_border height=30 align=\"left\" src=\"" + profile.pictureUrl + "\">";
}
}
$("#connections").html(profHTML);
});
}
</script>
</head>
<body>
<div id="connections"></div>
<script type="IN/Login" data-onAuth="loadData">
</script>
</body>
</html>