https://retellai.com/?utm_source=discord&utm_medium=seo logo
how to send emails based on conversation to differ...
# ❓・ai-evy-support
i
@AI Evy how to send emails based on conversation to different address
a
Thanks for tagging me @incredible_swan_16923. I'll look through relevant sources and get back to you shortly.
### Answer Based on the sources, there are several approaches to send emails with conversation data to different addresses: ## Webhook-Based Email Automation You can set up webhooks to get notified about call status updates [(1) ]() . Once the call has ended, you can use a make.com automation to send an email . This would probably be the easiest way . ## Tool Calling Approach An alternative to using make.com would be to tool call to something like a cloud function (e.g. Digital Ocean Functions, AWS Lambda, etc.) and use an API like Mailgun [(2) ]() . ## Basic Setup Requirements For email integrations using functions, you will need : - A webhook module and a send gmail module - Define your variables in retell - This is a pretty basic setup ## Configuration Options You can configure webhook settings in your agent's privacy & webhook section [(3) ]() . The webhook URL can be set in your agent configuration [(4) ]() :
Copy code
javascript
const agentResponse = await client.agent.update('16b980523634a6dc504898cda492e939', { 
  webhook_url: "<https://webhook-url-here%22>
}) ;
The webhook will receive call events that you can then process to extract conversation data and send to different email addresses based on your business logic.
​ To learn more, see the sources I considered: [[1] Voice info to Email](https://discord.com/channels/1186424376300679209/1376371533827670016) [[2] Discord message from @fyodor2572 on 2024-10-29](https://discord.com/channels/1186424376300679209/1294891368505937952/1300903143940296817) [[3] Step 2: Configure the basic settings](https://docs.retellai.com/build/single-multi-prompt/configure-basic-settings) [[4] Update Agent](https://docs.retellai.com/api-references/update-agent) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.