Skip to main content
The AGO Send Email Tool enables agents to send emails during conversations using AWS Simple Email Service (SES).

Overview

Tool Name: ago_send_email This tool allows agents to send emails to users, enabling workflows like sending confirmation emails, documentation, follow-up information, or automated notifications.

Key Features

  • HTML and plain text email support
  • Template-based emails with variables
  • Attachment handling
  • Dynamic content with Jinja2 templates
  • Integration with AWS SES
  • Trigger-based automation support

Prerequisites

AWS SES Requirements

Before using the Send Email tool, you must:
  1. Create an AWS account with SES access
  2. Verify sender identity (email address or domain)
  3. Move out of sandbox for production use
  4. Create IAM credentials with SES permissions

AWS Setup

You need an AWS account with SES (Simple Email Service) configured. Refer to the AWS SES documentation for:
  • Creating an IAM user with ses:SendEmail and ses:SendRawEmail permissions
  • Verifying a sender identity (domain or email address)
  • Moving out of the SES sandbox for production use

AGO Configuration

Configure via Admin Interface

  1. Navigate to SettingsEmail Configuration
  2. Enter your AWS credentials:
    • AWS Access Key ID
    • AWS Secret Access Key
    • AWS Region (e.g., eu-central-1)
  3. Configure email addresses:
    • From Address (must be verified in SES)
    • Reply-To Address (optional)
  4. Enable email sending
  5. Save changes

Configuration Fields


Tool Configuration

Create Email Tool for Agent

  1. Navigate to AI StudioTools
  2. Click Create Tool
  3. Select Send Email as the tool type
  4. Configure the tool settings:
    • Name: Internal identifier (e.g., “send_customer_email”)
    • Display Name: User-facing name (e.g., “Send Email”)
    • Description: What the tool does
    • Prompt: When the agent should use this tool
  5. Define the Input Schema with required fields:
    • to_email: Email address to send to
    • subject: Email subject line
    • body: Email body content (HTML supported)
  6. Click Save

Assign to Agent

  1. Navigate to AI StudioAgents
  2. Select the agent you want to configure
  3. Go to the Tools tab
  4. Add the Send Email tool to the agent’s tool list
  5. Click Save

Input Schema

Standard Fields

Extended Schema Example

For more complex email workflows, add additional input fields:

Email Templates

HTML Template Example

Template Variables


Usage in Conversations

Example Flow

Best Practices for Agents

Include in the agent’s prompt:

Trigger-Based Emails

Send automated emails based on events using triggers.

Creating Email Triggers

  1. Navigate to the Triggers configuration
  2. Click Create Trigger
  3. Select a trigger event (e.g., “Ticket Created”)
  4. Add a Send Email action
  5. Configure the email:
    • To: Use template variables like {{ user.email }}
    • Subject: Include dynamic data like Your support ticket #{{ ticket.id }} has been created
    • Template: Select an email template
  6. Enable the trigger and click Save

Available Trigger Events


Deliverability Best Practices

DNS Configuration

Configure these records for better deliverability:

SPF Record Example

Content Guidelines

  • Clear subject lines: Be specific about email purpose
  • Professional formatting: Use consistent branding
  • Mobile-friendly: Design for mobile viewing
  • Unsubscribe option: Include for marketing emails
  • Avoid spam triggers: No excessive caps, punctuation, or spam words

Troubleshooting

Problem: Tool executes but email never arrives.Solutions:
  1. Verify email sending is enabled in configuration
  2. Check AWS credentials are correct
  3. Verify sender address is verified in SES
  4. Check SES sending statistics for errors
  5. Review AWS CloudWatch logs
Problem: Emails arrive in spam folder.Solutions:
  1. Configure SPF record for your domain
  2. Set up DKIM signing in SES
  3. Consider DMARC policy
  4. Use consistent “From” address
  5. Avoid spam trigger words
Problem: Can only send to verified addresses.Solutions:
  1. Request production access from AWS
  2. Verify recipient addresses for testing
  3. Use SES simulator for development
Problem: Receiving throttling errors from SES.Solutions:
  1. Request sending limit increase from AWS
  2. Implement exponential backoff
  3. Queue emails for batch sending
  4. Monitor sending rate
Problem: Authentication failures with SES.Solutions:
  1. Verify access key and secret
  2. Check IAM permissions
  3. Ensure region matches SES setup
  4. Regenerate credentials if needed

API Reference

Test Email Configuration

To test your email configuration, use the Test Email button in SettingsEmail Configuration. For programmatic access, see: