Enable sending email/sms from function

Attempting to send emails from a function and hitting the roadblock of not actually being able to. Functionality expected would to not only be able to send emails to individuals, but also to send to user groups