C3 AI Documentation Home

Email Agent

The Email Agent is a specialized Canvas Agent designed to help users compose, edit, and send professional emails. Emails appear in a rich editor on the canvas where users can make direct edits before sending.

Note: The Email Agent is not enabled by default and requires explicit deployment. Additionally, email sending functionality requires Pipedream configuration.

Pipedream configuration (prerequisite)

To enable email sending functionality, you must configure Pipedream integration before deploying the agent. Without Pipedream, the agent can draft and edit emails but cannot send them.

Setup steps

  1. Create Pipedream account: Sign up at https://pipedream.com
  2. Create project: Set up a new project in the Pipedream dashboard
  3. Generate OAuth credentials: Create client ID and client secret for your application
  4. Configure Genai.Pipedream.AuthConfi:
JavaScript
// Set Pipedream client credentials
Genai.Pipedream.AuthConfig.inst().setConfigValue('clientId', 'your-pipedream-client-id');
Genai.Pipedream.AuthConfig.inst().setSecretValue('clientSecret', 'your-pipedream-client-secret');

// Set Pipedream project configuration
Genai.Pipedream.AuthConfig.inst().setConfigValue('projectId', 'your-pipedream-project-id');
Genai.Pipedream.AuthConfig.inst().setConfigValue('projectEnvironment', 'production');

// Optional: Set allowed origins for CORS
Genai.Pipedream.AuthConfig.inst().setConfigValue('allowedOrigins', ['https://your-domain.com']);

Once configured, users can connect their email accounts (Gmail, Outlook, etc.) through Pipedream's connect flow in the UI to send emails.

Email Agent deployment

Deploy the Email Agent by running:

JavaScript
Genai.QuickStart.deployCoreAgents(['CanvasAgent_email']);

After deployment, you can access the Email Agent configuration in your Application C3 AI Console by running:

JavaScript
Genai.Agent.Dynamic.Config.forConfigKey('CanvasAgent_email');

Default tools

The Email Agent uses the canvas_agent_email_toolkit, which includes:

  • Email Create – Creates new email drafts with subject, body, recipients (To, CC, BCC), and sender information
  • Email Update Subject – Modifies the subject line of existing drafts
  • Email Update Body – Revises email content (supports markdown formatting)
  • Email Update Recipients – Manages To, CC, and BCC recipient lists
  • Email Update Sender – Updates sender email address and display name
  • Vertex AI Web Search – Performs web searches to enhance email content with external information

Adding custom tools

You can extend the agent's capabilities with user-defined tools. Follow the process in Create Custom Tools.

Was this page helpful?