Don't have Telegram yet? Try it now!
https://hobo.house/2017/07/17/using-offlineimap-with-the-gmail-imap-api/
Using Offlineimap with the Gmail IMAP API