The Google Sheets tool lets theDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/vrashmanyu605-eng/Agentic_Sales-Markerting/llms.txt
Use this file to discover all available pages before exploring further.
crm_update_agent persist structured lead data to a spreadsheet at the end of each pipeline run. It authenticates with a service account, then uses the Sheets API v4 to append rows — never overwriting existing data. All connection errors and missing credential failures are returned as strings rather than raised exceptions, so agents can handle failures gracefully.
Source code
google_sheets_tool.py
update_google_sheet()
Appends one or more rows to a Google Sheet using a service account.
Parameters
The ID of the target Google Sheet. Found in the sheet URL:
https://docs.google.com/spreadsheets/d/<spreadsheet_id>/edit.The A1 notation range where data should be appended, e.g.
"Sheet1!A1". The API uses this range to determine the table and appends after the last row with data.A list of rows to write. Each inner list represents one row; each element in the inner list is one cell value. Example:
[["Acme Corp", "Discovery call completed", "Cloud migration", "$50,000", "Schedule demo"]].Return value
On success: a string in the format
On missing credentials:
On API error:
"N cells updated." where N is the number of cells written.On missing credentials:
"Error: credentials.json not found. Please provide Google Cloud service account credentials."On API error:
"Error updating Google Sheet: <exception message>".Authentication
The tool authenticates using a Google Cloud service account key file.| Setting | Value |
|---|---|
| Credentials file | credentials.json (project root) |
| Auth scope | https://www.googleapis.com/auth/spreadsheets |
| API | Google Sheets API v4 |
| Write mode | Append — does not overwrite existing rows |
CRM column layout
Thecrm_update_agent writes the following columns in order when it calls this tool:
| Column | Field | Description |
|---|---|---|
| A | client_name | Company name of the lead |
| B | meeting_summary | Summary of the qualification and research findings |
| C | client_requirements | Key requirements identified during research |
| D | opportunity_value | Estimated deal value |
| E | next_steps | Recommended next actions for the sales team |