Closed PRR24 closed 6 months ago
ImapFlow does not handle OAuth2 internally. It takes the accessToken value, and if authentication fails, you are supposed to generate a new token.
@andris9 This makes sense to keep OAuth2 login out of scope.
To be honest, it sounds reasonable for me as well. The trigger behind the request was that for some reason, the OAuth handling was considered to be in scope for NodeMailer. As I am using both of these great libraries, this discrepancy was weird for me and I would prefer to use the exact same approach for both cases, either delegating it to the library or using some other / my own implementation.
Please consider adding advanced OAuth2 handling to the IMapFlow, namely:
Thank you.