A package to automate message generation and sending for seminars from a csv file
Project description
Seminar Message Manager
A Python manager for automatically generating and sending mails, Zulip, Discord or Mattermost messages to announce upcoming seminars, using user-tunable html and markdown templates.
📦 Installation
Use pip to install the package:
pip install seminar-message-manager
💻 Usage
smm date [--seminar_csv csv_file.csv --mail_json mail.json --zulip_json zulip.json --discord_json discord.json --mattermost_json mattermost.json --template_mail template.html --template_zulip template.md --template_discord template.md (--send_mail | -sm) (--send_zulip | -sz) (--send_discord | -sd) (--send_mattermost | -smt) (--send | -s)]
Argument details
-
seminar_csv.csv file that describes the seminar's events following a specific template:date ; location; first_name; last_name; work_name ; work_link yyyy-mm-dd; room ; John ; Doe ; My beautiful article; https://article-link.com
By default, the package will look for
seminar.csvin the root directory. -
datethe date (yyyy-mm-dd) used to select the relevant information from the csv. -
mail_json.json file that described the mail information{ "user" : "mail@mail.com", "password" : "123456789", "smtp_server_domain_name": "smtp.mail.com", "port" : 587, "to" : ["mail_list@mail.com", "myothermail@mail.com"], "subject" : "Upcoming seminar" }
By default, the package will look for
mail.jsonin the root directory. -
zulip_json.json file that describes the information needed by the Zulip bot:{ "config_file": "zuliprc", // API file of the bot "bot_email" : "mylab-bot@mylab.zulipchat.com", "channel" : "Seminars", "topic" : "Upcomming seminar", "old_topic" : "Past seminars" // Topic in {channel} where past bot messages are moved }
By default, the package will look for
zulip.jsonin the root directory. -
discord_json.json file that describes the information needed by the Discord bot:{ "webhook_url": "https://discord.com/api/webhooks/..." }
By default, the package will look for
discord.jsonin the root directory. -
mattermost_json.json file that describes the information needed by the Mattermost bot:{ "webhook_url": "https://mattermost.com/hooks/..." }
By default, the package will look for
mattermost.jsonin the root directory. -
template_mail.html file that constitute the body of the mail (example). Some specific strings, indicated by{}, will be replaced by the package, using the corresponding csv line:{date}{room}{first_name}{last_name}{work_name}{work_link}
By default, the package will look for
announcement.htmlin the./templates/maildirectory. -
template_zulip.md file, similar to html file, see example.By default, the package will look for
announcement.mdin the./templates/zulipdirectory. -
template_discord.md file, similar to html file, see example.By default, the package will look for
announcement.mdin the./templates/discorddirectory. -
template_mattermost.md file, similar to html file, see example.By default, the package will look for
announcement.mdin the./templates/mattermostdirectory. -
--send_mailor-smif used, send message to the relevant mailing list. -
--send_zulipor-szif used, send message to the relevant Zulip topic. -
--send_discordor-sdif used, send message to the relevant Discord channel. -
--send_mattermostor-smtif used, send message to the relevant Mattermost channel. -
--sendor-sif used, send message to the relevant Zulip topic, Discord channel, Mattermost channel and mails.
⚖️ License
Distributed under the GNU GPL 3.0 License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file seminar_message_manager-0.0.5.tar.gz.
File metadata
- Download URL: seminar_message_manager-0.0.5.tar.gz
- Upload date:
- Size: 43.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5701fefbb9163b6644eefe8c95b18a958ba0920187978c10e201a37d723ea766
|
|
| MD5 |
21934a1b5156abc01099f9647a507111
|
|
| BLAKE2b-256 |
f57d40102bb2d7f848ee9c28380f3b77a2b185523240d1b22e4332a1a1a2c6bb
|