How to download attachmen from email in php/ laravel socialite?

The project I’m working on would ideally scan every delivered email to "[email protected]" then forward every email to gmail. If there is attachment with particular extension it would be extracted and stored on my app’s server for further examination.

From my research I could use Google developer API

With this official library

Or better with Laravel Socialite since I’m developing in Laravel

Is this the correct way to do it?

Source: Laravel

Leave a Reply