Skip to content

Latest commit

 

History

History
16 lines (16 loc) · 1.07 KB

README.md

File metadata and controls

16 lines (16 loc) · 1.07 KB

Google-Sheets-API-Python

This Python script demonstrates how to interact with Google Sheets using the Google Sheets API, enabling seamless data management and manipulation through Python scripts.

Prerequisites

Before utilizing this script, ensure you have the following prerequisites:

  1. Google Account: Create or use an existing Google account.
  2. Google Cloud Platform Project: Set up a project, enable the Google Sheets API, and obtain the credentials.json file.
  3. Python Environment: Install dependencies using pip install gspread oauth2client.

Usage

  1. Credentials: Place credentials.json in the script directory.
  2. Spreadsheet ID: Replace sheet_id with your Google Sheets document ID.
  3. Data Definition: Modify values to match your data.
  4. Worksheet: Specify the worksheet name in new_worksheet_name.
  5. Execution: Run the script to update the worksheet, calculate column sums, and format the header row.

Notes

. Ensure proper permissions for the Google account associated with credentials.json. . Keep credentials.json secure, as it contains sensitive authentication details.