Skip to content

Gmail

Reference


Gmail is a widely used email service by Google, offering free and feature-rich communication, organization, and storage capabilities accessible through web browsers and mobile apps.

Categories: [communication]

Version: 1


Connections

Version: 1

OAuth2 Authorization Code

Properties

NameTypeControl TypeDescription
Client IdSTRINGTEXT
Client SecretSTRINGTEXT

Triggers

New Email

Triggers when new mail is found in your Gmail inbox.

Type: STATIC_WEBHOOK

Properties

NameTypeControl TypeDescription
Topic nameSTRINGTEXTMust be 3-255 characters, start with a letter, and contain only the following characters:
letters, numbers, dashes (-), periods (.), underscores (_), tildes (~), percents (%) or
plus signs (+). Cannot start with goog.

Output

Type: ARRAY

Properties

TypeControl Type
{STRING(id), STRING(threadId), [STRING](labelIds), STRING(snippet), STRING(historyId), NUMBER(internalDate), {STRING(partId), STRING(mimeType), STRING(filename), [{STRING(name), STRING(value)}](headers), {STRING(attachmentId), INTEGER(size), STRING(data)}(body), [](parts)}(payload), INTEGER(sizeEstimate), STRING(raw)}OBJECT_BUILDER

New Email Polling

Periodically checks your Gmail inbox for any new incoming emails.

Type: POLLING

Properties

NameTypeControl TypeDescription
null

Output

Type: ARRAY

Properties

TypeControl Type
{STRING(id), STRING(threadId)}OBJECT_BUILDER

Actions

Get Mail

Get an email from your Gmail account via Id

Properties

NameTypeControl TypeDescription
Message IDSTRINGSELECTThe ID of the message to retrieve.
FormatSTRINGSELECTThe format to return the message in.
Metadata headers[STRING]ARRAY_BUILDERWhen given and format is METADATA, only include headers specified.

Get Thread

Gets the specified thread.

Properties

NameTypeControl TypeDescription
Thread IDSTRINGSELECTThe ID of the thread to retrieve.
FormatSTRINGSELECTThe format to return the message in.
Metadata headers[STRING]ARRAY_BUILDERWhen given and format is METADATA, only include headers specified.

Reply to Email

Send a reply to an email message.

Properties

NameTypeControl TypeDescription
Message IDSTRINGSELECTThe ID of the message to reply to.
To[STRING($email)]ARRAY_BUILDERRecipients email addresses.
Bcc[STRING($email)]ARRAY_BUILDERBcc recipients email addresses.
Cc[STRING($email)]ARRAY_BUILDERCc recipients email addresses.
BodySTRINGTEXTBody text of the email
Attachments[FILE_ENTRY]ARRAY_BUILDERA list of attachments to send with the email.

Output

Type: OBJECT

Properties

TypeControl Type
STRINGTEXT
[STRING]ARRAY_BUILDER
STRINGTEXT

Search Email

Lists the messages in the user’s mailbox.

Properties

NameTypeControl TypeDescription
Max resultsNUMBERNUMBERMaximum number of messages to return.
Page tokenSTRINGTEXTPage token to retrieve a specific page of results in the list.
FromSTRINGTEXTThe address sending the mail
ToSTRINGTEXTThe address receiving the new mail
SubjectSTRINGTEXTWords in the subject line
CategorySTRINGSELECTMessages in a certain category
LabelSTRINGSELECT
Label IDs[STRING]ARRAY_BUILDEROnly return messages with labels that match all of the specified label IDs. Messages in a thread might have labels that other messages in the same thread don’t have.
Include spam trashBOOLEANSELECTInclude messages from SPAM and TRASH in the results.

Output

Type: OBJECT

Properties

TypeControl Type
[{STRING(id), STRING(threadId)}]ARRAY_BUILDER
STRINGTEXT
NUMBERNUMBER

Send Email

Sends the specified message to the recipients in the To, Cc, and Bcc headers.

Properties

NameTypeControl TypeDescription
To[STRING($email)]ARRAY_BUILDERRecipients email addresses.
SubjectSTRINGTEXTSubject of the email.
Bcc[STRING($email)]ARRAY_BUILDERBcc recipients email addresses.
Cc[STRING($email)]ARRAY_BUILDERCc recipients email addresses.
Reply to[STRING($email)]ARRAY_BUILDERReply-to email addresses.
BodySTRINGTEXTBody text of the email
Attachments[FILE_ENTRY]ARRAY_BUILDERA list of attachments to send with the email.

Output

Type: OBJECT

Properties

TypeControl Type
STRINGTEXT
[STRING]ARRAY_BUILDER
STRINGTEXT

Additional instructions


anl-c-google-mail-md

CONNECTION

Setting up OAuth2

Turning on GMail API