Note: this script only read/write/update/clear (and so on) stuff, that all it does. Just simple tasks.
Also, You can replace Monobank API code to the bank you're using, or add more if needed.
- Go to Console Google Cloud.
- Go to API's and Services --> Library. Find Google Sheets API and Enable it. Or use direct link.
- Go to Credentials, hit Create New Credentials. Once at "Grant this service account access to project" setting, choose Editor role. Next step is optional.
- After newly created credentials you should see them under Service Accounts. Click on email --> Keys --> Add Key --> Create New Key --> Type: JSON (file will be downloaded)
- Put this file in the same directory where
.py
file is located or useos.path
or use Authorize Requests.
Then:
- Create Google Sheet or use existing.
- In the access settings, choose email that was created earlier in Console Google Cloud.
- Paste code from this repo.
Lines from main.py
SERVICE_ACCOUNT_FILE = 'keys.json'` # Change to the JSON file that was downloaded earlier.
SAMPLE_SPREADSHEET_ID` = 'your spreadsheet id'
# Example: https://docs.google.com/spreadsheets/d/**YOUR_SPREADSHEET_ID**/edit#gid=0