Discord bot to embed Piazza posts in the designated server
- PiazzaBot will give you a embeded preview of a Piazza post right on your server!
- Just enter in the link to the post, and PiazzaBot will take care of the rest!
- The bot will auto search for the post that is associated with the class enrolled supplied via environment variable
- This bot also works for several linked post and will output them if valid
To run PiazzaBot locally, do the following:
- First make a virtual environment in python using
python3 -m venv ./env
source ./env/bin/activate
pip3 install -r requirements.txt
-
Export your environment variables as such Rename
.env.template
to.env
and fill in all the fields defined in the file -
Then run the program with
python3 ./connect.py
To run PiazzaBot on services:
- Set all your environment variables
- Deploy!
NOTE 1: Your Piazza account must be enrolled in the class to get the embeded preview, or else it won't work.
NOTE 2: You can directly deploy onto web services that supports the use of Procfile (aka heroku)
NOTE 3: To use your account for all the classes you have access to, simply put CUR_CLASS="*"
as wildcard is supported
A: No, due to piazza-api requiring username and password, as officially they do not provide one. So storing plain text to authenticate is dangerous.
- Python 3
- Piazza-API
- Discord.py
This repository is a fork of piazza_bot by zzulanas all credits to original creator but this version is modified, improved and fixed errors for my personal use. Which can be quickly adapted for others to use.
This project is licensed under MIT - see the LICENSE file for details