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 pipenv
and then simply setup pipenv
pipenv install
and activate pipenv shell using
pipenv shell
mkdir cards
mkdir qrcodes
Create 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