# User blocks ################################################## # Username should be in ime.prezime@skole.hr format # Password is a cleartext skole.hr LDAP/SSO password # There can be as many user blocks as needed # [[user]] username = "ime.prezime@skole.hr" password = "lozinka" #[[user]] #username = "ime2.prezime2@skole.hr" #password = "lozinka2" # Telegram block ################################################## # Create a bot: https://core.telegram.org/bots#3-how-do-i-create-a-bot # Find a ChatID: https://sean-bradley.medium.com/get-telegram-chat-id-80b575520659 # And: https://api.telegram.org/botYOUR_BOT_TOKEN/getUpdates # [telegram] token = "telegram_bot_token" chatids = [ "chat_id", "chat_id2" ] # Discord block ################################################## # Create a bot: https://discordpy.readthedocs.io/en/stable/discord.html # Find UserIDs: https://www.remote.tools/remote-work/how-to-find-discord-id # Permissions Calculator: https://discordapi.com/permissions.html # Permissions: only "Send Messages" # #[discord] #token = "discord_bot_token" #userids = [ "user_id", "user_id2" ] # Slack block ################################################## # Create a bot: https://slack.com/help/articles/115005265703-Create-a-bot-for-your-workspace # Permissions: only chat:write # #[slack] #token = "xoxb-slack_bot_token" #chatids = [ "chat_id", "chat_id2" ] # Mail/SMTP block ################################################## # Configuration for Gmail: https://support.google.com/a/answer/176600?hl=en # Username, password and from are required. Port 465 uses TLS from the first # byte; any other port uses STARTTLS. # #[mail] #server = "smtp.gmail.com" #port = "587" #username = "user.name@gmail.com" #password = "legacy_app_password" #from = "user.name@gmail.com" #subject = "Nova ocjena iz e-Dnevnika" #to = [ "user.name@gmail.com", "user2.name2@gmail.com" ] # # Optional per-event subjects; missing keys fall back to subject, except # portaldrift, which has its own default. Keys: grade, exam, reading, # finalgrade, nationalexam, examdigest, portaldrift, absence, note. # #[mail.subjects] #exam = "Novi ispit u e-Dnevniku" #examdigest = "Tjedni pregled ispita" # Google Calendar block ################################################## # Exam events only. No Google Cloud setup is needed. Name is the target # calendar. The first run must be interactive, to authorize in a browser; over # SSH the log prints the tunnel command to use. # #[calendar] #name = "Djeca ispiti" # CalDAV block (alternative to Google Calendar; exam events only) ################################################## # Needs no Google account and no interactive first run. url is the full URL of # the calendar collection, not the server root -- Nextcloud shows it under the # calendar's "Copy private link" menu; Radicale uses # http://127.0.0.1:5232///. Use an app-specific password where # the provider supports one. https is required except to loopback. # #[caldav] #url = "https://cloud.example.com/remote.php/dav/calendars/pero/ispiti/" #username = "pero" #password = "app-password" # WhatsApp block ################################################## # If the phone number is provided, it will be used to initiate code linking with # main WhatsApp application. During the sync make sure to leave (and keep) # WhatsApp mobile application open and active. If the phone number is not set, # initial linking requires interactive terminal to display QR link code -- after # the sync, .e-dnevnik.wa.sqlite can be copied to the final location. Phone number # should be in international format with + and country code. # # Userids are either in the format of +XXXYYYYYYY@s.whatsapp.net (phone number # in international format) or in the format of # XXXYYYYYYY-ZZZZZZZZZZ@s.whatsapp.net (Group ID). Groups are actually group # names and will be appended to userids discovery process finds group ID. More # efficient way is to directly use group ID (run bot in debug mode) and append # to userids instead. If bot has permissions to write to configuration file, it # will rewrite config and move group to userids. # #[whatsapp] #phonenumber = "+385XXYYYYYYY" #userids = [ "+385XXYYYYYYY@s.whatsapp.net", "XXXYYYYYYY-ZZZZZZZZZZ@s.whatsapp.net" ] #groups = [ "group1", "group2" ] # Webhook blocks ################################################## # Every alert is POSTed to each endpoint; repeat the block as needed. format is # "json" (default) or "text" (what ntfy expects). headers are sent as they are. # Plain http to a non-loopback host logs a warning: alerts contain grades. # #[[webhook]] #url = "https://ntfy.sh/my-secret-topic" #format = "text" # #[[webhook]] #url = "https://gotify.example.com/message" #headers = { "X-Gotify-Key" = "AbCdEf123" } # Weekly exam digest block ################################################## # One message per user listing next week's exams, sent to all chat messengers # and webhooks. # On by default, even without this block. Day is an English weekday name, hour # is 0-23 in the bot's local time zone (set TZ=Europe/Zagreb in Docker). # #[digest] #enabled = true #day = "sunday" #hour = 18