In PHP, I need to fetch mails from gmail without using Application Specific Password when 2 step verification is enabled. I already tried fetching mails with Application Specific Password using imap and its working fine. But I don't want that. I need without using app specific password I should able to fetch mails from gmail.
For example: if you go through nimble.com, you can login through google and there they are fetching emails from gmail using login credentials only with or without 2-step verification.
You need to use the OAuth 2.0 protocol to authorize the Gmail API. I think the OAuth 2.0 Playground is a great way to learn how it works. Just set your scopes to the Gmail API v1 ones to try the Gmail API.
Then you can check out the PHP client library to learn how to use it in your own application.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With