27 lines
869 B
Python
Executable File
27 lines
869 B
Python
Executable File
#!/usr/bin/env python3
|
|
import requests
|
|
from datetime import datetime
|
|
|
|
|
|
docstring = """
|
|
This script sends a reminder message via a Discord webhook every month to import the latest bank statements into actual.
|
|
"""
|
|
|
|
DISCORD_WEBHOOK_URL = "https://discord.com/api/webhooks/1461100056580067684/BAxF4ndrugLJX8L6WyUtbzOtqoTR0GyxMWhg6jzkdCy1CC8yLfDb7e5erz_FoMUHmviw"
|
|
|
|
if __name__ == "__main__":
|
|
|
|
actual_link = "https://actual.zainezq.com/"
|
|
halifax_link = "https://www.halifax-online.co.uk/personal/logon/login.jsp"
|
|
|
|
message = f"Reminder to import your latest bank statements into Actual!\n\n"
|
|
message += f"🔗 [Actual App]({actual_link})\n"
|
|
message += f"🔗 [Halifax Online Banking]({halifax_link})\n"
|
|
|
|
payload = {
|
|
"content": message
|
|
}
|
|
|
|
r = requests.post(DISCORD_WEBHOOK_URL, json=payload, timeout=10)
|
|
r.raise_for_status()
|