Now to figure out how to send... I usually use msmtp, but I know I've got some python code to send email using Google's API lying around somewhere.
Mischief managed. Just POST the message to https://www.googleapis.com/upload/gmail/v1/users/me/messages/send?uploadType=media with these headers...
Authorization: Bearer <access token>
Content-Length: <message size>
... and you're good to go.
arktos.social is a private Mastodon instance. Contact the administrator to request an account.