This similar code can be used further for certificate generation also.
Visit this and click on the 'Enable the Google Sheets API' to enable sheets API for your account, and get your credentials.json file.
Use the command
sudo -H pip install pipenvand then simply setup pipenv
pipenv installand activate pipenv shell using
pipenv shell mkdir cards
mkdir qrcodesCreate a .env file in the root directory of your project, and add the following variables:
FONT=<FONT-FILE-NAME>
SHEET_ID=<YOUR-GOOGLE-SHEET-ID>
ORG_EMAIL=<ORG-EMAIL>
ORG_NAME=<ORG-NAME>
MJ_APIKEY_PUBLIC=<YOUR-MAILJET-PUBLIC-KEY>
MJ_APIKEY_PRIVATE=<YOUR-MAILJET-PRIVATE-KEY>
SG_APIKEY=<YOUR-SENDGRID-API-KEY>Now simply run:
python idgen.py- Code by Jay Mistry @rossoskull
- Designs by Pranay Agarwal pydesigns