You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
finalOauthToken token =await_retrieveOauthToken();
final account =MailAccount.fromDiscoveredSettingsWithAuth(
'acccount name',
email,
OauthAuthentication(email, token),
discoveredClientConfig,
);
final mailClient =MailClient(
account,
refresh: (mailClient, expiredToken) async {
// TODO refresh tokenreturn expiredToken;
}
}
With the above high level code you only need to fill in the google specific ways to get your token and then refresh your expired token. You can learn about gmail specific details here: https://developers.google.com/gmail/imap/xoauth2-protocol
How to use google sign in and enough mail to get emails from gmail without the user having to sign in with their raw credentials.
The text was updated successfully, but these errors were encountered: