Get IMAP Mail Messages/Gmail Login not working

I’m trying to login to Gmail by using “Get IMAP Mail Messages” activity. I have configured all the necessary properties, gave the right credentials. while debugging I’m getting following error “Invalid Credentials”.

Any help is appreciated.

Hi @GANGA_REDDY1

Please check the below threads

Regards

Hi @GANGA_REDDY1

How you passed the credentials of username and password to the Get IMAP activity.

You have to pass the password in the secure password field. This field will accept only secure string datatype format variable.

Hope it helps!!

I have passed the password with the help of password property field. I’m not aware of using SecurePassword field. Could you please explain me how to use it.

May I know how you are storing the password in any assign activity or using any get credentials activity to get the credentials from the orchestrator assets @GANGA_REDDY1

I’m directly hardcoding it.

Don’t hardcode the value take an assign activity and create a variable with the System.Secure string datatype, let’s call the variable name as SecurePassword. In the value field of assign activity

- Assign -> SecurePassword = New System.net.networkcredential("","Give your password here").SecurePassword

Pass the SecurePassword variable in the SecurePassword field in the properties.

Hope you understand!!

Hi @GANGA_REDDY1

  1. Go to Manage your google account
    image

  2. Search App Password

  3. Give any Name for create Password (I’m giving MailPass)

  4. After Click on Create you will get the password

**NOTE: **
1. USE THIS GENERATED PASSWORD FOR GMAIL PASSWORD in IMAP
2. If you not found App Password, then first ON 2 Step Verification on your account then try above steps.

Hope it will helps you :slight_smile:
Cheers

1 Like