【发布时间】:2015-11-22 05:24:40
【问题描述】:
我将这个instagram wrapper package 用于laravel 5.1。我试图通过 API 连接到 instagram,然后验证用户使用
use Vinkla\Instagram\Facades\Instagram;
public function instagramlogin(Request $request)
{
// Get code parameter.
$code = $request->get('code');
// Request the access token.
$data = Instagram::getOAuthToken($code);
// Set the access token with $data object.
Instagram::setAccessToken($data);
// We're done here - how easy was that, it just works!
Instagram::getUserLikes();
// This example is simple, and there are far more methods available.
}
然后能够访问他/她的个人资料数据。但我不断收到错误说明
ErrorException in Instagram.php line 526:
Undefined property: stdClass::$access_token
如何对用户进行身份验证?
【问题讨论】:
标签: php oauth-2.0 instagram laravel-5.1 instagram-api