# /// script # dependencies = [ # "resend", # ] # /// import subprocess from pathlib import Path import resend resend.api_key = ( Path("/usr/local/etc/resend_api_key.txt").read_text().strip("\n") ) params: resend.Emails.SendParams = { "from": "Borgmatic ", "to": ["hyperreal@moonshadow.dev"], "subject": "[moonshadow] Error running Borgmatic", "text": "There was an error running your Borgmatic backup on moonshadow. Please investigate.", } email = resend.Emails.send(params) print(email)