@Ho, Keith D Thanks for reaching out. The preferred way to send e-mail from within Azure is through an SMTP relay service like the SendGrid Output binding: Azure Functions SendGrid bindings | Microsoft Learn , rather than sending e-mail directly from Azure Functions/ VMs etc
Sending email on Port 25 is unsupported from all Azure Platform-as-a-Service (PaaS) resources, including Azure App Service and Azure Functions and it is blocked with most subscriptions
please review this article for more information: Troubleshoot outbound SMTP connectivity in Azure | Microsoft Learn.
do let me know incase of further queries, I would be happy to assist you.