{"action":"created","issue":{"url":"https://api.github.com/repos/SammyK/LaravelFacebookSdk/issues/29","labels_url":"https://api.github.com/repos/SammyK/LaravelFacebookSdk/issues/29/labels{/name}","comments_url":"https://api.github.com/repos/SammyK/LaravelFacebookSdk/issues/29/comments","events_url":"https://api.github.com/repos/SammyK/LaravelFacebookSdk/issues/29/events","html_url":"https://github.com/SammyK/LaravelFacebookSdk/issues/29","id":56078643,"number":29,"title":"Save access_token in users table?","user":{"login":"natenrb9","id":9954488,"avatar_url":"https://avatars.githubusercontent.com/u/9954488?v=3","gravatar_id":"","url":"https://api.github.com/users/natenrb9","html_url":"https://github.com/natenrb9","followers_url":"https://api.github.com/users/natenrb9/followers","following_url":"https://api.github.com/users/natenrb9/following{/other_user}","gists_url":"https://api.github.com/users/natenrb9/gists{/gist_id}","starred_url":"https://api.github.com/users/natenrb9/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/natenrb9/subscriptions","organizations_url":"https://api.github.com/users/natenrb9/orgs","repos_url":"https://api.github.com/users/natenrb9/repos","events_url":"https://api.github.com/users/natenrb9/events{/privacy}","received_events_url":"https://api.github.com/users/natenrb9/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-01-30T20:07:40Z","updated_at":"2015-01-31T18:24:19Z","closed_at":null,"body":"I have a user logging in fine and saving all of their info (id, name, email, etc) to the DB, but it does not seem to be saving the access_token? Isn't it supposed to be? I am not sure why it isn't saving that portion in the DB...I can't tell if it is a bug, or something I need to configure so that it saves correctly."},"comment":{"url":"https://api.github.com/repos/SammyK/LaravelFacebookSdk/issues/comments/72329313","html_url":"https://github.com/SammyK/LaravelFacebookSdk/issues/29#issuecomment-72329313","issue_url":"https://api.github.com/repos/SammyK/LaravelFacebookSdk/issues/29","id":72329313,"user":{"login":"natenrb9","id":9954488,"avatar_url":"https://avatars.githubusercontent.com/u/9954488?v=3","gravatar_id":"","url":"https://api.github.com/users/natenrb9","html_url":"https://github.com/natenrb9","followers_url":"https://api.github.com/users/natenrb9/followers","following_url":"https://api.github.com/users/natenrb9/following{/other_user}","gists_url":"https://api.github.com/users/natenrb9/gists{/gist_id}","starred_url":"https://api.github.com/users/natenrb9/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/natenrb9/subscriptions","organizations_url":"https://api.github.com/users/natenrb9/orgs","repos_url":"https://api.github.com/users/natenrb9/repos","events_url":"https://api.github.com/users/natenrb9/events{/privacy}","received_events_url":"https://api.github.com/users/natenrb9/received_events","type":"User","site_admin":false},"created_at":"2015-01-31T18:24:19Z","updated_at":"2015-01-31T18:24:19Z","body":"I am using the example that had been give: https://github.com/SammyK/LaravelFacebookSdk#user-authentication-example\r\n\r\nAfter reading through: https://www.sammyk.me/best-practice-for-facebook-login-with-the-javascript-sdk-and-php-sdk-v4-1\r\n\r\nIt looks like I do not need to save the access_token unless I am accessing their data when they are offline, which I am not.\r\n\r\nREMAINING QUESTIONS:\r\n1. What I am not understanding is where the access token is actually saved when I use the above example? Is it being saved into the JS or the PHP session? I var dumped the session data and it did not seem to be in there...\r\n\r\n2. I can get a user to log in, but when I try to make Graph requests while they are logged in it throws this error: `Method Facebook\\Entities\\AccessToken::__toString() must return a string value`\r\nI am not sure where it is trying to pull the access_token from, so it is difficult to troubleshoot and it seems like the code should already convert it over. This is the code I am trying to execute in my controller:\r\n`$friends = Facebook::edge('user_friends')->fields('id', 'name')->limit(5);\r\n$user = Facebook::object('me')->fields('name', $friends)->get();`"}}