added sendsms interface

This commit is contained in:
2023-10-19 10:23:04 +02:00
parent e25bf72b0b
commit eb0136d4b8
+12
View File
@@ -0,0 +1,12 @@
from .sendmail import sendmail
SMS_GATEWAY_ADDRESS = "swissphone-gateway.com"
def sendsms(phone_number, text):
to_addr = f"{phone_number}@{SMS_GATEWAY_ADDRESS}"
sendmail(to_addr, body=text)