laravel-gmail
laravel-gmail copied to clipboard
refresh token must be passed in or set as part of setaccesstoken
I've encountered a new issue right after authorizing Google. Firstly, I received the following error message:
"Refresh token must be passed in or set as part of setaccesstoken (view: /var/www/html/domain/resources/views/layouts/header.blade.php)."
To temporarily resolve this, I deleted the file located at "storage/app/gmail/tokens/gmail-json.json" and then re-authenticate. This allows the application to work again. However, after approximately one hour, the same problem recurs.
Could you please assist me with this issue? My application is currently live, and this problem is affecting its functionality.
I have the same issue @dacastro4 - do you have time to look at this ?
I identified the issue and resolved it. To generate the token successfully, make sure to include the GOOGLE_PROJECT_ID, like this:
LaravelGmail::setUserId("gmail-api-000964")->makeToken();
This worked correctly in my case, and I hope it works for you as well.