GOOGLE WORKSPACE Send email function

The GOOGLE WORKSPACE Send email function in RPA.

Help CentreFunctions & Formulas

This article describes the RPA Google Workspace connector function to send an email via Gmail.

For a full list of available functions, please read GOOGLE WORKSPACE functions.


Description

The Send email function sends an email via the Gmail API. The email must be provided as a base64url-encoded RFC 2822 message. This gives full control over headers, HTML body, and attachments.


Setting it up

{{popups:rpas/add:action=google-workspace-gmail-send}}

Once on a process map:

  1. Navigate to the process where you would like to add the function
  2. Click on the green button’s drop-down (right side of the green button labelled “Process”)
  3. On the menu that appears, click on the “+ Activity” item
  4. From here you can select the GOOGLE WORKSPACE Send email option
  5. Click "Add" once you are done

Input parameters

ParameterRequiredTypeDefaultDescription
ConnectorYesSelect-Select the Google Workspace connector to use
RawYesTextarea-Base64url-encoded RFC 2822 email message including To, Subject, and body
VariableYesText-Variable to store the result

Output variables

VariableTypeDescription
VariableObjectAPI response with id, threadId, and labelIds of the sent message

Errors

  • Invalid message format – the raw message is not valid RFC 2822
  • Insufficient permissions – the app lacks gmail.send scope

Tips

  • The raw field should contain a base64url-encoded email with headers like To:, Subject:, Content-Type:
  • Use Python code or a helper step to construct and encode the RFC 2822 message
  • For simpler email sending, consider using the Send email action in the Messaging category

Related functions

  • List emails – List inbox messages
  • Get email – Read an email by ID
  • Trash email – Delete an email

See it working on your own data

Everything documented here ships with the platform – try the document tools free, or go live in 7 days.