G Suite Gmail IMAP and SMTP Settings
If your G Suite users want to use EmailTree to access their G Suite mail, you need to enable Internet Message Access Protocol (IMAP) access in the G Suite admin console. You can enable access for everyone in your account or only for users in specific organizational units.
You can enable access for everyone in your account or only for users in specific organizational units.
If you uncheck the box, POP and IMAP using modern security standards is enabled for your users, but IMAP for use with less secure apps remains disabled.
Don't see this tab? Make sure IMAP is enabled for your domain.
Choose a second verification step
When you set up 2-Step Verification, you can choose your second verification step:
Most of the time, you’ll only have to enter an App Password once per app or device, so don’t worry about memorizing it.
You might need to provide the following details:
Your Account information
Full name or display name: This is how your name appears when you send email
Your G Suite account details: Your username and password
Incoming mail settings
Server: imap.gmail.com
Require SSL: Yes
Port: 993
Outgoing mail
Server: smtp.gmail.com
Require SSL: Yes
Require TLS: Yes
Require authentication: Yes
Port for SSL: 465
Port for TLS/STARTTLS: 587
Source: https://support.google.com/a/answer/105694?authuser=1