MarketplaceStudioActivityAPI Activities for Gmail

Create your first automation in just a few minutes.Try Studio Web

API Activities for Gmail

API Activities for Gmail

by Internal Labs

2

Activity

Downloads

43.5k

Petr Jenčo
Posted 6 years ago

Hello Magali, thanks a lot for these activities, they work flawlessly. I am just wanted to ask: Is there any possibility to get not just a body of a mail, but also other mail related info like sender address, date, subject, etc ? I know that gsute activity pack from UIp can do it, but they do not offer such a wide scope of activities like your object does (label manipulation, attachments, and so on)

Magali Philippe
Posted 6 years ago ago

Hi,

The format of the message is as https://developers.google.com/gmail/api/v1/reference/users/messages.

To get different headers, you can loop on message.Payload.Headers and then see each header's name and value (header.name or header.value)

Gehad Abo Harga
Posted 6 years ago

It looks really helpful but if you provided any user guide or instructions for use I would be grateful

Magali Philippe
Posted 6 years ago ago

Hi, here is the user guide:

Every activity should be in a gmail scope.

Gmail Scope

Description:

It handles the authentication into Google account and it is a placeholder for all the other activities in the package

Input arguments:

ID (required):

Can be a Google OAuth 2.0 Id or a Google Service Account Email. To get one, follow this link

Client Secret (mutual exclusive with Certificate Password and Certificate path):

The Client Secret value for case when ID is a Goolge OAuth 2.0 Id

Email address: User's email address. The special value "me" (default) can be used to indicate the authenticated user

Certificate password:(mutual exclusive with Client Secret):

  • password for certificate key

Certificate path (mutual exclusive with Client Secret):

  • local path to the file containing the certificate for the Service Account Key

Timeout:

  • timeout value, in milliseconds

Get mails

Description:

Gets all emails matching the query

Should be placed inside a Gmail Scope activity

Input arguments:

"Query" : Supports the same query format as the Gmail search box. For example, "is:unread". See https://support.google.com/mail/answer/7190?hl=en

"MaxResults": Max number of messages to return. Default is 100

Output arguments:

Result : String array of email ids 

Get Mesage By ID:

Description:

Retrieve a Message by ID.

Should be placed inside a Gmail Scope activity

Input arguments:

Message ID: The ID of the message to be retrieved (for example one result of get mails

Output arguments:

Result : Message

Message body: String for text found in the message body. In case of error (cannot convert to string), will be message.Snippet

Get Attachments:

Description:

Saves all the attachments of a message in a specific folder.

Should be placed inside a Gmail Scope activity

Input arguments:

Message ID: The ID of the message to be retrieved (for example one result of get mails

Output Directory: Where the attachments will be saved

Output arguments:

Saved Files (List of string) : Paths of the saved files

Send Email:

Description:

Sends an email with optional attachments.

Should be placed inside a Gmail Scope activity

Input arguments:

To: Array of email addresses to send to

Subject: Subject of the message

Body: Text of the message

Attachments: Array of paths of the attachments. Video is not supported

Get Labels:

Description:

List the labels in the user's mailbox

Should be placed inside a Gmail Scope activity

Output arguments:

Result : List of labels

Create Label:

Description:

Add a new Label to user's mailbox.

Should be placed inside a Gmail Scope activity

Input arguments:

Label: Name of label to be created

Modify Message Labels:

Description:

Modifies the labels on the specified message.

Should be placed inside a Gmail Scope activity

Input arguments:

Message ID: Of the message to which the labels will be added or removed

Labels to add: List of label IDs to add to the message

Labels to remove: List of label IDs to remove from the message

Publisher

Internal Labs

Visit publisher's page

License & Privacy

License Agreement

Privacy Terms

Technical

Version

1.0.68

Updated

April 4, 2023

Works with

Studio: 21.10 - 22.10

Certification

Silver Certified

Tags

Application

Google Gmail

Support

UiPath Community Support

Resources